RTEMS 4.10.2Annotated Report
Tue Dec 13 19:19:46 2011
0200b7b8 <IMFS_Set_handlers>:
{
IMFS_jnode_t *node = loc->node_access;
IMFS_fs_info_t *fs_info;
fs_info = loc->mt_entry->fs_info;
switch( node->type ) {
200b7b8: c2 02 00 00 ld [ %o0 ], %g1
)
{
IMFS_jnode_t *node = loc->node_access;
IMFS_fs_info_t *fs_info;
fs_info = loc->mt_entry->fs_info;
200b7bc: c4 02 20 10 ld [ %o0 + 0x10 ], %g2
switch( node->type ) {
200b7c0: c2 00 60 4c ld [ %g1 + 0x4c ], %g1
200b7c4: 80 a0 60 07 cmp %g1, 7
200b7c8: 18 80 00 0a bgu 200b7f0 <IMFS_Set_handlers+0x38> <== NEVER TAKEN
200b7cc: c4 00 a0 34 ld [ %g2 + 0x34 ], %g2
200b7d0: 83 28 60 02 sll %g1, 2, %g1
200b7d4: 07 00 80 2d sethi %hi(0x200b400), %g3
200b7d8: 86 10 e3 98 or %g3, 0x398, %g3 ! 200b798 <IMFS_create_node+0x114>
200b7dc: c2 00 c0 01 ld [ %g3 + %g1 ], %g1
200b7e0: 81 c0 40 00 jmp %g1
200b7e4: 01 00 00 00 nop
case IMFS_DIRECTORY:
loc->handlers = fs_info->directory_handlers;
200b7e8: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
200b7ec: c2 22 20 08 st %g1, [ %o0 + 8 ]
loc->handlers = &IMFS_fifo_handlers;
break;
}
return 0;
}
200b7f0: 81 c3 e0 08 retl
200b7f4: 90 10 20 00 clr %o0
break;
case IMFS_LINEAR_FILE:
loc->handlers = fs_info->memfile_handlers;
break;
case IMFS_MEMORY_FILE:
loc->handlers = fs_info->memfile_handlers;
200b7f8: c2 00 a0 08 ld [ %g2 + 8 ], %g1
200b7fc: c2 22 20 08 st %g1, [ %o0 + 8 ]
loc->handlers = &IMFS_fifo_handlers;
break;
}
return 0;
}
200b800: 81 c3 e0 08 retl
200b804: 90 10 20 00 clr %o0
case IMFS_DEVICE:
loc->handlers = &IMFS_device_handlers;
break;
case IMFS_SYM_LINK:
case IMFS_HARD_LINK:
loc->handlers = &IMFS_link_handlers;
200b808: 03 00 80 76 sethi %hi(0x201d800), %g1
200b80c: 82 10 61 f8 or %g1, 0x1f8, %g1 ! 201d9f8 <IMFS_link_handlers>
200b810: c2 22 20 08 st %g1, [ %o0 + 8 ]
loc->handlers = &IMFS_fifo_handlers;
break;
}
return 0;
}
200b814: 81 c3 e0 08 retl
200b818: 90 10 20 00 clr %o0
break;
case IMFS_MEMORY_FILE:
loc->handlers = fs_info->memfile_handlers;
break;
case IMFS_FIFO:
loc->handlers = &IMFS_fifo_handlers;
200b81c: 03 00 80 76 sethi %hi(0x201d800), %g1
200b820: 82 10 60 b0 or %g1, 0xb0, %g1 ! 201d8b0 <IMFS_fifo_handlers>
200b824: c2 22 20 08 st %g1, [ %o0 + 8 ]
break;
}
return 0;
}
200b828: 81 c3 e0 08 retl
200b82c: 90 10 20 00 clr %o0
switch( node->type ) {
case IMFS_DIRECTORY:
loc->handlers = fs_info->directory_handlers;
break;
case IMFS_DEVICE:
loc->handlers = &IMFS_device_handlers;
200b830: 03 00 80 76 sethi %hi(0x201d800), %g1
200b834: 82 10 61 88 or %g1, 0x188, %g1 ! 201d988 <IMFS_device_handlers>
200b838: c2 22 20 08 st %g1, [ %o0 + 8 ]
loc->handlers = &IMFS_fifo_handlers;
break;
}
return 0;
}
200b83c: 81 c3 e0 08 retl
200b840: 90 10 20 00 clr %o0
0200b5d8 <IMFS_allocate_node>:
IMFS_jnode_t *IMFS_allocate_node(
IMFS_jnode_types_t type,
const char *name,
mode_t mode
)
{
200b5d8: 9d e3 bf 98 save %sp, -104, %sp
struct timeval tv;
/*
* Allocate an IMFS jnode
*/
node = calloc( 1, sizeof( IMFS_jnode_t ) );
200b5dc: 90 10 20 01 mov 1, %o0
200b5e0: 7f ff dd 20 call 2002a60 <calloc>
200b5e4: 92 10 20 68 mov 0x68, %o1
if ( !node )
200b5e8: a0 92 20 00 orcc %o0, 0, %l0
200b5ec: 02 80 00 14 be 200b63c <IMFS_allocate_node+0x64> <== NEVER TAKEN
200b5f0: 82 10 20 01 mov 1, %g1
/*
* Fill in the basic information
*/
node->st_nlink = 1;
node->type = type;
strncpy( node->name, name, IMFS_NAME_MAX );
200b5f4: 92 10 00 19 mov %i1, %o1
return NULL;
/*
* Fill in the basic information
*/
node->st_nlink = 1;
200b5f8: c2 34 20 34 sth %g1, [ %l0 + 0x34 ]
node->type = type;
strncpy( node->name, name, IMFS_NAME_MAX );
200b5fc: 94 10 20 20 mov 0x20, %o2
/*
* Fill in the basic information
*/
node->st_nlink = 1;
node->type = type;
200b600: f0 24 20 4c st %i0, [ %l0 + 0x4c ]
strncpy( node->name, name, IMFS_NAME_MAX );
200b604: 40 00 1d 00 call 2012a04 <strncpy>
200b608: 90 04 20 0c add %l0, 0xc, %o0
/*
* Fill in the mode and permission information for the jnode structure.
*/
node->st_mode = mode;
#if defined(RTEMS_POSIX_API)
node->st_uid = geteuid();
200b60c: 40 00 05 4b call 200cb38 <geteuid>
200b610: f4 24 20 30 st %i2, [ %l0 + 0x30 ]
node->st_gid = getegid();
200b614: 40 00 05 45 call 200cb28 <getegid>
200b618: d0 34 20 3c sth %o0, [ %l0 + 0x3c ]
#endif
/*
* Now set all the times.
*/
gettimeofday( &tv, 0 );
200b61c: 92 10 20 00 clr %o1
* Fill in the mode and permission information for the jnode structure.
*/
node->st_mode = mode;
#if defined(RTEMS_POSIX_API)
node->st_uid = geteuid();
node->st_gid = getegid();
200b620: d0 34 20 3e sth %o0, [ %l0 + 0x3e ]
#endif
/*
* Now set all the times.
*/
gettimeofday( &tv, 0 );
200b624: 7f ff dd dd call 2002d98 <gettimeofday>
200b628: 90 07 bf f8 add %fp, -8, %o0
node->stat_atime = (time_t) tv.tv_sec;
200b62c: c2 07 bf f8 ld [ %fp + -8 ], %g1
node->stat_mtime = (time_t) tv.tv_sec;
node->stat_ctime = (time_t) tv.tv_sec;
200b630: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
/*
* Now set all the times.
*/
gettimeofday( &tv, 0 );
node->stat_atime = (time_t) tv.tv_sec;
200b634: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
node->stat_mtime = (time_t) tv.tv_sec;
200b638: c2 24 20 44 st %g1, [ %l0 + 0x44 ]
node->stat_ctime = (time_t) tv.tv_sec;
return node;
}
200b63c: 81 c7 e0 08 ret
200b640: 91 e8 00 10 restore %g0, %l0, %o0
0200b550 <IMFS_chown>:
int IMFS_chown(
rtems_filesystem_location_info_t *pathloc, /* IN */
uid_t owner, /* IN */
gid_t group /* IN */
)
{
200b550: 9d e3 bf 98 save %sp, -104, %sp
/*
* Verify I am the owner of the node or the super user.
*/
#if defined(RTEMS_POSIX_API)
st_uid = geteuid();
200b554: 40 00 05 79 call 200cb38 <geteuid>
200b558: e0 06 00 00 ld [ %i0 ], %l0
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
200b55c: 91 2a 20 10 sll %o0, 0x10, %o0
200b560: 91 32 20 10 srl %o0, 0x10, %o0
200b564: 80 a2 20 00 cmp %o0, 0
200b568: 32 80 00 0b bne,a 200b594 <IMFS_chown+0x44> <== NEVER TAKEN
200b56c: c2 14 20 3c lduh [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EPERM );
#endif
jnode->st_uid = owner;
200b570: f2 34 20 3c sth %i1, [ %l0 + 0x3c ]
jnode->st_gid = group;
200b574: f4 34 20 3e sth %i2, [ %l0 + 0x3e ]
IMFS_update_ctime( jnode );
200b578: 90 07 bf f8 add %fp, -8, %o0
200b57c: 7f ff de 07 call 2002d98 <gettimeofday>
200b580: 92 10 20 00 clr %o1
200b584: c2 07 bf f8 ld [ %fp + -8 ], %g1
200b588: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
return 0;
}
200b58c: 81 c7 e0 08 ret
200b590: 91 e8 20 00 restore %g0, 0, %o0
*/
#if defined(RTEMS_POSIX_API)
st_uid = geteuid();
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
200b594: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
200b598: 22 bf ff f7 be,a 200b574 <IMFS_chown+0x24> <== NOT EXECUTED
200b59c: f2 34 20 3c sth %i1, [ %l0 + 0x3c ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EPERM );
200b5a0: 40 00 19 17 call 20119fc <__errno> <== NOT EXECUTED
200b5a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200b5a8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
200b5ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200b5b0: 81 c7 e0 08 ret <== NOT EXECUTED
200b5b4: 81 e8 00 00 restore <== NOT EXECUTED
0200b684 <IMFS_create_node>:
IMFS_jnode_types_t type,
const char *name,
mode_t mode,
const IMFS_types_union *info
)
{
200b684: 9d e3 bf a0 save %sp, -96, %sp
IMFS_fs_info_t *fs_info;
/*
* MUST have a parent node to call this routine.
*/
if ( parent_loc == NULL )
200b688: 80 a6 20 00 cmp %i0, 0
200b68c: 12 80 00 04 bne 200b69c <IMFS_create_node+0x18> <== ALWAYS TAKEN
200b690: a0 10 20 00 clr %l0
node->st_ino = ++fs_info->ino_count;
rtems_chain_append( &parent->info.directory.Entries, &node->Node );
return node;
}
200b694: 81 c7 e0 08 ret <== NOT EXECUTED
200b698: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
return NULL;
/*
* Allocate filesystem node and fill in basic information
*/
node = IMFS_allocate_node( type, name, mode & ~rtems_filesystem_umask );
200b69c: 03 00 80 7a sethi %hi(0x201e800), %g1
200b6a0: c2 00 61 80 ld [ %g1 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
200b6a4: 92 10 00 1a mov %i2, %o1
200b6a8: d4 00 60 2c ld [ %g1 + 0x2c ], %o2
200b6ac: 90 10 00 19 mov %i1, %o0
200b6b0: 7f ff ff ca call 200b5d8 <IMFS_allocate_node>
200b6b4: 94 2e c0 0a andn %i3, %o2, %o2
if ( !node )
200b6b8: a0 92 20 00 orcc %o0, 0, %l0
200b6bc: 02 bf ff f6 be 200b694 <IMFS_create_node+0x10> <== NEVER TAKEN
200b6c0: 80 a6 60 07 cmp %i1, 7
return NULL;
/*
* Set the type specific information
*/
switch (type) {
200b6c4: 28 80 00 0a bleu,a 200b6ec <IMFS_create_node+0x68> <== ALWAYS TAKEN
200b6c8: b3 2e 60 02 sll %i1, 2, %i1
case IMFS_FIFO:
node->info.fifo.pipe = NULL;
break;
default:
assert(0);
200b6cc: 11 00 80 75 sethi %hi(0x201d400), %o0 <== NOT EXECUTED
200b6d0: 15 00 80 76 sethi %hi(0x201d800), %o2 <== NOT EXECUTED
200b6d4: 17 00 80 76 sethi %hi(0x201d800), %o3 <== NOT EXECUTED
200b6d8: 90 12 23 d8 or %o0, 0x3d8, %o0 <== NOT EXECUTED
200b6dc: 94 12 a0 30 or %o2, 0x30, %o2 <== NOT EXECUTED
200b6e0: 96 12 e0 28 or %o3, 0x28, %o3 <== NOT EXECUTED
200b6e4: 40 00 04 86 call 200c8fc <__assert_func> <== NOT EXECUTED
200b6e8: 92 10 20 5c mov 0x5c, %o1 <== NOT EXECUTED
return NULL;
/*
* Set the type specific information
*/
switch (type) {
200b6ec: 03 00 80 2d sethi %hi(0x200b400), %g1
200b6f0: 82 10 61 b8 or %g1, 0x1b8, %g1 ! 200b5b8 <IMFS_chown+0x68>
200b6f4: c2 00 40 19 ld [ %g1 + %i1 ], %g1
200b6f8: 81 c0 40 00 jmp %g1
200b6fc: 01 00 00 00 nop
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;
200b700: c2 07 00 00 ld [ %i4 ], %g1
200b704: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
/*
* 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;
200b708: c2 06 20 10 ld [ %i0 + 0x10 ], %g1
}
/*
* This node MUST have a parent, so put it in that directory list.
*/
parent = parent_loc->node_access;
200b70c: d0 06 00 00 ld [ %i0 ], %o0
fs_info = parent_loc->mt_entry->fs_info;
200b710: c4 00 60 34 ld [ %g1 + 0x34 ], %g2
node->Parent = parent;
200b714: d0 24 20 08 st %o0, [ %l0 + 8 ]
node->st_ino = ++fs_info->ino_count;
200b718: c2 00 a0 04 ld [ %g2 + 4 ], %g1
200b71c: 90 02 20 50 add %o0, 0x50, %o0
200b720: 82 00 60 01 inc %g1
200b724: c2 20 a0 04 st %g1, [ %g2 + 4 ]
200b728: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
200b72c: 92 10 00 10 mov %l0, %o1
200b730: 7f ff ee f9 call 2007314 <_Chain_Append>
200b734: b0 10 00 10 mov %l0, %i0
rtems_chain_append( &parent->info.directory.Entries, &node->Node );
return node;
}
200b738: 81 c7 e0 08 ret
200b73c: 81 e8 00 00 restore
node->info.device.major = info->device.major;
node->info.device.minor = info->device.minor;
break;
case IMFS_LINEAR_FILE:
node->info.linearfile.size = 0;
200b740: c0 24 20 50 clr [ %l0 + 0x50 ] <== NOT EXECUTED
200b744: c0 24 20 54 clr [ %l0 + 0x54 ] <== NOT EXECUTED
node->info.linearfile.direct = 0;
200b748: c0 24 20 58 clr [ %l0 + 0x58 ] <== NOT EXECUTED
case IMFS_MEMORY_FILE:
node->info.file.size = 0;
200b74c: c0 24 20 50 clr [ %l0 + 0x50 ]
200b750: c0 24 20 54 clr [ %l0 + 0x54 ]
node->info.file.indirect = 0;
200b754: c0 24 20 58 clr [ %l0 + 0x58 ]
node->info.file.doubly_indirect = 0;
200b758: c0 24 20 5c clr [ %l0 + 0x5c ]
node->info.file.triply_indirect = 0;
break;
200b75c: 10 bf ff eb b 200b708 <IMFS_create_node+0x84>
200b760: c0 24 20 60 clr [ %l0 + 0x60 ]
case IMFS_FIFO:
node->info.fifo.pipe = NULL;
break;
200b764: 10 bf ff e9 b 200b708 <IMFS_create_node+0x84>
200b768: c0 24 20 50 clr [ %l0 + 0x50 ]
node->info.sym_link.name = info->sym_link.name;
break;
case IMFS_DEVICE:
node->info.device.major = info->device.major;
node->info.device.minor = info->device.minor;
200b76c: 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;
200b770: c2 07 00 00 ld [ %i4 ], %g1
node->info.device.minor = info->device.minor;
200b774: c4 24 20 54 st %g2, [ %l0 + 0x54 ]
break;
200b778: 10 bf ff e4 b 200b708 <IMFS_create_node+0x84>
200b77c: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200b780: 82 04 20 54 add %l0, 0x54, %g1
the_chain->permanent_null = NULL;
200b784: c0 24 20 54 clr [ %l0 + 0x54 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200b788: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200b78c: 82 04 20 50 add %l0, 0x50, %g1
200b790: 10 bf ff de b 200b708 <IMFS_create_node+0x84>
200b794: c2 24 20 58 st %g1, [ %l0 + 0x58 ]
0200b644 <IMFS_create_root_node>:
IMFS_jnode_t *IMFS_create_root_node(void)
{
200b644: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node;
/*
* Allocate filesystem node and fill in basic information
*/
node = IMFS_allocate_node( IMFS_DIRECTORY, "", (S_IFDIR | 0755) );
200b648: 90 10 20 01 mov 1, %o0
200b64c: 13 00 80 75 sethi %hi(0x201d400), %o1
200b650: 15 00 00 10 sethi %hi(0x4000), %o2
200b654: 92 12 63 d0 or %o1, 0x3d0, %o1
200b658: 7f ff ff e0 call 200b5d8 <IMFS_allocate_node>
200b65c: 94 12 a1 ed or %o2, 0x1ed, %o2
if ( !node )
200b660: 80 a2 20 00 cmp %o0, 0
200b664: 02 80 00 06 be 200b67c <IMFS_create_root_node+0x38> <== NEVER TAKEN
200b668: 82 02 20 54 add %o0, 0x54, %g1
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
200b66c: c0 22 20 54 clr [ %o0 + 0x54 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200b670: c2 22 20 50 st %g1, [ %o0 + 0x50 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200b674: 82 02 20 50 add %o0, 0x50, %g1
200b678: c2 22 20 58 st %g1, [ %o0 + 0x58 ]
* NOTE: Root node is always a directory.
*/
rtems_chain_initialize_empty(&node->info.directory.Entries);
return node;
}
200b67c: 81 c7 e0 08 ret
200b680: 91 e8 00 08 restore %g0, %o0, %o0
02004b38 <IMFS_dump_directory>:
void IMFS_dump_directory(
IMFS_jnode_t *the_directory,
int level
)
{
2004b38: 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 );
2004b3c: 80 a6 20 00 cmp %i0, 0
2004b40: 02 80 00 2b be 2004bec <IMFS_dump_directory+0xb4> <== NEVER TAKEN
2004b44: 80 a6 60 00 cmp %i1, 0
assert( level >= 0 );
2004b48: 06 80 00 38 bl 2004c28 <IMFS_dump_directory+0xf0> <== NEVER TAKEN
2004b4c: 11 00 80 99 sethi %hi(0x2026400), %o0
assert( the_directory->type == IMFS_DIRECTORY );
2004b50: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
2004b54: 80 a0 60 01 cmp %g1, 1
2004b58: 12 80 00 2d bne 2004c0c <IMFS_dump_directory+0xd4> <== NEVER TAKEN
2004b5c: a8 06 20 54 add %i0, 0x54, %l4
the_chain = &the_directory->info.directory.Entries;
for ( the_node = the_chain->first;
2004b60: e6 06 20 50 ld [ %i0 + 0x50 ], %l3
2004b64: 80 a4 c0 14 cmp %l3, %l4
2004b68: 02 80 00 1b be 2004bd4 <IMFS_dump_directory+0x9c>
2004b6c: 25 00 80 a1 sethi %hi(0x2028400), %l2
2004b70: 23 00 80 99 sethi %hi(0x2026400), %l1
2004b74: a4 14 a0 90 or %l2, 0x90, %l2
the_node = the_node->next ) {
the_jnode = (IMFS_jnode_t *) the_node;
for ( i=0 ; i<=level ; i++ )
fprintf(stdout, "...." );
2004b78: a2 14 61 30 or %l1, 0x130, %l1
IMFS_print_jnode( the_jnode );
if ( the_jnode->type == IMFS_DIRECTORY )
IMFS_dump_directory( the_jnode, level + 1 );
2004b7c: aa 06 60 01 add %i1, 1, %l5
for ( the_node = the_chain->first;
!rtems_chain_is_tail( the_chain, the_node );
the_node = the_node->next ) {
the_jnode = (IMFS_jnode_t *) the_node;
2004b80: a0 10 20 00 clr %l0
for ( i=0 ; i<=level ; i++ )
fprintf(stdout, "...." );
2004b84: c2 04 80 00 ld [ %l2 ], %g1
2004b88: 90 10 00 11 mov %l1, %o0
2004b8c: d6 00 60 08 ld [ %g1 + 8 ], %o3
2004b90: 92 10 20 01 mov 1, %o1
2004b94: 40 00 49 5c call 2017104 <fwrite>
2004b98: 94 10 20 04 mov 4, %o2
!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++ )
2004b9c: a0 04 20 01 inc %l0
2004ba0: 80 a6 40 10 cmp %i1, %l0
2004ba4: 36 bf ff f9 bge,a 2004b88 <IMFS_dump_directory+0x50>
2004ba8: c2 04 80 00 ld [ %l2 ], %g1
fprintf(stdout, "...." );
IMFS_print_jnode( the_jnode );
2004bac: 7f ff ff 7d call 20049a0 <IMFS_print_jnode>
2004bb0: 90 10 00 13 mov %l3, %o0
if ( the_jnode->type == IMFS_DIRECTORY )
2004bb4: c2 04 e0 4c ld [ %l3 + 0x4c ], %g1
2004bb8: 80 a0 60 01 cmp %g1, 1
2004bbc: 22 80 00 08 be,a 2004bdc <IMFS_dump_directory+0xa4>
2004bc0: 90 10 00 13 mov %l3, %o0
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 ) {
2004bc4: e6 04 c0 00 ld [ %l3 ], %l3
assert( the_directory->type == IMFS_DIRECTORY );
the_chain = &the_directory->info.directory.Entries;
for ( the_node = the_chain->first;
2004bc8: 80 a4 c0 14 cmp %l3, %l4
2004bcc: 12 bf ff ee bne 2004b84 <IMFS_dump_directory+0x4c>
2004bd0: a0 10 20 00 clr %l0
2004bd4: 81 c7 e0 08 ret
2004bd8: 81 e8 00 00 restore
for ( i=0 ; i<=level ; i++ )
fprintf(stdout, "...." );
IMFS_print_jnode( the_jnode );
if ( the_jnode->type == IMFS_DIRECTORY )
IMFS_dump_directory( the_jnode, level + 1 );
2004bdc: 7f ff ff d7 call 2004b38 <IMFS_dump_directory>
2004be0: 92 10 00 15 mov %l5, %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 ) {
2004be4: 10 bf ff f9 b 2004bc8 <IMFS_dump_directory+0x90>
2004be8: e6 04 c0 00 ld [ %l3 ], %l3
rtems_chain_node *the_node;
rtems_chain_control *the_chain;
IMFS_jnode_t *the_jnode;
int i;
assert( the_directory );
2004bec: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
2004bf0: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED
2004bf4: 17 00 80 99 sethi %hi(0x2026400), %o3 <== NOT EXECUTED
2004bf8: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
2004bfc: 94 12 a1 f8 or %o2, 0x1f8, %o2 <== NOT EXECUTED
2004c00: 96 12 e0 e8 or %o3, 0xe8, %o3 <== NOT EXECUTED
2004c04: 40 00 02 3a call 20054ec <__assert_func> <== NOT EXECUTED
2004c08: 92 10 20 84 mov 0x84, %o1 <== NOT EXECUTED
assert( level >= 0 );
assert( the_directory->type == IMFS_DIRECTORY );
2004c0c: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED
2004c10: 17 00 80 99 sethi %hi(0x2026400), %o3 <== NOT EXECUTED
2004c14: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
2004c18: 94 12 a1 f8 or %o2, 0x1f8, %o2 <== NOT EXECUTED
2004c1c: 96 12 e1 08 or %o3, 0x108, %o3 <== NOT EXECUTED
2004c20: 40 00 02 33 call 20054ec <__assert_func> <== NOT EXECUTED
2004c24: 92 10 20 88 mov 0x88, %o1 <== NOT EXECUTED
IMFS_jnode_t *the_jnode;
int i;
assert( the_directory );
assert( level >= 0 );
2004c28: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED
2004c2c: 17 00 80 99 sethi %hi(0x2026400), %o3 <== NOT EXECUTED
2004c30: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
2004c34: 94 12 a1 f8 or %o2, 0x1f8, %o2 <== NOT EXECUTED
2004c38: 96 12 e0 f8 or %o3, 0xf8, %o3 <== NOT EXECUTED
2004c3c: 40 00 02 2c call 20054ec <__assert_func> <== NOT EXECUTED
2004c40: 92 10 20 86 mov 0x86, %o1 <== NOT EXECUTED
0200b9e8 <IMFS_eval_path>:
const char *pathname, /* IN */
size_t pathnamelen, /* IN */
int flags, /* IN */
rtems_filesystem_location_info_t *pathloc /* IN/OUT */
)
{
200b9e8: 9d e3 bf 78 save %sp, -136, %sp
IMFS_token_types type = IMFS_CURRENT_DIR;
char token[ IMFS_NAME_MAX + 1 ];
IMFS_jnode_t *node;
int result;
if ( !rtems_libio_is_valid_perms( flags ) ) {
200b9ec: 80 8e bf f8 btst -8, %i2
200b9f0: 12 80 00 ee bne 200bda8 <IMFS_eval_path+0x3c0> <== NEVER TAKEN
200b9f4: a0 10 00 18 mov %i0, %l0
/*
* This was filled in by the caller and is valid in the
* mount table.
*/
node = pathloc->node_access;
200b9f8: e4 06 c0 00 ld [ %i3 ], %l2
case IMFS_UP_DIR:
/*
* Am I at the root of all filesystems? (chroot'ed?)
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access )
200b9fc: 2b 00 80 7a sethi %hi(0x201e800), %l5
/*
* This was filled in by the caller and is valid in the
* mount table.
*/
node = pathloc->node_access;
200ba00: a2 10 20 00 clr %l1
case IMFS_UP_DIR:
/*
* Am I at the root of all filesystems? (chroot'ed?)
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access )
200ba04: aa 15 61 80 or %l5, 0x180, %l5
200ba08: a6 07 bf d8 add %fp, -40, %l3
200ba0c: a8 07 bf fc add %fp, -4, %l4
* 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 );
200ba10: 90 04 00 11 add %l0, %l1, %o0
200ba14: 92 10 00 19 mov %i1, %o1
200ba18: 94 10 00 13 mov %l3, %o2
200ba1c: 40 00 03 15 call 200c670 <IMFS_get_token>
200ba20: 96 10 00 14 mov %l4, %o3
pathnamelen -= len;
i += len;
if ( !pathloc->node_access )
200ba24: 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 );
200ba28: ac 10 00 08 mov %o0, %l6
pathnamelen -= len;
i += len;
if ( !pathloc->node_access )
200ba2c: 80 a0 60 00 cmp %g1, 0
200ba30: 02 80 00 87 be 200bc4c <IMFS_eval_path+0x264> <== NEVER TAKEN
200ba34: c4 07 bf fc ld [ %fp + -4 ], %g2
while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
type = IMFS_get_token( &pathname[i], pathnamelen, token, &len );
pathnamelen -= len;
i += len;
200ba38: a2 04 40 02 add %l1, %g2, %l1
rtems_set_errno_and_return_minus_one( ENOENT );
/*
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
200ba3c: 80 a2 20 00 cmp %o0, 0
200ba40: 12 80 00 11 bne 200ba84 <IMFS_eval_path+0x9c>
200ba44: b2 26 40 02 sub %i1, %g2, %i1
* 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 ) {
200ba48: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
200ba4c: 80 a0 a0 01 cmp %g2, 1
200ba50: 22 80 00 85 be,a 200bc64 <IMFS_eval_path+0x27c>
200ba54: c4 00 60 5c ld [ %g1 + 0x5c ], %g2
flags, pathloc );
} else {
result = IMFS_Set_handlers( pathloc );
}
} else {
result = IMFS_Set_handlers( pathloc );
200ba58: 7f ff ff 58 call 200b7b8 <IMFS_Set_handlers>
200ba5c: 90 10 00 1b mov %i3, %o0
/*
* Verify we have the correct permissions for this node.
*/
if ( !IMFS_evaluate_permission( pathloc, flags ) )
200ba60: 92 10 00 1a mov %i2, %o1
flags, pathloc );
} else {
result = IMFS_Set_handlers( pathloc );
}
} else {
result = IMFS_Set_handlers( pathloc );
200ba64: b0 10 00 08 mov %o0, %i0
/*
* Verify we have the correct permissions for this node.
*/
if ( !IMFS_evaluate_permission( pathloc, flags ) )
200ba68: 7f ff ff 77 call 200b844 <IMFS_evaluate_permission>
200ba6c: 90 10 00 1b mov %i3, %o0
200ba70: 80 a2 20 00 cmp %o0, 0
200ba74: 02 80 00 98 be 200bcd4 <IMFS_eval_path+0x2ec>
200ba78: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EACCES );
return result;
}
200ba7c: 81 c7 e0 08 ret
200ba80: 81 e8 00 00 restore
/*
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
200ba84: c4 04 a0 4c ld [ %l2 + 0x4c ], %g2
200ba88: 80 a0 a0 01 cmp %g2, 1
200ba8c: 02 80 00 60 be 200bc0c <IMFS_eval_path+0x224>
200ba90: 90 10 00 1b mov %i3, %o0
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
rtems_set_errno_and_return_minus_one( EACCES );
node = pathloc->node_access;
switch( type ) {
200ba94: 80 a5 a0 03 cmp %l6, 3
200ba98: 02 80 00 0b be 200bac4 <IMFS_eval_path+0xdc>
200ba9c: a4 10 00 01 mov %g1, %l2
200baa0: 80 a5 a0 04 cmp %l6, 4
200baa4: 02 80 00 2f be 200bb60 <IMFS_eval_path+0x178>
200baa8: 80 a5 a0 02 cmp %l6, 2
200baac: 02 80 00 1a be 200bb14 <IMFS_eval_path+0x12c>
200bab0: 80 a5 a0 04 cmp %l6, 4
/*
* Evaluate all tokens until we are done or an error occurs.
*/
while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
200bab4: 12 bf ff d8 bne 200ba14 <IMFS_eval_path+0x2c> <== ALWAYS TAKEN
200bab8: 90 04 00 11 add %l0, %l1, %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 ) {
200babc: 10 bf ff e4 b 200ba4c <IMFS_eval_path+0x64> <== NOT EXECUTED
200bac0: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 <== NOT EXECUTED
case IMFS_NAME:
/*
* If we are at a link follow it.
*/
if ( node->type == IMFS_HARD_LINK ) {
200bac4: c2 00 60 4c ld [ %g1 + 0x4c ], %g1
200bac8: 80 a0 60 03 cmp %g1, 3
200bacc: 02 80 00 57 be 200bc28 <IMFS_eval_path+0x240>
200bad0: 80 a0 60 04 cmp %g1, 4
node = pathloc->node_access;
if ( !node )
rtems_set_errno_and_return_minus_one( ENOTDIR );
} else if ( node->type == IMFS_SYM_LINK ) {
200bad4: 02 80 00 99 be 200bd38 <IMFS_eval_path+0x350>
200bad8: 90 10 00 1b mov %i3, %o0
/*
* Only a directory can be decended into.
*/
if ( node->type != IMFS_DIRECTORY )
200badc: 80 a0 60 01 cmp %g1, 1
200bae0: 12 80 00 77 bne 200bcbc <IMFS_eval_path+0x2d4>
200bae4: 90 10 00 12 mov %l2, %o0
/*
* Find the token name in the current node.
*/
node = IMFS_find_match_in_dir( node, token );
200bae8: 40 00 02 b1 call 200c5ac <IMFS_find_match_in_dir>
200baec: 92 10 00 13 mov %l3, %o1
if ( !node )
200baf0: a4 92 20 00 orcc %o0, 0, %l2
200baf4: 02 80 00 56 be 200bc4c <IMFS_eval_path+0x264>
200baf8: 01 00 00 00 nop
* file system and not the IMFS. For example the IMFS length is
* limited. If the token is a parent directory move back up otherwise
* set loc to the new fs root node and let them finish evaluating the
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
200bafc: c2 04 a0 4c ld [ %l2 + 0x4c ], %g1
200bb00: 80 a0 60 01 cmp %g1, 1
200bb04: 22 80 00 1d be,a 200bb78 <IMFS_eval_path+0x190>
200bb08: c2 04 a0 5c ld [ %l2 + 0x5c ], %g1
/*
* Set the node access to the point we have found.
*/
pathloc->node_access = node;
break;
200bb0c: 10 bf ff c1 b 200ba10 <IMFS_eval_path+0x28>
200bb10: e4 26 c0 00 st %l2, [ %i3 ]
case IMFS_UP_DIR:
/*
* Am I at the root of all filesystems? (chroot'ed?)
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access )
200bb14: c4 05 40 00 ld [ %l5 ], %g2
200bb18: c4 00 a0 18 ld [ %g2 + 0x18 ], %g2
200bb1c: 80 a0 80 01 cmp %g2, %g1
200bb20: 02 bf ff bd be 200ba14 <IMFS_eval_path+0x2c>
200bb24: 90 04 00 11 add %l0, %l1, %o0
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
pathloc->mt_entry->mt_fs_root.node_access) {
200bb28: d2 06 e0 10 ld [ %i3 + 0x10 ], %o1
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
200bb2c: c4 02 60 1c ld [ %o1 + 0x1c ], %g2
200bb30: 80 a0 80 01 cmp %g2, %g1
200bb34: 02 80 00 8f be 200bd70 <IMFS_eval_path+0x388>
200bb38: 92 02 60 08 add %o1, 8, %o1
return (*pathloc->ops->evalpath_h)(&(pathname[i-len]),
pathnamelen+len,
flags,pathloc);
}
} else {
if ( !node->Parent )
200bb3c: e4 00 60 08 ld [ %g1 + 8 ], %l2
200bb40: 80 a4 a0 00 cmp %l2, 0
200bb44: 32 bf ff b4 bne,a 200ba14 <IMFS_eval_path+0x2c>
200bb48: e4 26 c0 00 st %l2, [ %i3 ]
rtems_set_errno_and_return_minus_one( ENOENT );
200bb4c: 40 00 17 ac call 20119fc <__errno>
200bb50: b0 10 3f ff mov -1, %i0
200bb54: ec 22 00 00 st %l6, [ %o0 ]
200bb58: 81 c7 e0 08 ret
200bb5c: 81 e8 00 00 restore
case IMFS_NO_MORE_PATH:
case IMFS_CURRENT_DIR:
break;
case IMFS_INVALID_TOKEN:
rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
200bb60: 40 00 17 a7 call 20119fc <__errno>
200bb64: b0 10 3f ff mov -1, %i0
200bb68: 82 10 20 5b mov 0x5b, %g1
200bb6c: c2 22 00 00 st %g1, [ %o0 ]
200bb70: 81 c7 e0 08 ret
200bb74: 81 e8 00 00 restore
* file system and not the IMFS. For example the IMFS length is
* limited. If the token is a parent directory move back up otherwise
* set loc to the new fs root node and let them finish evaluating the
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
200bb78: 80 a0 60 00 cmp %g1, 0
200bb7c: 02 bf ff e4 be 200bb0c <IMFS_eval_path+0x124>
200bb80: ac 04 00 11 add %l0, %l1, %l6
const char *path, /* IN */
size_t *len, /* IN/OUT */
int *index /* IN/OUT */
)
{
while ( IMFS_is_separator( path[*index] ) && path[*index] && *len ) {
200bb84: d0 4d 80 00 ldsb [ %l6 ], %o0
200bb88: 7f ff e0 9b call 2003df4 <rtems_filesystem_is_separator>
200bb8c: b0 10 00 16 mov %l6, %i0
200bb90: 80 a2 20 00 cmp %o0, 0
200bb94: 22 80 00 11 be,a 200bbd8 <IMFS_eval_path+0x1f0> <== NEVER TAKEN
200bb98: c2 0d 80 00 ldub [ %l6 ], %g1 <== NOT EXECUTED
200bb9c: c2 0d 80 00 ldub [ %l6 ], %g1
200bba0: 83 28 60 18 sll %g1, 0x18, %g1
200bba4: 80 a0 60 00 cmp %g1, 0
200bba8: 02 80 00 51 be 200bcec <IMFS_eval_path+0x304>
200bbac: 80 a6 60 00 cmp %i1, 0
200bbb0: 02 80 00 0b be 200bbdc <IMFS_eval_path+0x1f4> <== NEVER TAKEN
200bbb4: ac 05 a0 01 inc %l6
200bbb8: d0 4d 80 00 ldsb [ %l6 ], %o0
200bbbc: 7f ff e0 8e call 2003df4 <rtems_filesystem_is_separator>
200bbc0: a2 04 60 01 inc %l1
++(*index);
--(*len);
200bbc4: b2 06 7f ff add %i1, -1, %i1
const char *path, /* IN */
size_t *len, /* IN/OUT */
int *index /* IN/OUT */
)
{
while ( IMFS_is_separator( path[*index] ) && path[*index] && *len ) {
200bbc8: 80 a2 20 00 cmp %o0, 0
200bbcc: 12 bf ff f4 bne 200bb9c <IMFS_eval_path+0x1b4>
200bbd0: b0 10 00 16 mov %l6, %i0
200bbd4: c2 0d 80 00 ldub [ %l6 ], %g1
200bbd8: 83 28 60 18 sll %g1, 0x18, %g1
* set loc to the new fs root node and let them finish evaluating the
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
200bbdc: 83 38 60 18 sra %g1, 0x18, %g1
200bbe0: 80 a0 60 2e cmp %g1, 0x2e
200bbe4: 12 80 00 42 bne 200bcec <IMFS_eval_path+0x304>
200bbe8: 82 04 00 11 add %l0, %l1, %g1
200bbec: c2 48 60 01 ldsb [ %g1 + 1 ], %g1
200bbf0: 80 a0 60 2e cmp %g1, 0x2e
200bbf4: 12 80 00 3e bne 200bcec <IMFS_eval_path+0x304>
200bbf8: a2 04 60 02 add %l1, 2, %l1
pathnamelen,
flags, pathloc );
}
i += 2;
pathnamelen -= 2;
node = node->Parent;
200bbfc: e4 04 a0 08 ld [ %l2 + 8 ], %l2
return (*pathloc->ops->evalpath_h)( &pathname[i],
pathnamelen,
flags, pathloc );
}
i += 2;
pathnamelen -= 2;
200bc00: b2 06 7f fe add %i1, -2, %i1
/*
* Set the node access to the point we have found.
*/
pathloc->node_access = node;
200bc04: 10 bf ff 83 b 200ba10 <IMFS_eval_path+0x28>
200bc08: e4 26 c0 00 st %l2, [ %i3 ]
/*
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
200bc0c: 7f ff ff 0e call 200b844 <IMFS_evaluate_permission>
200bc10: 92 10 20 01 mov 1, %o1
200bc14: 80 a2 20 00 cmp %o0, 0
200bc18: 02 80 00 50 be 200bd58 <IMFS_eval_path+0x370>
200bc1c: 01 00 00 00 nop
200bc20: 10 bf ff 9d b 200ba94 <IMFS_eval_path+0xac>
200bc24: c2 06 c0 00 ld [ %i3 ], %g1
* If we are at a link follow it.
*/
if ( node->type == IMFS_HARD_LINK ) {
IMFS_evaluate_hard_link( pathloc, 0 );
200bc28: 90 10 00 1b mov %i3, %o0
200bc2c: 7f ff ff 27 call 200b8c8 <IMFS_evaluate_hard_link>
200bc30: 92 10 20 00 clr %o1
node = pathloc->node_access;
200bc34: e4 06 c0 00 ld [ %i3 ], %l2
if ( !node )
200bc38: 80 a4 a0 00 cmp %l2, 0
200bc3c: 02 80 00 20 be 200bcbc <IMFS_eval_path+0x2d4> <== NEVER TAKEN
200bc40: 01 00 00 00 nop
} else if ( node->type == IMFS_SYM_LINK ) {
result = IMFS_evaluate_sym_link( pathloc, 0 );
node = pathloc->node_access;
200bc44: 10 bf ff a6 b 200badc <IMFS_eval_path+0xf4>
200bc48: c2 04 a0 4c ld [ %l2 + 0x4c ], %g1
*/
node = IMFS_find_match_in_dir( node, token );
if ( !node )
rtems_set_errno_and_return_minus_one( ENOENT );
200bc4c: 40 00 17 6c call 20119fc <__errno>
200bc50: b0 10 3f ff mov -1, %i0
200bc54: 82 10 20 02 mov 2, %g1
200bc58: c2 22 00 00 st %g1, [ %o0 ]
200bc5c: 81 c7 e0 08 ret
200bc60: 81 e8 00 00 restore
*
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
200bc64: 80 a0 a0 00 cmp %g2, 0
200bc68: 02 bf ff 7c be 200ba58 <IMFS_eval_path+0x70> <== ALWAYS TAKEN
200bc6c: c2 07 bf fc ld [ %fp + -4 ], %g1
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bc70: c6 00 a0 1c ld [ %g2 + 0x1c ], %g3 <== NOT EXECUTED
200bc74: c6 26 c0 00 st %g3, [ %i3 ] <== NOT EXECUTED
200bc78: c6 00 a0 20 ld [ %g2 + 0x20 ], %g3 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bc7c: 92 06 40 01 add %i1, %g1, %o1 <== NOT EXECUTED
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bc80: c6 26 e0 04 st %g3, [ %i3 + 4 ] <== NOT EXECUTED
200bc84: c6 00 a0 24 ld [ %g2 + 0x24 ], %g3 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bc88: 90 24 40 01 sub %l1, %g1, %o0 <== NOT EXECUTED
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bc8c: c6 26 e0 08 st %g3, [ %i3 + 8 ] <== NOT EXECUTED
200bc90: c2 00 a0 28 ld [ %g2 + 0x28 ], %g1 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bc94: 90 04 00 08 add %l0, %o0, %o0 <== NOT EXECUTED
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bc98: c2 26 e0 0c st %g1, [ %i3 + 0xc ] <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bc9c: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bca0: c4 00 a0 2c ld [ %g2 + 0x2c ], %g2 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bca4: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
* NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
if ( node->type == IMFS_DIRECTORY ) {
if ( node->info.directory.mt_fs != NULL ) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bca8: c4 26 e0 10 st %g2, [ %i3 + 0x10 ] <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
200bcac: 9f c0 40 00 call %g1 <== NOT EXECUTED
200bcb0: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
200bcb4: 81 c7 e0 08 ret <== NOT EXECUTED
200bcb8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
/*
* Only a directory can be decended into.
*/
if ( node->type != IMFS_DIRECTORY )
rtems_set_errno_and_return_minus_one( ENOTDIR );
200bcbc: 40 00 17 50 call 20119fc <__errno>
200bcc0: b0 10 3f ff mov -1, %i0
200bcc4: 82 10 20 14 mov 0x14, %g1
200bcc8: c2 22 00 00 st %g1, [ %o0 ]
200bccc: 81 c7 e0 08 ret
200bcd0: 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 );
200bcd4: 40 00 17 4a call 20119fc <__errno>
200bcd8: b0 10 3f ff mov -1, %i0
200bcdc: 82 10 20 0d mov 0xd, %g1
200bce0: c2 22 00 00 st %g1, [ %o0 ]
return result;
}
200bce4: 81 c7 e0 08 ret
200bce8: 81 e8 00 00 restore
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bcec: c4 04 a0 5c ld [ %l2 + 0x5c ], %g2
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bcf0: 90 10 00 18 mov %i0, %o0
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bcf4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bcf8: 92 10 00 19 mov %i1, %o1
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bcfc: c2 26 c0 00 st %g1, [ %i3 ]
200bd00: c2 00 a0 20 ld [ %g2 + 0x20 ], %g1
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bd04: 94 10 00 1a mov %i2, %o2
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bd08: c2 26 e0 04 st %g1, [ %i3 + 4 ]
200bd0c: c2 00 a0 24 ld [ %g2 + 0x24 ], %g1
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bd10: 96 10 00 1b mov %i3, %o3
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bd14: c2 26 e0 08 st %g1, [ %i3 + 8 ]
200bd18: c2 00 a0 28 ld [ %g2 + 0x28 ], %g1
200bd1c: c2 26 e0 0c st %g1, [ %i3 + 0xc ]
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bd20: c2 00 40 00 ld [ %g1 ], %g1
* path.
*/
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( pathname, &pathnamelen, &i);
if ((pathname[i] != '.') || (pathname[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200bd24: c4 00 a0 2c ld [ %g2 + 0x2c ], %g2
return (*pathloc->ops->evalpath_h)( &pathname[i],
200bd28: 9f c0 40 00 call %g1
200bd2c: c4 26 e0 10 st %g2, [ %i3 + 0x10 ]
200bd30: 81 c7 e0 08 ret
200bd34: 91 e8 00 08 restore %g0, %o0, %o0
if ( !node )
rtems_set_errno_and_return_minus_one( ENOTDIR );
} else if ( node->type == IMFS_SYM_LINK ) {
result = IMFS_evaluate_sym_link( pathloc, 0 );
200bd38: 7f ff fe ff call 200b934 <IMFS_evaluate_sym_link>
200bd3c: 92 10 20 00 clr %o1
node = pathloc->node_access;
200bd40: e4 06 c0 00 ld [ %i3 ], %l2
if ( result == -1 )
200bd44: 80 a2 3f ff cmp %o0, -1
200bd48: 02 bf ff 4d be 200ba7c <IMFS_eval_path+0x94> <== NEVER TAKEN
200bd4c: b0 10 00 08 mov %o0, %i0
} else if ( node->type == IMFS_SYM_LINK ) {
result = IMFS_evaluate_sym_link( pathloc, 0 );
node = pathloc->node_access;
200bd50: 10 bf ff 63 b 200badc <IMFS_eval_path+0xf4>
200bd54: c2 04 a0 4c ld [ %l2 + 0x4c ], %g1
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
rtems_set_errno_and_return_minus_one( EACCES );
200bd58: 40 00 17 29 call 20119fc <__errno>
200bd5c: b0 10 3f ff mov -1, %i0
200bd60: 82 10 20 0d mov 0xd, %g1
200bd64: c2 22 00 00 st %g1, [ %o0 ]
200bd68: 81 c7 e0 08 ret
200bd6c: 81 e8 00 00 restore
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access ) {
break; /* Throw out the .. in this case */
} else {
*pathloc = pathloc->mt_entry->mt_point_node;
200bd70: 94 10 20 14 mov 0x14, %o2
200bd74: 40 00 19 5e call 20122ec <memcpy>
200bd78: 90 10 00 1b mov %i3, %o0
return (*pathloc->ops->evalpath_h)(&(pathname[i-len]),
200bd7c: c2 06 e0 0c ld [ %i3 + 0xc ], %g1
200bd80: c4 07 bf fc ld [ %fp + -4 ], %g2
200bd84: c2 00 40 00 ld [ %g1 ], %g1
200bd88: 92 06 40 02 add %i1, %g2, %o1
200bd8c: 84 24 40 02 sub %l1, %g2, %g2
200bd90: 94 10 00 1a mov %i2, %o2
200bd94: 90 04 00 02 add %l0, %g2, %o0
200bd98: 9f c0 40 00 call %g1
200bd9c: 96 10 00 1b mov %i3, %o3
200bda0: 81 c7 e0 08 ret
200bda4: 91 e8 00 08 restore %g0, %o0, %o0
char token[ IMFS_NAME_MAX + 1 ];
IMFS_jnode_t *node;
int result;
if ( !rtems_libio_is_valid_perms( flags ) ) {
assert( 0 );
200bda8: 11 00 80 76 sethi %hi(0x201d800), %o0 <== NOT EXECUTED
200bdac: 15 00 80 76 sethi %hi(0x201d800), %o2 <== NOT EXECUTED
200bdb0: 17 00 80 76 sethi %hi(0x201d800), %o3 <== NOT EXECUTED
200bdb4: 90 12 20 58 or %o0, 0x58, %o0 <== NOT EXECUTED
200bdb8: 94 12 a0 48 or %o2, 0x48, %o2 <== NOT EXECUTED
200bdbc: 96 12 e0 a8 or %o3, 0xa8, %o3 <== NOT EXECUTED
200bdc0: 40 00 02 cf call 200c8fc <__assert_func> <== NOT EXECUTED
200bdc4: 92 10 22 08 mov 0x208, %o1 <== NOT EXECUTED
0200bea4 <IMFS_evaluate_for_make>:
int IMFS_evaluate_for_make(
const char *path, /* IN */
rtems_filesystem_location_info_t *pathloc, /* IN/OUT */
const char **name /* OUT */
)
{
200bea4: 9d e3 bf 78 save %sp, -136, %sp
/*
* This was filled in by the caller and is valid in the
* mount table.
*/
node = pathloc->node_access;
200bea8: e0 06 40 00 ld [ %i1 ], %l0
/*
* Get the path length.
*/
pathlen = strlen( path );
200beac: 90 10 00 18 mov %i0, %o0
200beb0: 40 00 1a a0 call 2012930 <strlen>
200beb4: 2d 00 80 7a sethi %hi(0x201e800), %l6
int IMFS_evaluate_for_make(
const char *path, /* IN */
rtems_filesystem_location_info_t *pathloc, /* IN/OUT */
const char **name /* OUT */
)
{
200beb8: a2 10 00 18 mov %i0, %l1
node = pathloc->node_access;
/*
* Get the path length.
*/
pathlen = strlen( path );
200bebc: a6 10 20 00 clr %l3
200bec0: a8 07 bf d8 add %fp, -40, %l4
200bec4: aa 07 bf fc add %fp, -4, %l5
200bec8: a4 10 00 08 mov %o0, %l2
case IMFS_UP_DIR:
/*
* Am I at the root of all filesystems? (chroot'ed?)
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access )
200becc: ac 15 a1 80 or %l6, 0x180, %l6
* Evaluate all tokens until we are done or an error occurs.
*/
while( !done ) {
type = IMFS_get_token( &path[i], pathlen, token, &len );
200bed0: 90 04 40 13 add %l1, %l3, %o0
200bed4: 92 10 00 12 mov %l2, %o1
200bed8: 94 10 00 14 mov %l4, %o2
200bedc: 40 00 01 e5 call 200c670 <IMFS_get_token>
200bee0: 96 10 00 15 mov %l5, %o3
pathlen -= len;
i += len;
if ( !pathloc->node_access )
200bee4: c2 06 40 00 ld [ %i1 ], %g1
* Evaluate all tokens until we are done or an error occurs.
*/
while( !done ) {
type = IMFS_get_token( &path[i], pathlen, token, &len );
200bee8: ae 10 00 08 mov %o0, %l7
pathlen -= len;
i += len;
if ( !pathloc->node_access )
200beec: 80 a0 60 00 cmp %g1, 0
200bef0: 02 80 00 85 be 200c104 <IMFS_evaluate_for_make+0x260> <== NEVER TAKEN
200bef4: fa 07 bf fc ld [ %fp + -4 ], %i5
/*
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
200bef8: 80 a2 20 00 cmp %o0, 0
200befc: 32 80 00 08 bne,a 200bf1c <IMFS_evaluate_for_make+0x78>
200bf00: c4 04 20 4c ld [ %l0 + 0x4c ], %g2
pathloc->node_access = node;
}
break;
case IMFS_NO_MORE_PATH:
rtems_set_errno_and_return_minus_one( EEXIST );
200bf04: 40 00 16 be call 20119fc <__errno>
200bf08: b0 10 3f ff mov -1, %i0
200bf0c: 82 10 20 11 mov 0x11, %g1
200bf10: c2 22 00 00 st %g1, [ %o0 ]
200bf14: 81 c7 e0 08 ret
200bf18: 81 e8 00 00 restore
/*
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
200bf1c: 80 a0 a0 01 cmp %g2, 1
200bf20: 02 80 00 69 be 200c0c4 <IMFS_evaluate_for_make+0x220>
200bf24: 90 10 00 19 mov %i1, %o0
while( !done ) {
type = IMFS_get_token( &path[i], pathlen, token, &len );
pathlen -= len;
i += len;
200bf28: a6 04 c0 1d add %l3, %i5, %l3
*/
while( !done ) {
type = IMFS_get_token( &path[i], pathlen, token, &len );
pathlen -= len;
200bf2c: a4 24 80 1d sub %l2, %i5, %l2
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
rtems_set_errno_and_return_minus_one( EACCES );
node = pathloc->node_access;
switch( type ) {
200bf30: 80 a5 e0 02 cmp %l7, 2
200bf34: 02 80 00 30 be 200bff4 <IMFS_evaluate_for_make+0x150>
200bf38: a0 10 00 01 mov %g1, %l0
200bf3c: 80 a5 e0 02 cmp %l7, 2
200bf40: 08 80 00 0d bleu 200bf74 <IMFS_evaluate_for_make+0xd0>
200bf44: 80 a5 e0 00 cmp %l7, 0
200bf48: 80 a5 e0 03 cmp %l7, 3
200bf4c: 02 80 00 12 be 200bf94 <IMFS_evaluate_for_make+0xf0>
200bf50: 80 a5 e0 04 cmp %l7, 4
200bf54: 12 bf ff e0 bne 200bed4 <IMFS_evaluate_for_make+0x30> <== NEVER TAKEN
200bf58: 90 04 40 13 add %l1, %l3, %o0
case IMFS_NO_MORE_PATH:
rtems_set_errno_and_return_minus_one( EEXIST );
break;
case IMFS_INVALID_TOKEN:
rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
200bf5c: 40 00 16 a8 call 20119fc <__errno>
200bf60: b0 10 3f ff mov -1, %i0
200bf64: 82 10 20 5b mov 0x5b, %g1
200bf68: c2 22 00 00 st %g1, [ %o0 ]
200bf6c: 81 c7 e0 08 ret
200bf70: 81 e8 00 00 restore
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
rtems_set_errno_and_return_minus_one( EACCES );
node = pathloc->node_access;
switch( type ) {
200bf74: 12 bf ff d8 bne 200bed4 <IMFS_evaluate_for_make+0x30> <== ALWAYS TAKEN
200bf78: 90 04 40 13 add %l1, %l3, %o0
pathloc->node_access = node;
}
break;
case IMFS_NO_MORE_PATH:
rtems_set_errno_and_return_minus_one( EEXIST );
200bf7c: 40 00 16 a0 call 20119fc <__errno> <== NOT EXECUTED
200bf80: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200bf84: 82 10 20 11 mov 0x11, %g1 <== NOT EXECUTED
200bf88: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200bf8c: 81 c7 e0 08 ret <== NOT EXECUTED
200bf90: 81 e8 00 00 restore <== NOT EXECUTED
case IMFS_NAME:
/*
* If we are at a link follow it.
*/
if ( node->type == IMFS_HARD_LINK ) {
200bf94: c2 00 60 4c ld [ %g1 + 0x4c ], %g1
200bf98: 80 a0 60 03 cmp %g1, 3
200bf9c: 02 80 00 83 be 200c1a8 <IMFS_evaluate_for_make+0x304>
200bfa0: 80 a0 60 04 cmp %g1, 4
result = IMFS_evaluate_link( pathloc, 0 );
if ( result == -1 )
return -1;
} else if ( node->type == IMFS_SYM_LINK ) {
200bfa4: 02 80 00 82 be 200c1ac <IMFS_evaluate_for_make+0x308>
200bfa8: 90 10 00 19 mov %i1, %o0
if ( result == -1 )
return -1;
}
node = pathloc->node_access;
if ( !node )
200bfac: 80 a4 20 00 cmp %l0, 0
200bfb0: 02 80 00 78 be 200c190 <IMFS_evaluate_for_make+0x2ec> <== NEVER TAKEN
200bfb4: 01 00 00 00 nop
/*
* Only a directory can be decended into.
*/
if ( node->type != IMFS_DIRECTORY )
200bfb8: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200bfbc: 80 a0 60 01 cmp %g1, 1
200bfc0: 12 80 00 74 bne 200c190 <IMFS_evaluate_for_make+0x2ec>
200bfc4: 90 10 00 10 mov %l0, %o0
/*
* Find the token name in the present location.
*/
node = IMFS_find_match_in_dir( node, token );
200bfc8: 40 00 01 79 call 200c5ac <IMFS_find_match_in_dir>
200bfcc: 92 10 00 14 mov %l4, %o1
/*
* If there is no node we have found the name of the node we
* wish to create.
*/
if ( ! node )
200bfd0: a0 92 20 00 orcc %o0, 0, %l0
200bfd4: 02 80 00 52 be 200c11c <IMFS_evaluate_for_make+0x278>
200bfd8: c2 07 bf fc ld [ %fp + -4 ], %g1
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
200bfdc: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200bfe0: 80 a0 60 01 cmp %g1, 1
200bfe4: 22 80 00 17 be,a 200c040 <IMFS_evaluate_for_make+0x19c>
200bfe8: c2 04 20 5c ld [ %l0 + 0x5c ], %g1
i += 2;
pathlen -= 2;
node = node->Parent;
}
pathloc->node_access = node;
200bfec: 10 bf ff b9 b 200bed0 <IMFS_evaluate_for_make+0x2c>
200bff0: e0 26 40 00 st %l0, [ %i1 ]
case IMFS_UP_DIR:
/*
* Am I at the root of all filesystems? (chroot'ed?)
*/
if ( pathloc->node_access == rtems_filesystem_root.node_access )
200bff4: c4 05 80 00 ld [ %l6 ], %g2
200bff8: c4 00 a0 18 ld [ %g2 + 0x18 ], %g2
200bffc: 80 a0 80 01 cmp %g2, %g1
200c000: 02 bf ff b5 be 200bed4 <IMFS_evaluate_for_make+0x30>
200c004: 90 04 40 13 add %l1, %l3, %o0
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access){
200c008: d2 06 60 10 ld [ %i1 + 0x10 ], %o1
200c00c: c4 02 60 1c ld [ %o1 + 0x1c ], %g2
200c010: 80 a0 80 01 cmp %g2, %g1
200c014: 02 80 00 85 be 200c228 <IMFS_evaluate_for_make+0x384>
200c018: 92 02 60 08 add %o1, 8, %o1
} else {
*pathloc = pathloc->mt_entry->mt_point_node;
return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name );
}
} else {
if ( !node->Parent )
200c01c: e0 00 60 08 ld [ %g1 + 8 ], %l0
200c020: 80 a4 20 00 cmp %l0, 0
200c024: 32 bf ff ac bne,a 200bed4 <IMFS_evaluate_for_make+0x30>
200c028: e0 26 40 00 st %l0, [ %i1 ]
rtems_set_errno_and_return_minus_one( ENOENT );
200c02c: 40 00 16 74 call 20119fc <__errno>
200c030: b0 10 3f ff mov -1, %i0
200c034: ee 22 00 00 st %l7, [ %o0 ]
200c038: 81 c7 e0 08 ret
200c03c: 81 e8 00 00 restore
*/
if ( ! node )
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
200c040: 80 a0 60 00 cmp %g1, 0
200c044: 12 80 00 0d bne 200c078 <IMFS_evaluate_for_make+0x1d4>
200c048: ae 04 40 13 add %l1, %l3, %l7
200c04c: 10 bf ff a1 b 200bed0 <IMFS_evaluate_for_make+0x2c>
200c050: e0 26 40 00 st %l0, [ %i1 ]
const char *path, /* IN */
size_t *len, /* IN/OUT */
int *index /* IN/OUT */
)
{
while ( IMFS_is_separator( path[*index] ) && path[*index] && *len ) {
200c054: 83 28 60 18 sll %g1, 0x18, %g1
200c058: 80 a0 60 00 cmp %g1, 0
200c05c: 02 80 00 5b be 200c1c8 <IMFS_evaluate_for_make+0x324> <== NEVER TAKEN
200c060: ae 05 e0 01 inc %l7
200c064: 80 a4 a0 00 cmp %l2, 0
200c068: 02 80 00 0c be 200c098 <IMFS_evaluate_for_make+0x1f4> <== NEVER TAKEN
200c06c: 83 38 60 18 sra %g1, 0x18, %g1
++(*index);
200c070: a6 04 e0 01 inc %l3
--(*len);
200c074: a4 04 bf ff add %l2, -1, %l2
const char *path, /* IN */
size_t *len, /* IN/OUT */
int *index /* IN/OUT */
)
{
while ( IMFS_is_separator( path[*index] ) && path[*index] && *len ) {
200c078: d0 4d c0 00 ldsb [ %l7 ], %o0
200c07c: 7f ff df 5e call 2003df4 <rtems_filesystem_is_separator>
200c080: ba 10 00 17 mov %l7, %i5
200c084: 80 a2 20 00 cmp %o0, 0
200c088: 12 bf ff f3 bne 200c054 <IMFS_evaluate_for_make+0x1b0>
200c08c: c2 0d c0 00 ldub [ %l7 ], %g1
200c090: 83 28 60 18 sll %g1, 0x18, %g1
if ( ! node )
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
200c094: 83 38 60 18 sra %g1, 0x18, %g1
200c098: 80 a0 60 2e cmp %g1, 0x2e
200c09c: 12 80 00 4b bne 200c1c8 <IMFS_evaluate_for_make+0x324>
200c0a0: 82 04 40 13 add %l1, %l3, %g1
200c0a4: c2 48 60 01 ldsb [ %g1 + 1 ], %g1
200c0a8: 80 a0 60 2e cmp %g1, 0x2e
200c0ac: 12 80 00 47 bne 200c1c8 <IMFS_evaluate_for_make+0x324> <== NEVER TAKEN
200c0b0: a6 04 e0 02 add %l3, 2, %l3
pathloc,
name );
}
i += 2;
pathlen -= 2;
node = node->Parent;
200c0b4: e0 04 20 08 ld [ %l0 + 8 ], %l0
return (*pathloc->ops->evalformake_h)( &path[i],
pathloc,
name );
}
i += 2;
pathlen -= 2;
200c0b8: a4 04 bf fe add %l2, -2, %l2
node = node->Parent;
}
pathloc->node_access = node;
200c0bc: 10 bf ff 85 b 200bed0 <IMFS_evaluate_for_make+0x2c>
200c0c0: e0 26 40 00 st %l0, [ %i1 ]
* I cannot move out of this directory without execute permission.
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
200c0c4: 7f ff fd e0 call 200b844 <IMFS_evaluate_permission>
200c0c8: 92 10 20 01 mov 1, %o1
200c0cc: 80 a2 20 00 cmp %o0, 0
200c0d0: 02 80 00 50 be 200c210 <IMFS_evaluate_for_make+0x36c>
200c0d4: 01 00 00 00 nop
200c0d8: 10 bf ff 94 b 200bf28 <IMFS_evaluate_for_make+0x84>
200c0dc: c2 06 40 00 ld [ %i1 ], %g1
/*
* We have evaluated the path as far as we can.
* Verify there is not any invalid stuff at the end of the name.
*/
for( ; path[i] != '\0'; i++) {
200c0e0: 91 2a 20 18 sll %o0, 0x18, %o0
200c0e4: 80 a2 20 00 cmp %o0, 0
200c0e8: 02 80 00 15 be 200c13c <IMFS_evaluate_for_make+0x298>
200c0ec: a2 04 60 01 inc %l1
if ( !IMFS_is_separator( path[ i ] ) )
200c0f0: 7f ff df 41 call 2003df4 <rtems_filesystem_is_separator>
200c0f4: 91 3a 20 18 sra %o0, 0x18, %o0
200c0f8: 80 a2 20 00 cmp %o0, 0
200c0fc: 32 bf ff f9 bne,a 200c0e0 <IMFS_evaluate_for_make+0x23c>
200c100: d0 0c 60 01 ldub [ %l1 + 1 ], %o0
rtems_set_errno_and_return_minus_one( ENOENT );
200c104: 40 00 16 3e call 20119fc <__errno>
200c108: b0 10 3f ff mov -1, %i0
200c10c: 82 10 20 02 mov 2, %g1
200c110: c2 22 00 00 st %g1, [ %o0 ]
200c114: 81 c7 e0 08 ret
200c118: 81 e8 00 00 restore
case IMFS_CURRENT_DIR:
break;
}
}
*name = &path[ i - len ];
200c11c: 82 24 c0 01 sub %l3, %g1, %g1
200c120: 82 04 40 01 add %l1, %g1, %g1
200c124: c2 26 80 00 st %g1, [ %i2 ]
/*
* We have evaluated the path as far as we can.
* Verify there is not any invalid stuff at the end of the name.
*/
for( ; path[i] != '\0'; i++) {
200c128: d0 0c 40 13 ldub [ %l1 + %l3 ], %o0
200c12c: 91 2a 20 18 sll %o0, 0x18, %o0
200c130: 80 a2 20 00 cmp %o0, 0
200c134: 12 bf ff ef bne 200c0f0 <IMFS_evaluate_for_make+0x24c>
200c138: a2 04 40 13 add %l1, %l3, %l1
/*
* Verify we can execute and write to this directory.
*/
result = IMFS_Set_handlers( pathloc );
200c13c: 7f ff fd 9f call 200b7b8 <IMFS_Set_handlers>
200c140: 90 10 00 19 mov %i1, %o0
/*
* The returned node must be a directory
*/
node = pathloc->node_access;
200c144: c2 06 40 00 ld [ %i1 ], %g1
200c148: c2 00 60 4c ld [ %g1 + 0x4c ], %g1
200c14c: 80 a0 60 01 cmp %g1, 1
200c150: 12 80 00 10 bne 200c190 <IMFS_evaluate_for_make+0x2ec> <== NEVER TAKEN
200c154: b0 10 00 08 mov %o0, %i0
/*
* We must have Write and execute permission on the returned node.
*/
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_WX ) )
200c158: 90 10 00 19 mov %i1, %o0
200c15c: 7f ff fd ba call 200b844 <IMFS_evaluate_permission>
200c160: 92 10 20 03 mov 3, %o1
200c164: 80 a2 20 00 cmp %o0, 0
200c168: 02 80 00 04 be 200c178 <IMFS_evaluate_for_make+0x2d4>
200c16c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EACCES );
return result;
}
200c170: 81 c7 e0 08 ret
200c174: 81 e8 00 00 restore
/*
* We must have Write and execute permission on the returned node.
*/
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_WX ) )
rtems_set_errno_and_return_minus_one( EACCES );
200c178: 40 00 16 21 call 20119fc <__errno>
200c17c: b0 10 3f ff mov -1, %i0
200c180: 82 10 20 0d mov 0xd, %g1
200c184: c2 22 00 00 st %g1, [ %o0 ]
return result;
}
200c188: 81 c7 e0 08 ret
200c18c: 81 e8 00 00 restore
/*
* The returned node must be a directory
*/
node = pathloc->node_access;
if ( node->type != IMFS_DIRECTORY )
rtems_set_errno_and_return_minus_one( ENOTDIR );
200c190: 40 00 16 1b call 20119fc <__errno>
200c194: b0 10 3f ff mov -1, %i0
200c198: 82 10 20 14 mov 0x14, %g1
200c19c: c2 22 00 00 st %g1, [ %o0 ]
200c1a0: 81 c7 e0 08 ret
200c1a4: 81 e8 00 00 restore
if ( result == -1 )
return -1;
} else if ( node->type == IMFS_SYM_LINK ) {
result = IMFS_evaluate_link( pathloc, 0 );
200c1a8: 90 10 00 19 mov %i1, %o0
200c1ac: 7f ff ff 08 call 200bdcc <IMFS_evaluate_link>
200c1b0: 92 10 20 00 clr %o1
if ( result == -1 )
200c1b4: 80 a2 3f ff cmp %o0, -1
200c1b8: 02 bf ff 57 be 200bf14 <IMFS_evaluate_for_make+0x70> <== NEVER TAKEN
200c1bc: b0 10 00 08 mov %o0, %i0
200c1c0: 10 bf ff 7b b 200bfac <IMFS_evaluate_for_make+0x108>
200c1c4: e0 06 40 00 ld [ %i1 ], %l0
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200c1c8: c4 04 20 5c ld [ %l0 + 0x5c ], %g2
return (*pathloc->ops->evalformake_h)( &path[i],
200c1cc: 90 10 00 1d mov %i5, %o0
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200c1d0: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1
return (*pathloc->ops->evalformake_h)( &path[i],
200c1d4: 92 10 00 19 mov %i1, %o1
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200c1d8: c2 26 40 00 st %g1, [ %i1 ]
200c1dc: c2 00 a0 20 ld [ %g2 + 0x20 ], %g1
return (*pathloc->ops->evalformake_h)( &path[i],
200c1e0: 94 10 00 1a mov %i2, %o2
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200c1e4: c2 26 60 04 st %g1, [ %i1 + 4 ]
200c1e8: c2 00 a0 24 ld [ %g2 + 0x24 ], %g1
200c1ec: c2 26 60 08 st %g1, [ %i1 + 8 ]
200c1f0: c2 00 a0 28 ld [ %g2 + 0x28 ], %g1
200c1f4: c2 26 60 0c st %g1, [ %i1 + 0xc ]
return (*pathloc->ops->evalformake_h)( &path[i],
200c1f8: c2 00 60 04 ld [ %g1 + 4 ], %g1
done = true;
else {
if (( node->type == IMFS_DIRECTORY ) && ( node->info.directory.mt_fs != NULL )) {
IMFS_skip_separator( path, &pathlen, &i);
if ((path[i] != '.') || (path[i + 1] != '.')) {
*pathloc = node->info.directory.mt_fs->mt_fs_root;
200c1fc: c4 00 a0 2c ld [ %g2 + 0x2c ], %g2
return (*pathloc->ops->evalformake_h)( &path[i],
200c200: 9f c0 40 00 call %g1
200c204: c4 26 60 10 st %g2, [ %i1 + 0x10 ]
200c208: 81 c7 e0 08 ret
200c20c: 91 e8 00 08 restore %g0, %o0, %o0
*/
if ( type != IMFS_NO_MORE_PATH )
if ( node->type == IMFS_DIRECTORY )
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
rtems_set_errno_and_return_minus_one( EACCES );
200c210: 40 00 15 fb call 20119fc <__errno>
200c214: b0 10 3f ff mov -1, %i0
200c218: 82 10 20 0d mov 0xd, %g1
200c21c: c2 22 00 00 st %g1, [ %o0 ]
200c220: 81 c7 e0 08 ret
200c224: 81 e8 00 00 restore
if ( pathloc->node_access == rtems_filesystem_root.node_access ) {
break;
} else {
*pathloc = pathloc->mt_entry->mt_point_node;
200c228: 94 10 20 14 mov 0x14, %o2
200c22c: 40 00 18 30 call 20122ec <memcpy>
200c230: 90 10 00 19 mov %i1, %o0
return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name );
200c234: c2 06 60 0c ld [ %i1 + 0xc ], %g1
200c238: d0 07 bf fc ld [ %fp + -4 ], %o0
200c23c: c2 00 60 04 ld [ %g1 + 4 ], %g1
200c240: 90 24 c0 08 sub %l3, %o0, %o0
200c244: 92 10 00 19 mov %i1, %o1
200c248: 90 04 40 08 add %l1, %o0, %o0
200c24c: 9f c0 40 00 call %g1
200c250: 94 10 00 1a mov %i2, %o2
200c254: 81 c7 e0 08 ret
200c258: 91 e8 00 08 restore %g0, %o0, %o0
0200b8c8 <IMFS_evaluate_hard_link>:
int IMFS_evaluate_hard_link(
rtems_filesystem_location_info_t *node, /* IN/OUT */
int flags /* IN */
)
{
200b8c8: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *jnode = node->node_access;
200b8cc: c2 06 00 00 ld [ %i0 ], %g1
/*
* Check for things that should never happen.
*/
if ( jnode->type != IMFS_HARD_LINK )
200b8d0: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
200b8d4: 80 a0 a0 03 cmp %g2, 3
200b8d8: 12 80 00 14 bne 200b928 <IMFS_evaluate_hard_link+0x60> <== NEVER TAKEN
200b8dc: 90 10 00 18 mov %i0, %o0
/*
* Set the hard link value and the handlers.
*/
node->node_access = jnode->info.hard_link.link_node;
200b8e0: c2 00 60 50 ld [ %g1 + 0x50 ], %g1
IMFS_Set_handlers( node );
200b8e4: 7f ff ff b5 call 200b7b8 <IMFS_Set_handlers>
200b8e8: c2 26 00 00 st %g1, [ %i0 ]
/*
* Verify we have the correct permissions for this node.
*/
if ( !IMFS_evaluate_permission( node, flags ) )
200b8ec: 90 10 00 18 mov %i0, %o0
200b8f0: 92 10 00 19 mov %i1, %o1
200b8f4: 7f ff ff d4 call 200b844 <IMFS_evaluate_permission>
200b8f8: b0 10 20 00 clr %i0
200b8fc: 80 a2 20 00 cmp %o0, 0
200b900: 02 80 00 04 be 200b910 <IMFS_evaluate_hard_link+0x48> <== NEVER TAKEN
200b904: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EACCES );
return result;
}
200b908: 81 c7 e0 08 ret
200b90c: 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 );
200b910: 40 00 18 3b call 20119fc <__errno> <== NOT EXECUTED
200b914: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200b918: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED
200b91c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return result;
}
200b920: 81 c7 e0 08 ret <== NOT EXECUTED
200b924: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Check for things that should never happen.
*/
if ( jnode->type != IMFS_HARD_LINK )
rtems_fatal_error_occurred (0xABCD0000);
200b928: 7f ff ed 8c call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
200b92c: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED
0200bdcc <IMFS_evaluate_link>:
int IMFS_evaluate_link(
rtems_filesystem_location_info_t *node, /* IN/OUT */
int flags /* IN */
)
{
200bdcc: 9d e3 bf a0 save %sp, -96, %sp
200bdd0: 21 00 80 7a sethi %hi(0x201e800), %l0
200bdd4: a2 10 00 18 mov %i0, %l1
200bdd8: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
else if (jnode->type == IMFS_SYM_LINK )
result = IMFS_evaluate_sym_link( node, flags );
} while ( ( result == 0 ) && ( ( jnode->type == IMFS_SYM_LINK ) ||
( jnode->type == IMFS_HARD_LINK ) ) );
200bddc: 10 80 00 07 b 200bdf8 <IMFS_evaluate_link+0x2c>
200bde0: a6 14 21 80 or %l0, 0x180, %l3
*/
if ( jnode->type == IMFS_HARD_LINK )
result = IMFS_evaluate_hard_link( node, flags );
else if (jnode->type == IMFS_SYM_LINK )
200bde4: 02 80 00 21 be 200be68 <IMFS_evaluate_link+0x9c>
200bde8: 84 00 bf fd add %g2, -3, %g2
result = IMFS_evaluate_sym_link( node, flags );
} while ( ( result == 0 ) && ( ( jnode->type == IMFS_SYM_LINK ) ||
( jnode->type == IMFS_HARD_LINK ) ) );
200bdec: 80 a0 a0 01 cmp %g2, 1
200bdf0: 18 80 00 1b bgu 200be5c <IMFS_evaluate_link+0x90> <== ALWAYS TAKEN
200bdf4: 90 10 20 00 clr %o0
/*
* Increment and check the link counter.
*/
rtems_filesystem_link_counts ++;
200bdf8: c4 10 60 30 lduh [ %g1 + 0x30 ], %g2
{
IMFS_jnode_t *jnode;
int result = 0;
do {
jnode = node->node_access;
200bdfc: e4 04 40 00 ld [ %l1 ], %l2
/*
* Increment and check the link counter.
*/
rtems_filesystem_link_counts ++;
200be00: 84 00 a0 01 inc %g2
200be04: c4 30 60 30 sth %g2, [ %g1 + 0x30 ]
if ( rtems_filesystem_link_counts > MAXSYMLINK ) {
200be08: 85 28 a0 10 sll %g2, 0x10, %g2
200be0c: 85 30 a0 10 srl %g2, 0x10, %g2
200be10: 80 a0 a0 05 cmp %g2, 5
200be14: 18 80 00 1d bgu 200be88 <IMFS_evaluate_link+0xbc>
200be18: 01 00 00 00 nop
/*
* Follow the Link node.
*/
if ( jnode->type == IMFS_HARD_LINK )
200be1c: c4 04 a0 4c ld [ %l2 + 0x4c ], %g2
200be20: 80 a0 a0 03 cmp %g2, 3
200be24: 12 bf ff f0 bne 200bde4 <IMFS_evaluate_link+0x18>
200be28: 80 a0 a0 04 cmp %g2, 4
result = IMFS_evaluate_hard_link( node, flags );
200be2c: 90 10 00 11 mov %l1, %o0
200be30: 7f ff fe a6 call 200b8c8 <IMFS_evaluate_hard_link>
200be34: 92 10 00 19 mov %i1, %o1
else if (jnode->type == IMFS_SYM_LINK )
result = IMFS_evaluate_sym_link( node, flags );
} while ( ( result == 0 ) && ( ( jnode->type == IMFS_SYM_LINK ) ||
( jnode->type == IMFS_HARD_LINK ) ) );
200be38: 80 a2 20 00 cmp %o0, 0
200be3c: 12 80 00 08 bne 200be5c <IMFS_evaluate_link+0x90> <== NEVER TAKEN
200be40: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
200be44: c4 04 a0 4c ld [ %l2 + 0x4c ], %g2
200be48: 84 00 bf fd add %g2, -3, %g2
200be4c: 80 a0 a0 01 cmp %g2, 1
200be50: 08 bf ff ea bleu 200bdf8 <IMFS_evaluate_link+0x2c> <== ALWAYS TAKEN
200be54: c2 04 c0 00 ld [ %l3 ], %g1
200be58: 90 10 20 00 clr %o0 <== NOT EXECUTED
/*
* Clear link counter.
*/
rtems_filesystem_link_counts = 0;
200be5c: c0 30 60 30 clrh [ %g1 + 0x30 ]
return result;
}
200be60: 81 c7 e0 08 ret
200be64: 91 e8 00 08 restore %g0, %o0, %o0
if ( jnode->type == IMFS_HARD_LINK )
result = IMFS_evaluate_hard_link( node, flags );
else if (jnode->type == IMFS_SYM_LINK )
result = IMFS_evaluate_sym_link( node, flags );
200be68: 90 10 00 11 mov %l1, %o0
200be6c: 7f ff fe b2 call 200b934 <IMFS_evaluate_sym_link>
200be70: 92 10 00 19 mov %i1, %o1
} while ( ( result == 0 ) && ( ( jnode->type == IMFS_SYM_LINK ) ||
( jnode->type == IMFS_HARD_LINK ) ) );
200be74: 80 a2 20 00 cmp %o0, 0
200be78: 22 bf ff f4 be,a 200be48 <IMFS_evaluate_link+0x7c>
200be7c: c4 04 a0 4c ld [ %l2 + 0x4c ], %g2
200be80: 10 bf ff f7 b 200be5c <IMFS_evaluate_link+0x90>
200be84: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
*/
rtems_filesystem_link_counts ++;
if ( rtems_filesystem_link_counts > MAXSYMLINK ) {
rtems_filesystem_link_counts = 0;
rtems_set_errno_and_return_minus_one( ELOOP );
200be88: 40 00 16 dd call 20119fc <__errno>
200be8c: c0 30 60 30 clrh [ %g1 + 0x30 ]
200be90: 82 10 20 5c mov 0x5c, %g1
200be94: c2 22 00 00 st %g1, [ %o0 ]
200be98: 90 10 3f ff mov -1, %o0
*/
rtems_filesystem_link_counts = 0;
return result;
}
200be9c: 81 c7 e0 08 ret
200bea0: 91 e8 00 08 restore %g0, %o0, %o0
0200b844 <IMFS_evaluate_permission>:
int IMFS_evaluate_permission(
rtems_filesystem_location_info_t *node,
int flags
)
{
200b844: 9d e3 bf a0 save %sp, -96, %sp
uid_t st_uid;
gid_t st_gid;
IMFS_jnode_t *jnode;
int flags_to_test;
if ( !rtems_libio_is_valid_perms( flags ) )
200b848: 80 8e 7f f8 btst -8, %i1
200b84c: 12 80 00 19 bne 200b8b0 <IMFS_evaluate_permission+0x6c> <== NEVER TAKEN
200b850: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EPERM );
jnode = node->node_access;
#if defined(RTEMS_POSIX_API)
st_uid = geteuid();
200b854: 40 00 04 b9 call 200cb38 <geteuid>
200b858: e0 06 00 00 ld [ %i0 ], %l0
st_gid = getegid();
200b85c: 40 00 04 b3 call 200cb28 <getegid>
200b860: a2 10 00 08 mov %o0, %l1
* Check if I am owner or a group member or someone else.
*/
flags_to_test = flags;
if ( st_uid == jnode->st_uid )
200b864: c2 14 20 3c lduh [ %l0 + 0x3c ], %g1
200b868: a3 2c 60 10 sll %l1, 0x10, %l1
200b86c: a3 34 60 10 srl %l1, 0x10, %l1
200b870: 80 a4 40 01 cmp %l1, %g1
200b874: 02 80 00 09 be 200b898 <IMFS_evaluate_permission+0x54>
200b878: 83 2e 60 06 sll %i1, 6, %g1
flags_to_test <<= 6;
else if ( st_gid == jnode->st_gid )
200b87c: c2 14 20 3e lduh [ %l0 + 0x3e ], %g1
200b880: 91 2a 20 10 sll %o0, 0x10, %o0
200b884: 91 32 20 10 srl %o0, 0x10, %o0
200b888: 80 a2 00 01 cmp %o0, %g1
200b88c: 02 80 00 03 be 200b898 <IMFS_evaluate_permission+0x54> <== ALWAYS TAKEN
200b890: 83 2e 60 03 sll %i1, 3, %g1
200b894: 82 10 00 19 mov %i1, %g1 <== NOT EXECUTED
/*
* If all of the flags are set we have permission
* to do this.
*/
if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
200b898: c4 04 20 30 ld [ %l0 + 0x30 ], %g2
200b89c: 82 28 40 02 andn %g1, %g2, %g1
200b8a0: 80 a0 00 01 cmp %g0, %g1
200b8a4: b0 60 3f ff subx %g0, -1, %i0
return 1;
return 0;
}
200b8a8: 81 c7 e0 08 ret
200b8ac: 81 e8 00 00 restore
gid_t st_gid;
IMFS_jnode_t *jnode;
int flags_to_test;
if ( !rtems_libio_is_valid_perms( flags ) )
rtems_set_errno_and_return_minus_one( EPERM );
200b8b0: 40 00 18 53 call 20119fc <__errno> <== NOT EXECUTED
200b8b4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200b8b8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
200b8bc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200b8c0: 81 c7 e0 08 ret <== NOT EXECUTED
200b8c4: 81 e8 00 00 restore <== NOT EXECUTED
0200b934 <IMFS_evaluate_sym_link>:
int IMFS_evaluate_sym_link(
rtems_filesystem_location_info_t *node, /* IN/OUT */
int flags /* IN */
)
{
200b934: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *jnode = node->node_access;
200b938: e0 06 00 00 ld [ %i0 ], %l0
/*
* Check for things that should never happen.
*/
if ( jnode->type != IMFS_SYM_LINK )
200b93c: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200b940: 80 a0 60 04 cmp %g1, 4
200b944: 12 80 00 26 bne 200b9dc <IMFS_evaluate_sym_link+0xa8> <== NEVER TAKEN
200b948: 01 00 00 00 nop
rtems_fatal_error_occurred (0xABCD0000);
if ( !jnode->Parent )
200b94c: c2 04 20 08 ld [ %l0 + 8 ], %g1
200b950: 80 a0 60 00 cmp %g1, 0
200b954: 02 80 00 20 be 200b9d4 <IMFS_evaluate_sym_link+0xa0> <== NEVER TAKEN
200b958: 92 07 bf fc add %fp, -4, %o1
/*
* Move the node_access to either the symbolic links parent or
* root depending on the symbolic links path.
*/
node->node_access = jnode->Parent;
200b95c: c2 26 00 00 st %g1, [ %i0 ]
rtems_filesystem_get_sym_start_loc(
200b960: d0 04 20 50 ld [ %l0 + 0x50 ], %o0
200b964: 40 00 05 e8 call 200d104 <rtems_filesystem_get_sym_start_loc>
200b968: 94 10 00 18 mov %i0, %o2
/*
* Use eval path to evaluate the path of the symbolic link.
*/
result = IMFS_eval_path(
200b96c: c2 07 bf fc ld [ %fp + -4 ], %g1
200b970: e0 04 20 50 ld [ %l0 + 0x50 ], %l0
200b974: a0 04 00 01 add %l0, %g1, %l0
200b978: 40 00 1b ee call 2012930 <strlen>
200b97c: 90 10 00 10 mov %l0, %o0
200b980: 94 10 00 19 mov %i1, %o2
200b984: 92 10 00 08 mov %o0, %o1
200b988: 96 10 00 18 mov %i0, %o3
200b98c: 40 00 00 17 call 200b9e8 <IMFS_eval_path>
200b990: 90 10 00 10 mov %l0, %o0
200b994: a0 10 00 08 mov %o0, %l0
strlen( &jnode->info.sym_link.name[i] ),
flags,
node
);
IMFS_Set_handlers( node );
200b998: 7f ff ff 88 call 200b7b8 <IMFS_Set_handlers>
200b99c: 90 10 00 18 mov %i0, %o0
/*
* Verify we have the correct permissions for this node.
*/
if ( !IMFS_evaluate_permission( node, flags ) )
200b9a0: 90 10 00 18 mov %i0, %o0
200b9a4: 7f ff ff a8 call 200b844 <IMFS_evaluate_permission>
200b9a8: 92 10 00 19 mov %i1, %o1
200b9ac: 80 a2 20 00 cmp %o0, 0
200b9b0: 02 80 00 04 be 200b9c0 <IMFS_evaluate_sym_link+0x8c> <== NEVER TAKEN
200b9b4: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EACCES );
return result;
}
200b9b8: 81 c7 e0 08 ret
200b9bc: 91 e8 00 10 restore %g0, %l0, %o0
/*
* Verify we have the correct permissions for this node.
*/
if ( !IMFS_evaluate_permission( node, flags ) )
rtems_set_errno_and_return_minus_one( EACCES );
200b9c0: 40 00 18 0f call 20119fc <__errno> <== NOT EXECUTED
200b9c4: a0 10 3f ff mov -1, %l0 <== NOT EXECUTED
200b9c8: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED
200b9cc: 10 bf ff fb b 200b9b8 <IMFS_evaluate_sym_link+0x84> <== NOT EXECUTED
200b9d0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
if ( jnode->type != IMFS_SYM_LINK )
rtems_fatal_error_occurred (0xABCD0000);
if ( !jnode->Parent )
rtems_fatal_error_occurred( 0xBAD00000 );
200b9d4: 7f ff ed 61 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
200b9d8: 11 2e b4 00 sethi %hi(0xbad00000), %o0 <== NOT EXECUTED
/*
* Check for things that should never happen.
*/
if ( jnode->type != IMFS_SYM_LINK )
rtems_fatal_error_occurred (0xABCD0000);
200b9dc: 7f ff ed 5f call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
200b9e0: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED
02010488 <IMFS_fchmod>:
int IMFS_fchmod(
rtems_filesystem_location_info_t *loc,
mode_t mode
)
{
2010488: 9d e3 bf 98 save %sp, -104, %sp
/*
* Verify I am the owner of the node or the super user.
*/
#if defined(RTEMS_POSIX_API)
st_uid = geteuid();
201048c: 7f ff f1 ab call 200cb38 <geteuid>
2010490: e0 06 00 00 ld [ %i0 ], %l0
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
2010494: 91 2a 20 10 sll %o0, 0x10, %o0
2010498: 91 32 20 10 srl %o0, 0x10, %o0
201049c: 80 a2 20 00 cmp %o0, 0
20104a0: 32 80 00 0e bne,a 20104d8 <IMFS_fchmod+0x50> <== NEVER TAKEN
20104a4: c2 14 20 3c lduh [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
/*
* Change only the RWX permissions on the jnode to mode.
*/
jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
20104a8: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
IMFS_update_ctime( jnode );
20104ac: 90 07 bf f8 add %fp, -8, %o0
/*
* Change only the RWX permissions on the jnode to mode.
*/
jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
20104b0: 82 08 70 00 and %g1, -4096, %g1
IMFS_update_ctime( jnode );
20104b4: 92 10 20 00 clr %o1
/*
* Change only the RWX permissions on the jnode to mode.
*/
jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
20104b8: b2 0e 6f ff and %i1, 0xfff, %i1
20104bc: b2 16 40 01 or %i1, %g1, %i1
IMFS_update_ctime( jnode );
20104c0: 7f ff ca 36 call 2002d98 <gettimeofday>
20104c4: f2 24 20 30 st %i1, [ %l0 + 0x30 ]
20104c8: c2 07 bf f8 ld [ %fp + -8 ], %g1
20104cc: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
return 0;
}
20104d0: 81 c7 e0 08 ret
20104d4: 91 e8 20 00 restore %g0, 0, %o0
* Verify I am the owner of the node or the super user.
*/
#if defined(RTEMS_POSIX_API)
st_uid = geteuid();
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
20104d8: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
20104dc: 22 bf ff f4 be,a 20104ac <IMFS_fchmod+0x24> <== NOT EXECUTED
20104e0: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EPERM );
20104e4: 40 00 05 46 call 20119fc <__errno> <== NOT EXECUTED
20104e8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20104ec: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20104f0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20104f4: 81 c7 e0 08 ret <== NOT EXECUTED
20104f8: 81 e8 00 00 restore <== NOT EXECUTED
0200c41c <IMFS_fifo_close>:
}
int IMFS_fifo_close(
rtems_libio_t *iop
)
{
200c41c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200c420: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
int err = pipe_release(&JNODE2PIPE(jnode), iop);
200c424: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
}
int IMFS_fifo_close(
rtems_libio_t *iop
)
{
200c428: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
int err = pipe_release(&JNODE2PIPE(jnode), iop);
200c42c: 7f ff fa e0 call 200afac <pipe_release> <== NOT EXECUTED
200c430: 90 04 60 50 add %l1, 0x50, %o0 <== NOT EXECUTED
if (! err) {
200c434: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
200c438: 02 80 00 06 be 200c450 <IMFS_fifo_close+0x34> <== NOT EXECUTED
200c43c: 80 a6 20 00 cmp %i0, 0 <== 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)
free(jnode);
}
IMFS_FIFO_RETURN(err);
200c440: 06 80 00 14 bl 200c490 <IMFS_fifo_close+0x74> <== NOT EXECUTED
200c444: 01 00 00 00 nop <== NOT EXECUTED
}
200c448: 81 c7 e0 08 ret <== NOT EXECUTED
200c44c: 81 e8 00 00 restore <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
int err = pipe_release(&JNODE2PIPE(jnode), iop);
if (! err) {
iop->flags &= ~LIBIO_FLAGS_OPEN;
200c450: c2 04 20 18 ld [ %l0 + 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)
200c454: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
int err = pipe_release(&JNODE2PIPE(jnode), iop);
if (! err) {
iop->flags &= ~LIBIO_FLAGS_OPEN;
200c458: 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)
200c45c: 40 00 01 d5 call 200cbb0 <rtems_libio_is_file_open> <== NOT EXECUTED
200c460: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
200c464: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200c468: 12 80 00 08 bne 200c488 <IMFS_fifo_close+0x6c> <== NOT EXECUTED
200c46c: 01 00 00 00 nop <== NOT EXECUTED
200c470: c2 14 60 34 lduh [ %l1 + 0x34 ], %g1 <== NOT EXECUTED
200c474: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200c478: 12 80 00 04 bne 200c488 <IMFS_fifo_close+0x6c> <== NOT EXECUTED
200c47c: 01 00 00 00 nop <== NOT EXECUTED
free(jnode);
200c480: 7f ff da 1b call 2002cec <free> <== NOT EXECUTED
200c484: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200c488: 81 c7 e0 08 ret <== NOT EXECUTED
200c48c: 81 e8 00 00 restore <== NOT EXECUTED
}
IMFS_FIFO_RETURN(err);
200c490: 40 00 15 5b call 20119fc <__errno> <== NOT EXECUTED
200c494: b0 20 00 18 neg %i0 <== NOT EXECUTED
200c498: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED
}
200c49c: 81 c7 e0 08 ret <== NOT EXECUTED
200c4a0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0200c2b8 <IMFS_fifo_ioctl>:
int IMFS_fifo_ioctl(
rtems_libio_t *iop,
uint32_t command,
void *buffer
)
{
200c2b8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int err;
if (command == FIONBIO) {
200c2bc: 03 20 01 19 sethi %hi(0x80046400), %g1 <== NOT EXECUTED
200c2c0: 82 10 62 7e or %g1, 0x27e, %g1 ! 8004667e <RAM_END+0x7dc4667e><== NOT EXECUTED
200c2c4: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
200c2c8: 02 80 00 0c be 200c2f8 <IMFS_fifo_ioctl+0x40> <== NOT EXECUTED
200c2cc: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
return 0;
}
}
else
err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop);
200c2d0: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
200c2d4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200c2d8: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 <== NOT EXECUTED
200c2dc: 7f ff fa 25 call 200ab70 <pipe_ioctl> <== NOT EXECUTED
200c2e0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
200c2e4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
200c2e8: 06 80 00 13 bl 200c334 <IMFS_fifo_ioctl+0x7c> <== NOT EXECUTED
200c2ec: b2 20 00 18 neg %i0, %i1 <== NOT EXECUTED
}
200c2f0: 81 c7 e0 08 ret <== NOT EXECUTED
200c2f4: 81 e8 00 00 restore <== NOT EXECUTED
)
{
int err;
if (command == FIONBIO) {
if (buffer == NULL)
200c2f8: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
200c2fc: 02 80 00 0e be 200c334 <IMFS_fifo_ioctl+0x7c> <== NOT EXECUTED
200c300: b2 10 20 0e mov 0xe, %i1 <== NOT EXECUTED
err = -EFAULT;
else {
if (*(int *)buffer)
200c304: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
200c308: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200c30c: 02 80 00 06 be 200c324 <IMFS_fifo_ioctl+0x6c> <== NOT EXECUTED
200c310: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
iop->flags |= LIBIO_FLAGS_NO_DELAY;
200c314: 82 10 60 01 or %g1, 1, %g1 <== NOT EXECUTED
200c318: c2 22 e0 18 st %g1, [ %o3 + 0x18 ] <== NOT EXECUTED
200c31c: 81 c7 e0 08 ret <== NOT EXECUTED
200c320: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
else
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
200c324: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED
200c328: c2 22 e0 18 st %g1, [ %o3 + 0x18 ] <== NOT EXECUTED
200c32c: 81 c7 e0 08 ret <== NOT EXECUTED
200c330: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
}
else
err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop);
IMFS_FIFO_RETURN(err);
200c334: 40 00 15 b2 call 20119fc <__errno> <== NOT EXECUTED
200c338: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200c33c: f2 22 00 00 st %i1, [ %o0 ] <== NOT EXECUTED
}
200c340: 81 c7 e0 08 ret <== NOT EXECUTED
200c344: 81 e8 00 00 restore <== NOT EXECUTED
0200c25c <IMFS_fifo_lseek>:
rtems_off64_t IMFS_fifo_lseek(
rtems_libio_t *iop,
rtems_off64_t offset,
int whence
)
{
200c25c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
200c260: 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
)
{
200c264: 98 10 00 18 mov %i0, %o4 <== NOT EXECUTED
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
200c268: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 <== NOT EXECUTED
200c26c: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
200c270: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200c274: 7f ff fa 21 call 200aaf8 <pipe_lseek> <== NOT EXECUTED
200c278: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
200c27c: 85 3a 20 1f sra %o0, 0x1f, %g2 <== NOT EXECUTED
200c280: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
200c284: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200c288: 06 80 00 05 bl 200c29c <IMFS_fifo_lseek+0x40> <== NOT EXECUTED
200c28c: 86 10 00 08 mov %o0, %g3 <== NOT EXECUTED
}
200c290: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
200c294: 81 c7 e0 08 ret <== NOT EXECUTED
200c298: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
rtems_off64_t offset,
int whence
)
{
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
IMFS_FIFO_RETURN(err);
200c29c: 40 00 15 d8 call 20119fc <__errno> <== NOT EXECUTED
200c2a0: a0 20 00 10 neg %l0 <== NOT EXECUTED
200c2a4: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
200c2a8: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
200c2ac: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
200c2b0: 10 bf ff f8 b 200c290 <IMFS_fifo_lseek+0x34> <== NOT EXECUTED
200c2b4: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
0200c4a4 <IMFS_fifo_open>:
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
200c4a4: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *jnode = iop->file_info;
int err = fifo_open(&JNODE2PIPE(jnode), iop);
200c4a8: d0 06 20 3c ld [ %i0 + 0x3c ], %o0
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
200c4ac: 92 10 00 18 mov %i0, %o1
IMFS_jnode_t *jnode = iop->file_info;
int err = fifo_open(&JNODE2PIPE(jnode), iop);
200c4b0: 7f ff fb 10 call 200b0f0 <fifo_open>
200c4b4: 90 02 20 50 add %o0, 0x50, %o0
IMFS_FIFO_RETURN(err);
200c4b8: b0 92 20 00 orcc %o0, 0, %i0
200c4bc: 06 80 00 04 bl 200c4cc <IMFS_fifo_open+0x28> <== ALWAYS TAKEN
200c4c0: 01 00 00 00 nop
}
200c4c4: 81 c7 e0 08 ret <== NOT EXECUTED
200c4c8: 81 e8 00 00 restore <== NOT EXECUTED
)
{
IMFS_jnode_t *jnode = iop->file_info;
int err = fifo_open(&JNODE2PIPE(jnode), iop);
IMFS_FIFO_RETURN(err);
200c4cc: 40 00 15 4c call 20119fc <__errno>
200c4d0: b0 20 00 18 neg %i0
200c4d4: f0 22 00 00 st %i0, [ %o0 ]
}
200c4d8: 81 c7 e0 08 ret
200c4dc: 91 e8 3f ff restore %g0, -1, %o0
0200c3b4 <IMFS_fifo_read>:
ssize_t IMFS_fifo_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
200c3b4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200c3b8: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
ssize_t IMFS_fifo_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
200c3bc: 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);
200c3c0: d0 04 20 50 ld [ %l0 + 0x50 ], %o0 <== NOT EXECUTED
200c3c4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200c3c8: 7f ff fa 03 call 200abd4 <pipe_read> <== NOT EXECUTED
200c3cc: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (err > 0)
200c3d0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
200c3d4: 04 80 00 08 ble 200c3f4 <IMFS_fifo_read+0x40> <== NOT EXECUTED
200c3d8: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
IMFS_update_atime(jnode);
200c3dc: 7f ff da 6f call 2002d98 <gettimeofday> <== NOT EXECUTED
200c3e0: 92 10 20 00 clr %o1 <== NOT EXECUTED
200c3e4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
200c3e8: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
200c3ec: 81 c7 e0 08 ret <== NOT EXECUTED
200c3f0: 81 e8 00 00 restore <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
200c3f4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200c3f8: 12 80 00 04 bne 200c408 <IMFS_fifo_read+0x54> <== NOT EXECUTED
200c3fc: 01 00 00 00 nop <== NOT EXECUTED
}
200c400: 81 c7 e0 08 ret <== NOT EXECUTED
200c404: 81 e8 00 00 restore <== NOT EXECUTED
int err = pipe_read(JNODE2PIPE(jnode), buffer, count, iop);
if (err > 0)
IMFS_update_atime(jnode);
IMFS_FIFO_RETURN(err);
200c408: 40 00 15 7d call 20119fc <__errno> <== NOT EXECUTED
200c40c: b0 20 00 18 neg %i0 <== NOT EXECUTED
200c410: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED
}
200c414: 81 c7 e0 08 ret <== NOT EXECUTED
200c418: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0200c348 <IMFS_fifo_write>:
ssize_t IMFS_fifo_write(
rtems_libio_t *iop,
const void *buffer,
size_t count
)
{
200c348: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200c34c: 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
)
{
200c350: 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);
200c354: d0 04 20 50 ld [ %l0 + 0x50 ], %o0 <== NOT EXECUTED
200c358: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200c35c: 7f ff fa 8d call 200ad90 <pipe_write> <== NOT EXECUTED
200c360: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (err > 0) {
200c364: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
200c368: 04 80 00 09 ble 200c38c <IMFS_fifo_write+0x44> <== NOT EXECUTED
200c36c: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
IMFS_mtime_ctime_update(jnode);
200c370: 7f ff da 8a call 2002d98 <gettimeofday> <== NOT EXECUTED
200c374: 92 10 20 00 clr %o1 <== NOT EXECUTED
200c378: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
200c37c: c2 24 20 48 st %g1, [ %l0 + 0x48 ] <== NOT EXECUTED
200c380: c2 24 20 44 st %g1, [ %l0 + 0x44 ] <== NOT EXECUTED
200c384: 81 c7 e0 08 ret <== NOT EXECUTED
200c388: 81 e8 00 00 restore <== NOT EXECUTED
}
IMFS_FIFO_RETURN(err);
200c38c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200c390: 12 80 00 04 bne 200c3a0 <IMFS_fifo_write+0x58> <== NOT EXECUTED
200c394: 01 00 00 00 nop <== NOT EXECUTED
}
200c398: 81 c7 e0 08 ret <== NOT EXECUTED
200c39c: 81 e8 00 00 restore <== NOT EXECUTED
int err = pipe_write(JNODE2PIPE(jnode), buffer, count, iop);
if (err > 0) {
IMFS_mtime_ctime_update(jnode);
}
IMFS_FIFO_RETURN(err);
200c3a0: 40 00 15 97 call 20119fc <__errno> <== NOT EXECUTED
200c3a4: b0 20 00 18 neg %i0 <== NOT EXECUTED
200c3a8: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED
}
200c3ac: 81 c7 e0 08 ret <== NOT EXECUTED
200c3b0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0200c5ac <IMFS_find_match_in_dir>:
IMFS_jnode_t *IMFS_find_match_in_dir(
IMFS_jnode_t *directory,
char *name
)
{
200c5ac: 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 );
200c5b0: 80 a6 20 00 cmp %i0, 0
200c5b4: 02 80 00 26 be 200c64c <IMFS_find_match_in_dir+0xa0> <== NEVER TAKEN
200c5b8: 80 a6 60 00 cmp %i1, 0
if ( !name )
200c5bc: 02 80 00 11 be 200c600 <IMFS_find_match_in_dir+0x54> <== NEVER TAKEN
200c5c0: 90 10 00 19 mov %i1, %o0
/*
* Check for "." and ".."
*/
if ( !strcmp( name, dotname ) )
200c5c4: 13 00 80 76 sethi %hi(0x201d800), %o1
200c5c8: 40 00 18 74 call 2012798 <strcmp>
200c5cc: 92 12 61 50 or %o1, 0x150, %o1 ! 201d950 <dotname>
200c5d0: 80 a2 20 00 cmp %o0, 0
200c5d4: 02 80 00 09 be 200c5f8 <IMFS_find_match_in_dir+0x4c> <== NEVER TAKEN
200c5d8: 90 10 00 19 mov %i1, %o0
return directory;
if ( !strcmp( name, dotdotname ) )
200c5dc: 13 00 80 76 sethi %hi(0x201d800), %o1
200c5e0: 40 00 18 6e call 2012798 <strcmp>
200c5e4: 92 12 61 58 or %o1, 0x158, %o1 ! 201d958 <dotdotname>
200c5e8: 80 a2 20 00 cmp %o0, 0
200c5ec: 32 80 00 07 bne,a 200c608 <IMFS_find_match_in_dir+0x5c> <== ALWAYS TAKEN
200c5f0: e0 06 20 50 ld [ %i0 + 0x50 ], %l0
return directory->Parent;
200c5f4: f0 06 20 08 ld [ %i0 + 8 ], %i0 <== NOT EXECUTED
200c5f8: 81 c7 e0 08 ret <== NOT EXECUTED
200c5fc: 81 e8 00 00 restore <== NOT EXECUTED
if ( !strcmp( name, the_jnode->name ) )
return the_jnode;
}
return 0;
}
200c600: 81 c7 e0 08 ret
200c604: 91 e8 20 00 restore %g0, 0, %o0
200c608: b0 06 20 54 add %i0, 0x54, %i0
if ( !strcmp( name, dotdotname ) )
return directory->Parent;
the_chain = &directory->info.directory.Entries;
for ( the_node = the_chain->first;
200c60c: 80 a4 00 18 cmp %l0, %i0
200c610: 12 80 00 07 bne 200c62c <IMFS_find_match_in_dir+0x80>
200c614: 90 10 00 19 mov %i1, %o0
200c618: 81 c7 e0 08 ret
200c61c: 91 e8 20 00 restore %g0, 0, %o0
200c620: 80 a4 00 18 cmp %l0, %i0
200c624: 02 bf ff f7 be 200c600 <IMFS_find_match_in_dir+0x54>
200c628: 90 10 00 19 mov %i1, %o0
!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 ) )
200c62c: 40 00 18 5b call 2012798 <strcmp>
200c630: 92 04 20 0c add %l0, 0xc, %o1
200c634: 80 a2 20 00 cmp %o0, 0
200c638: 32 bf ff fa bne,a 200c620 <IMFS_find_match_in_dir+0x74>
200c63c: e0 04 00 00 ld [ %l0 ], %l0
200c640: b0 10 00 10 mov %l0, %i0
200c644: 81 c7 e0 08 ret
200c648: 81 e8 00 00 restore
/*
* Check for fatal errors. A NULL directory show a problem in the
* the IMFS code.
*/
assert( directory );
200c64c: 11 00 80 76 sethi %hi(0x201d800), %o0 <== NOT EXECUTED
200c650: 15 00 80 76 sethi %hi(0x201d800), %o2 <== NOT EXECUTED
200c654: 17 00 80 76 sethi %hi(0x201d800), %o3 <== NOT EXECUTED
200c658: 90 12 20 e8 or %o0, 0xe8, %o0 <== NOT EXECUTED
200c65c: 94 12 a1 60 or %o2, 0x160, %o2 <== NOT EXECUTED
200c660: 96 12 e1 40 or %o3, 0x140, %o3 <== NOT EXECUTED
200c664: 40 00 00 a6 call 200c8fc <__assert_func> <== NOT EXECUTED
200c668: 92 10 20 2a mov 0x2a, %o1 <== NOT EXECUTED
0200c4e8 <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
)
{
200c4e8: 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;
200c4ec: c8 06 20 20 ld [ %i0 + 0x20 ], %g4
200c4f0: c6 06 20 24 ld [ %i0 + 0x24 ], %g3
200c4f4: c4 06 20 28 ld [ %i0 + 0x28 ], %g2
200c4f8: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
/*
* 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;
200c4fc: e4 06 20 1c ld [ %i0 + 0x1c ], %l2
loc = temp_mt_entry->mt_fs_root;
200c500: c8 27 bf f0 st %g4, [ %fp + -16 ]
200c504: c6 27 bf f4 st %g3, [ %fp + -12 ]
200c508: c4 27 bf f8 st %g2, [ %fp + -8 ]
200c50c: c2 27 bf fc st %g1, [ %fp + -4 ]
/*
* Set this to null to indicate that it is being unmounted.
*/
temp_mt_entry->mt_fs_root.node_access = NULL;
200c510: c0 26 20 1c clr [ %i0 + 0x1c ]
200c514: a0 07 bf ec add %fp, -20, %l0
do {
next = jnode->Parent;
loc.node_access = (void *)jnode;
200c518: e4 27 bf ec st %l2, [ %fp + -20 ]
*/
temp_mt_entry->mt_fs_root.node_access = NULL;
do {
next = jnode->Parent;
200c51c: e2 04 a0 08 ld [ %l2 + 8 ], %l1
loc.node_access = (void *)jnode;
IMFS_Set_handlers( &loc );
200c520: 7f ff fc a6 call 200b7b8 <IMFS_Set_handlers>
200c524: 90 10 00 10 mov %l0, %o0
if ( jnode->type != IMFS_DIRECTORY ) {
200c528: c2 04 a0 4c ld [ %l2 + 0x4c ], %g1
200c52c: 80 a0 60 01 cmp %g1, 1
200c530: 12 80 00 17 bne 200c58c <IMFS_fsunmount+0xa4>
200c534: 84 04 a0 54 add %l2, 0x54, %g2
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200c538: c2 04 a0 50 ld [ %l2 + 0x50 ], %g1
200c53c: 80 a0 40 02 cmp %g1, %g2
200c540: 22 80 00 14 be,a 200c590 <IMFS_fsunmount+0xa8>
200c544: 90 10 20 00 clr %o0
result = IMFS_unlink( NULL, &loc );
if (result != 0)
return -1;
jnode = next;
}
if ( jnode != NULL ) {
200c548: 80 a4 a0 00 cmp %l2, 0
200c54c: 02 80 00 0e be 200c584 <IMFS_fsunmount+0x9c>
200c550: 01 00 00 00 nop
if ( jnode->type == IMFS_DIRECTORY ) {
200c554: c2 04 a0 4c ld [ %l2 + 0x4c ], %g1
200c558: 80 a0 60 01 cmp %g1, 1
200c55c: 32 bf ff f0 bne,a 200c51c <IMFS_fsunmount+0x34> <== NEVER TAKEN
200c560: e4 27 bf ec st %l2, [ %fp + -20 ] <== NOT EXECUTED
200c564: c2 04 a0 50 ld [ %l2 + 0x50 ], %g1
200c568: 84 04 a0 54 add %l2, 0x54, %g2
200c56c: 80 a0 40 02 cmp %g1, %g2
200c570: 22 bf ff eb be,a 200c51c <IMFS_fsunmount+0x34>
200c574: e4 27 bf ec st %l2, [ %fp + -20 ]
if ( jnode_has_children( jnode ) )
jnode = jnode_get_first_child( jnode );
}
}
} while (jnode != NULL);
200c578: a4 90 60 00 orcc %g1, 0, %l2
200c57c: 32 bf ff e8 bne,a 200c51c <IMFS_fsunmount+0x34> <== ALWAYS TAKEN
200c580: e4 27 bf ec st %l2, [ %fp + -20 ]
return 0;
}
200c584: 81 c7 e0 08 ret
200c588: 91 e8 20 00 restore %g0, 0, %o0
result = IMFS_unlink( NULL, &loc );
if (result != 0)
return -1;
jnode = next;
} else if ( jnode_has_no_children( jnode ) ) {
result = IMFS_unlink( NULL, &loc );
200c58c: 90 10 20 00 clr %o0
200c590: 7f ff d8 3f call 200268c <IMFS_unlink>
200c594: 92 10 00 10 mov %l0, %o1
if (result != 0)
200c598: 80 a2 20 00 cmp %o0, 0
200c59c: 02 bf ff eb be 200c548 <IMFS_fsunmount+0x60> <== ALWAYS TAKEN
200c5a0: a4 10 00 11 mov %l1, %l2
if ( jnode->type == IMFS_DIRECTORY ) {
if ( jnode_has_children( jnode ) )
jnode = jnode_get_first_child( jnode );
}
}
} while (jnode != NULL);
200c5a4: 81 c7 e0 08 ret <== NOT EXECUTED
200c5a8: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0200c670 <IMFS_get_token>:
const char *path,
int pathlen,
char *token,
int *token_len
)
{
200c670: 9d e3 bf a0 save %sp, -96, %sp
register char c;
/*
* Copy a name into token. (Remember NULL is a token.)
*/
c = path[i];
200c674: a0 10 20 00 clr %l0
while ( (!IMFS_is_separator(c)) && (i < pathlen) && (i <= IMFS_NAME_MAX) ) {
200c678: 10 80 00 08 b 200c698 <IMFS_get_token+0x28>
200c67c: e2 0e 00 00 ldub [ %i0 ], %l1
200c680: 16 80 00 0c bge 200c6b0 <IMFS_get_token+0x40>
200c684: 80 a4 20 20 cmp %l0, 0x20
token[i] = c;
200c688: e2 2e 80 10 stb %l1, [ %i2 + %l0 ]
if ( i == IMFS_NAME_MAX )
200c68c: 02 80 00 2c be 200c73c <IMFS_get_token+0xcc>
200c690: a0 04 20 01 inc %l0
return IMFS_INVALID_TOKEN;
if ( !IMFS_is_valid_name_char(c) )
type = IMFS_INVALID_TOKEN;
c = path [++i];
200c694: e2 0e 00 10 ldub [ %i0 + %l0 ], %l1
/*
* Copy a name into token. (Remember NULL is a token.)
*/
c = path[i];
while ( (!IMFS_is_separator(c)) && (i < pathlen) && (i <= IMFS_NAME_MAX) ) {
200c698: a5 2c 60 18 sll %l1, 0x18, %l2
200c69c: 7f ff dd d6 call 2003df4 <rtems_filesystem_is_separator>
200c6a0: 91 3c a0 18 sra %l2, 0x18, %o0
200c6a4: 80 a2 20 00 cmp %o0, 0
200c6a8: 02 bf ff f6 be 200c680 <IMFS_get_token+0x10>
200c6ac: 80 a4 00 19 cmp %l0, %i1
/*
* Copy a seperator into token.
*/
if ( i == 0 ) {
200c6b0: 80 a4 20 00 cmp %l0, 0
200c6b4: 12 80 00 0c bne 200c6e4 <IMFS_get_token+0x74>
200c6b8: 82 06 80 10 add %i2, %l0, %g1
token[i] = c;
if ( (token[i] != '\0') && pathlen ) {
200c6bc: 80 a4 a0 00 cmp %l2, 0
200c6c0: 02 80 00 21 be 200c744 <IMFS_get_token+0xd4>
200c6c4: e2 2e 80 00 stb %l1, [ %i2 ]
200c6c8: 80 a6 60 00 cmp %i1, 0
200c6cc: 22 80 00 1f be,a 200c748 <IMFS_get_token+0xd8>
200c6d0: e0 26 c0 00 st %l0, [ %i3 ]
200c6d4: a0 10 20 01 mov 1, %l0
/*
* Set token_len to the number of characters copied.
*/
*token_len = i;
200c6d8: e0 26 c0 00 st %l0, [ %i3 ]
*/
if ( i == 0 ) {
token[i] = c;
if ( (token[i] != '\0') && pathlen ) {
200c6dc: 81 c7 e0 08 ret
200c6e0: 91 e8 20 01 restore %g0, 1, %o0
i++;
type = IMFS_CURRENT_DIR;
} else {
type = IMFS_NO_MORE_PATH;
}
} else if (token[ i-1 ] != '\0') {
200c6e4: c2 48 7f ff ldsb [ %g1 + -1 ], %g1
200c6e8: 80 a0 60 00 cmp %g1, 0
200c6ec: 32 80 00 02 bne,a 200c6f4 <IMFS_get_token+0x84> <== ALWAYS TAKEN
200c6f0: c0 2e 80 10 clrb [ %i2 + %l0 ]
/*
* Set token_len to the number of characters copied.
*/
*token_len = i;
200c6f4: e0 26 c0 00 st %l0, [ %i3 ]
* If we copied something that was not a seperator see if
* it was a special name.
*/
if ( type == IMFS_NAME ) {
if ( strcmp( token, "..") == 0 )
200c6f8: 90 10 00 1a mov %i2, %o0
200c6fc: 13 00 80 76 sethi %hi(0x201d800), %o1
200c700: b0 10 20 02 mov 2, %i0
200c704: 40 00 18 25 call 2012798 <strcmp>
200c708: 92 12 61 80 or %o1, 0x180, %o1
200c70c: 80 a2 20 00 cmp %o0, 0
200c710: 02 80 00 09 be 200c734 <IMFS_get_token+0xc4>
200c714: 90 10 00 1a mov %i2, %o0
type = IMFS_UP_DIR;
else if ( strcmp( token, "." ) == 0 )
200c718: 13 00 80 76 sethi %hi(0x201d800), %o1
200c71c: 40 00 18 1f call 2012798 <strcmp>
200c720: 92 12 61 78 or %o1, 0x178, %o1 ! 201d978 <__FUNCTION__.5518+0x18>
200c724: 80 a0 00 08 cmp %g0, %o0
200c728: b0 60 20 00 subx %g0, 0, %i0
200c72c: b0 0e 20 02 and %i0, 2, %i0
200c730: b0 06 20 01 inc %i0
type = IMFS_CURRENT_DIR;
}
return type;
}
200c734: 81 c7 e0 08 ret
200c738: 81 e8 00 00 restore
c = path[i];
while ( (!IMFS_is_separator(c)) && (i < pathlen) && (i <= IMFS_NAME_MAX) ) {
token[i] = c;
if ( i == IMFS_NAME_MAX )
200c73c: 81 c7 e0 08 ret
200c740: 91 e8 20 04 restore %g0, 4, %o0
/*
* Set token_len to the number of characters copied.
*/
*token_len = i;
200c744: e0 26 c0 00 st %l0, [ %i3 ]
type = IMFS_CURRENT_DIR;
} else {
type = IMFS_NO_MORE_PATH;
}
} else if (token[ i-1 ] != '\0') {
token[i] = '\0';
200c748: 81 c7 e0 08 ret
200c74c: 91 e8 20 00 restore %g0, 0, %o0
02002220 <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
)
{
2002220: 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,
2002224: 03 00 80 79 sethi %hi(0x201e400), %g1
2002228: c2 00 63 b8 ld [ %g1 + 0x3b8 ], %g1 ! 201e7b8 <imfs_rq_memfile_bytes_per_block>
int bit_mask;
/*
* check, whether requested bytes per block is valid
*/
for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) {
200222c: 80 a0 60 10 cmp %g1, 0x10
2002230: 02 80 00 0a be 2002258 <IMFS_initialize_support+0x38> <== NEVER TAKEN
2002234: 86 10 20 00 clr %g3
2002238: 84 10 20 20 mov 0x20, %g2
200223c: 80 a0 40 02 cmp %g1, %g2
2002240: 02 80 00 06 be 2002258 <IMFS_initialize_support+0x38>
2002244: 86 00 e0 01 inc %g3
2002248: 80 a0 e0 05 cmp %g3, 5
200224c: 12 bf ff fc bne 200223c <IMFS_initialize_support+0x1c> <== ALWAYS TAKEN
2002250: 85 28 a0 01 sll %g2, 1, %g2
2002254: 82 10 20 80 mov 0x80, %g1 <== NOT EXECUTED
if (bit_mask == requested_bytes_per_block) {
is_valid = true;
}
}
*dest_bytes_per_block = ((is_valid)
2002258: 05 00 80 7b sethi %hi(0x201ec00), %g2
/*
* 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();
200225c: 40 00 24 fa call 200b644 <IMFS_create_root_node>
2002260: c2 20 a3 38 st %g1, [ %g2 + 0x338 ] ! 201ef38 <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;
2002264: 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();
2002268: 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;
200226c: 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;
2002270: 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;
2002274: 13 00 80 75 sethi %hi(0x201d400), %o1
2002278: 90 06 20 38 add %i0, 0x38, %o0
200227c: 40 00 40 1c call 20122ec <memcpy>
2002280: 92 12 63 9c or %o1, 0x39c, %o1
/*
* Create custom file system data.
*/
fs_info = calloc( 1, sizeof( IMFS_fs_info_t ) );
2002284: 90 10 20 01 mov 1, %o0
2002288: 40 00 01 f6 call 2002a60 <calloc>
200228c: 92 10 20 10 mov 0x10, %o1
if ( !fs_info ) {
2002290: 80 a2 20 00 cmp %o0, 0
2002294: 02 80 00 11 be 20022d8 <IMFS_initialize_support+0xb8> <== NEVER TAKEN
2002298: 05 00 80 7b sethi %hi(0x201ec00), %g2
fs_info->ino_count = 1;
fs_info->memfile_handlers = memfile_handlers;
fs_info->directory_handlers = directory_handlers;
jnode = temp_mt_entry->mt_fs_root.node_access;
jnode->st_ino = fs_info->ino_count;
200229c: c8 06 20 1c ld [ %i0 + 0x1c ], %g4
/*
* Set st_ino for the root to 1.
*/
fs_info->instance = imfs_instance++;
20022a0: c2 00 a3 3c ld [ %g2 + 0x33c ], %g1
fs_info->ino_count = 1;
20022a4: 86 10 20 01 mov 1, %g3
20022a8: c6 22 20 04 st %g3, [ %o0 + 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;
20022ac: c6 21 20 38 st %g3, [ %g4 + 0x38 ]
/*
* Set st_ino for the root to 1.
*/
fs_info->instance = imfs_instance++;
20022b0: 86 00 60 01 add %g1, 1, %g3
20022b4: c6 20 a3 3c st %g3, [ %g2 + 0x33c ]
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;
20022b8: d0 26 20 34 st %o0, [ %i0 + 0x34 ]
*/
fs_info->instance = imfs_instance++;
fs_info->ino_count = 1;
fs_info->memfile_handlers = memfile_handlers;
fs_info->directory_handlers = directory_handlers;
20022bc: f6 22 20 0c st %i3, [ %o0 + 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;
20022c0: f4 22 20 08 st %i2, [ %o0 + 8 ]
/*
* Set st_ino for the root to 1.
*/
fs_info->instance = imfs_instance++;
20022c4: c2 22 00 00 st %g1, [ %o0 ]
jnode = temp_mt_entry->mt_fs_root.node_access;
jnode->st_ino = fs_info->ino_count;
/* Initialize POSIX FIFO/pipe module */
rtems_pipe_initialize();
20022c8: 40 00 22 0e call 200ab00 <rtems_pipe_initialize>
20022cc: b0 10 20 00 clr %i0
return 0;
}
20022d0: 81 c7 e0 08 ret
20022d4: 81 e8 00 00 restore
/*
* Create custom file system data.
*/
fs_info = calloc( 1, sizeof( IMFS_fs_info_t ) );
if ( !fs_info ) {
free(temp_mt_entry->mt_fs_root.node_access);
20022d8: d0 06 20 1c ld [ %i0 + 0x1c ], %o0 <== NOT EXECUTED
20022dc: 40 00 02 84 call 2002cec <free> <== NOT EXECUTED
20022e0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
20022e4: 40 00 3d c6 call 20119fc <__errno> <== NOT EXECUTED
20022e8: 01 00 00 00 nop <== NOT EXECUTED
20022ec: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
20022f0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20022f4: 81 c7 e0 08 ret <== NOT EXECUTED
20022f8: 81 e8 00 00 restore <== NOT EXECUTED
020022fc <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 */
)
{
20022fc: 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;
2002300: c2 06 00 00 ld [ %i0 ], %g1
2002304: c2 27 bf d8 st %g1, [ %fp + -40 ]
if ( info.hard_link.link_node->st_nlink >= LINK_MAX )
2002308: c2 10 60 34 lduh [ %g1 + 0x34 ], %g1
200230c: 80 a0 60 07 cmp %g1, 7
2002310: 18 80 00 1f bgu 200238c <IMFS_link+0x90>
2002314: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EMLINK );
/*
* Remove any separators at the end of the string.
*/
IMFS_get_token( token, strlen( token ), new_name, &i );
2002318: 40 00 41 86 call 2012930 <strlen>
200231c: 90 10 00 1a mov %i2, %o0
2002320: a0 07 bf b0 add %fp, -80, %l0
2002324: 92 10 00 08 mov %o0, %o1
2002328: 96 07 bf fc add %fp, -4, %o3
200232c: 94 10 00 10 mov %l0, %o2
2002330: 40 00 28 d0 call 200c670 <IMFS_get_token>
2002334: 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(
2002338: 90 10 00 19 mov %i1, %o0
200233c: 94 10 00 10 mov %l0, %o2
2002340: 92 10 20 03 mov 3, %o1
2002344: 17 00 00 28 sethi %hi(0xa000), %o3
2002348: 98 07 bf d8 add %fp, -40, %o4
200234c: 40 00 24 ce call 200b684 <IMFS_create_node>
2002350: 96 12 e1 ff or %o3, 0x1ff, %o3
new_name,
( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )),
&info
);
if ( !new_node )
2002354: 80 a2 20 00 cmp %o0, 0
2002358: 02 80 00 13 be 20023a4 <IMFS_link+0xa8> <== NEVER TAKEN
200235c: c2 07 bf d8 ld [ %fp + -40 ], %g1
/*
* 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 );
2002360: 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++;
2002364: c4 10 60 34 lduh [ %g1 + 0x34 ], %g2
IMFS_update_ctime( info.hard_link.link_node );
2002368: 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++;
200236c: 84 00 a0 01 inc %g2
IMFS_update_ctime( info.hard_link.link_node );
2002370: 40 00 02 8a call 2002d98 <gettimeofday>
2002374: c4 30 60 34 sth %g2, [ %g1 + 0x34 ]
2002378: c4 07 bf f4 ld [ %fp + -12 ], %g2
200237c: c2 07 bf d8 ld [ %fp + -40 ], %g1
2002380: c4 20 60 48 st %g2, [ %g1 + 0x48 ]
return 0;
}
2002384: 81 c7 e0 08 ret
2002388: 91 e8 20 00 restore %g0, 0, %o0
/*
* Verify this node can be linked to.
*/
info.hard_link.link_node = to_loc->node_access;
if ( info.hard_link.link_node->st_nlink >= LINK_MAX )
rtems_set_errno_and_return_minus_one( EMLINK );
200238c: 40 00 3d 9c call 20119fc <__errno>
2002390: b0 10 3f ff mov -1, %i0
2002394: 82 10 20 1f mov 0x1f, %g1
2002398: c2 22 00 00 st %g1, [ %o0 ]
200239c: 81 c7 e0 08 ret
20023a0: 81 e8 00 00 restore
( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )),
&info
);
if ( !new_node )
rtems_set_errno_and_return_minus_one( ENOMEM );
20023a4: 40 00 3d 96 call 20119fc <__errno> <== NOT EXECUTED
20023a8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20023ac: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
20023b0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20023b4: 81 c7 e0 08 ret <== NOT EXECUTED
20023b8: 81 e8 00 00 restore <== NOT EXECUTED
0200f358 <IMFS_memfile_addblock>:
MEMFILE_STATIC int IMFS_memfile_addblock(
IMFS_jnode_t *the_jnode,
unsigned int block
)
{
200f358: 9d e3 bf a0 save %sp, -96, %sp
block_p memory;
block_p *block_entry_ptr;
assert( the_jnode );
200f35c: 80 a6 20 00 cmp %i0, 0
200f360: 02 80 00 18 be 200f3c0 <IMFS_memfile_addblock+0x68> <== NEVER TAKEN
200f364: 11 00 80 77 sethi %hi(0x201dc00), %o0
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f368: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200f36c: 80 a0 60 05 cmp %g1, 5
200f370: 12 80 00 1b bne 200f3dc <IMFS_memfile_addblock+0x84> <== NEVER TAKEN
200f374: 90 10 00 18 mov %i0, %o0
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 );
200f378: 92 10 00 19 mov %i1, %o1
200f37c: 7f ff fe 61 call 200ed00 <IMFS_memfile_get_block_pointer>
200f380: 94 10 20 01 mov 1, %o2
if ( *block_entry_ptr )
200f384: 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 );
200f388: a0 10 00 08 mov %o0, %l0
if ( *block_entry_ptr )
200f38c: 80 a0 60 00 cmp %g1, 0
200f390: 02 80 00 04 be 200f3a0 <IMFS_memfile_addblock+0x48>
200f394: b0 10 20 00 clr %i0
if ( !memory )
return 1;
*block_entry_ptr = memory;
return 0;
}
200f398: 81 c7 e0 08 ret
200f39c: 81 e8 00 00 restore
#if 0
fprintf(stdout, "%d %p", block, block_entry_ptr );
fflush(stdout);
#endif
memory = memfile_alloc_block();
200f3a0: 7f ff fe 4b call 200eccc <memfile_alloc_block>
200f3a4: b0 10 20 01 mov 1, %i0
if ( !memory )
200f3a8: 80 a2 20 00 cmp %o0, 0
200f3ac: 02 bf ff fb be 200f398 <IMFS_memfile_addblock+0x40> <== NEVER TAKEN
200f3b0: 01 00 00 00 nop
return 1;
*block_entry_ptr = memory;
200f3b4: d0 24 00 00 st %o0, [ %l0 ]
return 0;
}
200f3b8: 81 c7 e0 08 ret
200f3bc: 91 e8 20 00 restore %g0, 0, %o0
)
{
block_p memory;
block_p *block_entry_ptr;
assert( the_jnode );
200f3c0: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f3c4: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f3c8: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f3cc: 94 12 a2 d0 or %o2, 0x2d0, %o2 <== NOT EXECUTED
200f3d0: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200f3d4: 7f ff f5 4a call 200c8fc <__assert_func> <== NOT EXECUTED
200f3d8: 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 );
200f3dc: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f3e0: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f3e4: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f3e8: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f3ec: 94 12 a2 d0 or %o2, 0x2d0, %o2 <== NOT EXECUTED
200f3f0: 96 12 e1 80 or %o3, 0x180, %o3 <== NOT EXECUTED
200f3f4: 7f ff f5 42 call 200c8fc <__assert_func> <== NOT EXECUTED
200f3f8: 92 10 21 6d mov 0x16d, %o1 <== NOT EXECUTED
0200f400 <IMFS_memfile_extend>:
MEMFILE_STATIC int IMFS_memfile_extend(
IMFS_jnode_t *the_jnode,
off_t new_length
)
{
200f400: 9d e3 bf a0 save %sp, -96, %sp
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f404: 80 a6 20 00 cmp %i0, 0
200f408: 02 80 00 5b be 200f574 <IMFS_memfile_extend+0x174> <== NEVER TAKEN
200f40c: 11 00 80 77 sethi %hi(0x201dc00), %o0
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f410: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200f414: 80 a0 60 05 cmp %g1, 5
200f418: 12 80 00 50 bne 200f558 <IMFS_memfile_extend+0x158> <== NEVER TAKEN
200f41c: 03 00 80 7b sethi %hi(0x201ec00), %g1
if ( the_jnode->type != IMFS_MEMORY_FILE )
rtems_set_errno_and_return_minus_one( EIO );
if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE )
200f420: e2 00 63 38 ld [ %g1 + 0x338 ], %l1 ! 201ef38 <imfs_memfile_bytes_per_block>
200f424: a1 34 60 02 srl %l1, 2, %l0
200f428: 92 10 00 10 mov %l0, %o1
200f42c: 40 00 2e 8d call 201ae60 <.umul>
200f430: 90 04 20 01 add %l0, 1, %o0
200f434: 92 10 00 10 mov %l0, %o1
200f438: 40 00 2e 8a call 201ae60 <.umul>
200f43c: 90 02 20 01 inc %o0
200f440: 92 10 00 11 mov %l1, %o1
200f444: 40 00 2e 87 call 201ae60 <.umul>
200f448: 90 02 3f ff add %o0, -1, %o0
200f44c: 82 10 20 00 clr %g1
200f450: 80 a0 40 19 cmp %g1, %i1
200f454: 04 80 00 37 ble 200f530 <IMFS_memfile_extend+0x130> <== ALWAYS TAKEN
200f458: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
if ( new_length <= the_jnode->info.file.size )
200f45c: e4 1e 20 50 ldd [ %i0 + 0x50 ], %l2 <== NOT EXECUTED
200f460: 80 a6 40 12 cmp %i1, %l2
200f464: 04 80 00 29 ble 200f508 <IMFS_memfile_extend+0x108> <== ALWAYS TAKEN
200f468: a9 3c 60 1f sra %l1, 0x1f, %l4
/*
* Calculate the number of range of blocks to allocate
*/
new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f46c: 96 10 00 11 mov %l1, %o3
200f470: 94 10 00 14 mov %l4, %o2
200f474: 90 10 00 19 mov %i1, %o0
200f478: 40 00 30 0c call 201b4a8 <__divdi3>
200f47c: 92 10 00 1a mov %i2, %o1
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f480: 90 10 00 12 mov %l2, %o0
/*
* Calculate the number of range of blocks to allocate
*/
new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f484: a0 10 00 09 mov %o1, %l0
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f488: 94 10 00 14 mov %l4, %o2
200f48c: 92 10 00 13 mov %l3, %o1
200f490: 40 00 30 06 call 201b4a8 <__divdi3>
200f494: 96 10 00 11 mov %l1, %o3
/*
* Now allocate each of those blocks.
*/
for ( block=old_blocks ; block<=new_blocks ; block++ ) {
200f498: 80 a4 00 09 cmp %l0, %o1
200f49c: 0a 80 00 21 bcs 200f520 <IMFS_memfile_extend+0x120> <== NEVER TAKEN
200f4a0: a4 10 00 09 mov %o1, %l2
200f4a4: 10 80 00 05 b 200f4b8 <IMFS_memfile_extend+0xb8>
200f4a8: a2 10 00 09 mov %o1, %l1
200f4ac: 80 a4 00 11 cmp %l0, %l1
200f4b0: 2a 80 00 1d bcs,a 200f524 <IMFS_memfile_extend+0x124>
200f4b4: f4 26 20 54 st %i2, [ %i0 + 0x54 ]
if ( IMFS_memfile_addblock( the_jnode, block ) ) {
200f4b8: 90 10 00 18 mov %i0, %o0
200f4bc: 7f ff ff a7 call 200f358 <IMFS_memfile_addblock>
200f4c0: 92 10 00 11 mov %l1, %o1
200f4c4: 80 a2 20 00 cmp %o0, 0
200f4c8: 22 bf ff f9 be,a 200f4ac <IMFS_memfile_extend+0xac> <== ALWAYS TAKEN
200f4cc: a2 04 60 01 inc %l1
for ( ; block>=old_blocks ; block-- ) {
200f4d0: 10 80 00 06 b 200f4e8 <IMFS_memfile_extend+0xe8> <== NOT EXECUTED
200f4d4: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
IMFS_memfile_remove_block( the_jnode, block );
200f4d8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
200f4dc: 7f ff fe dc call 200f04c <IMFS_memfile_remove_block> <== NOT EXECUTED
200f4e0: a2 04 7f ff add %l1, -1, %l1 <== 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-- ) {
200f4e4: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
200f4e8: 08 bf ff fc bleu 200f4d8 <IMFS_memfile_extend+0xd8> <== NOT EXECUTED
200f4ec: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
IMFS_memfile_remove_block( the_jnode, block );
}
rtems_set_errno_and_return_minus_one( ENOSPC );
200f4f0: 40 00 09 43 call 20119fc <__errno> <== NOT EXECUTED
200f4f4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200f4f8: 82 10 20 1c mov 0x1c, %g1 <== NOT EXECUTED
200f4fc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200f500: 81 c7 e0 08 ret <== NOT EXECUTED
200f504: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( new_length <= the_jnode->info.file.size )
200f508: 12 80 00 04 bne 200f518 <IMFS_memfile_extend+0x118> <== NEVER TAKEN
200f50c: 80 a6 80 13 cmp %i2, %l3
200f510: 18 bf ff d7 bgu 200f46c <IMFS_memfile_extend+0x6c>
200f514: a9 3c 60 1f sra %l1, 0x1f, %l4
200f518: 81 c7 e0 08 ret
200f51c: 91 e8 20 00 restore %g0, 0, %o0
/*
* Set the new length of the file.
*/
the_jnode->info.file.size = new_length;
200f520: f4 26 20 54 st %i2, [ %i0 + 0x54 ] <== NOT EXECUTED
200f524: f2 26 20 50 st %i1, [ %i0 + 0x50 ]
return 0;
}
200f528: 81 c7 e0 08 ret
200f52c: 91 e8 20 00 restore %g0, 0, %o0
assert( the_jnode->type == IMFS_MEMORY_FILE );
if ( the_jnode->type != IMFS_MEMORY_FILE )
rtems_set_errno_and_return_minus_one( EIO );
if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE )
200f530: 12 80 00 04 bne 200f540 <IMFS_memfile_extend+0x140> <== NEVER TAKEN
200f534: 80 a2 00 1a cmp %o0, %i2
200f538: 38 bf ff ca bgu,a 200f460 <IMFS_memfile_extend+0x60> <== ALWAYS TAKEN
200f53c: e4 1e 20 50 ldd [ %i0 + 0x50 ], %l2
rtems_set_errno_and_return_minus_one( EINVAL );
200f540: 40 00 09 2f call 20119fc <__errno> <== NOT EXECUTED
200f544: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200f548: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200f54c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200f550: 81 c7 e0 08 ret <== NOT EXECUTED
200f554: 81 e8 00 00 restore <== NOT EXECUTED
assert( the_jnode );
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f558: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f55c: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f560: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f564: 94 12 a2 e8 or %o2, 0x2e8, %o2 <== NOT EXECUTED
200f568: 96 12 e1 80 or %o3, 0x180, %o3 <== NOT EXECUTED
200f56c: 7f ff f4 e4 call 200c8fc <__assert_func> <== NOT EXECUTED
200f570: 92 10 21 35 mov 0x135, %o1 <== NOT EXECUTED
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f574: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f578: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f57c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f580: 94 12 a2 e8 or %o2, 0x2e8, %o2 <== NOT EXECUTED
200f584: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200f588: 7f ff f4 dd call 200c8fc <__assert_func> <== NOT EXECUTED
200f58c: 92 10 21 31 mov 0x131, %o1 <== NOT EXECUTED
0200ed00 <IMFS_memfile_get_block_pointer>:
#endif
IMFS_jnode_t *the_jnode,
unsigned int block,
int malloc_it
)
{
200ed00: 9d e3 bf a0 save %sp, -96, %sp
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200ed04: 80 a6 20 00 cmp %i0, 0
200ed08: 02 80 00 94 be 200ef58 <IMFS_memfile_get_block_pointer+0x258><== NEVER TAKEN
200ed0c: 11 00 80 77 sethi %hi(0x201dc00), %o0
if ( !the_jnode )
return NULL;
assert( the_jnode->type == IMFS_MEMORY_FILE );
200ed10: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200ed14: 80 a0 60 05 cmp %g1, 5
200ed18: 12 80 00 97 bne 200ef74 <IMFS_memfile_get_block_pointer+0x274><== NEVER TAKEN
200ed1c: 03 00 80 7b sethi %hi(0x201ec00), %g1
/*
* Is the block number in the simple indirect portion?
*/
if ( my_block <= LAST_INDIRECT ) {
200ed20: e0 00 63 38 ld [ %g1 + 0x338 ], %l0 ! 201ef38 <imfs_memfile_bytes_per_block>
200ed24: a1 34 20 02 srl %l0, 2, %l0
200ed28: 82 04 3f ff add %l0, -1, %g1
200ed2c: 80 a6 40 01 cmp %i1, %g1
200ed30: 08 80 00 20 bleu 200edb0 <IMFS_memfile_get_block_pointer+0xb0><== ALWAYS TAKEN
200ed34: 80 a6 a0 00 cmp %i2, 0
/*
* Is the block number in the doubly indirect portion?
*/
if ( my_block <= LAST_DOUBLY_INDIRECT ) {
200ed38: 90 04 20 01 add %l0, 1, %o0 <== NOT EXECUTED
200ed3c: 40 00 30 49 call 201ae60 <.umul> <== NOT EXECUTED
200ed40: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
200ed44: 82 02 3f ff add %o0, -1, %g1 <== NOT EXECUTED
200ed48: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
200ed4c: 18 80 00 21 bgu 200edd0 <IMFS_memfile_get_block_pointer+0xd0><== NOT EXECUTED
200ed50: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
#if 0
fprintf(stdout, "(d %d) ", block );
fflush(stdout);
#endif
my_block -= FIRST_DOUBLY_INDIRECT;
200ed54: b2 26 40 10 sub %i1, %l0, %i1 <== NOT EXECUTED
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
200ed58: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
200ed5c: 40 00 31 27 call 201b1f8 <.urem> <== NOT EXECUTED
200ed60: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
200ed64: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
fflush(stdout);
#endif
my_block -= FIRST_DOUBLY_INDIRECT;
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
200ed68: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
200ed6c: 40 00 30 77 call 201af48 <.udiv> <== NOT EXECUTED
200ed70: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
p = info->doubly_indirect;
if ( malloc_it ) {
200ed74: 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;
200ed78: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
p = info->doubly_indirect;
if ( malloc_it ) {
200ed7c: 02 80 00 42 be 200ee84 <IMFS_memfile_get_block_pointer+0x184><== NOT EXECUTED
200ed80: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 <== NOT EXECUTED
if ( !p ) {
200ed84: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ed88: 02 80 00 5e be 200ef00 <IMFS_memfile_get_block_pointer+0x200><== NOT EXECUTED
200ed8c: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
return 0;
info->doubly_indirect = p;
}
p1 = (block_p *)p[ doubly ];
200ed90: a1 2c 20 02 sll %l0, 2, %l0 <== NOT EXECUTED
200ed94: d0 00 40 10 ld [ %g1 + %l0 ], %o0 <== NOT EXECUTED
if ( !p1 ) {
200ed98: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ed9c: 02 80 00 52 be 200eee4 <IMFS_memfile_get_block_pointer+0x1e4><== NOT EXECUTED
200eda0: a0 00 40 10 add %g1, %l0, %l0 <== NOT EXECUTED
if ( !p1 )
return 0;
p[ doubly ] = (block_p) p1;
}
return (block_p *)&p1[ singly ];
200eda4: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
200eda8: 81 c7 e0 08 ret <== NOT EXECUTED
200edac: 91 ea 00 11 restore %o0, %l1, %o0 <== NOT EXECUTED
fprintf(stdout, "(s %d) ", block );
fflush(stdout);
#endif
p = info->indirect;
if ( malloc_it ) {
200edb0: 02 80 00 40 be 200eeb0 <IMFS_memfile_get_block_pointer+0x1b0>
200edb4: d0 06 20 58 ld [ %i0 + 0x58 ], %o0
if ( !p ) {
200edb8: 80 a2 20 00 cmp %o0, 0
200edbc: 02 80 00 43 be 200eec8 <IMFS_memfile_get_block_pointer+0x1c8>
200edc0: 01 00 00 00 nop
p2 = memfile_alloc_block();
if ( !p2 )
return 0;
p1[ doubly ] = (block_p) p2;
}
return (block_p *)&p2[ singly ];
200edc4: b3 2e 60 02 sll %i1, 2, %i1
200edc8: 81 c7 e0 08 ret
200edcc: 91 ea 00 19 restore %o0, %i1, %o0
#endif
/*
* Is the block number in the triply indirect portion?
*/
if ( my_block <= LAST_TRIPLY_INDIRECT ) {
200edd0: 90 02 20 01 inc %o0 <== NOT EXECUTED
200edd4: 40 00 30 23 call 201ae60 <.umul> <== NOT EXECUTED
200edd8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
200eddc: 90 02 3f ff add %o0, -1, %o0 <== NOT EXECUTED
200ede0: 80 a6 40 08 cmp %i1, %o0 <== NOT EXECUTED
200ede4: 18 80 00 31 bgu 200eea8 <IMFS_memfile_get_block_pointer+0x1a8><== NOT EXECUTED
200ede8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
my_block -= FIRST_TRIPLY_INDIRECT;
200edec: a2 26 40 11 sub %i1, %l1, %l1 <== NOT EXECUTED
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
200edf0: 40 00 31 02 call 201b1f8 <.urem> <== NOT EXECUTED
200edf4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
200edf8: 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;
200edfc: b2 10 00 08 mov %o0, %i1 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
200ee00: 40 00 30 52 call 201af48 <.udiv> <== NOT EXECUTED
200ee04: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS;
200ee08: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
200ee0c: 40 00 30 4f call 201af48 <.udiv> <== NOT EXECUTED
200ee10: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
200ee14: 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;
200ee18: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
200ee1c: 40 00 30 f7 call 201b1f8 <.urem> <== NOT EXECUTED
200ee20: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
p = info->triply_indirect;
if ( malloc_it ) {
200ee24: 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;
200ee28: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
p = info->triply_indirect;
if ( malloc_it ) {
200ee2c: 02 80 00 3c be 200ef1c <IMFS_memfile_get_block_pointer+0x21c><== NOT EXECUTED
200ee30: c2 06 20 60 ld [ %i0 + 0x60 ], %g1 <== NOT EXECUTED
if ( !p ) {
200ee34: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ee38: 02 80 00 56 be 200ef90 <IMFS_memfile_get_block_pointer+0x290><== NOT EXECUTED
200ee3c: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
return 0;
info->triply_indirect = p;
}
p1 = (block_p *) p[ triply ];
200ee40: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
200ee44: c4 00 40 11 ld [ %g1 + %l1 ], %g2 <== NOT EXECUTED
if ( !p1 ) {
200ee48: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200ee4c: 02 80 00 58 be 200efac <IMFS_memfile_get_block_pointer+0x2ac><== NOT EXECUTED
200ee50: a2 00 40 11 add %g1, %l1, %l1 <== NOT EXECUTED
if ( !p1 )
return 0;
p[ triply ] = (block_p) p1;
}
p2 = (block_p *)p1[ doubly ];
200ee54: a1 2c 20 02 sll %l0, 2, %l0 <== NOT EXECUTED
200ee58: d0 00 80 10 ld [ %g2 + %l0 ], %o0 <== NOT EXECUTED
if ( !p2 ) {
200ee5c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ee60: 12 bf ff d9 bne 200edc4 <IMFS_memfile_get_block_pointer+0xc4><== NOT EXECUTED
200ee64: a0 00 80 10 add %g2, %l0, %l0 <== NOT EXECUTED
p2 = memfile_alloc_block();
200ee68: 7f ff ff 99 call 200eccc <memfile_alloc_block> <== NOT EXECUTED
200ee6c: 01 00 00 00 nop <== NOT EXECUTED
if ( !p2 )
200ee70: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ee74: 22 80 00 13 be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200ee78: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
p1[ doubly ] = (block_p) p2;
200ee7c: 10 bf ff d2 b 200edc4 <IMFS_memfile_get_block_pointer+0xc4><== NOT EXECUTED
200ee80: d0 24 00 00 st %o0, [ %l0 ] <== NOT EXECUTED
}
return (block_p *)&p1[ singly ];
}
if ( !p )
200ee84: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ee88: 02 80 00 0e be 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200ee8c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
p = (block_p *)p[ doubly ];
200ee90: a1 2a 20 02 sll %o0, 2, %l0 <== NOT EXECUTED
200ee94: 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 ];
200ee98: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
if ( !p )
return 0;
p = (block_p *)p[ doubly ];
if ( !p )
200ee9c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200eea0: 12 80 00 08 bne 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200eea4: b0 00 40 11 add %g1, %l1, %i0 <== NOT EXECUTED
/*
* This means the requested block number is out of range.
*/
return 0;
}
200eea8: 81 c7 e0 08 ret <== NOT EXECUTED
200eeac: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
if ( !p )
return 0;
return &info->indirect[ my_block ];
200eeb0: b3 2e 60 02 sll %i1, 2, %i1
info->indirect = p;
}
return &info->indirect[ my_block ];
}
if ( !p )
200eeb4: 80 a2 20 00 cmp %o0, 0
200eeb8: 02 bf ff fc be 200eea8 <IMFS_memfile_get_block_pointer+0x1a8><== NEVER TAKEN
200eebc: b0 02 00 19 add %o0, %i1, %i0
/*
* This means the requested block number is out of range.
*/
return 0;
}
200eec0: 81 c7 e0 08 ret
200eec4: 81 e8 00 00 restore
p = info->indirect;
if ( malloc_it ) {
if ( !p ) {
p = memfile_alloc_block();
200eec8: 7f ff ff 81 call 200eccc <memfile_alloc_block>
200eecc: 01 00 00 00 nop
if ( !p )
200eed0: 80 a2 20 00 cmp %o0, 0
200eed4: 22 bf ff fb be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NEVER TAKEN
200eed8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
info->indirect = p;
200eedc: 10 bf ff ba b 200edc4 <IMFS_memfile_get_block_pointer+0xc4>
200eee0: d0 26 20 58 st %o0, [ %i0 + 0x58 ]
info->doubly_indirect = p;
}
p1 = (block_p *)p[ doubly ];
if ( !p1 ) {
p1 = memfile_alloc_block();
200eee4: 7f ff ff 7a call 200eccc <memfile_alloc_block> <== NOT EXECUTED
200eee8: 01 00 00 00 nop <== NOT EXECUTED
if ( !p1 )
200eeec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200eef0: 22 bf ff f4 be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200eef4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
p[ doubly ] = (block_p) p1;
200eef8: 10 bf ff ab b 200eda4 <IMFS_memfile_get_block_pointer+0xa4><== NOT EXECUTED
200eefc: d0 24 00 00 st %o0, [ %l0 ] <== NOT EXECUTED
p = info->doubly_indirect;
if ( malloc_it ) {
if ( !p ) {
p = memfile_alloc_block();
200ef00: 7f ff ff 73 call 200eccc <memfile_alloc_block> <== NOT EXECUTED
200ef04: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
200ef08: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
200ef0c: 22 bf ff ed be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200ef10: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
info->doubly_indirect = p;
200ef14: 10 bf ff 9f b 200ed90 <IMFS_memfile_get_block_pointer+0x90><== NOT EXECUTED
200ef18: c2 26 20 5c st %g1, [ %i0 + 0x5c ] <== NOT EXECUTED
p1[ doubly ] = (block_p) p2;
}
return (block_p *)&p2[ singly ];
}
if ( !p )
200ef1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ef20: 02 bf ff e8 be 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200ef24: 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 ];
200ef28: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
200ef2c: c2 00 40 11 ld [ %g1 + %l1 ], %g1 <== NOT EXECUTED
if ( !p1 )
200ef30: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ef34: 02 bf ff e3 be 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200ef38: a1 2a 20 02 sll %o0, 2, %l0 <== NOT EXECUTED
return 0;
p2 = (block_p *)p1[ doubly ];
200ef3c: c2 00 40 10 ld [ %g1 + %l0 ], %g1 <== NOT EXECUTED
if ( !p2 )
return 0;
return (block_p *)&p2[ singly ];
200ef40: b3 2e 60 02 sll %i1, 2, %i1 <== NOT EXECUTED
p1 = (block_p *) p[ triply ];
if ( !p1 )
return 0;
p2 = (block_p *)p1[ doubly ];
if ( !p2 )
200ef44: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ef48: 02 bf ff d8 be 200eea8 <IMFS_memfile_get_block_pointer+0x1a8><== NOT EXECUTED
200ef4c: b0 00 40 19 add %g1, %i1, %i0 <== NOT EXECUTED
/*
* This means the requested block number is out of range.
*/
return 0;
}
200ef50: 81 c7 e0 08 ret <== NOT EXECUTED
200ef54: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200ef58: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200ef5c: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200ef60: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200ef64: 94 12 a2 28 or %o2, 0x228, %o2 <== NOT EXECUTED
200ef68: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200ef6c: 7f ff f6 64 call 200c8fc <__assert_func> <== NOT EXECUTED
200ef70: 92 10 23 88 mov 0x388, %o1 <== NOT EXECUTED
if ( !the_jnode )
return NULL;
assert( the_jnode->type == IMFS_MEMORY_FILE );
200ef74: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200ef78: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200ef7c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200ef80: 94 12 a2 28 or %o2, 0x228, %o2 <== NOT EXECUTED
200ef84: 96 12 e1 80 or %o3, 0x180, %o3 <== NOT EXECUTED
200ef88: 7f ff f6 5d call 200c8fc <__assert_func> <== NOT EXECUTED
200ef8c: 92 10 23 8c mov 0x38c, %o1 <== NOT EXECUTED
p = info->triply_indirect;
if ( malloc_it ) {
if ( !p ) {
p = memfile_alloc_block();
200ef90: 7f ff ff 4f call 200eccc <memfile_alloc_block> <== NOT EXECUTED
200ef94: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
200ef98: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
200ef9c: 22 bf ff c9 be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200efa0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
info->triply_indirect = p;
200efa4: 10 bf ff a7 b 200ee40 <IMFS_memfile_get_block_pointer+0x140><== NOT EXECUTED
200efa8: c2 26 20 60 st %g1, [ %i0 + 0x60 ] <== NOT EXECUTED
}
p1 = (block_p *) p[ triply ];
if ( !p1 ) {
p1 = memfile_alloc_block();
200efac: 7f ff ff 48 call 200eccc <memfile_alloc_block> <== NOT EXECUTED
200efb0: 01 00 00 00 nop <== NOT EXECUTED
if ( !p1 )
200efb4: 84 92 20 00 orcc %o0, 0, %g2 <== NOT EXECUTED
200efb8: 22 bf ff c2 be,a 200eec0 <IMFS_memfile_get_block_pointer+0x1c0><== NOT EXECUTED
200efbc: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
p[ triply ] = (block_p) p1;
200efc0: 10 bf ff a5 b 200ee54 <IMFS_memfile_get_block_pointer+0x154><== NOT EXECUTED
200efc4: c4 24 40 00 st %g2, [ %l1 ] <== NOT EXECUTED
0200fa60 <IMFS_memfile_read>:
IMFS_jnode_t *the_jnode,
off_t start,
unsigned char *destination,
unsigned int length
)
{
200fa60: 9d e3 bf 98 save %sp, -104, %sp
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200fa64: a0 96 20 00 orcc %i0, 0, %l0
IMFS_jnode_t *the_jnode,
off_t start,
unsigned char *destination,
unsigned int length
)
{
200fa68: a4 10 00 19 mov %i1, %l2
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200fa6c: 02 80 00 b5 be 200fd40 <IMFS_memfile_read+0x2e0> <== NEVER TAKEN
200fa70: a6 10 00 1a mov %i2, %l3
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE ||
200fa74: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200fa78: 84 00 7f fb add %g1, -5, %g2
200fa7c: 80 a0 a0 01 cmp %g2, 1
200fa80: 18 80 00 a8 bgu 200fd20 <IMFS_memfile_read+0x2c0> <== NEVER TAKEN
200fa84: 80 a6 e0 00 cmp %i3, 0
/*
* Error checks on arguments
*/
assert( dest );
200fa88: 02 80 00 96 be 200fce0 <IMFS_memfile_read+0x280> <== NEVER TAKEN
200fa8c: 80 a7 20 00 cmp %i4, 0
/*
* If there is nothing to read, then quick exit.
*/
my_length = length;
if ( !my_length )
200fa90: 02 80 00 86 be 200fca8 <IMFS_memfile_read+0x248> <== NEVER TAKEN
200fa94: 80 a0 60 06 cmp %g1, 6
/*
* Linear files (as created from a tar file are easier to handle
* than block files).
*/
if (the_jnode->type == IMFS_LINEAR_FILE) {
200fa98: 02 80 00 5f be 200fc14 <IMFS_memfile_read+0x1b4> <== NEVER TAKEN
200fa9c: 86 10 20 00 clr %g3
* 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 )
200faa0: c4 04 20 50 ld [ %l0 + 0x50 ], %g2
/*
* 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;
200faa4: 82 10 00 1a mov %i2, %g1
if ( last_byte > the_jnode->info.file.size )
200faa8: 80 a0 c0 02 cmp %g3, %g2
200faac: c8 04 20 54 ld [ %l0 + 0x54 ], %g4
200fab0: 04 80 00 52 ble 200fbf8 <IMFS_memfile_read+0x198> <== ALWAYS TAKEN
200fab4: 9a 07 00 1a add %i4, %i2, %o5
my_length = the_jnode->info.file.size - start;
200fab8: b8 21 00 01 sub %g4, %g1, %i4 <== NOT EXECUTED
/*
* Phase 1: possibly the last part of one block
*/
start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
200fabc: 29 00 80 7b sethi %hi(0x201ec00), %l4 <== NOT EXECUTED
200fac0: e2 05 23 38 ld [ %l4 + 0x338 ], %l1 ! 201ef38 <imfs_memfile_bytes_per_block><== NOT EXECUTED
200fac4: 90 10 00 12 mov %l2, %o0
200fac8: ab 3c 60 1f sra %l1, 0x1f, %l5
200facc: 96 10 00 11 mov %l1, %o3
200fad0: 94 10 00 15 mov %l5, %o2
200fad4: 40 00 2f 5c call 201b844 <__moddi3>
200fad8: 92 10 00 13 mov %l3, %o1
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
200fadc: 90 10 00 12 mov %l2, %o0
/*
* Phase 1: possibly the last part of one block
*/
start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
200fae0: ac 10 00 09 mov %o1, %l6
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
200fae4: 94 10 00 15 mov %l5, %o2
200fae8: 92 10 00 13 mov %l3, %o1
200faec: 40 00 2e 6f call 201b4a8 <__divdi3>
200faf0: 96 10 00 11 mov %l1, %o3
if ( start_offset ) {
200faf4: 80 a5 a0 00 cmp %l6, 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;
200faf8: a4 10 00 09 mov %o1, %l2
if ( start_offset ) {
200fafc: aa 10 00 1b mov %i3, %l5
200fb00: 02 80 00 14 be 200fb50 <IMFS_memfile_read+0xf0>
200fb04: 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 );
200fb08: 90 10 00 10 mov %l0, %o0
200fb0c: 7f ff fc 7d call 200ed00 <IMFS_memfile_get_block_pointer>
200fb10: 94 10 20 00 clr %o2
assert( block_ptr );
200fb14: 80 a2 20 00 cmp %o0, 0
200fb18: 02 80 00 92 be 200fd60 <IMFS_memfile_read+0x300> <== NEVER TAKEN
200fb1c: a2 24 40 16 sub %l1, %l6, %l1
*/
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;
200fb20: 80 a7 00 11 cmp %i4, %l1
200fb24: 18 80 00 4f bgu 200fc60 <IMFS_memfile_read+0x200>
200fb28: b0 10 00 1c mov %i4, %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 );
200fb2c: d2 02 00 00 ld [ %o0 ], %o1
200fb30: 94 10 00 18 mov %i0, %o2
200fb34: 90 10 00 1b mov %i3, %o0
200fb38: 40 00 09 ed call 20122ec <memcpy>
200fb3c: 92 02 40 16 add %o1, %l6, %o1
dest += to_copy;
block++;
my_length -= to_copy;
200fb40: e2 05 23 38 ld [ %l4 + 0x338 ], %l1
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 );
dest += to_copy;
200fb44: aa 06 c0 18 add %i3, %i0, %l5
block++;
200fb48: a4 04 a0 01 inc %l2
my_length -= to_copy;
200fb4c: b8 27 00 18 sub %i4, %i0, %i4
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200fb50: 80 a7 00 11 cmp %i4, %l1
200fb54: 0a 80 00 15 bcs 200fba8 <IMFS_memfile_read+0x148>
200fb58: 80 a7 20 00 cmp %i4, 0
200fb5c: a8 15 23 38 or %l4, 0x338, %l4
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
200fb60: 90 10 00 10 mov %l0, %o0
200fb64: 92 10 00 12 mov %l2, %o1
200fb68: 7f ff fc 66 call 200ed00 <IMFS_memfile_get_block_pointer>
200fb6c: 94 10 20 00 clr %o2
assert( block_ptr );
200fb70: 80 a2 20 00 cmp %o0, 0
200fb74: 02 80 00 53 be 200fcc0 <IMFS_memfile_read+0x260> <== NEVER TAKEN
200fb78: 94 10 00 11 mov %l1, %o2
if ( !block_ptr )
return copied;
memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
200fb7c: d2 02 00 00 ld [ %o0 ], %o1
200fb80: 40 00 09 db call 20122ec <memcpy>
200fb84: 90 10 00 15 mov %l5, %o0
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200fb88: c2 05 00 00 ld [ %l4 ], %g1
if ( !block_ptr )
return copied;
memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
dest += to_copy;
block++;
my_length -= to_copy;
200fb8c: b8 27 00 11 sub %i4, %l1, %i4
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;
200fb90: aa 05 40 11 add %l5, %l1, %l5
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200fb94: 80 a0 40 1c cmp %g1, %i4
assert( block_ptr );
if ( !block_ptr )
return copied;
memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
dest += to_copy;
block++;
200fb98: a4 04 a0 01 inc %l2
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200fb9c: 08 bf ff f1 bleu 200fb60 <IMFS_memfile_read+0x100>
200fba0: b0 06 00 11 add %i0, %l1, %i0
* Phase 3: possibly the first part of one block
*/
assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );
if ( my_length ) {
200fba4: 80 a7 20 00 cmp %i4, 0
200fba8: 02 80 00 0e be 200fbe0 <IMFS_memfile_read+0x180>
200fbac: 90 07 bf f8 add %fp, -8, %o0
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
200fbb0: 92 10 00 12 mov %l2, %o1
200fbb4: 90 10 00 10 mov %l0, %o0
200fbb8: 7f ff fc 52 call 200ed00 <IMFS_memfile_get_block_pointer>
200fbbc: 94 10 20 00 clr %o2
assert( block_ptr );
200fbc0: 80 a2 20 00 cmp %o0, 0
200fbc4: 02 80 00 4f be 200fd00 <IMFS_memfile_read+0x2a0> <== NEVER TAKEN
200fbc8: b0 06 00 1c add %i0, %i4, %i0
if ( !block_ptr )
return copied;
memcpy( dest, &(*block_ptr)[ 0 ], my_length );
200fbcc: d2 02 00 00 ld [ %o0 ], %o1
200fbd0: 90 10 00 15 mov %l5, %o0
200fbd4: 40 00 09 c6 call 20122ec <memcpy>
200fbd8: 94 10 00 1c mov %i4, %o2
copied += my_length;
}
IMFS_update_atime( the_jnode );
200fbdc: 90 07 bf f8 add %fp, -8, %o0
200fbe0: 7f ff cc 6e call 2002d98 <gettimeofday>
200fbe4: 92 10 20 00 clr %o1
200fbe8: c2 07 bf f8 ld [ %fp + -8 ], %g1
200fbec: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
return copied;
}
200fbf0: 81 c7 e0 08 ret
200fbf4: 81 e8 00 00 restore
* 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 )
200fbf8: 12 bf ff b2 bne 200fac0 <IMFS_memfile_read+0x60> <== NEVER TAKEN
200fbfc: 29 00 80 7b sethi %hi(0x201ec00), %l4
200fc00: 80 a3 40 04 cmp %o5, %g4
200fc04: 08 bf ff b0 bleu 200fac4 <IMFS_memfile_read+0x64>
200fc08: e2 05 23 38 ld [ %l4 + 0x338 ], %l1
my_length = the_jnode->info.file.size - start;
200fc0c: 10 bf ff ae b 200fac4 <IMFS_memfile_read+0x64>
200fc10: b8 21 00 01 sub %g4, %g1, %i4
if (the_jnode->type == IMFS_LINEAR_FILE) {
unsigned char *file_ptr;
file_ptr = (unsigned char *)the_jnode->info.linearfile.direct;
if (my_length > (the_jnode->info.linearfile.size - start))
200fc14: d8 1c 20 50 ldd [ %l0 + 0x50 ], %o4 <== NOT EXECUTED
200fc18: 82 10 20 00 clr %g1 <== NOT EXECUTED
200fc1c: 86 a3 40 1a subcc %o5, %i2, %g3 <== NOT EXECUTED
200fc20: 84 63 00 19 subx %o4, %i1, %g2 <== NOT EXECUTED
200fc24: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200fc28: 04 80 00 10 ble 200fc68 <IMFS_memfile_read+0x208> <== NOT EXECUTED
200fc2c: d2 04 20 58 ld [ %l0 + 0x58 ], %o1 <== NOT EXECUTED
my_length = the_jnode->info.linearfile.size - start;
200fc30: b0 23 40 13 sub %o5, %l3, %i0 <== NOT EXECUTED
memcpy(dest, &file_ptr[start], my_length);
200fc34: 92 02 40 13 add %o1, %l3, %o1 <== NOT EXECUTED
200fc38: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
200fc3c: 40 00 09 ac call 20122ec <memcpy> <== NOT EXECUTED
200fc40: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
IMFS_update_atime( the_jnode );
200fc44: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
200fc48: 7f ff cc 54 call 2002d98 <gettimeofday> <== NOT EXECUTED
200fc4c: 92 10 20 00 clr %o1 <== NOT EXECUTED
200fc50: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
200fc54: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
return my_length;
200fc58: 81 c7 e0 08 ret <== NOT EXECUTED
200fc5c: 81 e8 00 00 restore <== 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;
200fc60: 10 bf ff b3 b 200fb2c <IMFS_memfile_read+0xcc>
200fc64: b0 10 00 11 mov %l1, %i0
if (the_jnode->type == IMFS_LINEAR_FILE) {
unsigned char *file_ptr;
file_ptr = (unsigned char *)the_jnode->info.linearfile.direct;
if (my_length > (the_jnode->info.linearfile.size - start))
200fc68: 12 80 00 04 bne 200fc78 <IMFS_memfile_read+0x218> <== NOT EXECUTED
200fc6c: 80 a7 00 03 cmp %i4, %g3 <== NOT EXECUTED
200fc70: 38 bf ff f1 bgu,a 200fc34 <IMFS_memfile_read+0x1d4> <== NOT EXECUTED
200fc74: b0 23 40 13 sub %o5, %l3, %i0 <== NOT EXECUTED
my_length = the_jnode->info.linearfile.size - start;
memcpy(dest, &file_ptr[start], my_length);
200fc78: 92 02 40 13 add %o1, %l3, %o1 <== NOT EXECUTED
if (the_jnode->type == IMFS_LINEAR_FILE) {
unsigned char *file_ptr;
file_ptr = (unsigned char *)the_jnode->info.linearfile.direct;
if (my_length > (the_jnode->info.linearfile.size - start))
200fc7c: b0 10 00 1c mov %i4, %i0 <== NOT EXECUTED
my_length = the_jnode->info.linearfile.size - start;
memcpy(dest, &file_ptr[start], my_length);
200fc80: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
200fc84: 40 00 09 9a call 20122ec <memcpy> <== NOT EXECUTED
200fc88: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
IMFS_update_atime( the_jnode );
200fc8c: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
200fc90: 7f ff cc 42 call 2002d98 <gettimeofday> <== NOT EXECUTED
200fc94: 92 10 20 00 clr %o1 <== NOT EXECUTED
200fc98: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
200fc9c: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
return my_length;
200fca0: 81 c7 e0 08 ret <== NOT EXECUTED
200fca4: 81 e8 00 00 restore <== NOT EXECUTED
* If there is nothing to read, then quick exit.
*/
my_length = length;
if ( !my_length )
rtems_set_errno_and_return_minus_one( EINVAL );
200fca8: 40 00 07 55 call 20119fc <__errno> <== NOT EXECUTED
200fcac: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200fcb0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200fcb4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200fcb8: 81 c7 e0 08 ret <== NOT EXECUTED
200fcbc: 81 e8 00 00 restore <== NOT EXECUTED
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
assert( block_ptr );
200fcc0: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fcc4: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fcc8: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fccc: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fcd0: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fcd4: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200fcd8: 7f ff f3 09 call 200c8fc <__assert_func> <== NOT EXECUTED
200fcdc: 92 10 22 a7 mov 0x2a7, %o1 <== NOT EXECUTED
/*
* Error checks on arguments
*/
assert( dest );
200fce0: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fce4: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fce8: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fcec: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fcf0: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fcf4: 96 12 e2 20 or %o3, 0x220, %o3 <== NOT EXECUTED
200fcf8: 7f ff f3 01 call 200c8fc <__assert_func> <== NOT EXECUTED
200fcfc: 92 10 22 5a mov 0x25a, %o1 <== NOT EXECUTED
assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );
if ( my_length ) {
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
assert( block_ptr );
200fd00: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fd04: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fd08: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fd0c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fd10: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fd14: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200fd18: 7f ff f2 f9 call 200c8fc <__assert_func> <== NOT EXECUTED
200fd1c: 92 10 22 b9 mov 0x2b9, %o1 <== NOT EXECUTED
assert( the_jnode );
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE ||
200fd20: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fd24: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fd28: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fd2c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fd30: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fd34: 96 12 e1 d0 or %o3, 0x1d0, %o3 <== NOT EXECUTED
200fd38: 7f ff f2 f1 call 200c8fc <__assert_func> <== NOT EXECUTED
200fd3c: 92 10 22 51 mov 0x251, %o1 <== NOT EXECUTED
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200fd40: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fd44: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fd48: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fd4c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fd50: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fd54: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200fd58: 7f ff f2 e9 call 200c8fc <__assert_func> <== NOT EXECUTED
200fd5c: 92 10 22 4c mov 0x24c, %o1 <== NOT EXECUTED
if ( start_offset ) {
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 );
assert( block_ptr );
200fd60: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200fd64: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200fd68: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200fd6c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200fd70: 94 12 a2 60 or %o2, 0x260, %o2 <== NOT EXECUTED
200fd74: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200fd78: 7f ff f2 e1 call 200c8fc <__assert_func> <== NOT EXECUTED
200fd7c: 92 10 22 96 mov 0x296, %o1 <== NOT EXECUTED
0200f0a8 <IMFS_memfile_remove>:
*/
int IMFS_memfile_remove(
IMFS_jnode_t *the_jnode
)
{
200f0a8: 9d e3 bf a0 save %sp, -96, %sp
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f0ac: 80 a6 20 00 cmp %i0, 0
200f0b0: 02 80 00 62 be 200f238 <IMFS_memfile_remove+0x190> <== NEVER TAKEN
200f0b4: 11 00 80 77 sethi %hi(0x201dc00), %o0
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f0b8: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200f0bc: 80 a0 60 05 cmp %g1, 5
200f0c0: 12 80 00 65 bne 200f254 <IMFS_memfile_remove+0x1ac> <== NEVER TAKEN
200f0c4: 23 00 80 7b sethi %hi(0x201ec00), %l1
* + indirect
* + doubly indirect
* + triply indirect
*/
info = &the_jnode->info.file;
200f0c8: c2 06 20 58 ld [ %i0 + 0x58 ], %g1
/*
* 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;
200f0cc: e6 04 63 38 ld [ %l1 + 0x338 ], %l3
* + indirect
* + doubly indirect
* + triply indirect
*/
info = &the_jnode->info.file;
200f0d0: 80 a0 60 00 cmp %g1, 0
200f0d4: 02 80 00 05 be 200f0e8 <IMFS_memfile_remove+0x40>
200f0d8: a7 34 e0 02 srl %l3, 2, %l3
if ( info->indirect ) {
memfile_free_blocks_in_table( &info->indirect, to_free );
200f0dc: 90 06 20 58 add %i0, 0x58, %o0
200f0e0: 7f ff ff ba call 200efc8 <memfile_free_blocks_in_table>
200f0e4: 92 10 00 13 mov %l3, %o1
}
if ( info->doubly_indirect ) {
200f0e8: c2 06 20 5c ld [ %i0 + 0x5c ], %g1
200f0ec: 80 a0 60 00 cmp %g1, 0
200f0f0: 02 80 00 1b be 200f15c <IMFS_memfile_remove+0xb4> <== ALWAYS TAKEN
200f0f4: c4 04 63 38 ld [ %l1 + 0x338 ], %g2
for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
200f0f8: 85 30 a0 02 srl %g2, 2, %g2 <== NOT EXECUTED
200f0fc: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200f100: 02 80 00 14 be 200f150 <IMFS_memfile_remove+0xa8> <== NOT EXECUTED
200f104: 90 10 20 00 clr %o0 <== NOT EXECUTED
200f108: 25 00 80 7b sethi %hi(0x201ec00), %l2 <== NOT EXECUTED
200f10c: a4 14 a3 38 or %l2, 0x338, %l2 ! 201ef38 <imfs_memfile_bytes_per_block><== NOT EXECUTED
200f110: 10 80 00 03 b 200f11c <IMFS_memfile_remove+0x74> <== NOT EXECUTED
200f114: a0 10 20 00 clr %l0 <== NOT EXECUTED
200f118: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 <== NOT EXECUTED
if ( info->doubly_indirect[i] ) {
200f11c: 91 2a 20 02 sll %o0, 2, %o0 <== NOT EXECUTED
200f120: c4 00 40 08 ld [ %g1 + %o0 ], %g2 <== NOT EXECUTED
200f124: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200f128: 02 80 00 04 be 200f138 <IMFS_memfile_remove+0x90> <== NOT EXECUTED
200f12c: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
memfile_free_blocks_in_table(
200f130: 7f ff ff a6 call 200efc8 <memfile_free_blocks_in_table> <== NOT EXECUTED
200f134: 92 10 00 13 mov %l3, %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++ ) {
200f138: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
200f13c: a0 04 20 01 inc %l0 <== NOT EXECUTED
200f140: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED
200f144: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
200f148: 18 bf ff f4 bgu 200f118 <IMFS_memfile_remove+0x70> <== NOT EXECUTED
200f14c: 90 10 00 10 mov %l0, %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 );
200f150: 90 06 20 5c add %i0, 0x5c, %o0 <== NOT EXECUTED
200f154: 7f ff ff 9d call 200efc8 <memfile_free_blocks_in_table> <== NOT EXECUTED
200f158: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
}
if ( info->triply_indirect ) {
200f15c: d0 06 20 60 ld [ %i0 + 0x60 ], %o0
200f160: 80 a2 20 00 cmp %o0, 0
200f164: 02 80 00 33 be 200f230 <IMFS_memfile_remove+0x188> <== ALWAYS TAKEN
200f168: c2 04 63 38 ld [ %l1 + 0x338 ], %g1
for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
200f16c: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED
200f170: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200f174: 22 80 00 2d be,a 200f228 <IMFS_memfile_remove+0x180> <== NOT EXECUTED
200f178: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
p = (block_p *) info->triply_indirect[i];
200f17c: e2 02 00 00 ld [ %o0 ], %l1 <== NOT EXECUTED
if ( !p ) /* ensure we have a valid pointer */
200f180: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
200f184: 22 80 00 29 be,a 200f228 <IMFS_memfile_remove+0x180> <== NOT EXECUTED
200f188: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
200f18c: 25 00 80 7b sethi %hi(0x201ec00), %l2 <== NOT EXECUTED
200f190: aa 10 20 00 clr %l5 <== NOT EXECUTED
200f194: a4 14 a3 38 or %l2, 0x338, %l2 <== NOT EXECUTED
200f198: a8 10 20 00 clr %l4 <== NOT EXECUTED
break;
for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) {
200f19c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200f1a0: 02 80 00 13 be 200f1ec <IMFS_memfile_remove+0x144> <== NOT EXECUTED
200f1a4: 90 02 00 15 add %o0, %l5, %o0 <== NOT EXECUTED
200f1a8: 90 10 20 00 clr %o0 <== NOT EXECUTED
200f1ac: a0 10 20 00 clr %l0 <== NOT EXECUTED
if ( p[j] ) {
200f1b0: 91 2a 20 02 sll %o0, 2, %o0 <== NOT EXECUTED
200f1b4: c2 04 40 08 ld [ %l1 + %o0 ], %g1 <== NOT EXECUTED
200f1b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200f1bc: 02 80 00 04 be 200f1cc <IMFS_memfile_remove+0x124> <== NOT EXECUTED
200f1c0: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
memfile_free_blocks_in_table( (block_p **)&p[j], to_free);
200f1c4: 7f ff ff 81 call 200efc8 <memfile_free_blocks_in_table> <== NOT EXECUTED
200f1c8: 92 10 00 13 mov %l3, %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++ ) {
200f1cc: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
200f1d0: a0 04 20 01 inc %l0 <== NOT EXECUTED
200f1d4: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED
200f1d8: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
200f1dc: 18 bf ff f5 bgu 200f1b0 <IMFS_memfile_remove+0x108> <== NOT EXECUTED
200f1e0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200f1e4: d0 06 20 60 ld [ %i0 + 0x60 ], %o0 <== NOT EXECUTED
if ( p[j] ) {
memfile_free_blocks_in_table( (block_p **)&p[j], to_free);
}
}
memfile_free_blocks_in_table(
200f1e8: 90 02 00 15 add %o0, %l5, %o0 <== NOT EXECUTED
200f1ec: 7f ff ff 77 call 200efc8 <memfile_free_blocks_in_table> <== NOT EXECUTED
200f1f0: 92 10 00 13 mov %l3, %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++ ) {
200f1f4: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
200f1f8: a8 05 20 01 inc %l4 <== NOT EXECUTED
200f1fc: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED
200f200: 80 a0 40 14 cmp %g1, %l4 <== NOT EXECUTED
200f204: 08 80 00 09 bleu 200f228 <IMFS_memfile_remove+0x180> <== NOT EXECUTED
200f208: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
p = (block_p *) info->triply_indirect[i];
200f20c: d0 06 20 60 ld [ %i0 + 0x60 ], %o0 <== NOT EXECUTED
if ( !p ) /* ensure we have a valid pointer */
200f210: ab 2d 20 02 sll %l4, 2, %l5 <== NOT EXECUTED
}
if ( info->triply_indirect ) {
for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
p = (block_p *) info->triply_indirect[i];
200f214: e2 02 00 15 ld [ %o0 + %l5 ], %l1 <== NOT EXECUTED
if ( !p ) /* ensure we have a valid pointer */
200f218: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
200f21c: 12 bf ff e1 bne 200f1a0 <IMFS_memfile_remove+0xf8> <== NOT EXECUTED
200f220: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
}
}
memfile_free_blocks_in_table(
(block_p **)&info->triply_indirect[i], to_free );
}
memfile_free_blocks_in_table(
200f224: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
200f228: 7f ff ff 68 call 200efc8 <memfile_free_blocks_in_table> <== NOT EXECUTED
200f22c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
(block_p **)&info->triply_indirect, to_free );
}
return 0;
}
200f230: 81 c7 e0 08 ret
200f234: 91 e8 20 00 restore %g0, 0, %o0
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f238: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f23c: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f240: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f244: 94 12 a2 78 or %o2, 0x278, %o2 <== NOT EXECUTED
200f248: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200f24c: 7f ff f5 ac call 200c8fc <__assert_func> <== NOT EXECUTED
200f250: 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 );
200f254: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f258: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f25c: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f260: 94 12 a2 78 or %o2, 0x278, %o2 <== NOT EXECUTED
200f264: 96 12 e1 80 or %o3, 0x180, %o3 <== NOT EXECUTED
200f268: 7f ff f5 a5 call 200c8fc <__assert_func> <== NOT EXECUTED
200f26c: 92 10 21 f2 mov 0x1f2, %o1 <== NOT EXECUTED
0200f04c <IMFS_memfile_remove_block>:
MEMFILE_STATIC int IMFS_memfile_remove_block(
IMFS_jnode_t *the_jnode,
unsigned int block
)
{
200f04c: 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 );
200f050: 94 10 20 00 clr %o2 <== NOT EXECUTED
200f054: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
200f058: 7f ff ff 2a call 200ed00 <IMFS_memfile_get_block_pointer> <== NOT EXECUTED
200f05c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
assert( block_ptr );
200f060: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200f064: 02 80 00 08 be 200f084 <IMFS_memfile_remove_block+0x38> <== NOT EXECUTED
200f068: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
if ( block_ptr ) {
ptr = *block_ptr;
200f06c: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
*block_ptr = 0;
200f070: c0 22 00 00 clr [ %o0 ] <== NOT EXECUTED
memfile_free_block( ptr );
200f074: 7f ff ff 0d call 200eca8 <memfile_free_block> <== NOT EXECUTED
200f078: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
}
return 1;
}
200f07c: 81 c7 e0 08 ret <== NOT EXECUTED
200f080: 81 e8 00 00 restore <== NOT EXECUTED
{
block_p *block_ptr;
block_p ptr;
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
assert( block_ptr );
200f084: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f088: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f08c: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f090: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f094: 94 12 a2 b0 or %o2, 0x2b0, %o2 <== NOT EXECUTED
200f098: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200f09c: 7f ff f6 18 call 200c8fc <__assert_func> <== NOT EXECUTED
200f0a0: 92 10 21 96 mov 0x196, %o1 <== NOT EXECUTED
0200f6bc <IMFS_memfile_write>:
IMFS_jnode_t *the_jnode,
off_t start,
const unsigned char *source,
unsigned int length
)
{
200f6bc: 9d e3 bf 98 save %sp, -104, %sp
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f6c0: a0 96 20 00 orcc %i0, 0, %l0
200f6c4: 02 80 00 8e be 200f8fc <IMFS_memfile_write+0x240> <== NEVER TAKEN
200f6c8: 11 00 80 77 sethi %hi(0x201dc00), %o0
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f6cc: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200f6d0: 80 a0 60 05 cmp %g1, 5
200f6d4: 12 80 00 83 bne 200f8e0 <IMFS_memfile_write+0x224> <== NEVER TAKEN
200f6d8: 80 a6 e0 00 cmp %i3, 0
/*
* Error check arguments
*/
assert( source );
200f6dc: 02 80 00 9f be 200f958 <IMFS_memfile_write+0x29c> <== NEVER TAKEN
200f6e0: 80 a7 20 00 cmp %i4, 0
/*
* If there is nothing to write, then quick exit.
*/
my_length = length;
if ( !my_length )
200f6e4: 02 80 00 71 be 200f8a8 <IMFS_memfile_write+0x1ec> <== NEVER TAKEN
200f6e8: 01 00 00 00 nop
* 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 ) {
200f6ec: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
200f6f0: 80 a0 60 00 cmp %g1, 0
200f6f4: 06 80 00 57 bl 200f850 <IMFS_memfile_write+0x194> <== NEVER TAKEN
200f6f8: 94 07 00 1a add %i4, %i2, %o2
200f6fc: 80 a0 60 00 cmp %g1, 0
200f700: 22 80 00 51 be,a 200f844 <IMFS_memfile_write+0x188> <== ALWAYS TAKEN
200f704: c2 04 20 54 ld [ %l0 + 0x54 ], %g1
/*
* Phase 1: possibly the last part of one block
*/
start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
200f708: 25 00 80 7b sethi %hi(0x201ec00), %l2 <== NOT EXECUTED
200f70c: e2 04 a3 38 ld [ %l2 + 0x338 ], %l1 ! 201ef38 <imfs_memfile_bytes_per_block>
200f710: 90 10 00 19 mov %i1, %o0
200f714: a7 3c 60 1f sra %l1, 0x1f, %l3
200f718: 96 10 00 11 mov %l1, %o3
200f71c: 94 10 00 13 mov %l3, %o2
200f720: 40 00 30 49 call 201b844 <__moddi3>
200f724: 92 10 00 1a mov %i2, %o1
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f728: 94 10 00 13 mov %l3, %o2
/*
* Phase 1: possibly the last part of one block
*/
start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
200f72c: a8 10 00 09 mov %o1, %l4
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
200f730: 90 10 00 19 mov %i1, %o0
200f734: 92 10 00 1a mov %i2, %o1
200f738: 40 00 2f 5c call 201b4a8 <__divdi3>
200f73c: 96 10 00 11 mov %l1, %o3
if ( start_offset ) {
200f740: b0 10 20 00 clr %i0
200f744: 80 a5 20 00 cmp %l4, 0
200f748: 12 80 00 2d bne 200f7fc <IMFS_memfile_write+0x140>
200f74c: a6 10 00 09 mov %o1, %l3
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200f750: 80 a7 00 11 cmp %i4, %l1
200f754: 0a 80 00 15 bcs 200f7a8 <IMFS_memfile_write+0xec>
200f758: 80 a7 20 00 cmp %i4, 0
200f75c: a4 14 a3 38 or %l2, 0x338, %l2
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
200f760: 90 10 00 10 mov %l0, %o0
200f764: 92 10 00 13 mov %l3, %o1
200f768: 7f ff fd 66 call 200ed00 <IMFS_memfile_get_block_pointer>
200f76c: 94 10 20 00 clr %o2
assert( block_ptr );
200f770: 80 a2 20 00 cmp %o0, 0
200f774: 02 80 00 53 be 200f8c0 <IMFS_memfile_write+0x204> <== NEVER TAKEN
200f778: 92 10 00 1b mov %i3, %o1
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 );
200f77c: d0 02 00 00 ld [ %o0 ], %o0
200f780: 40 00 0a db call 20122ec <memcpy>
200f784: 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 ) {
200f788: c2 04 80 00 ld [ %l2 ], %g1
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;
block++;
my_length -= to_copy;
200f78c: b8 27 00 11 sub %i4, %l1, %i4
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;
200f790: b6 06 c0 11 add %i3, %l1, %i3
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200f794: 80 a0 40 1c cmp %g1, %i4
#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;
block++;
200f798: a6 04 e0 01 inc %l3
/*
* Phase 2: all of zero of more blocks
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
200f79c: 08 bf ff f1 bleu 200f760 <IMFS_memfile_write+0xa4>
200f7a0: b0 06 00 11 add %i0, %l1, %i0
*/
assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );
to_copy = my_length;
if ( my_length ) {
200f7a4: 80 a7 20 00 cmp %i4, 0
200f7a8: 02 80 00 0e be 200f7e0 <IMFS_memfile_write+0x124>
200f7ac: 90 07 bf f8 add %fp, -8, %o0
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
200f7b0: 92 10 00 13 mov %l3, %o1
200f7b4: 90 10 00 10 mov %l0, %o0
200f7b8: 7f ff fd 52 call 200ed00 <IMFS_memfile_get_block_pointer>
200f7bc: 94 10 20 00 clr %o2
assert( block_ptr );
200f7c0: 80 a2 20 00 cmp %o0, 0
200f7c4: 02 80 00 5d be 200f938 <IMFS_memfile_write+0x27c> <== NEVER TAKEN
200f7c8: 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 );
200f7cc: d0 02 00 00 ld [ %o0 ], %o0
200f7d0: 92 10 00 1b mov %i3, %o1
200f7d4: 40 00 0a c6 call 20122ec <memcpy>
200f7d8: 94 10 00 1c mov %i4, %o2
my_length = 0;
copied += to_copy;
}
IMFS_mtime_ctime_update( the_jnode );
200f7dc: 90 07 bf f8 add %fp, -8, %o0
200f7e0: 7f ff cd 6e call 2002d98 <gettimeofday>
200f7e4: 92 10 20 00 clr %o1
200f7e8: c2 07 bf f8 ld [ %fp + -8 ], %g1
200f7ec: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
200f7f0: c2 24 20 44 st %g1, [ %l0 + 0x44 ]
return copied;
}
200f7f4: 81 c7 e0 08 ret
200f7f8: 81 e8 00 00 restore
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
if ( start_offset ) {
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 );
200f7fc: 90 10 00 10 mov %l0, %o0
200f800: 7f ff fd 40 call 200ed00 <IMFS_memfile_get_block_pointer>
200f804: 94 10 20 00 clr %o2
assert( block_ptr );
200f808: 80 a2 20 00 cmp %o0, 0
200f80c: 02 80 00 43 be 200f918 <IMFS_memfile_write+0x25c> <== NEVER TAKEN
200f810: b0 24 40 14 sub %l1, %l4, %i0
*/
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;
200f814: 80 a6 00 1c cmp %i0, %i4
200f818: 18 80 00 1a bgu 200f880 <IMFS_memfile_write+0x1c4>
200f81c: d0 02 00 00 ld [ %o0 ], %o0
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 );
200f820: 92 10 00 1b mov %i3, %o1
200f824: 90 02 00 14 add %o0, %l4, %o0
200f828: 94 10 00 18 mov %i0, %o2
200f82c: 40 00 0a b0 call 20122ec <memcpy>
200f830: b6 06 c0 18 add %i3, %i0, %i3
src += to_copy;
block++;
200f834: a6 04 e0 01 inc %l3
my_length -= to_copy;
copied += to_copy;
200f838: e2 04 a3 38 ld [ %l2 + 0x338 ], %l1
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 );
src += to_copy;
block++;
my_length -= to_copy;
200f83c: 10 bf ff c5 b 200f750 <IMFS_memfile_write+0x94>
200f840: b8 27 00 18 sub %i4, %i0, %i4
* 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 ) {
200f844: 80 a0 40 0a cmp %g1, %o2
200f848: 1a bf ff b1 bcc 200f70c <IMFS_memfile_write+0x50> <== NEVER TAKEN
200f84c: 25 00 80 7b sethi %hi(0x201ec00), %l2
status = IMFS_memfile_extend( the_jnode, last_byte );
200f850: 90 10 00 10 mov %l0, %o0
200f854: 7f ff fe eb call 200f400 <IMFS_memfile_extend>
200f858: 92 10 20 00 clr %o1
if ( status )
200f85c: 80 a2 20 00 cmp %o0, 0
200f860: 02 bf ff ab be 200f70c <IMFS_memfile_write+0x50> <== ALWAYS TAKEN
200f864: 25 00 80 7b sethi %hi(0x201ec00), %l2
rtems_set_errno_and_return_minus_one( ENOSPC );
200f868: 40 00 08 65 call 20119fc <__errno> <== NOT EXECUTED
200f86c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200f870: 82 10 20 1c mov 0x1c, %g1 <== NOT EXECUTED
200f874: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200f878: 81 c7 e0 08 ret <== NOT EXECUTED
200f87c: 81 e8 00 00 restore <== 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;
200f880: b0 10 00 1c mov %i4, %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 );
200f884: 92 10 00 1b mov %i3, %o1
200f888: 90 02 00 14 add %o0, %l4, %o0
200f88c: 94 10 00 18 mov %i0, %o2
200f890: 40 00 0a 97 call 20122ec <memcpy>
200f894: b6 06 c0 18 add %i3, %i0, %i3
src += to_copy;
block++;
200f898: a6 04 e0 01 inc %l3
my_length -= to_copy;
copied += to_copy;
200f89c: e2 04 a3 38 ld [ %l2 + 0x338 ], %l1
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 );
src += to_copy;
block++;
my_length -= to_copy;
200f8a0: 10 bf ff ac b 200f750 <IMFS_memfile_write+0x94>
200f8a4: b8 27 00 18 sub %i4, %i0, %i4
* If there is nothing to write, then quick exit.
*/
my_length = length;
if ( !my_length )
rtems_set_errno_and_return_minus_one( EINVAL );
200f8a8: 40 00 08 55 call 20119fc <__errno> <== NOT EXECUTED
200f8ac: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200f8b0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200f8b4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200f8b8: 81 c7 e0 08 ret <== NOT EXECUTED
200f8bc: 81 e8 00 00 restore <== NOT EXECUTED
*/
to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
assert( block_ptr );
200f8c0: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f8c4: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f8c8: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f8cc: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f8d0: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f8d4: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200f8d8: 7f ff f4 09 call 200c8fc <__assert_func> <== NOT EXECUTED
200f8dc: 92 10 23 30 mov 0x330, %o1 <== NOT EXECUTED
assert( the_jnode );
if ( !the_jnode )
rtems_set_errno_and_return_minus_one( EIO );
assert( the_jnode->type == IMFS_MEMORY_FILE );
200f8e0: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f8e4: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f8e8: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f8ec: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f8f0: 96 12 e1 80 or %o3, 0x180, %o3 <== NOT EXECUTED
200f8f4: 7f ff f4 02 call 200c8fc <__assert_func> <== NOT EXECUTED
200f8f8: 92 10 22 e7 mov 0x2e7, %o1 <== NOT EXECUTED
/*
* Perform internal consistency checks
*/
assert( the_jnode );
200f8fc: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f900: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f904: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f908: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f90c: 96 12 e1 70 or %o3, 0x170, %o3 <== NOT EXECUTED
200f910: 7f ff f3 fb call 200c8fc <__assert_func> <== NOT EXECUTED
200f914: 92 10 22 e3 mov 0x2e3, %o1 <== NOT EXECUTED
if ( start_offset ) {
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 );
assert( block_ptr );
200f918: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f91c: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f920: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f924: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f928: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f92c: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200f930: 7f ff f3 f3 call 200c8fc <__assert_func> <== NOT EXECUTED
200f934: 92 10 23 1c mov 0x31c, %o1 <== NOT EXECUTED
assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );
to_copy = my_length;
if ( my_length ) {
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
assert( block_ptr );
200f938: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f93c: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f940: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f944: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f948: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f94c: 96 12 e1 b8 or %o3, 0x1b8, %o3 <== NOT EXECUTED
200f950: 7f ff f3 eb call 200c8fc <__assert_func> <== NOT EXECUTED
200f954: 92 10 23 46 mov 0x346, %o1 <== NOT EXECUTED
/*
* Error check arguments
*/
assert( source );
200f958: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f95c: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f960: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f964: 94 12 a2 48 or %o2, 0x248, %o2 <== NOT EXECUTED
200f968: 96 12 e1 c8 or %o3, 0x1c8, %o3 <== NOT EXECUTED
200f96c: 7f ff f3 e4 call 200c8fc <__assert_func> <== NOT EXECUTED
200f970: 92 10 22 ef mov 0x2ef, %o1 <== NOT EXECUTED
020023bc <IMFS_mknod>:
const char *token, /* IN */
mode_t mode, /* IN */
dev_t dev, /* IN */
rtems_filesystem_location_info_t *pathloc /* IN/OUT */
)
{
20023bc: 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 );
20023c0: 40 00 41 5c call 2012930 <strlen>
20023c4: 90 10 00 18 mov %i0, %o0
20023c8: a0 07 bf b8 add %fp, -72, %l0
20023cc: 92 10 00 08 mov %o0, %o1
20023d0: 96 07 bf fc add %fp, -4, %o3
20023d4: 90 10 00 18 mov %i0, %o0
20023d8: 40 00 28 a6 call 200c670 <IMFS_get_token>
20023dc: 94 10 00 10 mov %l0, %o2
/*
* Figure out what type of IMFS node this is.
*/
if ( S_ISDIR(mode) )
20023e0: 03 00 00 3c sethi %hi(0xf000), %g1
20023e4: 05 00 00 10 sethi %hi(0x4000), %g2
20023e8: 82 0e 40 01 and %i1, %g1, %g1
20023ec: 80 a0 40 02 cmp %g1, %g2
20023f0: 02 80 00 23 be 200247c <IMFS_mknod+0xc0>
20023f4: 05 00 00 20 sethi %hi(0x8000), %g2
type = IMFS_DIRECTORY;
else if ( S_ISREG(mode) )
20023f8: 80 a0 40 02 cmp %g1, %g2
20023fc: 02 80 00 08 be 200241c <IMFS_mknod+0x60>
2002400: 92 10 20 05 mov 5, %o1
type = IMFS_MEMORY_FILE;
else if ( S_ISBLK(mode) || S_ISCHR(mode) ) {
2002404: 05 00 00 08 sethi %hi(0x2000), %g2
2002408: 80 a0 40 02 cmp %g1, %g2
200240c: 12 80 00 0f bne 2002448 <IMFS_mknod+0x8c>
2002410: 05 00 00 18 sethi %hi(0x6000), %g2
type = IMFS_DEVICE;
rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor );
2002414: f4 3f bf e0 std %i2, [ %fp + -32 ]
2002418: 92 10 20 02 mov 2, %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(
200241c: 90 10 00 1c mov %i4, %o0
2002420: 94 10 00 10 mov %l0, %o2
2002424: 96 10 00 19 mov %i1, %o3
2002428: 98 07 bf e0 add %fp, -32, %o4
200242c: 40 00 24 96 call 200b684 <IMFS_create_node>
2002430: b0 10 20 00 clr %i0
new_name,
mode,
&info
);
if ( !new_node )
2002434: 80 a2 20 00 cmp %o0, 0
2002438: 02 80 00 1b be 20024a4 <IMFS_mknod+0xe8> <== NEVER TAKEN
200243c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOMEM );
return 0;
}
2002440: 81 c7 e0 08 ret
2002444: 81 e8 00 00 restore
*/
if ( S_ISDIR(mode) )
type = IMFS_DIRECTORY;
else if ( S_ISREG(mode) )
type = IMFS_MEMORY_FILE;
else if ( S_ISBLK(mode) || S_ISCHR(mode) ) {
2002448: 80 a0 40 02 cmp %g1, %g2
200244c: 22 bf ff f3 be,a 2002418 <IMFS_mknod+0x5c>
2002450: f4 3f bf e0 std %i2, [ %fp + -32 ]
type = IMFS_DEVICE;
rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor );
}
else if (S_ISFIFO(mode))
2002454: 05 00 00 04 sethi %hi(0x1000), %g2
2002458: 80 a0 40 02 cmp %g1, %g2
200245c: 02 bf ff f0 be 200241c <IMFS_mknod+0x60> <== ALWAYS TAKEN
2002460: 92 10 20 07 mov 7, %o1
type = IMFS_FIFO;
else {
rtems_set_errno_and_return_minus_one( EINVAL );
2002464: 40 00 3d 66 call 20119fc <__errno> <== NOT EXECUTED
2002468: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200246c: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2002470: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002474: 81 c7 e0 08 ret <== NOT EXECUTED
2002478: 81 e8 00 00 restore <== NOT EXECUTED
200247c: 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(
2002480: 90 10 00 1c mov %i4, %o0
2002484: 94 10 00 10 mov %l0, %o2
2002488: 96 10 00 19 mov %i1, %o3
200248c: 98 07 bf e0 add %fp, -32, %o4
2002490: 40 00 24 7d call 200b684 <IMFS_create_node>
2002494: b0 10 20 00 clr %i0
new_name,
mode,
&info
);
if ( !new_node )
2002498: 80 a2 20 00 cmp %o0, 0
200249c: 12 80 00 06 bne 20024b4 <IMFS_mknod+0xf8> <== ALWAYS TAKEN
20024a0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOMEM );
20024a4: 40 00 3d 56 call 20119fc <__errno> <== NOT EXECUTED
20024a8: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
20024ac: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
20024b0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return 0;
}
20024b4: 81 c7 e0 08 ret
20024b8: 81 e8 00 00 restore
020024bc <IMFS_mount>:
#include <rtems/seterr.h>
int IMFS_mount(
rtems_filesystem_mount_table_entry_t *mt_entry
)
{
20024bc: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node;
node = mt_entry->mt_point_node.node_access;
20024c0: c2 06 20 08 ld [ %i0 + 8 ], %g1
/*
* Is the node that we are mounting onto a directory node ?
*/
if ( node->type != IMFS_DIRECTORY )
20024c4: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
20024c8: 80 a0 a0 01 cmp %g2, 1
20024cc: 12 80 00 05 bne 20024e0 <IMFS_mount+0x24> <== NEVER TAKEN
20024d0: 01 00 00 00 nop
/*
* Set mt_fs pointer to point to the mount table entry for
* the mounted file system.
*/
node->info.directory.mt_fs = mt_entry;
20024d4: f0 20 60 5c st %i0, [ %g1 + 0x5c ]
return 0;
}
20024d8: 81 c7 e0 08 ret
20024dc: 91 e8 20 00 restore %g0, 0, %o0
/*
* Is the node that we are mounting onto a directory node ?
*/
if ( node->type != IMFS_DIRECTORY )
rtems_set_errno_and_return_minus_one( ENOTDIR );
20024e0: 40 00 3d 47 call 20119fc <__errno> <== NOT EXECUTED
20024e4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20024e8: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED
20024ec: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20024f0: 81 c7 e0 08 ret <== NOT EXECUTED
20024f4: 81 e8 00 00 restore <== NOT EXECUTED
020049a0 <IMFS_print_jnode>:
*/
void IMFS_print_jnode(
IMFS_jnode_t *the_jnode
)
{
20049a0: 9d e3 bf a0 save %sp, -96, %sp
assert( the_jnode );
20049a4: 80 a6 20 00 cmp %i0, 0
20049a8: 02 80 00 5b be 2004b14 <IMFS_print_jnode+0x174> <== NEVER TAKEN
20049ac: 21 00 80 a1 sethi %hi(0x2028400), %l0
fprintf(stdout, "%s", the_jnode->name );
20049b0: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 ! 2028490 <_impure_ptr>
20049b4: 90 06 20 0c add %i0, 0xc, %o0
20049b8: 40 00 46 b4 call 2016488 <fputs>
20049bc: d2 00 60 08 ld [ %g1 + 8 ], %o1
switch( the_jnode->type ) {
20049c0: d4 06 20 4c ld [ %i0 + 0x4c ], %o2
20049c4: 80 a2 a0 07 cmp %o2, 7
20049c8: 08 80 00 0f bleu 2004a04 <IMFS_print_jnode+0x64> <== ALWAYS TAKEN
20049cc: 83 2a a0 02 sll %o2, 2, %g1
fprintf(stdout, " FIFO not printed\n" );
assert(0);
break;
default:
fprintf(stdout, " bad type %d\n", the_jnode->type );
20049d0: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 <== NOT EXECUTED
20049d4: 13 00 80 99 sethi %hi(0x2026400), %o1 <== NOT EXECUTED
20049d8: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
20049dc: 40 00 46 4d call 2016310 <fprintf> <== NOT EXECUTED
20049e0: 92 12 60 d0 or %o1, 0xd0, %o1 <== NOT EXECUTED
assert(0);
20049e4: 92 10 20 6c mov 0x6c, %o1 <== NOT EXECUTED
assert(0);
break;
case IMFS_SYM_LINK:
fprintf(stdout, " links not printed\n" );
assert(0);
20049e8: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
20049ec: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED
20049f0: 17 00 80 99 sethi %hi(0x2026400), %o3 <== NOT EXECUTED
20049f4: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
20049f8: 94 12 a2 10 or %o2, 0x210, %o2 <== NOT EXECUTED
20049fc: 40 00 02 bc call 20054ec <__assert_func> <== NOT EXECUTED
2004a00: 96 12 e0 b0 or %o3, 0xb0, %o3 <== NOT EXECUTED
)
{
assert( the_jnode );
fprintf(stdout, "%s", the_jnode->name );
switch( the_jnode->type ) {
2004a04: 05 00 80 12 sethi %hi(0x2004800), %g2
2004a08: 84 10 a1 44 or %g2, 0x144, %g2 ! 2004944 <console_inbyte_nonblocking+0xac>
2004a0c: c2 00 80 01 ld [ %g2 + %g1 ], %g1
2004a10: 81 c0 40 00 jmp %g1
2004a14: 01 00 00 00 nop
fprintf(stdout, " links not printed\n" );
assert(0);
break;
case IMFS_FIFO:
fprintf(stdout, " FIFO not printed\n" );
2004a18: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 <== NOT EXECUTED
2004a1c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004a20: d6 00 60 08 ld [ %g1 + 8 ], %o3 <== NOT EXECUTED
2004a24: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED
2004a28: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
2004a2c: 40 00 49 b6 call 2017104 <fwrite> <== NOT EXECUTED
2004a30: 90 12 20 b8 or %o0, 0xb8, %o0 ! 20264b8 <rtems_filesystem_mount_table_size+0x16c0><== NOT EXECUTED
assert(0);
2004a34: 10 bf ff ed b 20049e8 <IMFS_print_jnode+0x48> <== NOT EXECUTED
2004a38: 92 10 20 67 mov 0x67, %o1 <== NOT EXECUTED
fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")",
the_jnode->info.device.major, the_jnode->info.device.minor );
break;
case IMFS_LINEAR_FILE:
fprintf(stdout, " (file %" PRId32 " %p)",
2004a3c: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 <== NOT EXECUTED
2004a40: d6 06 20 58 ld [ %i0 + 0x58 ], %o3 <== NOT EXECUTED
2004a44: d4 06 20 54 ld [ %i0 + 0x54 ], %o2 <== NOT EXECUTED
2004a48: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
2004a4c: 13 00 80 99 sethi %hi(0x2026400), %o1 <== NOT EXECUTED
2004a50: 40 00 46 30 call 2016310 <fprintf> <== NOT EXECUTED
2004a54: 92 12 60 78 or %o1, 0x78, %o1 ! 2026478 <rtems_filesystem_mount_table_size+0x1680><== NOT EXECUTED
default:
fprintf(stdout, " bad type %d\n", the_jnode->type );
assert(0);
break;
}
puts("");
2004a58: 31 00 80 99 sethi %hi(0x2026400), %i0 <== NOT EXECUTED
2004a5c: 40 00 4d b4 call 201812c <puts> <== NOT EXECUTED
2004a60: 91 ee 20 e0 restore %i0, 0xe0, %o0 <== NOT EXECUTED
the_jnode->info.file.indirect,
the_jnode->info.file.doubly_indirect,
the_jnode->info.file.triply_indirect
);
#else
fprintf(stdout, " (file %" PRId32 ")",
2004a64: c2 04 20 90 ld [ %l0 + 0x90 ], %g1
2004a68: d4 06 20 54 ld [ %i0 + 0x54 ], %o2
2004a6c: d0 00 60 08 ld [ %g1 + 8 ], %o0
2004a70: 13 00 80 99 sethi %hi(0x2026400), %o1
2004a74: 40 00 46 27 call 2016310 <fprintf>
2004a78: 92 12 60 88 or %o1, 0x88, %o1 ! 2026488 <rtems_filesystem_mount_table_size+0x1690>
default:
fprintf(stdout, " bad type %d\n", the_jnode->type );
assert(0);
break;
}
puts("");
2004a7c: 31 00 80 99 sethi %hi(0x2026400), %i0
2004a80: 40 00 4d ab call 201812c <puts>
2004a84: 91 ee 20 e0 restore %i0, 0xe0, %o0
fprintf(stdout, " links not printed\n" );
assert(0);
break;
case IMFS_SYM_LINK:
fprintf(stdout, " links not printed\n" );
2004a88: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 <== NOT EXECUTED
2004a8c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004a90: d6 00 60 08 ld [ %g1 + 8 ], %o3 <== NOT EXECUTED
2004a94: 94 10 20 13 mov 0x13, %o2 <== NOT EXECUTED
2004a98: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
2004a9c: 40 00 49 9a call 2017104 <fwrite> <== NOT EXECUTED
2004aa0: 90 12 20 98 or %o0, 0x98, %o0 ! 2026498 <rtems_filesystem_mount_table_size+0x16a0><== NOT EXECUTED
assert(0);
2004aa4: 10 bf ff d1 b 20049e8 <IMFS_print_jnode+0x48> <== NOT EXECUTED
2004aa8: 92 10 20 62 mov 0x62, %o1 <== NOT EXECUTED
(uint32_t)the_jnode->info.file.size );
#endif
break;
case IMFS_HARD_LINK:
fprintf(stdout, " links not printed\n" );
2004aac: c2 04 20 90 ld [ %l0 + 0x90 ], %g1 <== NOT EXECUTED
2004ab0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004ab4: d6 00 60 08 ld [ %g1 + 8 ], %o3 <== NOT EXECUTED
2004ab8: 94 10 20 13 mov 0x13, %o2 <== NOT EXECUTED
2004abc: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
2004ac0: 40 00 49 91 call 2017104 <fwrite> <== NOT EXECUTED
2004ac4: 90 12 20 98 or %o0, 0x98, %o0 ! 2026498 <rtems_filesystem_mount_table_size+0x16a0><== NOT EXECUTED
assert(0);
2004ac8: 10 bf ff c8 b 20049e8 <IMFS_print_jnode+0x48> <== NOT EXECUTED
2004acc: 92 10 20 5d mov 0x5d, %o1 <== NOT EXECUTED
case IMFS_DIRECTORY:
fprintf(stdout, "/" );
break;
case IMFS_DEVICE:
fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")",
2004ad0: c2 04 20 90 ld [ %l0 + 0x90 ], %g1
2004ad4: d6 06 20 54 ld [ %i0 + 0x54 ], %o3
2004ad8: d4 06 20 50 ld [ %i0 + 0x50 ], %o2
2004adc: d0 00 60 08 ld [ %g1 + 8 ], %o0
2004ae0: 13 00 80 99 sethi %hi(0x2026400), %o1
2004ae4: 40 00 46 0b call 2016310 <fprintf>
2004ae8: 92 12 60 60 or %o1, 0x60, %o1 ! 2026460 <rtems_filesystem_mount_table_size+0x1668>
default:
fprintf(stdout, " bad type %d\n", the_jnode->type );
assert(0);
break;
}
puts("");
2004aec: 31 00 80 99 sethi %hi(0x2026400), %i0
2004af0: 40 00 4d 8f call 201812c <puts>
2004af4: 91 ee 20 e0 restore %i0, 0xe0, %o0
assert( the_jnode );
fprintf(stdout, "%s", the_jnode->name );
switch( the_jnode->type ) {
case IMFS_DIRECTORY:
fprintf(stdout, "/" );
2004af8: c2 04 20 90 ld [ %l0 + 0x90 ], %g1
2004afc: 90 10 20 2f mov 0x2f, %o0
2004b00: d2 00 60 08 ld [ %g1 + 8 ], %o1
2004b04: 40 00 46 1d call 2016378 <fputc>
2004b08: 31 00 80 99 sethi %hi(0x2026400), %i0
default:
fprintf(stdout, " bad type %d\n", the_jnode->type );
assert(0);
break;
}
puts("");
2004b0c: 40 00 4d 88 call 201812c <puts>
2004b10: 91 ee 20 e0 restore %i0, 0xe0, %o0
void IMFS_print_jnode(
IMFS_jnode_t *the_jnode
)
{
assert( the_jnode );
2004b14: 11 00 80 99 sethi %hi(0x2026400), %o0 <== NOT EXECUTED
2004b18: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED
2004b1c: 17 00 80 99 sethi %hi(0x2026400), %o3 <== NOT EXECUTED
2004b20: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
2004b24: 94 12 a2 10 or %o2, 0x210, %o2 <== NOT EXECUTED
2004b28: 96 12 e0 50 or %o3, 0x50, %o3 <== NOT EXECUTED
2004b2c: 40 00 02 70 call 20054ec <__assert_func> <== NOT EXECUTED
2004b30: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
02002504 <IMFS_readlink>:
int IMFS_readlink(
rtems_filesystem_location_info_t *loc,
char *buf, /* OUT */
size_t bufsize
)
{
2002504: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node;
int i;
node = loc->node_access;
2002508: c2 06 00 00 ld [ %i0 ], %g1
if ( node->type != IMFS_SYM_LINK )
200250c: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
2002510: 80 a0 a0 04 cmp %g2, 4
2002514: 12 80 00 19 bne 2002578 <IMFS_readlink+0x74> <== NEVER TAKEN
2002518: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL );
for( i=0; ((i<bufsize) && (node->info.sym_link.name[i] != '\0')); i++ )
200251c: 02 80 00 15 be 2002570 <IMFS_readlink+0x6c> <== NEVER TAKEN
2002520: 86 10 20 00 clr %g3
2002524: c4 00 60 50 ld [ %g1 + 0x50 ], %g2
2002528: c8 48 80 00 ldsb [ %g2 ], %g4
int i;
node = loc->node_access;
if ( node->type != IMFS_SYM_LINK )
rtems_set_errno_and_return_minus_one( EINVAL );
200252c: b0 10 20 00 clr %i0
for( i=0; ((i<bufsize) && (node->info.sym_link.name[i] != '\0')); i++ )
2002530: 80 a1 20 00 cmp %g4, 0
2002534: 12 80 00 08 bne 2002554 <IMFS_readlink+0x50> <== ALWAYS TAKEN
2002538: c4 08 80 00 ldub [ %g2 ], %g2
200253c: 30 80 00 13 b,a 2002588 <IMFS_readlink+0x84> <== NOT EXECUTED
2002540: c4 00 60 50 ld [ %g1 + 0x50 ], %g2
2002544: c8 48 80 18 ldsb [ %g2 + %i0 ], %g4
2002548: 80 a1 20 00 cmp %g4, 0
200254c: 02 80 00 07 be 2002568 <IMFS_readlink+0x64>
2002550: c4 08 80 18 ldub [ %g2 + %i0 ], %g2
buf[i] = node->info.sym_link.name[i];
2002554: c4 2e 40 03 stb %g2, [ %i1 + %g3 ]
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++ )
2002558: b0 06 20 01 inc %i0
200255c: 80 a6 80 18 cmp %i2, %i0
2002560: 18 bf ff f8 bgu 2002540 <IMFS_readlink+0x3c>
2002564: 86 10 00 18 mov %i0, %g3
buf[i] = node->info.sym_link.name[i];
return i;
}
2002568: 81 c7 e0 08 ret
200256c: 81 e8 00 00 restore
2002570: 81 c7 e0 08 ret <== NOT EXECUTED
2002574: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
int i;
node = loc->node_access;
if ( node->type != IMFS_SYM_LINK )
rtems_set_errno_and_return_minus_one( EINVAL );
2002578: 40 00 3d 21 call 20119fc <__errno> <== NOT EXECUTED
200257c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002580: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2002584: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002588: 81 c7 e0 08 ret <== NOT EXECUTED
200258c: 81 e8 00 00 restore <== NOT EXECUTED
02002590 <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 */
)
{
2002590: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode;
IMFS_jnode_t *new_parent;
the_jnode = old_loc->node_access;
2002594: e0 06 40 00 ld [ %i1 ], %l0
strncpy( the_jnode->name, new_name, IMFS_NAME_MAX );
2002598: 92 10 00 1b mov %i3, %o1
200259c: 90 04 20 0c add %l0, 0xc, %o0
20025a0: 40 00 41 19 call 2012a04 <strncpy>
20025a4: 94 10 20 20 mov 0x20, %o2
if ( the_jnode->Parent != NULL )
20025a8: c2 04 20 08 ld [ %l0 + 8 ], %g1
20025ac: 80 a0 60 00 cmp %g1, 0
20025b0: 22 80 00 05 be,a 20025c4 <IMFS_rename+0x34> <== NEVER TAKEN
20025b4: 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 );
20025b8: 40 00 13 63 call 2007344 <_Chain_Extract>
20025bc: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode );
new_parent = new_parent_loc->node_access;
20025c0: c2 06 80 00 ld [ %i2 ], %g1
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
20025c4: 92 10 00 10 mov %l0, %o1
20025c8: 90 00 60 50 add %g1, 0x50, %o0
20025cc: 40 00 13 52 call 2007314 <_Chain_Append>
20025d0: c2 24 20 08 st %g1, [ %l0 + 8 ]
rtems_chain_append( &new_parent->info.directory.Entries, &the_jnode->Node );
/*
* Update the time.
*/
IMFS_update_ctime( the_jnode );
20025d4: 90 07 bf f8 add %fp, -8, %o0
20025d8: 40 00 01 f0 call 2002d98 <gettimeofday>
20025dc: 92 10 20 00 clr %o1
20025e0: c2 07 bf f8 ld [ %fp + -8 ], %g1
20025e4: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
return 0;
}
20025e8: 81 c7 e0 08 ret
20025ec: 91 e8 20 00 restore %g0, 0, %o0
0200c750 <IMFS_rmnod>:
int IMFS_rmnod(
rtems_filesystem_location_info_t *parent_pathloc, /* IN */
rtems_filesystem_location_info_t *pathloc /* IN */
)
{
200c750: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode;
the_jnode = (IMFS_jnode_t *) pathloc->node_access;
200c754: 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 ) {
200c758: c2 04 20 08 ld [ %l0 + 8 ], %g1
200c75c: 80 a0 60 00 cmp %g1, 0
200c760: 22 80 00 06 be,a 200c778 <IMFS_rmnod+0x28> <== NEVER TAKEN
200c764: 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 );
200c768: 7f ff ea f7 call 2007344 <_Chain_Extract>
200c76c: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode );
the_jnode->Parent = NULL;
200c770: c0 24 20 08 clr [ %l0 + 8 ]
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
200c774: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
200c778: 92 10 20 00 clr %o1
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
200c77c: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
200c780: 90 07 bf f8 add %fp, -8, %o0
200c784: 7f ff d9 85 call 2002d98 <gettimeofday>
200c788: c2 34 20 34 sth %g1, [ %l0 + 0x34 ]
200c78c: 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) ) {
200c790: 90 10 00 10 mov %l0, %o0
200c794: 40 00 01 07 call 200cbb0 <rtems_libio_is_file_open>
200c798: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
200c79c: 80 a2 20 00 cmp %o0, 0
200c7a0: 12 80 00 12 bne 200c7e8 <IMFS_rmnod+0x98> <== NEVER TAKEN
200c7a4: 01 00 00 00 nop
200c7a8: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
200c7ac: 80 a0 60 00 cmp %g1, 0
200c7b0: 12 80 00 0e bne 200c7e8 <IMFS_rmnod+0x98> <== NEVER TAKEN
200c7b4: 03 00 80 7a sethi %hi(0x201e800), %g1
/*
* Is rtems_filesystem_current this node?
*/
if ( rtems_filesystem_current.node_access == pathloc->node_access )
200c7b8: c2 00 61 80 ld [ %g1 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
200c7bc: c4 06 40 00 ld [ %i1 ], %g2
200c7c0: c6 00 60 04 ld [ %g1 + 4 ], %g3
200c7c4: 80 a0 c0 02 cmp %g3, %g2
200c7c8: 22 80 00 02 be,a 200c7d0 <IMFS_rmnod+0x80> <== NEVER TAKEN
200c7cc: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
/*
* Free memory associated with a memory file.
*/
if ( the_jnode->type == IMFS_SYM_LINK ) {
200c7d0: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200c7d4: 80 a0 60 04 cmp %g1, 4
200c7d8: 22 80 00 06 be,a 200c7f0 <IMFS_rmnod+0xa0>
200c7dc: d0 04 20 50 ld [ %l0 + 0x50 ], %o0
if ( the_jnode->info.sym_link.name )
free( (void*) the_jnode->info.sym_link.name );
}
free( the_jnode );
200c7e0: 7f ff d9 43 call 2002cec <free>
200c7e4: 90 10 00 10 mov %l0, %o0
}
return 0;
}
200c7e8: 81 c7 e0 08 ret
200c7ec: 91 e8 20 00 restore %g0, 0, %o0
/*
* Free memory associated with a memory file.
*/
if ( the_jnode->type == IMFS_SYM_LINK ) {
if ( the_jnode->info.sym_link.name )
200c7f0: 80 a2 20 00 cmp %o0, 0
200c7f4: 02 bf ff fb be 200c7e0 <IMFS_rmnod+0x90> <== NEVER TAKEN
200c7f8: 01 00 00 00 nop
free( (void*) the_jnode->info.sym_link.name );
200c7fc: 7f ff d9 3c call 2002cec <free>
200c800: 01 00 00 00 nop
200c804: 30 bf ff f7 b,a 200c7e0 <IMFS_rmnod+0x90>
0200c828 <IMFS_stat>:
int IMFS_stat(
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
200c828: 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;
200c82c: c2 06 00 00 ld [ %i0 ], %g1
switch ( the_jnode->type ) {
200c830: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
200c834: 80 a0 a0 07 cmp %g2, 7
200c838: 08 80 00 08 bleu 200c858 <IMFS_stat+0x30> <== ALWAYS TAKEN
200c83c: 85 28 a0 02 sll %g2, 2, %g2
case IMFS_FIFO:
buf->st_size = 0;
break;
default:
rtems_set_errno_and_return_minus_one( ENOTSUP );
200c840: 40 00 14 6f call 20119fc <__errno> <== NOT EXECUTED
200c844: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200c848: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
200c84c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200c850: 81 c7 e0 08 ret <== NOT EXECUTED
200c854: 81 e8 00 00 restore <== NOT EXECUTED
IMFS_device_t *io;
the_jnode = loc->node_access;
switch ( the_jnode->type ) {
200c858: 07 00 80 32 sethi %hi(0x200c800), %g3
200c85c: 86 10 e0 08 or %g3, 8, %g3 ! 200c808 <IMFS_rmnod+0xb8>
200c860: c4 00 c0 02 ld [ %g3 + %g2 ], %g2
200c864: 81 c0 80 00 jmp %g2
200c868: 01 00 00 00 nop
case IMFS_SYM_LINK:
buf->st_size = 0;
break;
case IMFS_FIFO:
buf->st_size = 0;
200c86c: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
200c870: c0 26 60 24 clr [ %i1 + 0x24 ] <== 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;
200c874: c6 00 60 30 ld [ %g1 + 0x30 ], %g3
buf->st_nlink = the_jnode->st_nlink;
200c878: 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;
200c87c: c6 26 60 0c st %g3, [ %i1 + 0xc ]
buf->st_nlink = the_jnode->st_nlink;
buf->st_ino = the_jnode->st_ino;
200c880: 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 );
200c884: 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;
200c888: 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;
200c88c: 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;
200c890: 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;
200c894: c6 26 60 28 st %g3, [ %i1 + 0x28 ]
* 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 );
200c898: c6 00 a0 34 ld [ %g2 + 0x34 ], %g3
buf->st_ino = the_jnode->st_ino;
buf->st_uid = the_jnode->st_uid;
buf->st_gid = the_jnode->st_gid;
buf->st_atime = the_jnode->stat_atime;
buf->st_mtime = the_jnode->stat_mtime;
200c89c: c8 00 60 44 ld [ %g1 + 0x44 ], %g4
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;
200c8a0: c4 10 60 3c lduh [ %g1 + 0x3c ], %g2
buf->st_gid = the_jnode->st_gid;
buf->st_atime = the_jnode->stat_atime;
buf->st_mtime = the_jnode->stat_mtime;
200c8a4: c8 26 60 30 st %g4, [ %i1 + 0x30 ]
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;
200c8a8: c4 36 60 12 sth %g2, [ %i1 + 0x12 ]
* 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 );
200c8ac: c8 00 c0 00 ld [ %g3 ], %g4
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;
200c8b0: c4 00 60 48 ld [ %g1 + 0x48 ], %g2
buf->st_blksize = imfs_rq_memfile_bytes_per_block;
200c8b4: 07 00 80 79 sethi %hi(0x201e400), %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;
200c8b8: 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;
buf->st_blksize = imfs_rq_memfile_bytes_per_block;
200c8bc: c6 00 e3 b8 ld [ %g3 + 0x3b8 ], %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;
200c8c0: 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 =
200c8c4: c8 26 60 04 st %g4, [ %i1 + 4 ]
buf->st_atime = the_jnode->stat_atime;
buf->st_mtime = the_jnode->stat_mtime;
buf->st_ctime = the_jnode->stat_ctime;
buf->st_blksize = imfs_rq_memfile_bytes_per_block;
200c8c8: c6 26 60 40 st %g3, [ %i1 + 0x40 ]
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;
200c8cc: c4 26 60 38 st %g2, [ %i1 + 0x38 ]
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
200c8d0: 03 00 00 3f sethi %hi(0xfc00), %g1
200c8d4: 82 10 63 fe or %g1, 0x3fe, %g1 ! fffe <PROM_START+0xfffe>
/*
* 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 =
200c8d8: c2 26 40 00 st %g1, [ %i1 ]
buf->st_ctime = the_jnode->stat_ctime;
buf->st_blksize = imfs_rq_memfile_bytes_per_block;
return 0;
}
200c8dc: 81 c7 e0 08 ret
200c8e0: 91 e8 20 00 restore %g0, 0, %o0
200c8e4: c4 18 60 50 ldd [ %g1 + 0x50 ], %g2
switch ( the_jnode->type ) {
case IMFS_DEVICE:
io = &the_jnode->info.device;
buf->st_rdev = rtems_filesystem_make_dev_t( io->major, io->minor );
break;
200c8e8: 10 bf ff e3 b 200c874 <IMFS_stat+0x4c>
200c8ec: c4 3e 60 18 std %g2, [ %i1 + 0x18 ]
case IMFS_LINEAR_FILE:
case IMFS_MEMORY_FILE:
buf->st_size = the_jnode->info.file.size;
200c8f0: c4 18 60 50 ldd [ %g1 + 0x50 ], %g2
break;
200c8f4: 10 bf ff e0 b 200c874 <IMFS_stat+0x4c>
200c8f8: c4 3e 60 20 std %g2, [ %i1 + 0x20 ]
020025f0 <IMFS_symlink>:
int IMFS_symlink(
rtems_filesystem_location_info_t *parent_loc,
const char *link_name,
const char *node_name
)
{
20025f0: 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 );
20025f4: 40 00 40 cf call 2012930 <strlen>
20025f8: 90 10 00 1a mov %i2, %o0
20025fc: 96 07 bf fc add %fp, -4, %o3
2002600: 92 10 00 08 mov %o0, %o1
2002604: a0 07 bf b8 add %fp, -72, %l0
2002608: 90 10 00 1a mov %i2, %o0
200260c: 40 00 28 19 call 200c670 <IMFS_get_token>
2002610: 94 10 00 10 mov %l0, %o2
/*
* Duplicate link name
*/
info.sym_link.name = strdup(link_name);
2002614: 40 00 40 b2 call 20128dc <strdup>
2002618: 90 10 00 19 mov %i1, %o0
if (info.sym_link.name == NULL) {
200261c: 80 a2 20 00 cmp %o0, 0
2002620: 02 80 00 15 be 2002674 <IMFS_symlink+0x84> <== NEVER TAKEN
2002624: d0 27 bf e0 st %o0, [ %fp + -32 ]
* 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(
2002628: 90 10 00 18 mov %i0, %o0
200262c: 94 10 00 10 mov %l0, %o2
2002630: 92 10 20 04 mov 4, %o1
2002634: 17 00 00 28 sethi %hi(0xa000), %o3
2002638: 98 07 bf e0 add %fp, -32, %o4
200263c: 96 12 e1 ff or %o3, 0x1ff, %o3
2002640: 40 00 24 11 call 200b684 <IMFS_create_node>
2002644: b0 10 20 00 clr %i0
new_name,
( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )),
&info
);
if (new_node == NULL) {
2002648: 80 a2 20 00 cmp %o0, 0
200264c: 12 80 00 08 bne 200266c <IMFS_symlink+0x7c> <== ALWAYS TAKEN
2002650: d0 07 bf e0 ld [ %fp + -32 ], %o0
free(info.sym_link.name);
2002654: 40 00 01 a6 call 2002cec <free> <== NOT EXECUTED
2002658: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
200265c: 40 00 3c e8 call 20119fc <__errno> <== NOT EXECUTED
2002660: 01 00 00 00 nop <== NOT EXECUTED
2002664: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
2002668: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
return 0;
}
200266c: 81 c7 e0 08 ret
2002670: 81 e8 00 00 restore
/*
* Duplicate link name
*/
info.sym_link.name = strdup(link_name);
if (info.sym_link.name == NULL) {
rtems_set_errno_and_return_minus_one(ENOMEM);
2002674: 40 00 3c e2 call 20119fc <__errno> <== NOT EXECUTED
2002678: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200267c: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
2002680: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002684: 81 c7 e0 08 ret <== NOT EXECUTED
2002688: 81 e8 00 00 restore <== NOT EXECUTED
0200268c <IMFS_unlink>:
int IMFS_unlink(
rtems_filesystem_location_info_t *parentloc, /* IN */
rtems_filesystem_location_info_t *loc /* IN */
)
{
200268c: 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;
2002690: 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 ) {
2002694: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
2002698: 80 a0 60 03 cmp %g1, 3
200269c: 02 80 00 09 be 20026c0 <IMFS_unlink+0x34>
20026a0: a2 10 00 18 mov %i0, %l1
/*
* Now actually free the node we were asked to free.
*/
result = (*loc->handlers->rmnod_h)( parentloc, loc );
20026a4: c2 06 60 08 ld [ %i1 + 8 ], %g1
20026a8: 90 10 00 11 mov %l1, %o0
20026ac: c2 00 60 34 ld [ %g1 + 0x34 ], %g1
20026b0: 9f c0 40 00 call %g1
20026b4: 92 10 00 19 mov %i1, %o1
return result;
}
20026b8: 81 c7 e0 08 ret
20026bc: 91 e8 00 08 restore %g0, %o0, %o0
* free the node.
*/
if ( node->type == IMFS_HARD_LINK ) {
if ( !node->info.hard_link.link_node )
20026c0: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
20026c4: 80 a0 60 00 cmp %g1, 0
20026c8: 02 80 00 25 be 200275c <IMFS_unlink+0xd0> <== NEVER TAKEN
20026cc: a4 07 bf e4 add %fp, -28, %l2
rtems_set_errno_and_return_minus_one( EINVAL );
the_link = *loc;
20026d0: c4 06 60 10 ld [ %i1 + 0x10 ], %g2
20026d4: da 06 60 04 ld [ %i1 + 4 ], %o5
20026d8: c8 06 60 08 ld [ %i1 + 8 ], %g4
20026dc: c6 06 60 0c ld [ %i1 + 0xc ], %g3
20026e0: c4 27 bf f4 st %g2, [ %fp + -12 ]
the_link.node_access = node->info.hard_link.link_node;
20026e4: c2 27 bf e4 st %g1, [ %fp + -28 ]
if ( node->type == IMFS_HARD_LINK ) {
if ( !node->info.hard_link.link_node )
rtems_set_errno_and_return_minus_one( EINVAL );
the_link = *loc;
20026e8: da 27 bf e8 st %o5, [ %fp + -24 ]
20026ec: c8 27 bf ec st %g4, [ %fp + -20 ]
20026f0: c6 27 bf f0 st %g3, [ %fp + -16 ]
the_link.node_access = node->info.hard_link.link_node;
IMFS_Set_handlers( &the_link );
20026f4: 40 00 24 31 call 200b7b8 <IMFS_Set_handlers>
20026f8: 90 10 00 12 mov %l2, %o0
/*
* 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)
20026fc: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
2002700: c4 10 60 34 lduh [ %g1 + 0x34 ], %g2
2002704: 80 a0 a0 01 cmp %g2, 1
2002708: 02 80 00 0a be 2002730 <IMFS_unlink+0xa4>
200270c: 86 00 bf ff add %g2, -1, %g3
return -1;
}
else
{
node->info.hard_link.link_node->st_nlink --;
IMFS_update_ctime( node->info.hard_link.link_node );
2002710: 90 07 bf f8 add %fp, -8, %o0
if ( result != 0 )
return -1;
}
else
{
node->info.hard_link.link_node->st_nlink --;
2002714: c6 30 60 34 sth %g3, [ %g1 + 0x34 ]
IMFS_update_ctime( node->info.hard_link.link_node );
2002718: 40 00 01 a0 call 2002d98 <gettimeofday>
200271c: 92 10 20 00 clr %o1
2002720: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
2002724: c4 07 bf f8 ld [ %fp + -8 ], %g2
2002728: 10 bf ff df b 20026a4 <IMFS_unlink+0x18>
200272c: c4 20 60 48 st %g2, [ %g1 + 0x48 ]
* to remove the node that is a link and the node itself.
*/
if ( node->info.hard_link.link_node->st_nlink == 1)
{
result = (*the_link.handlers->rmnod_h)( parentloc, &the_link );
2002730: c2 07 bf ec ld [ %fp + -20 ], %g1
2002734: 90 10 00 18 mov %i0, %o0
2002738: c2 00 60 34 ld [ %g1 + 0x34 ], %g1
200273c: 92 10 00 12 mov %l2, %o1
2002740: 9f c0 40 00 call %g1
2002744: b0 10 3f ff mov -1, %i0
if ( result != 0 )
2002748: 80 a2 20 00 cmp %o0, 0
200274c: 22 bf ff d7 be,a 20026a8 <IMFS_unlink+0x1c>
2002750: c2 06 60 08 ld [ %i1 + 8 ], %g1
*/
result = (*loc->handlers->rmnod_h)( parentloc, loc );
return result;
}
2002754: 81 c7 e0 08 ret
2002758: 81 e8 00 00 restore
*/
if ( node->type == IMFS_HARD_LINK ) {
if ( !node->info.hard_link.link_node )
rtems_set_errno_and_return_minus_one( EINVAL );
200275c: 40 00 3c a8 call 20119fc <__errno> <== NOT EXECUTED
2002760: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002764: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2002768: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200276c: 81 c7 e0 08 ret <== NOT EXECUTED
2002770: 81 e8 00 00 restore <== NOT EXECUTED
02002774 <IMFS_unmount>:
#include <rtems/seterr.h>
int IMFS_unmount(
rtems_filesystem_mount_table_entry_t *mt_entry
)
{
2002774: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node;
node = mt_entry->mt_point_node.node_access;
2002778: c2 06 20 08 ld [ %i0 + 8 ], %g1
/*
* Is the node that we are mounting onto a directory node ?
*/
if ( node->type != IMFS_DIRECTORY )
200277c: c4 00 60 4c ld [ %g1 + 0x4c ], %g2
2002780: 80 a0 a0 01 cmp %g2, 1
2002784: 12 80 00 09 bne 20027a8 <IMFS_unmount+0x34> <== NEVER TAKEN
2002788: 01 00 00 00 nop
/*
* Did the node indicate that there was a directory mounted here?
*/
if ( node->info.directory.mt_fs == NULL )
200278c: c4 00 60 5c ld [ %g1 + 0x5c ], %g2
2002790: 80 a0 a0 00 cmp %g2, 0
2002794: 02 80 00 0b be 20027c0 <IMFS_unmount+0x4c> <== NEVER TAKEN
2002798: 01 00 00 00 nop
/*
* Set the mt_fs pointer to indicate that there is no longer
* a file system mounted to this point.
*/
node->info.directory.mt_fs = NULL;
200279c: c0 20 60 5c clr [ %g1 + 0x5c ]
return 0;
}
20027a0: 81 c7 e0 08 ret
20027a4: 91 e8 20 00 restore %g0, 0, %o0
/*
* Is the node that we are mounting onto a directory node ?
*/
if ( node->type != IMFS_DIRECTORY )
rtems_set_errno_and_return_minus_one( ENOTDIR );
20027a8: 40 00 3c 95 call 20119fc <__errno> <== NOT EXECUTED
20027ac: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20027b0: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED
20027b4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20027b8: 81 c7 e0 08 ret <== NOT EXECUTED
20027bc: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Did the node indicate that there was a directory mounted here?
*/
if ( node->info.directory.mt_fs == NULL )
rtems_set_errno_and_return_minus_one( EINVAL ); /* XXX */
20027c0: 40 00 3c 8f call 20119fc <__errno> <== NOT EXECUTED
20027c4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20027c8: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20027cc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20027d0: 81 c7 e0 08 ret <== NOT EXECUTED
20027d4: 81 e8 00 00 restore <== NOT EXECUTED
02002f98 <RTEMS_Malloc_Initialize>:
void RTEMS_Malloc_Initialize(
void *heap_begin,
uintptr_t heap_size,
size_t sbrk_amount
)
{
2002f98: 9d e3 bf a0 save %sp, -96, %sp
#endif
/*
* If configured, initialize the statistics support
*/
if ( rtems_malloc_statistics_helpers != NULL ) {
2002f9c: 03 00 80 7b sethi %hi(0x201ec00), %g1
2002fa0: c2 00 62 e8 ld [ %g1 + 0x2e8 ], %g1 ! 201eee8 <rtems_malloc_statistics_helpers>
2002fa4: 80 a0 60 00 cmp %g1, 0
2002fa8: 02 80 00 05 be 2002fbc <RTEMS_Malloc_Initialize+0x24>
2002fac: 01 00 00 00 nop
(*rtems_malloc_statistics_helpers->initialize)();
2002fb0: c2 00 40 00 ld [ %g1 ], %g1
2002fb4: 9f c0 40 00 call %g1
2002fb8: 01 00 00 00 nop
}
/*
* Initialize the garbage collection list to start with nothing on it.
*/
malloc_deferred_frees_initialize();
2002fbc: 7f ff ff dc call 2002f2c <malloc_deferred_frees_initialize>
2002fc0: 01 00 00 00 nop
/*
* Initialize the optional sbrk support for extending the heap
*/
if ( rtems_malloc_sbrk_helpers != NULL ) {
2002fc4: 03 00 80 7b sethi %hi(0x201ec00), %g1
2002fc8: c2 00 62 ec ld [ %g1 + 0x2ec ], %g1 ! 201eeec <rtems_malloc_sbrk_helpers>
2002fcc: 80 a0 60 00 cmp %g1, 0
2002fd0: 02 80 00 08 be 2002ff0 <RTEMS_Malloc_Initialize+0x58> <== ALWAYS TAKEN
2002fd4: 90 10 00 18 mov %i0, %o0
void *new_heap_begin = (*rtems_malloc_sbrk_helpers->initialize)(
2002fd8: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
heap_begin,
sbrk_amount
);
heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin;
2002fdc: 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)(
2002fe0: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002fe4: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
heap_begin,
sbrk_amount
);
heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin;
2002fe8: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
2002fec: 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 (
2002ff0: 23 00 80 7b sethi %hi(0x201ec00), %l1
2002ff4: c2 0c 62 e5 ldub [ %l1 + 0x2e5 ], %g1 ! 201eee5 <rtems_unified_work_area>
2002ff8: 80 a0 60 00 cmp %g1, 0
2002ffc: 12 80 00 10 bne 200303c <RTEMS_Malloc_Initialize+0xa4>
2003000: 21 00 80 79 sethi %hi(0x201e400), %l0
!rtems_unified_work_area
&& rtems_configuration_get_do_zero_of_workspace()
2003004: 03 00 80 7a sethi %hi(0x201e800), %g1
2003008: c2 08 60 90 ldub [ %g1 + 0x90 ], %g1 ! 201e890 <Configuration+0x28>
200300c: 80 a0 60 00 cmp %g1, 0
2003010: 12 80 00 13 bne 200305c <RTEMS_Malloc_Initialize+0xc4>
2003014: 90 10 00 18 mov %i0, %o0
void *area_begin,
uintptr_t area_size,
uintptr_t page_size
)
{
return _Heap_Initialize( heap, area_begin, area_size, page_size );
2003018: 21 00 80 79 sethi %hi(0x201e400), %l0
200301c: d0 04 23 c0 ld [ %l0 + 0x3c0 ], %o0 ! 201e7c0 <RTEMS_Malloc_Heap>
2003020: 92 10 00 18 mov %i0, %o1
2003024: 94 10 00 19 mov %i1, %o2
2003028: 40 00 12 40 call 2007928 <_Heap_Initialize>
200302c: 96 10 20 08 mov 8, %o3
RTEMS_Malloc_Heap,
heap_begin,
heap_size,
CPU_HEAP_ALIGNMENT
);
if ( status == 0 ) {
2003030: 80 a2 20 00 cmp %o0, 0
2003034: 02 80 00 13 be 2003080 <RTEMS_Malloc_Initialize+0xe8> <== NEVER TAKEN
2003038: 01 00 00 00 nop
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
}
}
MSBUMP( space_available, _Protected_heap_Get_size(RTEMS_Malloc_Heap) );
200303c: d0 04 23 c0 ld [ %l0 + 0x3c0 ], %o0
2003040: 21 00 80 7c sethi %hi(0x201f000), %l0
2003044: 40 00 15 a0 call 20086c4 <_Protected_heap_Get_size>
2003048: e2 04 21 e0 ld [ %l0 + 0x1e0 ], %l1 ! 201f1e0 <rtems_malloc_statistics>
200304c: 90 02 00 11 add %o0, %l1, %o0
2003050: d0 24 21 e0 st %o0, [ %l0 + 0x1e0 ]
printk( "\n" );
rtems_print_buffer( (heap_begin + heap_size) - 48, 48 );
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
}
#endif
}
2003054: 81 c7 e0 08 ret
2003058: 81 e8 00 00 restore
if (
!rtems_unified_work_area
&& rtems_configuration_get_do_zero_of_workspace()
) {
memset( heap_begin, 0, heap_size );
200305c: 92 10 20 00 clr %o1
2003060: 40 00 3c e2 call 20123e8 <memset>
2003064: 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 ) {
2003068: c2 0c 62 e5 ldub [ %l1 + 0x2e5 ], %g1
200306c: 80 a0 60 00 cmp %g1, 0
2003070: 22 bf ff eb be,a 200301c <RTEMS_Malloc_Initialize+0x84> <== ALWAYS TAKEN
2003074: 21 00 80 79 sethi %hi(0x201e400), %l0
if ( status == 0 ) {
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
}
}
MSBUMP( space_available, _Protected_heap_Get_size(RTEMS_Malloc_Heap) );
2003078: 10 bf ff f2 b 2003040 <RTEMS_Malloc_Initialize+0xa8> <== NOT EXECUTED
200307c: d0 04 23 c0 ld [ %l0 + 0x3c0 ], %o0 ! 201e7c0 <RTEMS_Malloc_Heap><== NOT EXECUTED
heap_begin,
heap_size,
CPU_HEAP_ALIGNMENT
);
if ( status == 0 ) {
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
2003080: 40 00 0f b6 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2003084: 90 10 20 1a mov 0x1a, %o0 <== NOT EXECUTED
02006a08 <Stack_check_Dump_threads_usage>:
static rtems_printk_plugin_t print_handler;
void Stack_check_Dump_threads_usage(
Thread_Control *the_thread
)
{
2006a08: 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 )
2006a0c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2006a10: 02 80 00 3b be 2006afc <Stack_check_Dump_threads_usage+0xf4><== NOT EXECUTED
2006a14: 27 00 81 c8 sethi %hi(0x2072000), %l3 <== NOT EXECUTED
return;
if ( !print_handler )
2006a18: e8 04 e0 f0 ld [ %l3 + 0xf0 ], %l4 ! 20720f0 <print_handler><== NOT EXECUTED
2006a1c: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
2006a20: 02 80 00 37 be 2006afc <Stack_check_Dump_threads_usage+0xf4><== NOT EXECUTED
2006a24: 80 a6 3f ff cmp %i0, -1 <== NOT EXECUTED
/*
* Obtain interrupt stack information
*/
if (the_thread == (Thread_Control *) -1) {
2006a28: 02 80 00 3e be 2006b20 <Stack_check_Dump_threads_usage+0x118><== NOT EXECUTED
2006a2c: a4 06 20 c4 add %i0, 0xc4, %l2 <== 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);
2006a30: ea 04 a0 04 ld [ %l2 + 4 ], %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
2006a34: e2 04 80 00 ld [ %l2 ], %l1 <== 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);
2006a38: aa 05 60 10 add %l5, 0x10, %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
2006a3c: a2 04 7f f0 add %l1, -16, %l1 <== NOT EXECUTED
}
else
return;
} else {
stack = &the_thread->Start.Initial_stack;
current = (void *)_CPU_Context_Get_SP( &the_thread->Registers );
2006a40: ec 06 21 50 ld [ %i0 + 0x150 ], %l6 <== 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);
2006a44: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2006a48: 7f ff ff d8 call 20069a8 <Stack_check_find_high_water_mark><== NOT EXECUTED
2006a4c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if ( high_water_mark )
2006a50: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
2006a54: a0 05 40 11 add %l5, %l1, %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 )
2006a58: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
2006a5c: a0 24 00 08 sub %l0, %o0, %l0 <== NOT EXECUTED
else
used = 0;
if ( the_thread ) {
2006a60: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2006a64: 02 80 00 44 be 2006b74 <Stack_check_Dump_threads_usage+0x16c><== NOT EXECUTED
2006a68: a0 0c 00 01 and %l0, %g1, %l0 <== NOT EXECUTED
(*print_handler)(
2006a6c: ee 06 20 08 ld [ %i0 + 8 ], %l7 <== NOT EXECUTED
2006a70: 2b 00 81 c8 sethi %hi(0x2072000), %l5 <== NOT EXECUTED
2006a74: fa 05 60 ec ld [ %l5 + 0xec ], %i5 ! 20720ec <print_context><== NOT EXECUTED
2006a78: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
2006a7c: 92 10 20 05 mov 5, %o1 <== NOT EXECUTED
2006a80: 40 00 1a 30 call 200d340 <rtems_object_get_name> <== NOT EXECUTED
2006a84: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
2006a88: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006a8c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2006a90: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
2006a94: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
2006a98: 9f c5 00 00 call %l4 <== NOT EXECUTED
2006a9c: 92 12 62 d8 or %o1, 0x2d8, %o1 <== NOT EXECUTED
);
} else {
(*print_handler)( print_context, "0x%08" PRIx32 " INTR", ~0 );
}
(*print_handler)(
2006aa0: d6 04 80 00 ld [ %l2 ], %o3 <== NOT EXECUTED
2006aa4: c2 04 e0 f0 ld [ %l3 + 0xf0 ], %g1 <== NOT EXECUTED
2006aa8: d4 04 a0 04 ld [ %l2 + 4 ], %o2 <== NOT EXECUTED
2006aac: d0 05 60 ec ld [ %l5 + 0xec ], %o0 <== NOT EXECUTED
2006ab0: 96 02 ff ff add %o3, -1, %o3 <== NOT EXECUTED
2006ab4: 98 10 00 16 mov %l6, %o4 <== NOT EXECUTED
2006ab8: 96 02 80 0b add %o2, %o3, %o3 <== NOT EXECUTED
2006abc: 9a 10 00 11 mov %l1, %o5 <== NOT EXECUTED
2006ac0: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006ac4: 9f c0 40 00 call %g1 <== NOT EXECUTED
2006ac8: 92 12 62 f8 or %o1, 0x2f8, %o1 ! 2065af8 <write_test_string.8866+0x438><== NOT EXECUTED
stack->area + stack->size - 1,
current,
size
);
if (Stack_check_Initialized == 0) {
2006acc: 03 00 81 c8 sethi %hi(0x2072000), %g1 <== NOT EXECUTED
2006ad0: c4 00 60 e8 ld [ %g1 + 0xe8 ], %g2 ! 20720e8 <Stack_check_Initialized><== NOT EXECUTED
);
} else {
(*print_handler)( print_context, "0x%08" PRIx32 " INTR", ~0 );
}
(*print_handler)(
2006ad4: 03 00 81 c8 sethi %hi(0x2072000), %g1 <== NOT EXECUTED
stack->area + stack->size - 1,
current,
size
);
if (Stack_check_Initialized == 0) {
2006ad8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2006adc: 02 80 00 0a be 2006b04 <Stack_check_Dump_threads_usage+0xfc><== NOT EXECUTED
2006ae0: 05 00 81 c8 sethi %hi(0x2072000), %g2 <== NOT EXECUTED
(*print_handler)( print_context, "Unavailable\n" );
} else {
(*print_handler)( print_context, "%8" PRId32 "\n", used );
2006ae4: c2 00 60 f0 ld [ %g1 + 0xf0 ], %g1 <== NOT EXECUTED
2006ae8: d0 00 a0 ec ld [ %g2 + 0xec ], %o0 <== NOT EXECUTED
2006aec: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006af0: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2006af4: 9f c0 40 00 call %g1 <== NOT EXECUTED
2006af8: 92 12 63 28 or %o1, 0x328, %o1 <== NOT EXECUTED
2006afc: 81 c7 e0 08 ret <== NOT EXECUTED
2006b00: 81 e8 00 00 restore <== NOT EXECUTED
current,
size
);
if (Stack_check_Initialized == 0) {
(*print_handler)( print_context, "Unavailable\n" );
2006b04: c2 00 60 f0 ld [ %g1 + 0xf0 ], %g1 <== NOT EXECUTED
2006b08: d0 00 a0 ec ld [ %g2 + 0xec ], %o0 <== NOT EXECUTED
2006b0c: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006b10: 9f c0 40 00 call %g1 <== NOT EXECUTED
2006b14: 92 12 63 18 or %o1, 0x318, %o1 ! 2065b18 <write_test_string.8866+0x458><== NOT EXECUTED
2006b18: 81 c7 e0 08 ret <== NOT EXECUTED
2006b1c: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Obtain interrupt stack information
*/
if (the_thread == (Thread_Control *) -1) {
if (Stack_check_Interrupt_stack.area) {
2006b20: 25 00 81 d3 sethi %hi(0x2074c00), %l2 <== NOT EXECUTED
2006b24: a4 14 a0 58 or %l2, 0x58, %l2 ! 2074c58 <Stack_check_Interrupt_stack><== NOT EXECUTED
2006b28: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
2006b2c: ac 10 20 00 clr %l6 <== NOT EXECUTED
2006b30: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2006b34: 02 bf ff f2 be 2006afc <Stack_check_Dump_threads_usage+0xf4><== NOT EXECUTED
2006b38: b0 10 20 00 clr %i0 <== 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);
2006b3c: ea 04 a0 04 ld [ %l2 + 4 ], %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
2006b40: e2 04 80 00 ld [ %l2 ], %l1 <== 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);
2006b44: aa 05 60 10 add %l5, 0x10, %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
2006b48: a2 04 7f f0 add %l1, -16, %l1 <== NOT EXECUTED
high_water_mark = Stack_check_find_high_water_mark(low, size);
2006b4c: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2006b50: 7f ff ff 96 call 20069a8 <Stack_check_find_high_water_mark><== NOT EXECUTED
2006b54: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if ( high_water_mark )
2006b58: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
2006b5c: a0 05 40 11 add %l5, %l1, %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 )
2006b60: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
2006b64: a0 24 00 08 sub %l0, %o0, %l0 <== NOT EXECUTED
else
used = 0;
if ( the_thread ) {
2006b68: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2006b6c: 12 bf ff c0 bne 2006a6c <Stack_check_Dump_threads_usage+0x64><== NOT EXECUTED
2006b70: a0 0c 00 01 and %l0, %g1, %l0 <== 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 );
2006b74: 2b 00 81 c8 sethi %hi(0x2072000), %l5 <== NOT EXECUTED
2006b78: d0 05 60 ec ld [ %l5 + 0xec ], %o0 ! 20720ec <print_context><== NOT EXECUTED
2006b7c: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006b80: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
2006b84: 9f c5 00 00 call %l4 <== NOT EXECUTED
2006b88: 92 12 62 e8 or %o1, 0x2e8, %o1 <== NOT EXECUTED
}
(*print_handler)(
2006b8c: 10 bf ff c6 b 2006aa4 <Stack_check_Dump_threads_usage+0x9c><== NOT EXECUTED
2006b90: d6 04 80 00 ld [ %l2 ], %o3 <== NOT EXECUTED
02006da8 <Stack_check_Initialize>:
/*
* Stack_check_Initialize
*/
void Stack_check_Initialize( void )
{
2006da8: 9d e3 bf a0 save %sp, -96, %sp
static uint32_t pattern[ 4 ] = {
0xFEEDF00D, 0x0BAD0D06, /* FEED FOOD to BAD DOG */
0xDEADF00D, 0x600D0D06 /* DEAD FOOD but GOOD DOG */
};
if (Stack_check_Initialized)
2006dac: 21 00 81 c8 sethi %hi(0x2072000), %l0
2006db0: c2 04 20 e8 ld [ %l0 + 0xe8 ], %g1 ! 20720e8 <Stack_check_Initialized>
2006db4: 80 a0 60 00 cmp %g1, 0
2006db8: 12 80 00 20 bne 2006e38 <Stack_check_Initialize+0x90>
2006dbc: 1b 00 81 d3 sethi %hi(0x2074c00), %o5
2006dc0: 09 00 81 97 sethi %hi(0x2065c00), %g4
2006dc4: 9a 13 60 48 or %o5, 0x48, %o5
2006dc8: 88 11 20 80 or %g4, 0x80, %g4
/*
* Dope the pattern and fill areas
*/
p = Stack_check_Pattern.pattern;
for ( i = 0; i < PATTERN_SIZE_WORDS; i++ ) {
p[i] = pattern[ i%4 ];
2006dcc: 84 08 60 03 and %g1, 3, %g2
2006dd0: 85 28 a0 02 sll %g2, 2, %g2
2006dd4: c6 01 00 02 ld [ %g4 + %g2 ], %g3
2006dd8: 85 28 60 02 sll %g1, 2, %g2
/*
* Dope the pattern and fill areas
*/
p = Stack_check_Pattern.pattern;
for ( i = 0; i < PATTERN_SIZE_WORDS; i++ ) {
2006ddc: 82 00 60 01 inc %g1
2006de0: 80 a0 60 04 cmp %g1, 4
2006de4: 12 bf ff fa bne 2006dcc <Stack_check_Initialize+0x24>
2006de8: c6 23 40 02 st %g3, [ %o5 + %g2 ]
/*
* If appropriate, setup the interrupt stack for high water testing
* also.
*/
#if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)
if (_CPU_Interrupt_stack_low && _CPU_Interrupt_stack_high) {
2006dec: 03 00 81 d3 sethi %hi(0x2074c00), %g1
2006df0: c2 00 62 50 ld [ %g1 + 0x250 ], %g1 ! 2074e50 <_CPU_Interrupt_stack_low>
2006df4: 80 a0 60 00 cmp %g1, 0
2006df8: 02 80 00 0e be 2006e30 <Stack_check_Initialize+0x88> <== NEVER TAKEN
2006dfc: 05 00 81 d3 sethi %hi(0x2074c00), %g2
2006e00: c6 00 a1 9c ld [ %g2 + 0x19c ], %g3 ! 2074d9c <_CPU_Interrupt_stack_high>
2006e04: 80 a0 e0 00 cmp %g3, 0
2006e08: 02 80 00 0a be 2006e30 <Stack_check_Initialize+0x88> <== NEVER TAKEN
2006e0c: 86 20 c0 01 sub %g3, %g1, %g3
Stack_check_Interrupt_stack.area = _CPU_Interrupt_stack_low;
2006e10: 05 00 81 d3 sethi %hi(0x2074c00), %g2
Stack_check_Interrupt_stack.size = (char *) _CPU_Interrupt_stack_high -
2006e14: c6 20 a0 58 st %g3, [ %g2 + 0x58 ] ! 2074c58 <Stack_check_Interrupt_stack>
* If appropriate, setup the interrupt stack for high water testing
* also.
*/
#if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)
if (_CPU_Interrupt_stack_low && _CPU_Interrupt_stack_high) {
Stack_check_Interrupt_stack.area = _CPU_Interrupt_stack_low;
2006e18: 84 10 a0 58 or %g2, 0x58, %g2
Stack_check_Interrupt_stack.size = (char *) _CPU_Interrupt_stack_high -
(char *) _CPU_Interrupt_stack_low;
Stack_check_Dope_stack(&Stack_check_Interrupt_stack);
2006e1c: 90 10 00 01 mov %g1, %o0
2006e20: 94 10 00 03 mov %g3, %o2
* If appropriate, setup the interrupt stack for high water testing
* also.
*/
#if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)
if (_CPU_Interrupt_stack_low && _CPU_Interrupt_stack_high) {
Stack_check_Interrupt_stack.area = _CPU_Interrupt_stack_low;
2006e24: c2 20 a0 04 st %g1, [ %g2 + 4 ]
Stack_check_Interrupt_stack.size = (char *) _CPU_Interrupt_stack_high -
(char *) _CPU_Interrupt_stack_low;
Stack_check_Dope_stack(&Stack_check_Interrupt_stack);
2006e28: 40 01 1b 75 call 204dbfc <memset>
2006e2c: 92 10 20 a5 mov 0xa5, %o1
}
#endif
Stack_check_Initialized = 1;
2006e30: 82 10 20 01 mov 1, %g1
2006e34: c2 24 20 e8 st %g1, [ %l0 + 0xe8 ]
2006e38: 81 c7 e0 08 ret
2006e3c: 81 e8 00 00 restore
020069a8 <Stack_check_find_high_water_mark>:
/*
* start at lower memory and find first word that does not
* match pattern
*/
base += PATTERN_SIZE_WORDS;
20069a8: 82 02 20 10 add %o0, 0x10, %g1 <== NOT EXECUTED
for (ebase = base + length; base < ebase; base++)
20069ac: 86 0a 7f fc and %o1, -4, %g3 <== NOT EXECUTED
20069b0: 86 00 40 03 add %g1, %g3, %g3 <== NOT EXECUTED
20069b4: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
20069b8: 1a 80 00 10 bcc 20069f8 <Stack_check_find_high_water_mark+0x50><== NOT EXECUTED
20069bc: 05 29 69 69 sethi %hi(0xa5a5a400), %g2 <== NOT EXECUTED
if (*base != U32_PATTERN)
20069c0: c8 02 20 10 ld [ %o0 + 0x10 ], %g4 <== NOT EXECUTED
20069c4: 84 10 a1 a5 or %g2, 0x1a5, %g2 <== NOT EXECUTED
20069c8: 80 a1 00 02 cmp %g4, %g2 <== NOT EXECUTED
20069cc: 22 80 00 08 be,a 20069ec <Stack_check_find_high_water_mark+0x44><== NOT EXECUTED
20069d0: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
return (void *) base;
20069d4: 81 c3 e0 08 retl <== NOT EXECUTED
20069d8: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
* match pattern
*/
base += PATTERN_SIZE_WORDS;
for (ebase = base + length; base < ebase; base++)
if (*base != U32_PATTERN)
20069dc: 80 a0 80 04 cmp %g2, %g4 <== NOT EXECUTED
20069e0: 12 80 00 08 bne 2006a00 <Stack_check_find_high_water_mark+0x58><== NOT EXECUTED
20069e4: 90 10 00 01 mov %g1, %o0 <== 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++)
20069e8: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
20069ec: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED
20069f0: 38 bf ff fb bgu,a 20069dc <Stack_check_find_high_water_mark+0x34><== NOT EXECUTED
20069f4: c4 00 40 00 ld [ %g1 ], %g2 <== NOT EXECUTED
if (*base != U32_PATTERN)
return (void *) base;
#endif
return (void *)0;
}
20069f8: 81 c3 e0 08 retl <== NOT EXECUTED
20069fc: 90 10 20 00 clr %o0 <== NOT EXECUTED
*/
base += PATTERN_SIZE_WORDS;
for (ebase = base + length; base < ebase; base++)
if (*base != U32_PATTERN)
return (void *) base;
2006a00: 81 c3 e0 08 retl <== NOT EXECUTED
02006c08 <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)
{
2006c08: 9d e3 bf 80 save %sp, -128, %sp
Stack_Control *stack = &running->Start.Initial_stack;
void *pattern_area = Stack_check_Get_pattern_area(stack);
char name [32];
printk("BLOWN STACK!!!\n");
2006c0c: 11 00 81 96 sethi %hi(0x2065800), %o0
* 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);
2006c10: e0 06 20 c8 ld [ %i0 + 0xc8 ], %l0
char name [32];
printk("BLOWN STACK!!!\n");
2006c14: 40 00 0c 99 call 2009e78 <printk>
2006c18: 90 12 23 98 or %o0, 0x398, %o0
printk("task control block: 0x%08" PRIxPTR "\n", running);
2006c1c: 92 10 00 18 mov %i0, %o1
2006c20: 11 00 81 96 sethi %hi(0x2065800), %o0
2006c24: 40 00 0c 95 call 2009e78 <printk>
2006c28: 90 12 23 a8 or %o0, 0x3a8, %o0 ! 2065ba8 <write_test_string.8866+0x4e8>
printk("task ID: 0x%08lx\n", (unsigned long) running->Object.id);
2006c2c: d2 06 20 08 ld [ %i0 + 8 ], %o1
2006c30: 11 00 81 96 sethi %hi(0x2065800), %o0
2006c34: 40 00 0c 91 call 2009e78 <printk>
2006c38: 90 12 23 c8 or %o0, 0x3c8, %o0 ! 2065bc8 <write_test_string.8866+0x508>
printk(
2006c3c: d2 06 20 0c ld [ %i0 + 0xc ], %o1
2006c40: 11 00 81 96 sethi %hi(0x2065800), %o0
2006c44: 40 00 0c 8d call 2009e78 <printk>
2006c48: 90 12 23 e0 or %o0, 0x3e0, %o0 ! 2065be0 <write_test_string.8866+0x520>
"task name: 0x%08" PRIx32 "\n",
running->Object.name.name_u32
);
printk(
2006c4c: d0 06 20 08 ld [ %i0 + 8 ], %o0
2006c50: 94 07 bf e0 add %fp, -32, %o2
2006c54: 40 00 19 bb call 200d340 <rtems_object_get_name>
2006c58: 92 10 20 20 mov 0x20, %o1
2006c5c: 92 10 00 08 mov %o0, %o1
2006c60: 11 00 81 96 sethi %hi(0x2065800), %o0
2006c64: 40 00 0c 85 call 2009e78 <printk>
2006c68: 90 12 23 f8 or %o0, 0x3f8, %o0 ! 2065bf8 <write_test_string.8866+0x538>
"task name string: %s\n",
rtems_object_get_name(running->Object.id, sizeof(name), name)
);
printk(
2006c6c: d2 06 20 c4 ld [ %i0 + 0xc4 ], %o1
2006c70: d4 06 20 c8 ld [ %i0 + 0xc8 ], %o2
2006c74: 11 00 81 97 sethi %hi(0x2065c00), %o0
2006c78: 96 02 80 09 add %o2, %o1, %o3
2006c7c: 40 00 0c 7f call 2009e78 <printk>
2006c80: 90 12 20 10 or %o0, 0x10, %o0
"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) {
2006c84: 80 8e 60 ff btst 0xff, %i1
2006c88: 02 80 00 04 be 2006c98 <Stack_check_report_blown_task+0x90><== ALWAYS TAKEN
2006c8c: 96 04 20 18 add %l0, 0x18, %o3
rtems_configuration_get_user_multiprocessing_table()->node
);
}
#endif
rtems_fatal_error_occurred(0x81);
2006c90: 40 00 1c 6d call 200de44 <rtems_fatal_error_occurred>
2006c94: 90 10 20 81 mov 0x81, %o0
(unsigned long) stack->size,
stack->area,
((char *) stack->area + stack->size)
);
if (!pattern_ok) {
printk(
2006c98: 11 00 81 97 sethi %hi(0x2065c00), %o0
2006c9c: 92 10 20 10 mov 0x10, %o1
2006ca0: 90 12 20 48 or %o0, 0x48, %o0
2006ca4: 40 00 0c 75 call 2009e78 <printk>
2006ca8: 94 04 20 08 add %l0, 8, %o2
2006cac: 30 bf ff f9 b,a 2006c90 <Stack_check_report_blown_task+0x88>
02049854 <T.54>:
return 0;
}
static int
rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
2049854: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_rfs_bitmap_element* map_bits;
int map_index;
int map_offset;
int rc;
*found = false;
2049858: c0 2e 80 00 clrb [ %i2 ] <== NOT EXECUTED
/*
* Load the bitmap.
*/
rc = rtems_rfs_bitmap_load_map (control, &map);
204985c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2049860: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
2049864: 7f ff fe dd call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
2049868: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rc > 0)
204986c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049870: 24 80 00 04 ble,a 2049880 <T.54+0x2c> <== NOT EXECUTED
2049874: e2 06 40 00 ld [ %i1 ], %l1 <== NOT EXECUTED
}
while (((direction < 0) && (test_bit >= end_bit))
|| ((direction > 0) && (test_bit <= end_bit)));
return 0;
}
2049878: 81 c7 e0 08 ret <== NOT EXECUTED
204987c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
/*
* Calculate the bit we are testing plus the end point we search over.
*/
test_bit = *bit;
end_bit = test_bit + (window * direction);
2049880: a5 2e e0 0b sll %i3, 0xb, %l2 <== NOT EXECUTED
if (end_bit < 0)
2049884: a4 84 80 11 addcc %l2, %l1, %l2 <== NOT EXECUTED
2049888: 2c 80 00 06 bneg,a 20498a0 <T.54+0x4c> <== NOT EXECUTED
204988c: a4 10 20 00 clr %l2 <== NOT EXECUTED
end_bit = 0;
else if (end_bit >= control->size)
2049890: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2049894: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED
2049898: 3a 80 00 02 bcc,a 20498a0 <T.54+0x4c> <== NOT EXECUTED
204989c: a4 00 7f ff add %g1, -1, %l2 <== NOT EXECUTED
map_index = rtems_rfs_bitmap_map_index (test_bit);
map_offset = rtems_rfs_bitmap_map_offset (test_bit);
search_index = rtems_rfs_bitmap_map_index (map_index);
search_offset = rtems_rfs_bitmap_map_offset (map_index);
search_bits = &control->search_bits[search_index];
20498a0: ee 04 20 14 ld [ %l0 + 0x14 ], %l7 <== NOT EXECUTED
20498a4: 83 3c 60 0a sra %l1, 0xa, %g1 <== NOT EXECUTED
map_bits = &map[map_index];
20498a8: ea 07 bf fc ld [ %fp + -4 ], %l5 <== NOT EXECUTED
map_index = rtems_rfs_bitmap_map_index (test_bit);
map_offset = rtems_rfs_bitmap_map_offset (test_bit);
search_index = rtems_rfs_bitmap_map_index (map_index);
search_offset = rtems_rfs_bitmap_map_offset (map_index);
search_bits = &control->search_bits[search_index];
20498ac: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
if (end_bit < 0)
end_bit = 0;
else if (end_bit >= control->size)
end_bit = control->size - 1;
map_index = rtems_rfs_bitmap_map_index (test_bit);
20498b0: a9 3c 60 05 sra %l1, 5, %l4 <== NOT EXECUTED
map_offset = rtems_rfs_bitmap_map_offset (test_bit);
search_index = rtems_rfs_bitmap_map_index (map_index);
search_offset = rtems_rfs_bitmap_map_offset (map_index);
search_bits = &control->search_bits[search_index];
20498b4: ae 05 c0 01 add %l7, %g1, %l7 <== NOT EXECUTED
map_bits = &map[map_index];
20498b8: 83 2d 20 02 sll %l4, 2, %g1 <== NOT EXECUTED
test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
search_offset += direction;
if (((direction < 0) && (test_bit <= end_bit))
20498bc: b9 36 e0 1f srl %i3, 0x1f, %i4 <== NOT EXECUTED
map_offset = rtems_rfs_bitmap_map_offset (test_bit);
search_index = rtems_rfs_bitmap_map_index (map_index);
search_offset = rtems_rfs_bitmap_map_offset (map_index);
search_bits = &control->search_bits[search_index];
map_bits = &map[map_index];
20498c0: aa 05 40 01 add %l5, %g1, %l5 <== NOT EXECUTED
end_bit = 0;
else if (end_bit >= control->size)
end_bit = control->size - 1;
map_index = rtems_rfs_bitmap_map_index (test_bit);
map_offset = rtems_rfs_bitmap_map_offset (test_bit);
20498c4: ac 0c 60 1f and %l1, 0x1f, %l6 <== NOT EXECUTED
search_index = rtems_rfs_bitmap_map_index (map_index);
search_offset = rtems_rfs_bitmap_map_offset (map_index);
20498c8: 90 0d 20 1f and %l4, 0x1f, %o0 <== NOT EXECUTED
map_offset += direction;
test_bit += direction;
}
}
map_bits += direction;
20498cc: bb 2e e0 02 sll %i3, 2, %i5 <== NOT EXECUTED
return 0;
}
static int
rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
20498d0: 83 2e e0 05 sll %i3, 5, %g1 <== NOT EXECUTED
*/
static bool
rtems_rfs_bitmap_test (rtems_rfs_bitmap_element target,
rtems_rfs_bitmap_bit bit)
{
return RTEMS_RFS_BITMAP_TEST_BIT (target, bit);
20498d4: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
search_offset += direction;
if (((direction < 0) && (test_bit <= end_bit))
20498d8: b0 0f 20 ff and %i4, 0xff, %i0 <== NOT EXECUTED
/*
* If any bit is clear find that bit and then search the map element. If
* all bits are set there are no map bits so move to the next search
* element.
*/
if (!rtems_rfs_bitmap_match (*search_bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
20498dc: d6 05 c0 00 ld [ %l7 ], %o3 <== NOT EXECUTED
return 0;
}
static int
rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
20498e0: 98 05 00 1b add %l4, %i3, %o4 <== NOT EXECUTED
/*
* If any bit is clear find that bit and then search the map element. If
* all bits are set there are no map bits so move to the next search
* element.
*/
if (!rtems_rfs_bitmap_match (*search_bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
20498e4: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
20498e8: 12 80 00 30 bne 20499a8 <T.54+0x154> <== NOT EXECUTED
20498ec: 99 2b 20 05 sll %o4, 5, %o4 <== NOT EXECUTED
* Align test_bit either up or down depending on the direction to next 32
* bit boundary.
*/
rtems_rfs_bitmap_bit bits_skipped;
test_bit &= ~((1 << RTEMS_RFS_ELEMENT_BITS_POWER_2) - 1);
if (direction > 0)
20498f0: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
20498f4: 04 80 00 80 ble 2049af4 <T.54+0x2a0> <== NOT EXECUTED
20498f8: a2 0c 7f e0 and %l1, -32, %l1 <== NOT EXECUTED
{
bits_skipped = rtems_rfs_bitmap_element_bits () - search_offset;
20498fc: 84 10 20 20 mov 0x20, %g2 <== NOT EXECUTED
test_bit += bits_skipped * rtems_rfs_bitmap_element_bits ();
2049900: ac 10 20 00 clr %l6 <== NOT EXECUTED
*/
rtems_rfs_bitmap_bit bits_skipped;
test_bit &= ~((1 << RTEMS_RFS_ELEMENT_BITS_POWER_2) - 1);
if (direction > 0)
{
bits_skipped = rtems_rfs_bitmap_element_bits () - search_offset;
2049904: 90 20 80 08 sub %g2, %o0, %o0 <== NOT EXECUTED
test_bit += bits_skipped * rtems_rfs_bitmap_element_bits ();
2049908: 85 2a 20 05 sll %o0, 5, %g2 <== NOT EXECUTED
204990c: a2 00 80 11 add %g2, %l1, %l1 <== NOT EXECUTED
* adds 1. Remember the logic is for subtraction.
*/
test_bit -= ((bits_skipped - 1) * rtems_rfs_bitmap_element_bits ()) + 1;
map_offset = rtems_rfs_bitmap_element_bits () - 1;
}
map_bits += direction * bits_skipped;
2049910: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
2049914: 7f fe e4 9e call 2002b8c <.umul> <== NOT EXECUTED
2049918: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
204991c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
map_index += direction * bits_skipped;
2049920: a8 05 00 08 add %l4, %o0, %l4 <== NOT EXECUTED
* adds 1. Remember the logic is for subtraction.
*/
test_bit -= ((bits_skipped - 1) * rtems_rfs_bitmap_element_bits ()) + 1;
map_offset = rtems_rfs_bitmap_element_bits () - 1;
}
map_bits += direction * bits_skipped;
2049924: 91 2a 20 02 sll %o0, 2, %o0 <== NOT EXECUTED
2049928: aa 05 40 08 add %l5, %o0, %l5 <== NOT EXECUTED
map_index += direction * bits_skipped;
}
search_bits += direction;
search_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
204992c: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2049930: 04 80 00 6a ble 2049ad8 <T.54+0x284> <== NOT EXECUTED
2049934: ae 05 c0 1d add %l7, %i5, %l7 <== NOT EXECUTED
2049938: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
204993c: 14 80 00 4d bg 2049a70 <T.54+0x21c> <== NOT EXECUTED
2049940: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2049944: 84 10 20 00 clr %g2 <== NOT EXECUTED
2049948: 90 10 20 00 clr %o0 <== NOT EXECUTED
}
while (((direction < 0) && (test_bit >= end_bit))
|| ((direction > 0) && (test_bit <= end_bit)));
204994c: 80 88 e0 ff btst 0xff, %g3 <== NOT EXECUTED
2049950: 12 80 00 3f bne 2049a4c <T.54+0x1f8> <== NOT EXECUTED
2049954: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2049958: 16 80 00 42 bge 2049a60 <T.54+0x20c> <== NOT EXECUTED
204995c: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2049960: 10 bf ff c6 b 2049878 <T.54+0x24> <== NOT EXECUTED
2049964: 90 10 20 00 clr %o0 <== NOT EXECUTED
return 0;
}
static int
rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
2049968: a8 06 c0 14 add %i3, %l4, %l4 <== NOT EXECUTED
}
}
map_bits += direction;
map_index += direction;
map_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
204996c: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2049970: a2 10 20 00 clr %l1 <== NOT EXECUTED
2049974: 04 80 00 42 ble 2049a7c <T.54+0x228> <== NOT EXECUTED
2049978: ac 10 20 00 clr %l6 <== NOT EXECUTED
test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
204997c: a2 03 00 11 add %o4, %l1, %l1 <== NOT EXECUTED
search_offset += direction;
if (((direction < 0) && (test_bit <= end_bit))
2049980: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2049984: 16 80 00 28 bge 2049a24 <T.54+0x1d0> <== NOT EXECUTED
2049988: 84 10 00 1c mov %i4, %g2 <== NOT EXECUTED
204998c: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2049990: 14 80 00 05 bg 20499a4 <T.54+0x150> <== NOT EXECUTED
2049994: 98 03 00 01 add %o4, %g1, %o4 <== NOT EXECUTED
2049998: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
204999c: 34 80 00 4d bg,a 2049ad0 <T.54+0x27c> <== NOT EXECUTED
20499a0: ae 05 c0 1d add %l7, %i5, %l7 <== NOT EXECUTED
20499a4: 90 06 c0 08 add %i3, %o0, %o0 <== NOT EXECUTED
* all bits are set there are no map bits so move to the next search
* element.
*/
if (!rtems_rfs_bitmap_match (*search_bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
{
while ((search_offset >= 0)
20499a8: 80 a2 20 1f cmp %o0, 0x1f <== NOT EXECUTED
20499ac: 18 bf ff e1 bgu 2049930 <T.54+0xdc> <== NOT EXECUTED
20499b0: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
*/
static bool
rtems_rfs_bitmap_test (rtems_rfs_bitmap_element target,
rtems_rfs_bitmap_bit bit)
{
return RTEMS_RFS_BITMAP_TEST_BIT (target, bit);
20499b4: 95 2c c0 08 sll %l3, %o0, %o2 <== NOT EXECUTED
if (!rtems_rfs_bitmap_match (*search_bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
{
while ((search_offset >= 0)
&& (search_offset < rtems_rfs_bitmap_element_bits ()))
{
if (!rtems_rfs_bitmap_test (*search_bits, search_offset))
20499b8: 80 8a 80 0b btst %o2, %o3 <== NOT EXECUTED
20499bc: 22 bf ff eb be,a 2049968 <T.54+0x114> <== NOT EXECUTED
20499c0: aa 05 40 1d add %l5, %i5, %l5 <== NOT EXECUTED
* found. We may find none are spare if searching up from the seed.
*/
while ((map_offset >= 0)
&& (map_offset < rtems_rfs_bitmap_element_bits ()))
{
if (!rtems_rfs_bitmap_test (*map_bits, map_offset))
20499c4: da 05 40 00 ld [ %l5 ], %o5 <== NOT EXECUTED
*/
static bool
rtems_rfs_bitmap_test (rtems_rfs_bitmap_element target,
rtems_rfs_bitmap_bit bit)
{
return RTEMS_RFS_BITMAP_TEST_BIT (target, bit);
20499c8: 87 2c c0 16 sll %l3, %l6, %g3 <== NOT EXECUTED
* found. We may find none are spare if searching up from the seed.
*/
while ((map_offset >= 0)
&& (map_offset < rtems_rfs_bitmap_element_bits ()))
{
if (!rtems_rfs_bitmap_test (*map_bits, map_offset))
20499cc: 80 88 c0 0d btst %g3, %o5 <== NOT EXECUTED
20499d0: 12 80 00 2e bne 2049a88 <T.54+0x234> <== NOT EXECUTED
20499d4: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
*found = true;
rtems_rfs_buffer_mark_dirty (control->buffer);
return 0;
}
if (test_bit == end_bit)
20499d8: ac 05 80 1b add %l6, %i3, %l6 <== NOT EXECUTED
20499dc: 12 80 00 0d bne 2049a10 <T.54+0x1bc> <== NOT EXECUTED
20499e0: 84 04 40 1b add %l1, %i3, %g2 <== NOT EXECUTED
map_offset += direction;
test_bit += direction;
}
}
map_bits += direction;
20499e4: 10 bf ff e1 b 2049968 <T.54+0x114> <== NOT EXECUTED
20499e8: aa 05 40 1d add %l5, %i5, %l5 <== NOT EXECUTED
*found = true;
rtems_rfs_buffer_mark_dirty (control->buffer);
return 0;
}
if (test_bit == end_bit)
20499ec: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
* found. We may find none are spare if searching up from the seed.
*/
while ((map_offset >= 0)
&& (map_offset < rtems_rfs_bitmap_element_bits ()))
{
if (!rtems_rfs_bitmap_test (*map_bits, map_offset))
20499f0: 80 88 c0 0d btst %g3, %o5 <== NOT EXECUTED
20499f4: 12 80 00 25 bne 2049a88 <T.54+0x234> <== NOT EXECUTED
20499f8: ac 05 80 1b add %l6, %i3, %l6 <== NOT EXECUTED
*search_bits = rtems_rfs_bitmap_set (*search_bits,
1 << search_offset);
control->free--;
*bit = test_bit;
*found = true;
rtems_rfs_buffer_mark_dirty (control->buffer);
20499fc: 84 00 80 1b add %g2, %i3, %g2 <== NOT EXECUTED
return 0;
}
if (test_bit == end_bit)
2049a00: 88 20 80 1b sub %g2, %i3, %g4 <== NOT EXECUTED
2049a04: 80 a4 80 04 cmp %l2, %g4 <== NOT EXECUTED
2049a08: 22 bf ff d8 be,a 2049968 <T.54+0x114> <== NOT EXECUTED
2049a0c: aa 05 40 1d add %l5, %i5, %l5 <== NOT EXECUTED
{
/*
* Find the clear bit in the map. Update the search map and map if
* found. We may find none are spare if searching up from the seed.
*/
while ((map_offset >= 0)
2049a10: 80 a5 a0 1f cmp %l6, 0x1f <== NOT EXECUTED
2049a14: 28 bf ff f6 bleu,a 20499ec <T.54+0x198> <== NOT EXECUTED
2049a18: 87 2c c0 16 sll %l3, %l6, %g3 <== NOT EXECUTED
map_offset += direction;
test_bit += direction;
}
}
map_bits += direction;
2049a1c: 10 bf ff d3 b 2049968 <T.54+0x114> <== NOT EXECUTED
2049a20: aa 05 40 1d add %l5, %i5, %l5 <== NOT EXECUTED
test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
search_offset += direction;
if (((direction < 0) && (test_bit <= end_bit))
2049a24: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2049a28: 02 bf ff da be 2049990 <T.54+0x13c> <== NOT EXECUTED
2049a2c: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
}
map_bits += direction * bits_skipped;
map_index += direction * bits_skipped;
}
search_bits += direction;
2049a30: ae 05 c0 1d add %l7, %i5, %l7 <== NOT EXECUTED
2049a34: 04 80 00 03 ble 2049a40 <T.54+0x1ec> <== NOT EXECUTED
2049a38: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2049a3c: 86 10 20 00 clr %g3 <== NOT EXECUTED
2049a40: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2049a44: 10 bf ff c2 b 204994c <T.54+0xf8> <== NOT EXECUTED
2049a48: 90 10 20 1f mov 0x1f, %o0 <== NOT EXECUTED
search_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
}
while (((direction < 0) && (test_bit >= end_bit))
|| ((direction > 0) && (test_bit <= end_bit)));
2049a4c: 80 88 a0 ff btst 0xff, %g2 <== NOT EXECUTED
2049a50: 32 bf ff a4 bne,a 20498e0 <T.54+0x8c> <== NOT EXECUTED
2049a54: d6 05 c0 00 ld [ %l7 ], %o3 <== NOT EXECUTED
2049a58: 10 bf ff c0 b 2049958 <T.54+0x104> <== NOT EXECUTED
2049a5c: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2049a60: 34 bf ff a0 bg,a 20498e0 <T.54+0x8c> <== NOT EXECUTED
2049a64: d6 05 c0 00 ld [ %l7 ], %o3 <== NOT EXECUTED
2049a68: 10 bf ff 84 b 2049878 <T.54+0x24> <== NOT EXECUTED
2049a6c: 90 10 20 00 clr %o0 <== NOT EXECUTED
map_bits += direction * bits_skipped;
map_index += direction * bits_skipped;
}
search_bits += direction;
search_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
2049a70: 86 10 20 00 clr %g3 <== NOT EXECUTED
2049a74: 10 bf ff b5 b 2049948 <T.54+0xf4> <== NOT EXECUTED
2049a78: 84 10 20 00 clr %g2 <== NOT EXECUTED
}
}
map_bits += direction;
map_index += direction;
map_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
2049a7c: a2 10 20 1f mov 0x1f, %l1 <== NOT EXECUTED
2049a80: 10 bf ff bf b 204997c <T.54+0x128> <== NOT EXECUTED
2049a84: ac 10 20 1f mov 0x1f, %l6 <== NOT EXECUTED
*/
static rtems_rfs_bitmap_element
rtems_rfs_bitmap_set (rtems_rfs_bitmap_element target,
rtems_rfs_bitmap_element bits)
{
return RTEMS_RFS_BITMAP_SET_BITS (target, bits);
2049a88: 86 2b 40 03 andn %o5, %g3, %g3 <== NOT EXECUTED
&& (map_offset < rtems_rfs_bitmap_element_bits ()))
{
if (!rtems_rfs_bitmap_test (*map_bits, map_offset))
{
*map_bits = rtems_rfs_bitmap_set (*map_bits, 1 << map_offset);
if (rtems_rfs_bitmap_match(*map_bits,
2049a8c: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2049a90: 12 80 00 05 bne 2049aa4 <T.54+0x250> <== NOT EXECUTED
2049a94: c6 25 40 00 st %g3, [ %l5 ] <== NOT EXECUTED
RTEMS_RFS_BITMAP_ELEMENT_SET))
*search_bits = rtems_rfs_bitmap_set (*search_bits,
2049a98: c2 05 c0 00 ld [ %l7 ], %g1 <== NOT EXECUTED
2049a9c: 94 28 40 0a andn %g1, %o2, %o2 <== NOT EXECUTED
2049aa0: d4 25 c0 00 st %o2, [ %l7 ] <== NOT EXECUTED
1 << search_offset);
control->free--;
2049aa4: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
*bit = test_bit;
*found = true;
rtems_rfs_buffer_mark_dirty (control->buffer);
2049aa8: c6 04 00 00 ld [ %l0 ], %g3 <== NOT EXECUTED
RTEMS_RFS_BITMAP_ELEMENT_SET))
*search_bits = rtems_rfs_bitmap_set (*search_bits,
1 << search_offset);
control->free--;
*bit = test_bit;
*found = true;
2049aac: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2049ab0: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
2049ab4: c2 28 c0 00 stb %g1, [ %g3 ] <== NOT EXECUTED
2049ab8: 90 10 20 00 clr %o0 <== NOT EXECUTED
*map_bits = rtems_rfs_bitmap_set (*map_bits, 1 << map_offset);
if (rtems_rfs_bitmap_match(*map_bits,
RTEMS_RFS_BITMAP_ELEMENT_SET))
*search_bits = rtems_rfs_bitmap_set (*search_bits,
1 << search_offset);
control->free--;
2049abc: 82 00 bf ff add %g2, -1, %g1 <== NOT EXECUTED
*bit = test_bit;
2049ac0: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
*map_bits = rtems_rfs_bitmap_set (*map_bits, 1 << map_offset);
if (rtems_rfs_bitmap_match(*map_bits,
RTEMS_RFS_BITMAP_ELEMENT_SET))
*search_bits = rtems_rfs_bitmap_set (*search_bits,
1 << search_offset);
control->free--;
2049ac4: c2 24 20 10 st %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
}
while (((direction < 0) && (test_bit >= end_bit))
|| ((direction > 0) && (test_bit <= end_bit)));
return 0;
}
2049ac8: 81 c7 e0 08 ret <== NOT EXECUTED
2049acc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
}
map_bits += direction * bits_skipped;
map_index += direction * bits_skipped;
}
search_bits += direction;
2049ad0: 10 bf ff 9e b 2049948 <T.54+0xf4> <== NOT EXECUTED
2049ad4: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
search_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
2049ad8: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2049adc: 84 10 00 1c mov %i4, %g2 <== NOT EXECUTED
2049ae0: 04 bf ff d9 ble 2049a44 <T.54+0x1f0> <== NOT EXECUTED
2049ae4: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2049ae8: 86 10 20 00 clr %g3 <== NOT EXECUTED
}
map_bits += direction * bits_skipped;
map_index += direction * bits_skipped;
}
search_bits += direction;
2049aec: 10 bf ff 98 b 204994c <T.54+0xf8> <== NOT EXECUTED
2049af0: 90 10 20 1f mov 0x1f, %o0 <== NOT EXECUTED
bits_skipped = search_offset + 1;
/*
* Need to remove 1 for the rounding up. The above rounds down and
* adds 1. Remember the logic is for subtraction.
*/
test_bit -= ((bits_skipped - 1) * rtems_rfs_bitmap_element_bits ()) + 1;
2049af4: 85 2a 20 05 sll %o0, 5, %g2 <== NOT EXECUTED
2049af8: ac 10 20 1f mov 0x1f, %l6 <== NOT EXECUTED
2049afc: 84 38 00 02 xnor %g0, %g2, %g2 <== NOT EXECUTED
test_bit += bits_skipped * rtems_rfs_bitmap_element_bits ();
map_offset = 0;
}
else
{
bits_skipped = search_offset + 1;
2049b00: 90 02 20 01 inc %o0 <== NOT EXECUTED
/*
* Need to remove 1 for the rounding up. The above rounds down and
* adds 1. Remember the logic is for subtraction.
*/
test_bit -= ((bits_skipped - 1) * rtems_rfs_bitmap_element_bits ()) + 1;
2049b04: 10 bf ff 83 b 2049910 <T.54+0xbc> <== NOT EXECUTED
2049b08: a2 00 80 11 add %g2, %l1, %l1 <== NOT EXECUTED
02007184 <_API_extensions_Run_postdriver>:
*
* _API_extensions_Run_postdriver
*/
void _API_extensions_Run_postdriver( void )
{
2007184: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
2007188: 23 00 80 7d sethi %hi(0x201f400), %l1
200718c: e0 04 61 e4 ld [ %l1 + 0x1e4 ], %l0 ! 201f5e4 <_API_extensions_List>
2007190: a2 14 61 e4 or %l1, 0x1e4, %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2007194: a2 04 60 04 add %l1, 4, %l1
2007198: 80 a4 00 11 cmp %l0, %l1
200719c: 02 80 00 09 be 20071c0 <_API_extensions_Run_postdriver+0x3c><== NEVER TAKEN
20071a0: 01 00 00 00 nop
* Currently all APIs configure this hook so it is always non-NULL.
*/
#if defined(FUNCTIONALITY_NOT_CURRENTLY_USED_BY_ANY_API)
if ( the_extension->postdriver_hook )
#endif
(*the_extension->postdriver_hook)();
20071a4: c2 04 20 08 ld [ %l0 + 8 ], %g1
20071a8: 9f c0 40 00 call %g1
20071ac: 01 00 00 00 nop
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
!_Chain_Is_tail( &_API_extensions_List, the_node ) ;
the_node = the_node->next ) {
20071b0: e0 04 00 00 ld [ %l0 ], %l0
void _API_extensions_Run_postdriver( void )
{
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
20071b4: 80 a4 00 11 cmp %l0, %l1
20071b8: 32 bf ff fc bne,a 20071a8 <_API_extensions_Run_postdriver+0x24>
20071bc: c2 04 20 08 ld [ %l0 + 8 ], %g1
20071c0: 81 c7 e0 08 ret
20071c4: 81 e8 00 00 restore
020071c8 <_API_extensions_Run_postswitch>:
*
* _API_extensions_Run_postswitch
*/
void _API_extensions_Run_postswitch( void )
{
20071c8: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
20071cc: 23 00 80 7d sethi %hi(0x201f400), %l1
20071d0: e0 04 61 e4 ld [ %l1 + 0x1e4 ], %l0 ! 201f5e4 <_API_extensions_List>
20071d4: a2 14 61 e4 or %l1, 0x1e4, %l1
20071d8: a2 04 60 04 add %l1, 4, %l1
20071dc: 80 a4 00 11 cmp %l0, %l1
20071e0: 02 80 00 0a be 2007208 <_API_extensions_Run_postswitch+0x40><== NEVER TAKEN
20071e4: 25 00 80 7d sethi %hi(0x201f400), %l2
20071e8: a4 14 a0 60 or %l2, 0x60, %l2 ! 201f460 <_Thread_Executing>
* provide this hook.
*/
#if defined(RTEMS_ITRON_API)
if ( the_extension->postswitch_hook )
#endif
(*the_extension->postswitch_hook)( _Thread_Executing );
20071ec: c2 04 20 0c ld [ %l0 + 0xc ], %g1
20071f0: 9f c0 40 00 call %g1
20071f4: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
!_Chain_Is_tail( &_API_extensions_List, the_node ) ;
the_node = the_node->next ) {
20071f8: e0 04 00 00 ld [ %l0 ], %l0
void _API_extensions_Run_postswitch( void )
{
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
20071fc: 80 a4 00 11 cmp %l0, %l1
2007200: 32 bf ff fc bne,a 20071f0 <_API_extensions_Run_postswitch+0x28>
2007204: c2 04 20 0c ld [ %l0 + 0xc ], %g1
2007208: 81 c7 e0 08 ret
200720c: 81 e8 00 00 restore
020012a8 <_Barrier_Manager_initialization>:
#include <rtems/score/object.h>
#include <rtems/rtems/barrier.h>
void _Barrier_Manager_initialization(void)
{
}
20012a8: 81 c3 e0 08 retl
020099f8 <_CORE_RWLock_Obtain_for_reading>:
Objects_Id id,
bool wait,
Watchdog_Interval timeout,
CORE_RWLock_API_mp_support_callout api_rwlock_mp_support
)
{
20099f8: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
20099fc: 03 00 80 89 sethi %hi(0x2022400), %g1
* If unlocked, then OK to read.
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
2009a00: 7f ff e7 3e call 20036f8 <sparc_disable_interrupts>
2009a04: e0 00 63 f0 ld [ %g1 + 0x3f0 ], %l0 ! 20227f0 <_Thread_Executing>
2009a08: a2 10 00 08 mov %o0, %l1
switch ( the_rwlock->current_state ) {
2009a0c: c2 06 20 44 ld [ %i0 + 0x44 ], %g1
2009a10: 80 a0 60 00 cmp %g1, 0
2009a14: 12 80 00 0c bne 2009a44 <_CORE_RWLock_Obtain_for_reading+0x4c>
2009a18: 80 a0 60 01 cmp %g1, 1
case CORE_RWLOCK_UNLOCKED:
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
the_rwlock->number_of_readers += 1;
2009a1c: c2 06 20 48 ld [ %i0 + 0x48 ], %g1
*/
_ISR_Disable( level );
switch ( the_rwlock->current_state ) {
case CORE_RWLOCK_UNLOCKED:
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
2009a20: 84 10 20 01 mov 1, %g2
the_rwlock->number_of_readers += 1;
2009a24: 82 00 60 01 inc %g1
*/
_ISR_Disable( level );
switch ( the_rwlock->current_state ) {
case CORE_RWLOCK_UNLOCKED:
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
2009a28: c4 26 20 44 st %g2, [ %i0 + 0x44 ]
the_rwlock->number_of_readers += 1;
2009a2c: c2 26 20 48 st %g1, [ %i0 + 0x48 ]
_ISR_Enable( level );
2009a30: 7f ff e7 36 call 2003708 <sparc_enable_interrupts>
2009a34: 01 00 00 00 nop
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
2009a38: c0 24 20 34 clr [ %l0 + 0x34 ]
return;
2009a3c: 81 c7 e0 08 ret
2009a40: 81 e8 00 00 restore
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
switch ( the_rwlock->current_state ) {
2009a44: 02 80 00 15 be 2009a98 <_CORE_RWLock_Obtain_for_reading+0xa0>
2009a48: 80 8e a0 ff btst 0xff, %i2
/*
* If the thread is not willing to wait, then return immediately.
*/
if ( !wait ) {
2009a4c: 02 80 00 0d be 2009a80 <_CORE_RWLock_Obtain_for_reading+0x88>
2009a50: 82 10 20 01 mov 1, %g1
* We need to wait to enter this critical section
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
executing->Wait.id = id;
2009a54: f2 24 20 20 st %i1, [ %l0 + 0x20 ]
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ;
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
2009a58: c0 24 20 34 clr [ %l0 + 0x34 ]
/*
* We need to wait to enter this critical section
*/
_Thread_queue_Enter_critical_section( &the_rwlock->Wait_queue );
executing->Wait.queue = &the_rwlock->Wait_queue;
2009a5c: f0 24 20 44 st %i0, [ %l0 + 0x44 ]
executing->Wait.id = id;
executing->Wait.option = CORE_RWLOCK_THREAD_WAITING_FOR_READ;
2009a60: c0 24 20 30 clr [ %l0 + 0x30 ]
2009a64: c2 26 20 30 st %g1, [ %i0 + 0x30 ]
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
_ISR_Enable( level );
2009a68: 90 10 00 11 mov %l1, %o0
2009a6c: 7f ff e7 27 call 2003708 <sparc_enable_interrupts>
2009a70: 35 00 80 27 sethi %hi(0x2009c00), %i2
_Thread_queue_Enqueue_with_handler(
2009a74: b2 10 00 1b mov %i3, %i1
2009a78: 40 00 07 68 call 200b818 <_Thread_queue_Enqueue_with_handler>
2009a7c: 95 ee a0 44 restore %i2, 0x44, %o2
/*
* If the thread is not willing to wait, then return immediately.
*/
if ( !wait ) {
_ISR_Enable( level );
2009a80: 7f ff e7 22 call 2003708 <sparc_enable_interrupts>
2009a84: 90 10 00 11 mov %l1, %o0
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
2009a88: 82 10 20 02 mov 2, %g1
2009a8c: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
2009a90: 81 c7 e0 08 ret
2009a94: 81 e8 00 00 restore
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
return;
case CORE_RWLOCK_LOCKED_FOR_READING: {
Thread_Control *waiter;
waiter = _Thread_queue_First( &the_rwlock->Wait_queue );
2009a98: 40 00 08 5b call 200bc04 <_Thread_queue_First>
2009a9c: 90 10 00 18 mov %i0, %o0
if ( !waiter ) {
2009aa0: 80 a2 20 00 cmp %o0, 0
2009aa4: 12 bf ff ea bne 2009a4c <_CORE_RWLock_Obtain_for_reading+0x54><== NEVER TAKEN
2009aa8: 80 8e a0 ff btst 0xff, %i2
the_rwlock->number_of_readers += 1;
2009aac: c2 06 20 48 ld [ %i0 + 0x48 ], %g1
2009ab0: 82 00 60 01 inc %g1
2009ab4: c2 26 20 48 st %g1, [ %i0 + 0x48 ]
_ISR_Enable( level );
2009ab8: 7f ff e7 14 call 2003708 <sparc_enable_interrupts>
2009abc: 90 10 00 11 mov %l1, %o0
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
2009ac0: c0 24 20 34 clr [ %l0 + 0x34 ]
return;
2009ac4: 81 c7 e0 08 ret
2009ac8: 81 e8 00 00 restore
02009b50 <_CORE_RWLock_Release>:
*/
CORE_RWLock_Status _CORE_RWLock_Release(
CORE_RWLock_Control *the_rwlock
)
{
2009b50: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Thread_Control *executing = _Thread_Executing;
2009b54: 03 00 80 89 sethi %hi(0x2022400), %g1
* Otherwise, we have to block.
* If locked for reading and no waiters, then OK to read.
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
2009b58: 7f ff e6 e8 call 20036f8 <sparc_disable_interrupts>
2009b5c: e0 00 63 f0 ld [ %g1 + 0x3f0 ], %l0 ! 20227f0 <_Thread_Executing>
2009b60: 84 10 00 08 mov %o0, %g2
if ( the_rwlock->current_state == CORE_RWLOCK_UNLOCKED){
2009b64: c2 06 20 44 ld [ %i0 + 0x44 ], %g1
2009b68: 80 a0 60 00 cmp %g1, 0
2009b6c: 02 80 00 2c be 2009c1c <_CORE_RWLock_Release+0xcc>
2009b70: 80 a0 60 01 cmp %g1, 1
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
return CORE_RWLOCK_SUCCESSFUL;
}
if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) {
2009b74: 22 80 00 23 be,a 2009c00 <_CORE_RWLock_Release+0xb0>
2009b78: c2 06 20 48 ld [ %i0 + 0x48 ], %g1
return CORE_RWLOCK_SUCCESSFUL;
}
}
/* CORE_RWLOCK_LOCKED_FOR_WRITING or READING with readers */
executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;
2009b7c: c0 24 20 34 clr [ %l0 + 0x34 ]
/*
* Implicitly transition to "unlocked" and find another thread interested
* in obtaining this rwlock.
*/
the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;
2009b80: c0 26 20 44 clr [ %i0 + 0x44 ]
_ISR_Enable( level );
2009b84: 7f ff e6 e1 call 2003708 <sparc_enable_interrupts>
2009b88: 90 10 00 02 mov %g2, %o0
next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue );
2009b8c: 40 00 06 c1 call 200b690 <_Thread_queue_Dequeue>
2009b90: 90 10 00 18 mov %i0, %o0
if ( next ) {
2009b94: 80 a2 20 00 cmp %o0, 0
2009b98: 22 80 00 25 be,a 2009c2c <_CORE_RWLock_Release+0xdc>
2009b9c: b0 10 20 00 clr %i0
if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) {
2009ba0: c2 02 20 30 ld [ %o0 + 0x30 ], %g1
2009ba4: 80 a0 60 01 cmp %g1, 1
2009ba8: 02 80 00 23 be 2009c34 <_CORE_RWLock_Release+0xe4>
2009bac: 84 10 20 01 mov 1, %g2
}
/*
* Must be CORE_RWLOCK_THREAD_WAITING_FOR_READING
*/
the_rwlock->number_of_readers += 1;
2009bb0: c2 06 20 48 ld [ %i0 + 0x48 ], %g1
2009bb4: 82 00 60 01 inc %g1
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;
2009bb8: c4 26 20 44 st %g2, [ %i0 + 0x44 ]
}
/*
* Must be CORE_RWLOCK_THREAD_WAITING_FOR_READING
*/
the_rwlock->number_of_readers += 1;
2009bbc: 10 80 00 0a b 2009be4 <_CORE_RWLock_Release+0x94>
2009bc0: c2 26 20 48 st %g1, [ %i0 + 0x48 ]
* Now see if more readers can be let go.
*/
while ( 1 ) {
next = _Thread_queue_First( &the_rwlock->Wait_queue );
if ( !next ||
next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE )
2009bc4: 80 a0 60 01 cmp %g1, 1
2009bc8: 02 80 00 0c be 2009bf8 <_CORE_RWLock_Release+0xa8> <== NEVER TAKEN
2009bcc: 92 10 00 08 mov %o0, %o1
return CORE_RWLOCK_SUCCESSFUL;
the_rwlock->number_of_readers += 1;
2009bd0: c2 06 20 48 ld [ %i0 + 0x48 ], %g1
_Thread_queue_Extract( &the_rwlock->Wait_queue, next );
2009bd4: 90 10 00 18 mov %i0, %o0
while ( 1 ) {
next = _Thread_queue_First( &the_rwlock->Wait_queue );
if ( !next ||
next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE )
return CORE_RWLOCK_SUCCESSFUL;
the_rwlock->number_of_readers += 1;
2009bd8: 82 00 60 01 inc %g1
_Thread_queue_Extract( &the_rwlock->Wait_queue, next );
2009bdc: 40 00 07 b9 call 200bac0 <_Thread_queue_Extract>
2009be0: c2 26 20 48 st %g1, [ %i0 + 0x48 ]
/*
* Now see if more readers can be let go.
*/
while ( 1 ) {
next = _Thread_queue_First( &the_rwlock->Wait_queue );
2009be4: 40 00 08 08 call 200bc04 <_Thread_queue_First>
2009be8: 90 10 00 18 mov %i0, %o0
if ( !next ||
2009bec: 80 a2 20 00 cmp %o0, 0
2009bf0: 32 bf ff f5 bne,a 2009bc4 <_CORE_RWLock_Release+0x74>
2009bf4: c2 02 20 30 ld [ %o0 + 0x30 ], %g1
}
/* indentation is to match _ISR_Disable at top */
return CORE_RWLOCK_SUCCESSFUL;
}
2009bf8: 81 c7 e0 08 ret
2009bfc: 91 e8 20 00 restore %g0, 0, %o0
_ISR_Enable( level );
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
return CORE_RWLOCK_SUCCESSFUL;
}
if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) {
the_rwlock->number_of_readers -= 1;
2009c00: 82 00 7f ff add %g1, -1, %g1
if ( the_rwlock->number_of_readers != 0 ) {
2009c04: 80 a0 60 00 cmp %g1, 0
2009c08: 02 bf ff dd be 2009b7c <_CORE_RWLock_Release+0x2c>
2009c0c: c2 26 20 48 st %g1, [ %i0 + 0x48 ]
/* must be unlocked again */
_ISR_Enable( level );
2009c10: 7f ff e6 be call 2003708 <sparc_enable_interrupts>
2009c14: b0 10 20 00 clr %i0
return CORE_RWLOCK_SUCCESSFUL;
2009c18: 30 80 00 05 b,a 2009c2c <_CORE_RWLock_Release+0xdc>
* If any thread is waiting, then we wait.
*/
_ISR_Disable( level );
if ( the_rwlock->current_state == CORE_RWLOCK_UNLOCKED){
_ISR_Enable( level );
2009c1c: 7f ff e6 bb call 2003708 <sparc_enable_interrupts>
2009c20: b0 10 20 00 clr %i0
executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;
2009c24: 82 10 20 02 mov 2, %g1
2009c28: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
}
/* indentation is to match _ISR_Disable at top */
return CORE_RWLOCK_SUCCESSFUL;
}
2009c2c: 81 c7 e0 08 ret
2009c30: 81 e8 00 00 restore
next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue );
if ( next ) {
if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) {
the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_WRITING;
2009c34: 82 10 20 02 mov 2, %g1
2009c38: c2 26 20 44 st %g1, [ %i0 + 0x44 ]
}
/* indentation is to match _ISR_Disable at top */
return CORE_RWLOCK_SUCCESSFUL;
}
2009c3c: 81 c7 e0 08 ret
2009c40: 91 e8 20 00 restore %g0, 0, %o0
02009c44 <_CORE_RWLock_Timeout>:
void _CORE_RWLock_Timeout(
Objects_Id id,
void *ignored
)
{
2009c44: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
2009c48: 90 10 00 18 mov %i0, %o0
2009c4c: 40 00 05 8e call 200b284 <_Thread_Get>
2009c50: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2009c54: c2 07 bf fc ld [ %fp + -4 ], %g1
2009c58: 80 a0 60 00 cmp %g1, 0
2009c5c: 12 80 00 08 bne 2009c7c <_CORE_RWLock_Timeout+0x38> <== NEVER TAKEN
2009c60: 01 00 00 00 nop
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_queue_Process_timeout( the_thread );
2009c64: 40 00 08 24 call 200bcf4 <_Thread_queue_Process_timeout>
2009c68: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
2009c6c: 03 00 80 89 sethi %hi(0x2022400), %g1
2009c70: c4 00 63 30 ld [ %g1 + 0x330 ], %g2 ! 2022730 <_Thread_Dispatch_disable_level>
2009c74: 84 00 bf ff add %g2, -1, %g2
2009c78: c4 20 63 30 st %g2, [ %g1 + 0x330 ]
2009c7c: 81 c7 e0 08 ret
2009c80: 81 e8 00 00 restore
02017b64 <_CORE_message_queue_Broadcast>:
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
2017b64: 9d e3 bf a0 save %sp, -96, %sp
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
2017b68: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
2017b6c: a0 10 00 18 mov %i0, %l0
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
2017b70: 80 a0 40 1a cmp %g1, %i2
2017b74: 0a 80 00 17 bcs 2017bd0 <_CORE_message_queue_Broadcast+0x6c><== NEVER TAKEN
2017b78: b0 10 20 01 mov 1, %i0
* NOTE: This check is critical because threads can block on
* send and receive and this ensures that we are broadcasting
* the message to threads waiting to receive -- not to send.
*/
if ( the_message_queue->number_of_pending_messages != 0 ) {
2017b7c: c2 04 20 48 ld [ %l0 + 0x48 ], %g1
2017b80: 80 a0 60 00 cmp %g1, 0
2017b84: 02 80 00 0a be 2017bac <_CORE_message_queue_Broadcast+0x48>
2017b88: a4 10 20 00 clr %l2
*count = 0;
2017b8c: c0 27 40 00 clr [ %i5 ]
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
2017b90: 81 c7 e0 08 ret
2017b94: 91 e8 20 00 restore %g0, 0, %o0
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
2017b98: d0 04 60 2c ld [ %l1 + 0x2c ], %o0
2017b9c: 40 00 2f aa call 2023a44 <memcpy>
2017ba0: a4 04 a0 01 inc %l2
buffer,
waitp->return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
2017ba4: c2 04 60 28 ld [ %l1 + 0x28 ], %g1
2017ba8: f4 20 40 00 st %i2, [ %g1 ]
* There must be no pending messages if there is a thread waiting to
* receive a message.
*/
number_broadcasted = 0;
while ((the_thread =
_Thread_queue_Dequeue(&the_message_queue->Wait_queue))) {
2017bac: 40 00 0a e9 call 201a750 <_Thread_queue_Dequeue>
2017bb0: 90 10 00 10 mov %l0, %o0
2017bb4: 92 10 00 19 mov %i1, %o1
2017bb8: a2 10 00 08 mov %o0, %l1
/*
* There must be no pending messages if there is a thread waiting to
* receive a message.
*/
number_broadcasted = 0;
while ((the_thread =
2017bbc: 80 a2 20 00 cmp %o0, 0
2017bc0: 12 bf ff f6 bne 2017b98 <_CORE_message_queue_Broadcast+0x34>
2017bc4: 94 10 00 1a mov %i2, %o2
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_message_queue_mp_support) ( the_thread, id );
#endif
}
*count = number_broadcasted;
2017bc8: e4 27 40 00 st %l2, [ %i5 ]
2017bcc: b0 10 20 00 clr %i0
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
}
2017bd0: 81 c7 e0 08 ret
2017bd4: 81 e8 00 00 restore
02011224 <_CORE_message_queue_Initialize>:
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
2011224: 9d e3 bf a0 save %sp, -96, %sp
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
the_message_queue->number_of_pending_messages = 0;
2011228: c0 26 20 48 clr [ %i0 + 0x48 ]
)
{
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
201122c: f4 26 20 44 st %i2, [ %i0 + 0x44 ]
the_message_queue->number_of_pending_messages = 0;
the_message_queue->maximum_message_size = maximum_message_size;
2011230: f6 26 20 4c st %i3, [ %i0 + 0x4c ]
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Notify_Handler the_handler,
void *the_argument
)
{
the_message_queue->notify_handler = the_handler;
2011234: c0 26 20 60 clr [ %i0 + 0x60 ]
the_message_queue->notify_argument = the_argument;
2011238: c0 26 20 64 clr [ %i0 + 0x64 ]
/*
* Round size up to multiple of a pointer for chain init and
* check for overflow on adding overhead to each message.
*/
allocated_message_size = maximum_message_size;
if (allocated_message_size & (sizeof(uint32_t) - 1)) {
201123c: 80 8e e0 03 btst 3, %i3
2011240: 02 80 00 09 be 2011264 <_CORE_message_queue_Initialize+0x40>
2011244: a2 10 00 1b mov %i3, %l1
allocated_message_size += sizeof(uint32_t);
2011248: a2 06 e0 04 add %i3, 4, %l1
allocated_message_size &= ~(sizeof(uint32_t) - 1);
201124c: a2 0c 7f fc and %l1, -4, %l1
}
if (allocated_message_size < maximum_message_size)
2011250: 80 a6 c0 11 cmp %i3, %l1
2011254: 08 80 00 05 bleu 2011268 <_CORE_message_queue_Initialize+0x44><== ALWAYS TAKEN
2011258: a0 04 60 14 add %l1, 0x14, %l0
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
}
201125c: 81 c7 e0 08 ret
2011260: 91 e8 20 00 restore %g0, 0, %o0
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
2011264: a0 04 60 14 add %l1, 0x14, %l0
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
2011268: 92 10 00 1a mov %i2, %o1
201126c: 40 00 58 af call 2027528 <.umul>
2011270: 90 10 00 10 mov %l0, %o0
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
if (message_buffering_required < allocated_message_size)
2011274: 80 a2 00 11 cmp %o0, %l1
2011278: 0a bf ff f9 bcs 201125c <_CORE_message_queue_Initialize+0x38><== NEVER TAKEN
201127c: 01 00 00 00 nop
return false;
/*
* Attempt to allocate the message memory
*/
the_message_queue->message_buffers = (CORE_message_queue_Buffer *)
2011280: 40 00 0c d1 call 20145c4 <_Workspace_Allocate>
2011284: 01 00 00 00 nop
_Workspace_Allocate( message_buffering_required );
if (the_message_queue->message_buffers == 0)
2011288: 80 a2 20 00 cmp %o0, 0
201128c: 02 bf ff f4 be 201125c <_CORE_message_queue_Initialize+0x38>
2011290: d0 26 20 5c st %o0, [ %i0 + 0x5c ]
/*
* Initialize the pool of inactive messages, pending messages,
* and set of waiting threads.
*/
_Chain_Initialize (
2011294: 92 10 00 08 mov %o0, %o1
2011298: 94 10 00 1a mov %i2, %o2
201129c: 90 06 20 68 add %i0, 0x68, %o0
20112a0: 40 00 1c 68 call 2018440 <_Chain_Initialize>
20112a4: 96 10 00 10 mov %l0, %o3
allocated_message_size + sizeof( CORE_message_queue_Buffer_control )
);
_Chain_Initialize_empty( &the_message_queue->Pending_messages );
_Thread_queue_Initialize(
20112a8: c2 06 40 00 ld [ %i1 ], %g1
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
20112ac: c0 26 20 54 clr [ %i0 + 0x54 ]
20112b0: 82 18 60 01 xor %g1, 1, %g1
20112b4: 80 a0 00 01 cmp %g0, %g1
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
20112b8: 82 06 20 54 add %i0, 0x54, %g1
20112bc: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
20112c0: 82 06 20 50 add %i0, 0x50, %g1
20112c4: 90 10 00 18 mov %i0, %o0
20112c8: c2 26 20 58 st %g1, [ %i0 + 0x58 ]
20112cc: 92 60 3f ff subx %g0, -1, %o1
20112d0: 94 10 20 80 mov 0x80, %o2
20112d4: 96 10 20 06 mov 6, %o3
20112d8: 40 00 09 67 call 2013874 <_Thread_queue_Initialize>
20112dc: b0 10 20 01 mov 1, %i0
THREAD_QUEUE_DISCIPLINE_PRIORITY : THREAD_QUEUE_DISCIPLINE_FIFO,
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
20112e0: 81 c7 e0 08 ret
20112e4: 81 e8 00 00 restore
02007530 <_CORE_mutex_Seize>:
Objects_Id _id,
bool _wait,
Watchdog_Interval _timeout,
ISR_Level _level
)
{
2007530: 9d e3 bf a0 save %sp, -96, %sp
_CORE_mutex_Seize_body( _the_mutex, _id, _wait, _timeout, _level );
2007534: 21 00 80 7c sethi %hi(0x201f000), %l0
2007538: c2 04 23 a0 ld [ %l0 + 0x3a0 ], %g1 ! 201f3a0 <_Thread_Dispatch_disable_level>
200753c: 80 a0 60 00 cmp %g1, 0
2007540: 02 80 00 05 be 2007554 <_CORE_mutex_Seize+0x24>
2007544: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
2007548: 80 8e a0 ff btst 0xff, %i2
200754c: 12 80 00 1a bne 20075b4 <_CORE_mutex_Seize+0x84> <== ALWAYS TAKEN
2007550: 03 00 80 7d sethi %hi(0x201f400), %g1
2007554: 90 10 00 18 mov %i0, %o0
2007558: 40 00 1b 0e call 200e190 <_CORE_mutex_Seize_interrupt_trylock>
200755c: 92 07 a0 54 add %fp, 0x54, %o1
2007560: 80 a2 20 00 cmp %o0, 0
2007564: 02 80 00 12 be 20075ac <_CORE_mutex_Seize+0x7c>
2007568: 80 8e a0 ff btst 0xff, %i2
200756c: 02 80 00 1a be 20075d4 <_CORE_mutex_Seize+0xa4>
2007570: 01 00 00 00 nop
2007574: c4 04 23 a0 ld [ %l0 + 0x3a0 ], %g2
2007578: 03 00 80 7d sethi %hi(0x201f400), %g1
200757c: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
2007580: f2 20 60 20 st %i1, [ %g1 + 0x20 ]
2007584: f0 20 60 44 st %i0, [ %g1 + 0x44 ]
2007588: 82 00 a0 01 add %g2, 1, %g1
200758c: c2 24 23 a0 st %g1, [ %l0 + 0x3a0 ]
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2007590: 82 10 20 01 mov 1, %g1
2007594: c2 26 20 30 st %g1, [ %i0 + 0x30 ]
2007598: 7f ff ea c7 call 20020b4 <sparc_enable_interrupts>
200759c: d0 07 a0 54 ld [ %fp + 0x54 ], %o0
20075a0: 90 10 00 18 mov %i0, %o0
20075a4: 7f ff ff c0 call 20074a4 <_CORE_mutex_Seize_interrupt_blocking>
20075a8: 92 10 00 1b mov %i3, %o1
20075ac: 81 c7 e0 08 ret
20075b0: 81 e8 00 00 restore
20075b4: c2 00 61 40 ld [ %g1 + 0x140 ], %g1
20075b8: 80 a0 60 01 cmp %g1, 1
20075bc: 28 bf ff e7 bleu,a 2007558 <_CORE_mutex_Seize+0x28>
20075c0: 90 10 00 18 mov %i0, %o0
20075c4: 90 10 20 00 clr %o0
20075c8: 92 10 20 00 clr %o1
20075cc: 40 00 01 c5 call 2007ce0 <_Internal_error_Occurred>
20075d0: 94 10 20 13 mov 0x13, %o2
20075d4: 7f ff ea b8 call 20020b4 <sparc_enable_interrupts>
20075d8: d0 07 a0 54 ld [ %fp + 0x54 ], %o0
20075dc: 03 00 80 7d sethi %hi(0x201f400), %g1
20075e0: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
20075e4: 84 10 20 01 mov 1, %g2
20075e8: c4 20 60 34 st %g2, [ %g1 + 0x34 ]
20075ec: 81 c7 e0 08 ret
20075f0: 81 e8 00 00 restore
02007790 <_CORE_semaphore_Surrender>:
CORE_semaphore_Status _CORE_semaphore_Surrender(
CORE_semaphore_Control *the_semaphore,
Objects_Id id,
CORE_semaphore_API_mp_support_callout api_semaphore_mp_support
)
{
2007790: 9d e3 bf a0 save %sp, -96, %sp
2007794: a0 10 00 18 mov %i0, %l0
ISR_Level level;
CORE_semaphore_Status status;
status = CORE_SEMAPHORE_STATUS_SUCCESSFUL;
if ( (the_thread = _Thread_queue_Dequeue(&the_semaphore->Wait_queue)) ) {
2007798: b0 10 20 00 clr %i0
200779c: 40 00 06 92 call 20091e4 <_Thread_queue_Dequeue>
20077a0: 90 10 00 10 mov %l0, %o0
20077a4: 80 a2 20 00 cmp %o0, 0
20077a8: 02 80 00 04 be 20077b8 <_CORE_semaphore_Surrender+0x28>
20077ac: 01 00 00 00 nop
status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED;
_ISR_Enable( level );
}
return status;
}
20077b0: 81 c7 e0 08 ret
20077b4: 81 e8 00 00 restore
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_semaphore_mp_support) ( the_thread, id );
#endif
} else {
_ISR_Disable( level );
20077b8: 7f ff ea 3b call 20020a4 <sparc_disable_interrupts>
20077bc: 01 00 00 00 nop
if ( the_semaphore->count < the_semaphore->Attributes.maximum_count )
20077c0: c2 04 20 48 ld [ %l0 + 0x48 ], %g1
20077c4: c4 04 20 40 ld [ %l0 + 0x40 ], %g2
20077c8: 80 a0 40 02 cmp %g1, %g2
20077cc: 1a 80 00 05 bcc 20077e0 <_CORE_semaphore_Surrender+0x50> <== NEVER TAKEN
20077d0: b0 10 20 04 mov 4, %i0
the_semaphore->count += 1;
20077d4: 82 00 60 01 inc %g1
20077d8: b0 10 20 00 clr %i0
20077dc: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
else
status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED;
_ISR_Enable( level );
20077e0: 7f ff ea 35 call 20020b4 <sparc_enable_interrupts>
20077e4: 01 00 00 00 nop
}
return status;
}
20077e8: 81 c7 e0 08 ret
20077ec: 81 e8 00 00 restore
0200e074 <_Chain_Initialize>:
Chain_Node *current;
Chain_Node *next;
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
200e074: c0 22 20 04 clr [ %o0 + 4 ]
next = starting_address;
while ( count-- ) {
200e078: 80 a2 a0 00 cmp %o2, 0
200e07c: 02 80 00 08 be 200e09c <_Chain_Initialize+0x28> <== NEVER TAKEN
200e080: 82 10 00 08 mov %o0, %g1
current->next = next;
next->previous = current;
200e084: c2 22 60 04 st %g1, [ %o1 + 4 ]
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
current->next = next;
200e088: d2 20 40 00 st %o1, [ %g1 ]
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
200e08c: 94 82 bf ff addcc %o2, -1, %o2
current->next = next;
next->previous = current;
current = next;
next = (Chain_Node *)
200e090: 82 10 00 09 mov %o1, %g1
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
200e094: 12 bf ff fc bne 200e084 <_Chain_Initialize+0x10>
200e098: 92 02 40 0b add %o1, %o3, %o1
next->previous = current;
current = next;
next = (Chain_Node *)
_Addresses_Add_offset( (void *) next, node_size );
}
current->next = _Chain_Tail( the_chain );
200e09c: 84 02 20 04 add %o0, 4, %g2
200e0a0: c4 20 40 00 st %g2, [ %g1 ]
the_chain->last = current;
}
200e0a4: 81 c3 e0 08 retl
200e0a8: c2 22 20 08 st %g1, [ %o0 + 8 ]
020012b0 <_Dual_ported_memory_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/dpmem.h>
void _Dual_ported_memory_Manager_initialization(void)
{
}
20012b0: 81 c3 e0 08 retl
020012b8 <_Event_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Event_Manager_initialization(void)
{
}
20012b8: 81 c3 e0 08 retl
020062cc <_Event_Seize>:
rtems_event_set event_in,
rtems_option option_set,
rtems_interval ticks,
rtems_event_set *event_out
)
{
20062cc: 9d e3 bf a0 save %sp, -96, %sp
rtems_event_set pending_events;
ISR_Level level;
RTEMS_API_Control *api;
Thread_blocking_operation_States sync_state;
executing = _Thread_Executing;
20062d0: 03 00 80 7d sethi %hi(0x201f400), %g1
20062d4: e0 00 60 60 ld [ %g1 + 0x60 ], %l0 ! 201f460 <_Thread_Executing>
executing->Wait.return_code = RTEMS_SUCCESSFUL;
20062d8: c0 24 20 34 clr [ %l0 + 0x34 ]
api = executing->API_Extensions[ THREAD_API_RTEMS ];
_ISR_Disable( level );
20062dc: 7f ff ef 72 call 20020a4 <sparc_disable_interrupts>
20062e0: e4 04 21 68 ld [ %l0 + 0x168 ], %l2
pending_events = api->pending_events;
20062e4: c2 04 80 00 ld [ %l2 ], %g1
seized_events = _Event_sets_Get( pending_events, event_in );
if ( !_Event_sets_Is_empty( seized_events ) &&
20062e8: a2 8e 00 01 andcc %i0, %g1, %l1
20062ec: 02 80 00 07 be 2006308 <_Event_Seize+0x3c>
20062f0: 80 8e 60 01 btst 1, %i1
20062f4: 80 a6 00 11 cmp %i0, %l1
20062f8: 02 80 00 23 be 2006384 <_Event_Seize+0xb8>
20062fc: 80 8e 60 02 btst 2, %i1
2006300: 12 80 00 21 bne 2006384 <_Event_Seize+0xb8> <== ALWAYS TAKEN
2006304: 80 8e 60 01 btst 1, %i1
_ISR_Enable( level );
*event_out = seized_events;
return;
}
if ( _Options_Is_no_wait( option_set ) ) {
2006308: 12 80 00 18 bne 2006368 <_Event_Seize+0x9c>
200630c: 82 10 20 01 mov 1, %g1
* set properly when we are marked as in the event critical section.
*
* NOTE: Since interrupts are disabled, this isn't that much of an
* issue but better safe than sorry.
*/
executing->Wait.option = (uint32_t) option_set;
2006310: f2 24 20 30 st %i1, [ %l0 + 0x30 ]
executing->Wait.count = (uint32_t) event_in;
2006314: f0 24 20 24 st %i0, [ %l0 + 0x24 ]
executing->Wait.return_argument = event_out;
2006318: f6 24 20 28 st %i3, [ %l0 + 0x28 ]
_Event_Sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
200631c: 33 00 80 7f sethi %hi(0x201fc00), %i1
2006320: c2 26 61 08 st %g1, [ %i1 + 0x108 ] ! 201fd08 <_Event_Sync_state>
_ISR_Enable( level );
2006324: 7f ff ef 64 call 20020b4 <sparc_enable_interrupts>
2006328: 01 00 00 00 nop
if ( ticks ) {
200632c: 80 a6 a0 00 cmp %i2, 0
2006330: 32 80 00 1c bne,a 20063a0 <_Event_Seize+0xd4>
2006334: c2 04 20 08 ld [ %l0 + 8 ], %g1
NULL
);
_Watchdog_Insert_ticks( &executing->Timer, ticks );
}
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
2006338: 90 10 00 10 mov %l0, %o0
200633c: 40 00 0d 2b call 20097e8 <_Thread_Set_state>
2006340: 92 10 21 00 mov 0x100, %o1
_ISR_Disable( level );
2006344: 7f ff ef 58 call 20020a4 <sparc_disable_interrupts>
2006348: 01 00 00 00 nop
sync_state = _Event_Sync_state;
200634c: f0 06 61 08 ld [ %i1 + 0x108 ], %i0
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
2006350: c0 26 61 08 clr [ %i1 + 0x108 ]
if ( sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
2006354: 80 a6 20 01 cmp %i0, 1
2006358: 02 80 00 1f be 20063d4 <_Event_Seize+0x108>
200635c: b2 10 00 10 mov %l0, %i1
* An interrupt completed the thread's blocking request.
* The blocking thread was satisfied by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
_Thread_blocking_operation_Cancel( sync_state, executing, level );
2006360: 40 00 08 db call 20086cc <_Thread_blocking_operation_Cancel>
2006364: 95 e8 00 08 restore %g0, %o0, %o2
*event_out = seized_events;
return;
}
if ( _Options_Is_no_wait( option_set ) ) {
_ISR_Enable( level );
2006368: 7f ff ef 53 call 20020b4 <sparc_enable_interrupts>
200636c: 01 00 00 00 nop
executing->Wait.return_code = RTEMS_UNSATISFIED;
2006370: 82 10 20 0d mov 0xd, %g1 ! d <PROM_START+0xd>
2006374: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
*event_out = seized_events;
2006378: e2 26 c0 00 st %l1, [ %i3 ]
200637c: 81 c7 e0 08 ret
2006380: 81 e8 00 00 restore
pending_events = api->pending_events;
seized_events = _Event_sets_Get( pending_events, event_in );
if ( !_Event_sets_Is_empty( seized_events ) &&
(seized_events == event_in || _Options_Is_any( option_set )) ) {
api->pending_events =
2006384: 82 28 40 11 andn %g1, %l1, %g1
2006388: c2 24 80 00 st %g1, [ %l2 ]
_Event_sets_Clear( pending_events, seized_events );
_ISR_Enable( level );
200638c: 7f ff ef 4a call 20020b4 <sparc_enable_interrupts>
2006390: 01 00 00 00 nop
*event_out = seized_events;
2006394: e2 26 c0 00 st %l1, [ %i3 ]
return;
2006398: 81 c7 e0 08 ret
200639c: 81 e8 00 00 restore
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
20063a0: f4 24 20 54 st %i2, [ %l0 + 0x54 ]
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
the_watchdog->id = id;
20063a4: c2 24 20 68 st %g1, [ %l0 + 0x68 ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
20063a8: 03 00 80 19 sethi %hi(0x2006400), %g1
20063ac: 82 10 61 70 or %g1, 0x170, %g1 ! 2006570 <_Event_Timeout>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
20063b0: c0 24 20 50 clr [ %l0 + 0x50 ]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
20063b4: c0 24 20 6c clr [ %l0 + 0x6c ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
20063b8: c2 24 20 64 st %g1, [ %l0 + 0x64 ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
20063bc: 11 00 80 7d sethi %hi(0x201f400), %o0
20063c0: 92 04 20 48 add %l0, 0x48, %o1
20063c4: 40 00 0f 25 call 200a058 <_Watchdog_Insert>
20063c8: 90 12 20 80 or %o0, 0x80, %o0
NULL
);
_Watchdog_Insert_ticks( &executing->Timer, ticks );
}
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
20063cc: 10 bf ff dc b 200633c <_Event_Seize+0x70>
20063d0: 90 10 00 10 mov %l0, %o0
_ISR_Disable( level );
sync_state = _Event_Sync_state;
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
_ISR_Enable( level );
20063d4: 7f ff ef 38 call 20020b4 <sparc_enable_interrupts>
20063d8: 91 e8 00 08 restore %g0, %o0, %o0
02006438 <_Event_Surrender>:
*/
void _Event_Surrender(
Thread_Control *the_thread
)
{
2006438: 9d e3 bf a0 save %sp, -96, %sp
rtems_event_set event_condition;
rtems_event_set seized_events;
rtems_option option_set;
RTEMS_API_Control *api;
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
200643c: e0 06 21 68 ld [ %i0 + 0x168 ], %l0
option_set = (rtems_option) the_thread->Wait.option;
_ISR_Disable( level );
2006440: 7f ff ef 19 call 20020a4 <sparc_disable_interrupts>
2006444: e4 06 20 30 ld [ %i0 + 0x30 ], %l2
2006448: a2 10 00 08 mov %o0, %l1
pending_events = api->pending_events;
200644c: c4 04 00 00 ld [ %l0 ], %g2
event_condition = (rtems_event_set) the_thread->Wait.count;
2006450: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
seized_events = _Event_sets_Get( pending_events, event_condition );
/*
* No events were seized in this operation
*/
if ( _Event_sets_Is_empty( seized_events ) ) {
2006454: 86 88 40 02 andcc %g1, %g2, %g3
2006458: 02 80 00 3a be 2006540 <_Event_Surrender+0x108>
200645c: 09 00 80 7d sethi %hi(0x201f400), %g4
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
2006460: c8 01 20 3c ld [ %g4 + 0x3c ], %g4 ! 201f43c <_ISR_Nest_level>
2006464: 80 a1 20 00 cmp %g4, 0
2006468: 12 80 00 1d bne 20064dc <_Event_Surrender+0xa4>
200646c: 09 00 80 7d sethi %hi(0x201f400), %g4
}
/*
* Otherwise, this is a normal send to another thread
*/
if ( _States_Is_waiting_for_event( the_thread->current_state ) ) {
2006470: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
2006474: 80 89 21 00 btst 0x100, %g4
2006478: 02 80 00 32 be 2006540 <_Event_Surrender+0x108>
200647c: 80 a0 40 03 cmp %g1, %g3
if ( seized_events == event_condition || _Options_Is_any( option_set ) ) {
2006480: 02 80 00 04 be 2006490 <_Event_Surrender+0x58>
2006484: 80 8c a0 02 btst 2, %l2
2006488: 02 80 00 2e be 2006540 <_Event_Surrender+0x108> <== NEVER TAKEN
200648c: 01 00 00 00 nop
api->pending_events = _Event_sets_Clear( pending_events, seized_events );
the_thread->Wait.count = 0;
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006490: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
/*
* Otherwise, this is a normal send to another thread
*/
if ( _States_Is_waiting_for_event( the_thread->current_state ) ) {
if ( seized_events == event_condition || _Options_Is_any( option_set ) ) {
api->pending_events = _Event_sets_Clear( pending_events, seized_events );
2006494: 84 28 80 03 andn %g2, %g3, %g2
2006498: c4 24 00 00 st %g2, [ %l0 ]
the_thread->Wait.count = 0;
200649c: c0 26 20 24 clr [ %i0 + 0x24 ]
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
20064a0: c6 20 40 00 st %g3, [ %g1 ]
_ISR_Flash( level );
20064a4: 7f ff ef 04 call 20020b4 <sparc_enable_interrupts>
20064a8: 90 10 00 11 mov %l1, %o0
20064ac: 7f ff ee fe call 20020a4 <sparc_disable_interrupts>
20064b0: 01 00 00 00 nop
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
20064b4: c2 06 20 50 ld [ %i0 + 0x50 ], %g1
20064b8: 80 a0 60 02 cmp %g1, 2
20064bc: 02 80 00 23 be 2006548 <_Event_Surrender+0x110>
20064c0: 82 10 20 03 mov 3, %g1
_ISR_Enable( level );
20064c4: 90 10 00 11 mov %l1, %o0
20064c8: 7f ff ee fb call 20020b4 <sparc_enable_interrupts>
20064cc: 33 04 00 ff sethi %hi(0x1003fc00), %i1
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
20064d0: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <RAM_END+0xdc3fff8>
20064d4: 40 00 09 19 call 2008938 <_Thread_Clear_state>
20064d8: 81 e8 00 00 restore
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
20064dc: c8 01 20 60 ld [ %g4 + 0x60 ], %g4
20064e0: 80 a6 00 04 cmp %i0, %g4
20064e4: 32 bf ff e4 bne,a 2006474 <_Event_Surrender+0x3c>
20064e8: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
20064ec: 09 00 80 7f sethi %hi(0x201fc00), %g4
20064f0: da 01 21 08 ld [ %g4 + 0x108 ], %o5 ! 201fd08 <_Event_Sync_state>
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
20064f4: 80 a3 60 02 cmp %o5, 2
20064f8: 02 80 00 07 be 2006514 <_Event_Surrender+0xdc> <== NEVER TAKEN
20064fc: 80 a0 40 03 cmp %g1, %g3
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
2006500: da 01 21 08 ld [ %g4 + 0x108 ], %o5
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
2006504: 80 a3 60 01 cmp %o5, 1
2006508: 32 bf ff db bne,a 2006474 <_Event_Surrender+0x3c>
200650c: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
2006510: 80 a0 40 03 cmp %g1, %g3
2006514: 02 80 00 04 be 2006524 <_Event_Surrender+0xec>
2006518: 80 8c a0 02 btst 2, %l2
200651c: 02 80 00 09 be 2006540 <_Event_Surrender+0x108> <== NEVER TAKEN
2006520: 01 00 00 00 nop
api->pending_events = _Event_sets_Clear( pending_events,seized_events );
the_thread->Wait.count = 0;
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006524: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
if ( _ISR_Is_in_progress() &&
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
api->pending_events = _Event_sets_Clear( pending_events,seized_events );
2006528: 84 28 80 03 andn %g2, %g3, %g2
200652c: c4 24 00 00 st %g2, [ %l0 ]
the_thread->Wait.count = 0;
2006530: c0 26 20 24 clr [ %i0 + 0x24 ]
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006534: c6 20 40 00 st %g3, [ %g1 ]
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SATISFIED;
2006538: 82 10 20 03 mov 3, %g1
200653c: c2 21 21 08 st %g1, [ %g4 + 0x108 ]
_Thread_Unblock( the_thread );
}
return;
}
}
_ISR_Enable( level );
2006540: 7f ff ee dd call 20020b4 <sparc_enable_interrupts>
2006544: 91 e8 00 11 restore %g0, %l1, %o0
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
2006548: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
_ISR_Enable( level );
_Thread_Unblock( the_thread );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
200654c: 7f ff ee da call 20020b4 <sparc_enable_interrupts>
2006550: 90 10 00 11 mov %l1, %o0
(void) _Watchdog_Remove( &the_thread->Timer );
2006554: 40 00 0f 2a call 200a1fc <_Watchdog_Remove>
2006558: 90 06 20 48 add %i0, 0x48, %o0
200655c: 33 04 00 ff sethi %hi(0x1003fc00), %i1
2006560: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <RAM_END+0xdc3fff8>
2006564: 40 00 08 f5 call 2008938 <_Thread_Clear_state>
2006568: 81 e8 00 00 restore
02006570 <_Event_Timeout>:
void _Event_Timeout(
Objects_Id id,
void *ignored
)
{
2006570: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
ISR_Level level;
the_thread = _Thread_Get( id, &location );
2006574: 90 10 00 18 mov %i0, %o0
2006578: 40 00 0a 18 call 2008dd8 <_Thread_Get>
200657c: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2006580: c2 07 bf fc ld [ %fp + -4 ], %g1
2006584: 80 a0 60 00 cmp %g1, 0
2006588: 12 80 00 15 bne 20065dc <_Event_Timeout+0x6c> <== NEVER TAKEN
200658c: a0 10 00 08 mov %o0, %l0
*
* If it is not satisfied, then it is "nothing happened" and
* this is the "timeout" transition. After a request is satisfied,
* a timeout is not allowed to occur.
*/
_ISR_Disable( level );
2006590: 7f ff ee c5 call 20020a4 <sparc_disable_interrupts>
2006594: 01 00 00 00 nop
return;
}
#endif
the_thread->Wait.count = 0;
if ( _Thread_Is_executing( the_thread ) ) {
2006598: 03 00 80 7d sethi %hi(0x201f400), %g1
200659c: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
20065a0: 80 a4 00 01 cmp %l0, %g1
20065a4: 02 80 00 10 be 20065e4 <_Event_Timeout+0x74>
20065a8: c0 24 20 24 clr [ %l0 + 0x24 ]
if ( _Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
_Event_Sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
}
the_thread->Wait.return_code = RTEMS_TIMEOUT;
20065ac: 82 10 20 06 mov 6, %g1
20065b0: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
_ISR_Enable( level );
20065b4: 7f ff ee c0 call 20020b4 <sparc_enable_interrupts>
20065b8: 01 00 00 00 nop
20065bc: 90 10 00 10 mov %l0, %o0
20065c0: 13 04 00 ff sethi %hi(0x1003fc00), %o1
20065c4: 40 00 08 dd call 2008938 <_Thread_Clear_state>
20065c8: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 1003fff8 <RAM_END+0xdc3fff8>
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
20065cc: 03 00 80 7c sethi %hi(0x201f000), %g1
20065d0: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
20065d4: 84 00 bf ff add %g2, -1, %g2
20065d8: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
20065dc: 81 c7 e0 08 ret
20065e0: 81 e8 00 00 restore
}
#endif
the_thread->Wait.count = 0;
if ( _Thread_Is_executing( the_thread ) ) {
if ( _Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
20065e4: 03 00 80 7f sethi %hi(0x201fc00), %g1
20065e8: c4 00 61 08 ld [ %g1 + 0x108 ], %g2 ! 201fd08 <_Event_Sync_state>
20065ec: 80 a0 a0 01 cmp %g2, 1
20065f0: 32 bf ff f0 bne,a 20065b0 <_Event_Timeout+0x40>
20065f4: 82 10 20 06 mov 6, %g1
_Event_Sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
20065f8: 84 10 20 02 mov 2, %g2
20065fc: c4 20 61 08 st %g2, [ %g1 + 0x108 ]
}
the_thread->Wait.return_code = RTEMS_TIMEOUT;
2006600: 10 bf ff ec b 20065b0 <_Event_Timeout+0x40>
2006604: 82 10 20 06 mov 6, %g1
020012f0 <_Extension_Manager_initialization>:
#include <rtems/extension.h>
#include <rtems/score/interr.h>
void _Extension_Manager_initialization(void)
{
}
20012f0: 81 c3 e0 08 retl
0200e364 <_Heap_Allocate_aligned_with_boundary>:
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
200e364: 9d e3 bf 98 save %sp, -104, %sp
Heap_Statistics *const stats = &heap->stats;
Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
Heap_Block *block = _Heap_Free_list_first( heap );
uintptr_t const block_size_floor = alloc_size + HEAP_BLOCK_HEADER_SIZE
- HEAP_BLOCK_SIZE_OFFSET;
200e368: a8 06 60 04 add %i1, 4, %l4
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
200e36c: a0 10 00 18 mov %i0, %l0
- HEAP_BLOCK_SIZE_OFFSET;
uintptr_t const page_size = heap->page_size;
uintptr_t alloc_begin = 0;
uint32_t search_count = 0;
if ( block_size_floor < alloc_size ) {
200e370: 80 a6 40 14 cmp %i1, %l4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
200e374: e4 06 20 08 ld [ %i0 + 8 ], %l2
200e378: 18 80 00 72 bgu 200e540 <_Heap_Allocate_aligned_with_boundary+0x1dc>
200e37c: fa 06 20 10 ld [ %i0 + 0x10 ], %i5
/* Integer overflow occured */
return NULL;
}
if ( boundary != 0 ) {
200e380: 80 a6 e0 00 cmp %i3, 0
200e384: 12 80 00 6d bne 200e538 <_Heap_Allocate_aligned_with_boundary+0x1d4>
200e388: 80 a6 40 1b cmp %i1, %i3
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200e38c: 80 a4 00 12 cmp %l0, %l2
200e390: 02 80 00 6f be 200e54c <_Heap_Allocate_aligned_with_boundary+0x1e8>
200e394: a2 10 20 00 clr %l1
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200e398: 82 10 20 04 mov 4, %g1
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
200e39c: b8 07 60 07 add %i5, 7, %i4
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200e3a0: 82 20 40 19 sub %g1, %i1, %g1
200e3a4: 10 80 00 09 b 200e3c8 <_Heap_Allocate_aligned_with_boundary+0x64>
200e3a8: c2 27 bf fc st %g1, [ %fp + -4 ]
boundary
);
}
}
if ( alloc_begin != 0 ) {
200e3ac: 80 a6 20 00 cmp %i0, 0
200e3b0: 32 80 00 54 bne,a 200e500 <_Heap_Allocate_aligned_with_boundary+0x19c><== ALWAYS TAKEN
200e3b4: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
break;
}
block = block->next;
200e3b8: e4 04 a0 08 ld [ %l2 + 8 ], %l2
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200e3bc: 80 a4 00 12 cmp %l0, %l2
200e3c0: 22 80 00 57 be,a 200e51c <_Heap_Allocate_aligned_with_boundary+0x1b8>
200e3c4: b0 10 20 00 clr %i0
/*
* The HEAP_PREV_BLOCK_USED flag is always set in the block size_and_flag
* field. Thus the value is about one unit larger than the real block
* size. The greater than operator takes this into account.
*/
if ( block->size_and_flag > block_size_floor ) {
200e3c8: e6 04 a0 04 ld [ %l2 + 4 ], %l3
200e3cc: 80 a5 00 13 cmp %l4, %l3
200e3d0: 1a bf ff fa bcc 200e3b8 <_Heap_Allocate_aligned_with_boundary+0x54>
200e3d4: a2 04 60 01 inc %l1
if ( alignment == 0 ) {
200e3d8: 80 a6 a0 00 cmp %i2, 0
200e3dc: 02 bf ff f4 be 200e3ac <_Heap_Allocate_aligned_with_boundary+0x48>
200e3e0: b0 04 a0 08 add %l2, 8, %i0
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200e3e4: c2 07 bf fc ld [ %fp + -4 ], %g1
uintptr_t alignment,
uintptr_t boundary
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
200e3e8: ee 04 20 14 ld [ %l0 + 0x14 ], %l7
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
200e3ec: a6 0c ff fe and %l3, -2, %l3
200e3f0: a6 04 80 13 add %l2, %l3, %l3
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200e3f4: b0 00 40 13 add %g1, %l3, %i0
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
200e3f8: 82 27 00 17 sub %i4, %l7, %g1
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
200e3fc: 90 10 00 18 mov %i0, %o0
200e400: a6 00 40 13 add %g1, %l3, %l3
200e404: 40 00 33 7d call 201b1f8 <.urem>
200e408: 92 10 00 1a mov %i2, %o1
200e40c: b0 26 00 08 sub %i0, %o0, %i0
uintptr_t alloc_begin = alloc_end - alloc_size;
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
200e410: 80 a4 c0 18 cmp %l3, %i0
200e414: 1a 80 00 06 bcc 200e42c <_Heap_Allocate_aligned_with_boundary+0xc8>
200e418: ac 04 a0 08 add %l2, 8, %l6
200e41c: 90 10 00 13 mov %l3, %o0
200e420: 40 00 33 76 call 201b1f8 <.urem>
200e424: 92 10 00 1a mov %i2, %o1
200e428: b0 24 c0 08 sub %l3, %o0, %i0
}
alloc_end = alloc_begin + alloc_size;
/* Ensure boundary constaint */
if ( boundary != 0 ) {
200e42c: 80 a6 e0 00 cmp %i3, 0
200e430: 02 80 00 24 be 200e4c0 <_Heap_Allocate_aligned_with_boundary+0x15c>
200e434: 80 a5 80 18 cmp %l6, %i0
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
alloc_begin = _Heap_Align_down( alloc_begin_ceiling, alignment );
}
alloc_end = alloc_begin + alloc_size;
200e438: a6 06 00 19 add %i0, %i1, %l3
200e43c: 92 10 00 1b mov %i3, %o1
200e440: 40 00 33 6e call 201b1f8 <.urem>
200e444: 90 10 00 13 mov %l3, %o0
200e448: 90 24 c0 08 sub %l3, %o0, %o0
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200e44c: 80 a4 c0 08 cmp %l3, %o0
200e450: 08 80 00 1b bleu 200e4bc <_Heap_Allocate_aligned_with_boundary+0x158>
200e454: 80 a6 00 08 cmp %i0, %o0
200e458: 1a 80 00 1a bcc 200e4c0 <_Heap_Allocate_aligned_with_boundary+0x15c>
200e45c: 80 a5 80 18 cmp %l6, %i0
alloc_end = alloc_begin + alloc_size;
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
200e460: aa 05 80 19 add %l6, %i1, %l5
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
if ( boundary_line < boundary_floor ) {
200e464: 80 a5 40 08 cmp %l5, %o0
200e468: 28 80 00 09 bleu,a 200e48c <_Heap_Allocate_aligned_with_boundary+0x128>
200e46c: b0 22 00 19 sub %o0, %i1, %i0
if ( alloc_begin != 0 ) {
break;
}
block = block->next;
200e470: 10 bf ff d3 b 200e3bc <_Heap_Allocate_aligned_with_boundary+0x58>
200e474: e4 04 a0 08 ld [ %l2 + 8 ], %l2
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200e478: 1a 80 00 11 bcc 200e4bc <_Heap_Allocate_aligned_with_boundary+0x158>
200e47c: 80 a5 40 08 cmp %l5, %o0
if ( boundary_line < boundary_floor ) {
200e480: 38 bf ff cf bgu,a 200e3bc <_Heap_Allocate_aligned_with_boundary+0x58><== NEVER TAKEN
200e484: e4 04 a0 08 ld [ %l2 + 8 ], %l2 <== NOT EXECUTED
return 0;
}
alloc_begin = boundary_line - alloc_size;
200e488: b0 22 00 19 sub %o0, %i1, %i0
200e48c: 92 10 00 1a mov %i2, %o1
200e490: 40 00 33 5a call 201b1f8 <.urem>
200e494: 90 10 00 18 mov %i0, %o0
200e498: 92 10 00 1b mov %i3, %o1
200e49c: b0 26 00 08 sub %i0, %o0, %i0
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
alloc_end = alloc_begin + alloc_size;
200e4a0: a6 06 00 19 add %i0, %i1, %l3
200e4a4: 40 00 33 55 call 201b1f8 <.urem>
200e4a8: 90 10 00 13 mov %l3, %o0
200e4ac: 90 24 c0 08 sub %l3, %o0, %o0
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200e4b0: 80 a4 c0 08 cmp %l3, %o0
200e4b4: 18 bf ff f1 bgu 200e478 <_Heap_Allocate_aligned_with_boundary+0x114>
200e4b8: 80 a6 00 08 cmp %i0, %o0
boundary_line = _Heap_Align_down( alloc_end, boundary );
}
}
/* Ensure that the we have a valid new block at the beginning */
if ( alloc_begin >= alloc_begin_floor ) {
200e4bc: 80 a5 80 18 cmp %l6, %i0
200e4c0: 18 bf ff be bgu 200e3b8 <_Heap_Allocate_aligned_with_boundary+0x54>
200e4c4: 82 10 3f f8 mov -8, %g1
uintptr_t const alloc_block_begin =
(uintptr_t) _Heap_Block_of_alloc_area( alloc_begin, page_size );
uintptr_t const free_size = alloc_block_begin - block_begin;
200e4c8: 90 10 00 18 mov %i0, %o0
200e4cc: a6 20 40 12 sub %g1, %l2, %l3
200e4d0: 92 10 00 1d mov %i5, %o1
200e4d4: 40 00 33 49 call 201b1f8 <.urem>
200e4d8: a6 04 c0 18 add %l3, %i0, %l3
if ( free_size >= min_block_size || free_size == 0 ) {
200e4dc: 90 a4 c0 08 subcc %l3, %o0, %o0
200e4e0: 02 bf ff b4 be 200e3b0 <_Heap_Allocate_aligned_with_boundary+0x4c>
200e4e4: 80 a6 20 00 cmp %i0, 0
200e4e8: 80 a5 c0 08 cmp %l7, %o0
200e4ec: 18 bf ff b3 bgu 200e3b8 <_Heap_Allocate_aligned_with_boundary+0x54>
200e4f0: 80 a6 20 00 cmp %i0, 0
boundary
);
}
}
if ( alloc_begin != 0 ) {
200e4f4: 22 bf ff b2 be,a 200e3bc <_Heap_Allocate_aligned_with_boundary+0x58><== NEVER TAKEN
200e4f8: e4 04 a0 08 ld [ %l2 + 8 ], %l2 <== NOT EXECUTED
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200e4fc: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200e500: 92 10 00 12 mov %l2, %o1
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200e504: 82 00 40 11 add %g1, %l1, %g1
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200e508: 96 10 00 19 mov %i1, %o3
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200e50c: c2 24 20 4c st %g1, [ %l0 + 0x4c ]
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200e510: 90 10 00 10 mov %l0, %o0
200e514: 7f ff e5 a2 call 2007b9c <_Heap_Block_allocate>
200e518: 94 10 00 18 mov %i0, %o2
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
Heap_Statistics *const stats = &heap->stats;
200e51c: c2 04 20 44 ld [ %l0 + 0x44 ], %g1
200e520: 80 a0 40 11 cmp %g1, %l1
200e524: 1a 80 00 08 bcc 200e544 <_Heap_Allocate_aligned_with_boundary+0x1e0>
200e528: 01 00 00 00 nop
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
200e52c: e2 24 20 44 st %l1, [ %l0 + 0x44 ]
200e530: 81 c7 e0 08 ret
200e534: 81 e8 00 00 restore
/* Integer overflow occured */
return NULL;
}
if ( boundary != 0 ) {
if ( boundary < alloc_size ) {
200e538: 08 80 00 07 bleu 200e554 <_Heap_Allocate_aligned_with_boundary+0x1f0>
200e53c: 80 a6 a0 00 cmp %i2, 0
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
200e540: b0 10 20 00 clr %i0
}
return (void *) alloc_begin;
}
200e544: 81 c7 e0 08 ret
200e548: 81 e8 00 00 restore
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200e54c: 10 bf ff f4 b 200e51c <_Heap_Allocate_aligned_with_boundary+0x1b8>
200e550: b0 10 20 00 clr %i0
if ( boundary != 0 ) {
if ( boundary < alloc_size ) {
return NULL;
}
if ( alignment == 0 ) {
200e554: 22 bf ff 8e be,a 200e38c <_Heap_Allocate_aligned_with_boundary+0x28>
200e558: b4 10 00 1d mov %i5, %i2
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200e55c: 10 bf ff 8d b 200e390 <_Heap_Allocate_aligned_with_boundary+0x2c>
200e560: 80 a4 00 12 cmp %l0, %l2
02012fb8 <_Heap_Extend>:
Heap_Control *heap,
void *area_begin_ptr,
uintptr_t area_size,
uintptr_t *amount_extended
)
{
2012fb8: 9d e3 bf a0 save %sp, -96, %sp
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
uintptr_t const heap_area_end = heap->area_end;
2012fbc: c2 06 20 1c ld [ %i0 + 0x1c ], %g1
Heap_Control *heap,
void *area_begin_ptr,
uintptr_t area_size,
uintptr_t *amount_extended
)
{
2012fc0: a0 10 00 18 mov %i0, %l0
* 5. non-contiguous higher address (NOT SUPPORTED)
*
* As noted, this code only supports (4).
*/
if ( area_begin >= heap_area_begin && area_begin < heap_area_end ) {
2012fc4: 80 a6 40 01 cmp %i1, %g1
2012fc8: 0a 80 00 2a bcs 2013070 <_Heap_Extend+0xb8>
2012fcc: e2 06 20 24 ld [ %i0 + 0x24 ], %l1
return HEAP_EXTEND_ERROR; /* case 3 */
} else if ( area_begin != heap_area_end ) {
2012fd0: 80 a6 40 01 cmp %i1, %g1
2012fd4: 12 80 00 25 bne 2013068 <_Heap_Extend+0xb0>
2012fd8: b0 10 20 02 mov 2, %i0
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
2012fdc: d2 04 20 10 ld [ %l0 + 0x10 ], %o1
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
uintptr_t const heap_area_end = heap->area_end;
uintptr_t const new_heap_area_end = heap_area_end + area_size;
2012fe0: b4 06 40 1a add %i1, %i2, %i2
* block and free it.
*/
heap->area_end = new_heap_area_end;
extend_size = new_heap_area_end
2012fe4: b2 26 80 11 sub %i2, %l1, %i1
* Currently only case 4 should make it to this point.
* The basic trick is to make the extend area look like a used
* block and free it.
*/
heap->area_end = new_heap_area_end;
2012fe8: f4 24 20 1c st %i2, [ %l0 + 0x1c ]
extend_size = new_heap_area_end
2012fec: b2 06 7f f8 add %i1, -8, %i1
2012ff0: 7f ff c4 e7 call 200438c <.urem>
2012ff4: 90 10 00 19 mov %i1, %o0
2012ff8: 90 26 40 08 sub %i1, %o0, %o0
- (uintptr_t) last_block - HEAP_BLOCK_HEADER_SIZE;
extend_size = _Heap_Align_down( extend_size, heap->page_size );
*amount_extended = extend_size;
2012ffc: d0 26 c0 00 st %o0, [ %i3 ]
if( extend_size >= heap->min_block_size ) {
2013000: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
2013004: 80 a0 40 08 cmp %g1, %o0
2013008: 18 80 00 18 bgu 2013068 <_Heap_Extend+0xb0> <== NEVER TAKEN
201300c: b0 10 20 00 clr %i0
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
block->size_and_flag = size | flag;
2013010: c2 04 60 04 ld [ %l1 + 4 ], %g1
Heap_Block *const new_last_block = _Heap_Block_at( last_block, extend_size );
_Heap_Block_set_size( last_block, extend_size );
new_last_block->size_and_flag =
2013014: c4 04 20 20 ld [ %l0 + 0x20 ], %g2
2013018: 82 08 60 01 and %g1, 1, %g1
201301c: 82 12 00 01 or %o0, %g1, %g1
2013020: c2 24 60 04 st %g1, [ %l1 + 4 ]
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
2013024: 82 02 00 11 add %o0, %l1, %g1
2013028: 84 20 80 01 sub %g2, %g1, %g2
201302c: 84 10 a0 01 or %g2, 1, %g2
2013030: c4 20 60 04 st %g2, [ %g1 + 4 ]
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
++stats->used_blocks;
2013034: c6 04 20 40 ld [ %l0 + 0x40 ], %g3
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
2013038: f2 04 20 2c ld [ %l0 + 0x2c ], %i1
++stats->used_blocks;
--stats->frees; /* Do not count subsequent call as actual free() */
201303c: c4 04 20 50 ld [ %l0 + 0x50 ], %g2
new_last_block->size_and_flag =
((uintptr_t) heap->first_block - (uintptr_t) new_last_block)
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
2013040: c2 24 20 24 st %g1, [ %l0 + 0x24 ]
/* Statistics */
stats->size += extend_size;
++stats->used_blocks;
2013044: 82 00 e0 01 add %g3, 1, %g1
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
2013048: 90 06 40 08 add %i1, %o0, %o0
++stats->used_blocks;
201304c: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
--stats->frees; /* Do not count subsequent call as actual free() */
2013050: 82 00 bf ff add %g2, -1, %g1
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
2013054: d0 24 20 2c st %o0, [ %l0 + 0x2c ]
++stats->used_blocks;
--stats->frees; /* Do not count subsequent call as actual free() */
2013058: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
_Heap_Free( heap, (void *) _Heap_Alloc_area_of_block( last_block ));
201305c: 90 10 00 10 mov %l0, %o0
2013060: 7f ff e2 26 call 200b8f8 <_Heap_Free>
2013064: 92 04 60 08 add %l1, 8, %o1
}
return HEAP_EXTEND_SUCCESSFUL;
}
2013068: 81 c7 e0 08 ret
201306c: 81 e8 00 00 restore
uintptr_t *amount_extended
)
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
2013070: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
2013074: 80 a6 40 02 cmp %i1, %g2
2013078: 0a bf ff d6 bcs 2012fd0 <_Heap_Extend+0x18>
201307c: b0 10 20 01 mov 1, %i0
_Heap_Free( heap, (void *) _Heap_Alloc_area_of_block( last_block ));
}
return HEAP_EXTEND_SUCCESSFUL;
}
2013080: 81 c7 e0 08 ret
2013084: 81 e8 00 00 restore
0200e564 <_Heap_Free>:
#include <rtems/system.h>
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
200e564: 9d e3 bf a0 save %sp, -96, %sp
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
200e568: d2 06 20 10 ld [ %i0 + 0x10 ], %o1
200e56c: 40 00 33 23 call 201b1f8 <.urem>
200e570: 90 10 00 19 mov %i1, %o0
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
200e574: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
200e578: b2 06 7f f8 add %i1, -8, %i1
200e57c: 90 26 40 08 sub %i1, %o0, %o0
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200e580: 80 a2 00 01 cmp %o0, %g1
200e584: 0a 80 00 36 bcs 200e65c <_Heap_Free+0xf8>
200e588: 01 00 00 00 nop
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
200e58c: c6 06 20 24 ld [ %i0 + 0x24 ], %g3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200e590: 80 a2 00 03 cmp %o0, %g3
200e594: 18 80 00 32 bgu 200e65c <_Heap_Free+0xf8>
200e598: 01 00 00 00 nop
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
200e59c: da 02 20 04 ld [ %o0 + 4 ], %o5
200e5a0: 88 0b 7f fe and %o5, -2, %g4
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
200e5a4: 84 02 00 04 add %o0, %g4, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200e5a8: 80 a0 40 02 cmp %g1, %g2
200e5ac: 18 80 00 2c bgu 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e5b0: 80 a0 c0 02 cmp %g3, %g2
200e5b4: 0a 80 00 2a bcs 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e5b8: 01 00 00 00 nop
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
200e5bc: d8 00 a0 04 ld [ %g2 + 4 ], %o4
if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {
_HAssert( false );
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
200e5c0: 80 8b 20 01 btst 1, %o4
200e5c4: 02 80 00 26 be 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e5c8: 96 0b 3f fe and %o4, -2, %o3
_HAssert( false );
return false;
}
next_block_size = _Heap_Block_size( next_block );
next_is_free = next_block != heap->last_block
200e5cc: 80 a0 c0 02 cmp %g3, %g2
200e5d0: 02 80 00 06 be 200e5e8 <_Heap_Free+0x84>
200e5d4: 98 10 20 00 clr %o4
#include <rtems/system.h>
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
200e5d8: 98 00 80 0b add %g2, %o3, %o4
200e5dc: d8 03 20 04 ld [ %o4 + 4 ], %o4
200e5e0: 98 0b 20 01 and %o4, 1, %o4
200e5e4: 98 1b 20 01 xor %o4, 1, %o4
next_block_size = _Heap_Block_size( next_block );
next_is_free = next_block != heap->last_block
&& !_Heap_Is_prev_used( _Heap_Block_at( next_block, next_block_size ));
if ( !_Heap_Is_prev_used( block ) ) {
200e5e8: 80 8b 60 01 btst 1, %o5
200e5ec: 12 80 00 1e bne 200e664 <_Heap_Free+0x100>
200e5f0: 80 8b 20 ff btst 0xff, %o4
uintptr_t const prev_size = block->prev_size;
200e5f4: d4 02 00 00 ld [ %o0 ], %o2
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
200e5f8: 9a 22 00 0a sub %o0, %o2, %o5
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200e5fc: 80 a0 40 0d cmp %g1, %o5
200e600: 18 80 00 17 bgu 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e604: 80 a0 c0 0d cmp %g3, %o5
200e608: 0a 80 00 15 bcs 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e60c: 01 00 00 00 nop
return( false );
}
/* As we always coalesce free blocks, the block that preceedes prev_block
must have been used. */
if ( !_Heap_Is_prev_used ( prev_block) ) {
200e610: c2 03 60 04 ld [ %o5 + 4 ], %g1
200e614: 80 88 60 01 btst 1, %g1
200e618: 02 80 00 11 be 200e65c <_Heap_Free+0xf8> <== NEVER TAKEN
200e61c: 80 8b 20 ff btst 0xff, %o4
_HAssert( false );
return( false );
}
if ( next_is_free ) { /* coalesce both */
200e620: 22 80 00 3a be,a 200e708 <_Heap_Free+0x1a4>
200e624: 94 01 00 0a add %g4, %o2, %o2
uintptr_t const size = block_size + prev_size + next_block_size;
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
200e628: c6 06 20 38 ld [ %i0 + 0x38 ], %g3
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
Heap_Block *prev = block->prev;
200e62c: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
return _Heap_Free_list_tail(heap)->prev;
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
200e630: c4 00 a0 08 ld [ %g2 + 8 ], %g2
200e634: 86 00 ff ff add %g3, -1, %g3
200e638: c6 26 20 38 st %g3, [ %i0 + 0x38 ]
_HAssert( false );
return( false );
}
if ( next_is_free ) { /* coalesce both */
uintptr_t const size = block_size + prev_size + next_block_size;
200e63c: 96 01 00 0b add %g4, %o3, %o3
Heap_Block *prev = block->prev;
prev->next = next;
next->prev = prev;
200e640: c2 20 a0 0c st %g1, [ %g2 + 0xc ]
200e644: 94 02 c0 0a add %o3, %o2, %o2
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
Heap_Block *prev = block->prev;
prev->next = next;
200e648: c4 20 60 08 st %g2, [ %g1 + 8 ]
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block = _Heap_Block_at( prev_block, size );
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
200e64c: d4 23 40 0a st %o2, [ %o5 + %o2 ]
if ( next_is_free ) { /* coalesce both */
uintptr_t const size = block_size + prev_size + next_block_size;
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200e650: 94 12 a0 01 or %o2, 1, %o2
200e654: 10 80 00 10 b 200e694 <_Heap_Free+0x130>
200e658: d4 23 60 04 st %o2, [ %o5 + 4 ]
--stats->used_blocks;
++stats->frees;
stats->free_size += block_size;
return( true );
}
200e65c: 81 c7 e0 08 ret
200e660: 91 e8 20 00 restore %g0, 0, %o0
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
next_block->prev_size = size;
}
} else if ( next_is_free ) { /* coalesce next */
200e664: 02 80 00 17 be 200e6c0 <_Heap_Free+0x15c>
200e668: 82 11 20 01 or %g4, 1, %g1
Heap_Block *old_block,
Heap_Block *new_block
)
{
Heap_Block *next = old_block->next;
Heap_Block *prev = old_block->prev;
200e66c: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
RTEMS_INLINE_ROUTINE void _Heap_Free_list_replace(
Heap_Block *old_block,
Heap_Block *new_block
)
{
Heap_Block *next = old_block->next;
200e670: c4 00 a0 08 ld [ %g2 + 8 ], %g2
Heap_Block *prev = old_block->prev;
new_block->next = next;
new_block->prev = prev;
200e674: c2 22 20 0c st %g1, [ %o0 + 0xc ]
)
{
Heap_Block *next = old_block->next;
Heap_Block *prev = old_block->prev;
new_block->next = next;
200e678: c4 22 20 08 st %g2, [ %o0 + 8 ]
uintptr_t const size = block_size + next_block_size;
200e67c: 96 02 c0 04 add %o3, %g4, %o3
new_block->prev = prev;
next->prev = new_block;
200e680: d0 20 a0 0c st %o0, [ %g2 + 0xc ]
_Heap_Free_list_replace( next_block, block );
block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block = _Heap_Block_at( block, size );
next_block->prev_size = size;
200e684: d6 22 00 0b st %o3, [ %o0 + %o3 ]
prev->next = new_block;
200e688: d0 20 60 08 st %o0, [ %g1 + 8 ]
next_block->prev_size = size;
}
} else if ( next_is_free ) { /* coalesce next */
uintptr_t const size = block_size + next_block_size;
_Heap_Free_list_replace( next_block, block );
block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200e68c: 96 12 e0 01 or %o3, 1, %o3
200e690: d6 22 20 04 st %o3, [ %o0 + 4 ]
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200e694: c4 06 20 40 ld [ %i0 + 0x40 ], %g2
++stats->frees;
200e698: c2 06 20 50 ld [ %i0 + 0x50 ], %g1
stats->free_size += block_size;
200e69c: c6 06 20 30 ld [ %i0 + 0x30 ], %g3
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200e6a0: 84 00 bf ff add %g2, -1, %g2
++stats->frees;
stats->free_size += block_size;
200e6a4: 88 00 c0 04 add %g3, %g4, %g4
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200e6a8: c4 26 20 40 st %g2, [ %i0 + 0x40 ]
++stats->frees;
stats->free_size += block_size;
200e6ac: c8 26 20 30 st %g4, [ %i0 + 0x30 ]
}
}
/* Statistics */
--stats->used_blocks;
++stats->frees;
200e6b0: 82 00 60 01 inc %g1
200e6b4: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
stats->free_size += block_size;
return( true );
200e6b8: 81 c7 e0 08 ret
200e6bc: 91 e8 20 01 restore %g0, 1, %o0
next_block->prev_size = size;
} else { /* no coalesce */
/* Add 'block' to the head of the free blocks list as it tends to
produce less fragmentation than adding to the tail. */
_Heap_Free_list_insert_after( _Heap_Free_list_head( heap), block );
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
200e6c0: c2 22 20 04 st %g1, [ %o0 + 4 ]
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200e6c4: c2 00 a0 04 ld [ %g2 + 4 ], %g1
RTEMS_INLINE_ROUTINE void _Heap_Free_list_insert_after(
Heap_Block *block_before,
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
200e6c8: c6 06 20 08 ld [ %i0 + 8 ], %g3
200e6cc: 82 08 7f fe and %g1, -2, %g1
next_block->prev_size = block_size;
200e6d0: c8 22 00 04 st %g4, [ %o0 + %g4 ]
} else { /* no coalesce */
/* Add 'block' to the head of the free blocks list as it tends to
produce less fragmentation than adding to the tail. */
_Heap_Free_list_insert_after( _Heap_Free_list_head( heap), block );
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200e6d4: c2 20 a0 04 st %g1, [ %g2 + 4 ]
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
200e6d8: c2 06 20 38 ld [ %i0 + 0x38 ], %g1
new_block->next = next;
200e6dc: c6 22 20 08 st %g3, [ %o0 + 8 ]
new_block->prev = block_before;
200e6e0: f0 22 20 0c st %i0, [ %o0 + 0xc ]
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
Heap_Statistics *const stats = &heap->stats;
200e6e4: c4 06 20 3c ld [ %i0 + 0x3c ], %g2
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
200e6e8: 82 00 60 01 inc %g1
block_before->next = new_block;
next->prev = new_block;
200e6ec: d0 20 e0 0c st %o0, [ %g3 + 0xc ]
{
Heap_Block *next = block_before->next;
new_block->next = next;
new_block->prev = block_before;
block_before->next = new_block;
200e6f0: d0 26 20 08 st %o0, [ %i0 + 8 ]
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
Heap_Statistics *const stats = &heap->stats;
200e6f4: 80 a0 40 02 cmp %g1, %g2
200e6f8: 08 bf ff e7 bleu 200e694 <_Heap_Free+0x130>
200e6fc: c2 26 20 38 st %g1, [ %i0 + 0x38 ]
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
if ( stats->max_free_blocks < stats->free_blocks ) {
stats->max_free_blocks = stats->free_blocks;
200e700: 10 bf ff e5 b 200e694 <_Heap_Free+0x130>
200e704: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
next_block = _Heap_Block_at( prev_block, size );
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
} else { /* coalesce prev */
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200e708: 82 12 a0 01 or %o2, 1, %g1
200e70c: c2 23 60 04 st %g1, [ %o5 + 4 ]
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200e710: c2 00 a0 04 ld [ %g2 + 4 ], %g1
next_block->prev_size = size;
200e714: d4 22 00 04 st %o2, [ %o0 + %g4 ]
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
} else { /* coalesce prev */
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200e718: 82 08 7f fe and %g1, -2, %g1
200e71c: 10 bf ff de b 200e694 <_Heap_Free+0x130>
200e720: c2 20 a0 04 st %g1, [ %g2 + 4 ]
02030d04 <_Heap_Get_free_information>:
void _Heap_Get_free_information(
Heap_Control *the_heap,
Heap_Information *info
)
{
2030d04: 9d e3 bf a0 save %sp, -96, %sp
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2030d08: c2 06 20 08 ld [ %i0 + 8 ], %g1
Heap_Block *the_block;
Heap_Block *const tail = _Heap_Free_list_tail(the_heap);
info->number = 0;
2030d0c: c0 26 40 00 clr [ %i1 ]
info->largest = 0;
2030d10: c0 26 60 04 clr [ %i1 + 4 ]
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
2030d14: 80 a6 00 01 cmp %i0, %g1
2030d18: 02 80 00 13 be 2030d64 <_Heap_Get_free_information+0x60> <== NEVER TAKEN
2030d1c: c0 26 60 08 clr [ %i1 + 8 ]
2030d20: 88 10 20 01 mov 1, %g4
2030d24: 10 80 00 03 b 2030d30 <_Heap_Get_free_information+0x2c>
2030d28: 86 10 20 00 clr %g3
2030d2c: 88 10 00 02 mov %g2, %g4
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2030d30: c4 00 60 04 ld [ %g1 + 4 ], %g2
/* As we always coalesce free blocks, prev block must have been used. */
_HAssert(_Heap_Is_prev_used(the_block));
info->number++;
info->total += the_size;
if ( info->largest < the_size )
2030d34: da 06 60 04 ld [ %i1 + 4 ], %o5
2030d38: 84 08 bf fe and %g2, -2, %g2
2030d3c: 80 a3 40 02 cmp %o5, %g2
2030d40: 1a 80 00 03 bcc 2030d4c <_Heap_Get_free_information+0x48>
2030d44: 86 00 c0 02 add %g3, %g2, %g3
info->largest = the_size;
2030d48: c4 26 60 04 st %g2, [ %i1 + 4 ]
info->largest = 0;
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
the_block != tail;
the_block = the_block->next)
2030d4c: c2 00 60 08 ld [ %g1 + 8 ], %g1
info->number = 0;
info->largest = 0;
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
2030d50: 80 a6 00 01 cmp %i0, %g1
2030d54: 12 bf ff f6 bne 2030d2c <_Heap_Get_free_information+0x28>
2030d58: 84 01 20 01 add %g4, 1, %g2
2030d5c: c6 26 60 08 st %g3, [ %i1 + 8 ]
2030d60: c8 26 40 00 st %g4, [ %i1 ]
2030d64: 81 c7 e0 08 ret
2030d68: 81 e8 00 00 restore
020475cc <_Heap_Get_information>:
void _Heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
20475cc: 9d e3 bf a0 save %sp, -96, %sp
Heap_Block *the_block = the_heap->first_block;
Heap_Block *const end = the_heap->last_block;
20475d0: c4 06 20 24 ld [ %i0 + 0x24 ], %g2
void _Heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
Heap_Block *the_block = the_heap->first_block;
20475d4: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
Heap_Block *const end = the_heap->last_block;
_HAssert(the_block->prev_size == the_heap->page_size);
_HAssert(_Heap_Is_prev_used(the_block));
the_info->Free.number = 0;
20475d8: c0 26 40 00 clr [ %i1 ]
the_info->Free.total = 0;
20475dc: c0 26 60 08 clr [ %i1 + 8 ]
the_info->Free.largest = 0;
20475e0: c0 26 60 04 clr [ %i1 + 4 ]
the_info->Used.number = 0;
20475e4: c0 26 60 0c clr [ %i1 + 0xc ]
the_info->Used.total = 0;
20475e8: c0 26 60 14 clr [ %i1 + 0x14 ]
the_info->Used.largest = 0;
20475ec: c0 26 60 10 clr [ %i1 + 0x10 ]
while ( the_block != end ) {
20475f0: 80 a0 40 02 cmp %g1, %g2
20475f4: 02 80 00 1a be 204765c <_Heap_Get_information+0x90> <== NEVER TAKEN
20475f8: 86 10 20 08 mov 8, %g3
20475fc: da 00 60 04 ld [ %g1 + 4 ], %o5
uintptr_t const the_size = _Heap_Block_size(the_block);
Heap_Block *const next_block = _Heap_Block_at(the_block, the_size);
Heap_Information *info;
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
2047600: 92 06 60 0c add %i1, 0xc, %o1
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2047604: 88 0b 7f fe and %o5, -2, %g4
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
2047608: 82 00 40 04 add %g1, %g4, %g1
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
204760c: da 00 60 04 ld [ %g1 + 4 ], %o5
while ( the_block != end ) {
uintptr_t const the_size = _Heap_Block_size(the_block);
Heap_Block *const next_block = _Heap_Block_at(the_block, the_size);
Heap_Information *info;
if ( _Heap_Is_prev_used(next_block) )
2047610: 80 8b 60 01 btst 1, %o5
2047614: 12 80 00 03 bne 2047620 <_Heap_Get_information+0x54>
2047618: 86 10 00 09 mov %o1, %g3
204761c: 86 10 00 19 mov %i1, %g3
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
2047620: d4 00 c0 00 ld [ %g3 ], %o2
info->total += the_size;
2047624: d6 00 e0 08 ld [ %g3 + 8 ], %o3
if ( info->largest < the_size )
2047628: d8 00 e0 04 ld [ %g3 + 4 ], %o4
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
204762c: 94 02 a0 01 inc %o2
info->total += the_size;
2047630: 96 02 c0 04 add %o3, %g4, %o3
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
2047634: d4 20 c0 00 st %o2, [ %g3 ]
info->total += the_size;
if ( info->largest < the_size )
2047638: 80 a3 00 04 cmp %o4, %g4
204763c: 1a 80 00 03 bcc 2047648 <_Heap_Get_information+0x7c>
2047640: d6 20 e0 08 st %o3, [ %g3 + 8 ]
info->largest = the_size;
2047644: c8 20 e0 04 st %g4, [ %g3 + 4 ]
the_info->Free.largest = 0;
the_info->Used.number = 0;
the_info->Used.total = 0;
the_info->Used.largest = 0;
while ( the_block != end ) {
2047648: 80 a0 80 01 cmp %g2, %g1
204764c: 12 bf ff ef bne 2047608 <_Heap_Get_information+0x3c>
2047650: 88 0b 7f fe and %o5, -2, %g4
2047654: c6 06 60 14 ld [ %i1 + 0x14 ], %g3
2047658: 86 00 e0 08 add %g3, 8, %g3
/*
* Handle the last dummy block. Don't consider this block to be
* "used" as client never allocated it. Make 'Used.total' contain this
* blocks' overhead though.
*/
the_info->Used.total += HEAP_BLOCK_HEADER_SIZE;
204765c: c6 26 60 14 st %g3, [ %i1 + 0x14 ]
}
2047660: 81 c7 e0 08 ret
2047664: 81 e8 00 00 restore
0201cc24 <_Heap_Size_of_alloc_area>:
bool _Heap_Size_of_alloc_area(
Heap_Control *heap,
void *alloc_begin_ptr,
uintptr_t *alloc_size
)
{
201cc24: 9d e3 bf a0 save %sp, -96, %sp
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
201cc28: d2 06 20 10 ld [ %i0 + 0x10 ], %o1
201cc2c: 7f ff f9 73 call 201b1f8 <.urem>
201cc30: 90 10 00 19 mov %i1, %o0
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
201cc34: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
201cc38: 84 06 7f f8 add %i1, -8, %g2
201cc3c: 84 20 80 08 sub %g2, %o0, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201cc40: 80 a0 80 01 cmp %g2, %g1
201cc44: 0a 80 00 16 bcs 201cc9c <_Heap_Size_of_alloc_area+0x78>
201cc48: 01 00 00 00 nop
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
201cc4c: c6 06 20 24 ld [ %i0 + 0x24 ], %g3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201cc50: 80 a0 80 03 cmp %g2, %g3
201cc54: 18 80 00 12 bgu 201cc9c <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201cc58: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
201cc5c: c8 00 a0 04 ld [ %g2 + 4 ], %g4
201cc60: 88 09 3f fe and %g4, -2, %g4
201cc64: 84 00 80 04 add %g2, %g4, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201cc68: 80 a0 40 02 cmp %g1, %g2
201cc6c: 18 80 00 0c bgu 201cc9c <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201cc70: 80 a0 c0 02 cmp %g3, %g2
201cc74: 0a 80 00 0a bcs 201cc9c <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201cc78: 01 00 00 00 nop
}
block_size = _Heap_Block_size( block );
next_block = _Heap_Block_at( block, block_size );
if (
201cc7c: c2 00 a0 04 ld [ %g2 + 4 ], %g1
201cc80: 80 88 60 01 btst 1, %g1
201cc84: 02 80 00 06 be 201cc9c <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201cc88: 84 20 80 19 sub %g2, %i1, %g2
|| !_Heap_Is_prev_used( next_block )
) {
return false;
}
*alloc_size = (uintptr_t) next_block + HEAP_BLOCK_SIZE_OFFSET - alloc_begin;
201cc8c: 84 00 a0 04 add %g2, 4, %g2
201cc90: c4 26 80 00 st %g2, [ %i2 ]
return true;
201cc94: 81 c7 e0 08 ret
201cc98: 91 e8 20 01 restore %g0, 1, %o0
}
201cc9c: 81 c7 e0 08 ret
201cca0: 91 e8 20 00 restore %g0, 0, %o0
02008afc <_Heap_Walk>:
bool _Heap_Walk(
Heap_Control *heap,
int source,
bool dump
)
{
2008afc: 9d e3 bf 80 save %sp, -128, %sp
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const last_block = heap->last_block;
Heap_Block *block = heap->first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
2008b00: 25 00 80 24 sethi %hi(0x2009000), %l2
2008b04: 80 8e a0 ff btst 0xff, %i2
2008b08: a4 14 a1 2c or %l2, 0x12c, %l2
Heap_Control *heap,
int source,
bool dump
)
{
uintptr_t const page_size = heap->page_size;
2008b0c: ea 06 20 10 ld [ %i0 + 0x10 ], %l5
uintptr_t const min_block_size = heap->min_block_size;
2008b10: e6 06 20 14 ld [ %i0 + 0x14 ], %l3
Heap_Block *const last_block = heap->last_block;
2008b14: e8 06 20 24 ld [ %i0 + 0x24 ], %l4
Heap_Block *block = heap->first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
2008b18: 12 80 00 04 bne 2008b28 <_Heap_Walk+0x2c>
2008b1c: e0 06 20 20 ld [ %i0 + 0x20 ], %l0
2008b20: 25 00 80 22 sethi %hi(0x2008800), %l2
2008b24: a4 14 a2 f4 or %l2, 0x2f4, %l2 ! 2008af4 <_Heap_Walk_print_nothing>
if ( !_System_state_Is_up( _System_state_Get() ) ) {
2008b28: 03 00 80 87 sethi %hi(0x2021c00), %g1
2008b2c: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 2021ee0 <_System_state_Current>
2008b30: 80 a0 60 03 cmp %g1, 3
2008b34: 22 80 00 04 be,a 2008b44 <_Heap_Walk+0x48>
2008b38: da 06 20 18 ld [ %i0 + 0x18 ], %o5
block = next_block;
}
return true;
}
2008b3c: 81 c7 e0 08 ret
2008b40: 91 e8 20 01 restore %g0, 1, %o0
Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
(*printer)(
2008b44: c6 06 20 1c ld [ %i0 + 0x1c ], %g3
2008b48: c4 06 20 08 ld [ %i0 + 8 ], %g2
2008b4c: c2 06 20 0c ld [ %i0 + 0xc ], %g1
2008b50: 90 10 00 19 mov %i1, %o0
2008b54: c6 23 a0 5c st %g3, [ %sp + 0x5c ]
2008b58: c4 23 a0 68 st %g2, [ %sp + 0x68 ]
2008b5c: c2 23 a0 6c st %g1, [ %sp + 0x6c ]
2008b60: e0 23 a0 60 st %l0, [ %sp + 0x60 ]
2008b64: e8 23 a0 64 st %l4, [ %sp + 0x64 ]
2008b68: 92 10 20 00 clr %o1
2008b6c: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008b70: 96 10 00 15 mov %l5, %o3
2008b74: 94 12 a0 30 or %o2, 0x30, %o2
2008b78: 9f c4 80 00 call %l2
2008b7c: 98 10 00 13 mov %l3, %o4
heap->area_begin, heap->area_end,
first_block, last_block,
first_free_block, last_free_block
);
if ( page_size == 0 ) {
2008b80: 80 a5 60 00 cmp %l5, 0
2008b84: 02 80 00 36 be 2008c5c <_Heap_Walk+0x160>
2008b88: 80 8d 60 07 btst 7, %l5
(*printer)( source, true, "page size is zero\n" );
return false;
}
if ( !_Addresses_Is_aligned( (void *) page_size ) ) {
2008b8c: 12 80 00 3c bne 2008c7c <_Heap_Walk+0x180>
2008b90: 90 10 00 13 mov %l3, %o0
);
return false;
}
if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {
2008b94: 7f ff e3 cc call 2001ac4 <.urem>
2008b98: 92 10 00 15 mov %l5, %o1
2008b9c: 80 a2 20 00 cmp %o0, 0
2008ba0: 12 80 00 40 bne 2008ca0 <_Heap_Walk+0x1a4>
2008ba4: 90 04 20 08 add %l0, 8, %o0
);
return false;
}
if (
2008ba8: 7f ff e3 c7 call 2001ac4 <.urem>
2008bac: 92 10 00 15 mov %l5, %o1
2008bb0: 80 a2 20 00 cmp %o0, 0
2008bb4: 32 80 00 44 bne,a 2008cc4 <_Heap_Walk+0x1c8>
2008bb8: 90 10 00 19 mov %i1, %o0
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
2008bbc: ec 04 20 04 ld [ %l0 + 4 ], %l6
);
return false;
}
if ( !_Heap_Is_prev_used( first_block ) ) {
2008bc0: ba 8d a0 01 andcc %l6, 1, %i5
2008bc4: 22 80 00 48 be,a 2008ce4 <_Heap_Walk+0x1e8>
2008bc8: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( first_block->prev_size != page_size ) {
2008bcc: d6 04 00 00 ld [ %l0 ], %o3
2008bd0: 80 a5 40 0b cmp %l5, %o3
2008bd4: 32 80 00 1a bne,a 2008c3c <_Heap_Walk+0x140>
2008bd8: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_free( last_block ) ) {
2008bdc: c2 05 20 04 ld [ %l4 + 4 ], %g1
2008be0: 82 08 7f fe and %g1, -2, %g1
2008be4: 82 05 00 01 add %l4, %g1, %g1
2008be8: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008bec: 80 88 60 01 btst 1, %g1
2008bf0: 22 80 01 2e be,a 20090a8 <_Heap_Walk+0x5ac>
2008bf4: 90 10 00 19 mov %i1, %o0
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008bf8: ee 06 20 08 ld [ %i0 + 8 ], %l7
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008bfc: 80 a6 00 17 cmp %i0, %l7
2008c00: 02 80 00 79 be 2008de4 <_Heap_Walk+0x2e8>
2008c04: f8 06 20 10 ld [ %i0 + 0x10 ], %i4
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
2008c08: f6 06 20 20 ld [ %i0 + 0x20 ], %i3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
2008c0c: 80 a6 c0 17 cmp %i3, %l7
2008c10: 28 80 00 3c bleu,a 2008d00 <_Heap_Walk+0x204> <== ALWAYS TAKEN
2008c14: f4 06 20 24 ld [ %i0 + 0x24 ], %i2
if ( !_Heap_Is_block_in_heap( heap, free_block ) ) {
(*printer)(
2008c18: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2008c1c: 96 10 00 17 mov %l7, %o3
2008c20: 92 10 20 01 mov 1, %o1
2008c24: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008c28: b0 10 20 00 clr %i0
2008c2c: 9f c4 80 00 call %l2
2008c30: 94 12 a1 d8 or %o2, 0x1d8, %o2
2008c34: 81 c7 e0 08 ret
2008c38: 81 e8 00 00 restore
return false;
}
if ( first_block->prev_size != page_size ) {
(*printer)(
2008c3c: 98 10 00 15 mov %l5, %o4
2008c40: 92 10 20 01 mov 1, %o1
2008c44: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008c48: b0 10 20 00 clr %i0
2008c4c: 9f c4 80 00 call %l2
2008c50: 94 12 a1 90 or %o2, 0x190, %o2
2008c54: 81 c7 e0 08 ret
2008c58: 81 e8 00 00 restore
first_block, last_block,
first_free_block, last_free_block
);
if ( page_size == 0 ) {
(*printer)( source, true, "page size is zero\n" );
2008c5c: 90 10 00 19 mov %i1, %o0
2008c60: 92 10 20 01 mov 1, %o1
2008c64: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008c68: b0 10 20 00 clr %i0
2008c6c: 9f c4 80 00 call %l2
2008c70: 94 12 a0 c8 or %o2, 0xc8, %o2
2008c74: 81 c7 e0 08 ret
2008c78: 81 e8 00 00 restore
return false;
}
if ( !_Addresses_Is_aligned( (void *) page_size ) ) {
(*printer)(
2008c7c: 90 10 00 19 mov %i1, %o0
2008c80: 96 10 00 15 mov %l5, %o3
2008c84: 92 10 20 01 mov 1, %o1
2008c88: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008c8c: b0 10 20 00 clr %i0
2008c90: 9f c4 80 00 call %l2
2008c94: 94 12 a0 e0 or %o2, 0xe0, %o2
2008c98: 81 c7 e0 08 ret
2008c9c: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {
(*printer)(
2008ca0: 90 10 00 19 mov %i1, %o0
2008ca4: 96 10 00 13 mov %l3, %o3
2008ca8: 92 10 20 01 mov 1, %o1
2008cac: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008cb0: b0 10 20 00 clr %i0
2008cb4: 9f c4 80 00 call %l2
2008cb8: 94 12 a1 00 or %o2, 0x100, %o2
2008cbc: 81 c7 e0 08 ret
2008cc0: 81 e8 00 00 restore
}
if (
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size )
) {
(*printer)(
2008cc4: 96 10 00 10 mov %l0, %o3
2008cc8: 92 10 20 01 mov 1, %o1
2008ccc: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008cd0: b0 10 20 00 clr %i0
2008cd4: 9f c4 80 00 call %l2
2008cd8: 94 12 a1 28 or %o2, 0x128, %o2
2008cdc: 81 c7 e0 08 ret
2008ce0: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_prev_used( first_block ) ) {
(*printer)(
2008ce4: 92 10 20 01 mov 1, %o1
2008ce8: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008cec: b0 10 20 00 clr %i0
2008cf0: 9f c4 80 00 call %l2
2008cf4: 94 12 a1 60 or %o2, 0x160, %o2
2008cf8: 81 c7 e0 08 ret
2008cfc: 81 e8 00 00 restore
2008d00: 80 a5 c0 1a cmp %l7, %i2
2008d04: 18 bf ff c6 bgu 2008c1c <_Heap_Walk+0x120> <== NEVER TAKEN
2008d08: 90 10 00 19 mov %i1, %o0
);
return false;
}
if (
2008d0c: 90 05 e0 08 add %l7, 8, %o0
2008d10: 7f ff e3 6d call 2001ac4 <.urem>
2008d14: 92 10 00 1c mov %i4, %o1
2008d18: 80 a2 20 00 cmp %o0, 0
2008d1c: 12 80 00 ea bne 20090c4 <_Heap_Walk+0x5c8> <== NEVER TAKEN
2008d20: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_used( free_block ) ) {
2008d24: c2 05 e0 04 ld [ %l7 + 4 ], %g1
2008d28: 82 08 7f fe and %g1, -2, %g1
2008d2c: 82 05 c0 01 add %l7, %g1, %g1
2008d30: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008d34: 80 88 60 01 btst 1, %g1
2008d38: 12 80 00 f5 bne 200910c <_Heap_Walk+0x610> <== NEVER TAKEN
2008d3c: 01 00 00 00 nop
);
return false;
}
if ( free_block->prev != prev_block ) {
2008d40: e2 05 e0 0c ld [ %l7 + 0xc ], %l1
2008d44: 80 a4 40 18 cmp %l1, %i0
2008d48: 12 80 00 e9 bne 20090ec <_Heap_Walk+0x5f0> <== NEVER TAKEN
2008d4c: 96 10 00 17 mov %l7, %o3
2008d50: fa 27 bf fc st %i5, [ %fp + -4 ]
2008d54: ba 10 00 15 mov %l5, %i5
2008d58: aa 10 00 13 mov %l3, %l5
2008d5c: a6 10 00 10 mov %l0, %l3
2008d60: 10 80 00 18 b 2008dc0 <_Heap_Walk+0x2c4>
2008d64: a0 10 00 1c mov %i4, %l0
2008d68: 18 bf ff ad bgu 2008c1c <_Heap_Walk+0x120>
2008d6c: 90 10 00 19 mov %i1, %o0
2008d70: 80 a5 c0 1a cmp %l7, %i2
2008d74: 18 bf ff ab bgu 2008c20 <_Heap_Walk+0x124> <== NEVER TAKEN
2008d78: 96 10 00 17 mov %l7, %o3
);
return false;
}
if (
2008d7c: 90 05 e0 08 add %l7, 8, %o0
2008d80: 7f ff e3 51 call 2001ac4 <.urem>
2008d84: 92 10 00 10 mov %l0, %o1
2008d88: 80 a2 20 00 cmp %o0, 0
2008d8c: 32 80 00 ce bne,a 20090c4 <_Heap_Walk+0x5c8>
2008d90: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_used( free_block ) ) {
2008d94: c2 05 e0 04 ld [ %l7 + 4 ], %g1
2008d98: 82 08 7f fe and %g1, -2, %g1
2008d9c: 82 00 40 17 add %g1, %l7, %g1
2008da0: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008da4: 80 88 60 01 btst 1, %g1
2008da8: 32 80 00 d9 bne,a 200910c <_Heap_Walk+0x610>
2008dac: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( free_block->prev != prev_block ) {
2008db0: c2 05 e0 0c ld [ %l7 + 0xc ], %g1
2008db4: 80 a7 00 01 cmp %i4, %g1
2008db8: 32 80 00 cb bne,a 20090e4 <_Heap_Walk+0x5e8>
2008dbc: a2 10 00 01 mov %g1, %l1
(*printer)(
2008dc0: b8 10 00 17 mov %l7, %i4
return false;
}
prev_block = free_block;
free_block = free_block->next;
2008dc4: ee 05 e0 08 ld [ %l7 + 8 ], %l7
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008dc8: 80 a4 40 17 cmp %l1, %l7
2008dcc: 12 bf ff e7 bne 2008d68 <_Heap_Walk+0x26c>
2008dd0: 80 a6 c0 17 cmp %i3, %l7
2008dd4: a0 10 00 13 mov %l3, %l0
2008dd8: a6 10 00 15 mov %l5, %l3
2008ddc: aa 10 00 1d mov %i5, %l5
2008de0: fa 07 bf fc ld [ %fp + -4 ], %i5
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
}
while ( block != last_block ) {
2008de4: 80 a5 00 10 cmp %l4, %l0
2008de8: 02 bf ff 55 be 2008b3c <_Heap_Walk+0x40> <== NEVER TAKEN
2008dec: 37 00 80 7b sethi %hi(0x201ec00), %i3
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008df0: 35 00 80 7b sethi %hi(0x201ec00), %i2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008df4: 39 00 80 7b sethi %hi(0x201ec00), %i4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008df8: 82 10 00 1d mov %i5, %g1
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
if ( prev_used ) {
(*printer)(
2008dfc: b6 16 e2 80 or %i3, 0x280, %i3
2008e00: ba 10 00 15 mov %l5, %i5
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008e04: b4 16 a2 98 or %i2, 0x298, %i2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008e08: b8 17 23 98 or %i4, 0x398, %i4
2008e0c: aa 10 00 14 mov %l4, %l5
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2008e10: ac 0d bf fe and %l6, -2, %l6
uintptr_t const block_size = _Heap_Block_size( block );
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
if ( prev_used ) {
2008e14: 80 a0 60 00 cmp %g1, 0
2008e18: 02 80 00 16 be 2008e70 <_Heap_Walk+0x374>
2008e1c: a2 05 80 10 add %l6, %l0, %l1
(*printer)(
2008e20: 90 10 00 19 mov %i1, %o0
2008e24: 92 10 20 00 clr %o1
2008e28: 94 10 00 1b mov %i3, %o2
2008e2c: 96 10 00 10 mov %l0, %o3
2008e30: 9f c4 80 00 call %l2
2008e34: 98 10 00 16 mov %l6, %o4
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
2008e38: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
2008e3c: 80 a0 40 11 cmp %g1, %l1
2008e40: 28 80 00 18 bleu,a 2008ea0 <_Heap_Walk+0x3a4> <== ALWAYS TAKEN
2008e44: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
block->prev_size
);
}
if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {
(*printer)(
2008e48: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2008e4c: 96 10 00 10 mov %l0, %o3
2008e50: 98 10 00 11 mov %l1, %o4
2008e54: 92 10 20 01 mov 1, %o1
2008e58: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008e5c: b0 10 20 00 clr %i0
2008e60: 9f c4 80 00 call %l2
2008e64: 94 12 a2 c0 or %o2, 0x2c0, %o2
"block 0x%08x: next block 0x%08x not in heap\n",
block,
next_block
);
return false;
2008e68: 81 c7 e0 08 ret
2008e6c: 81 e8 00 00 restore
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008e70: da 04 00 00 ld [ %l0 ], %o5
2008e74: 90 10 00 19 mov %i1, %o0
2008e78: 92 10 20 00 clr %o1
2008e7c: 94 10 00 1a mov %i2, %o2
2008e80: 96 10 00 10 mov %l0, %o3
2008e84: 9f c4 80 00 call %l2
2008e88: 98 10 00 16 mov %l6, %o4
2008e8c: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
2008e90: 80 a0 40 11 cmp %g1, %l1
2008e94: 18 bf ff ee bgu 2008e4c <_Heap_Walk+0x350> <== NEVER TAKEN
2008e98: 90 10 00 19 mov %i1, %o0
2008e9c: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
2008ea0: 80 a0 40 11 cmp %g1, %l1
2008ea4: 0a bf ff ea bcs 2008e4c <_Heap_Walk+0x350>
2008ea8: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( !_Heap_Is_aligned( block_size, page_size ) ) {
2008eac: 90 10 00 16 mov %l6, %o0
2008eb0: 7f ff e3 05 call 2001ac4 <.urem>
2008eb4: 92 10 00 1d mov %i5, %o1
2008eb8: 80 a2 20 00 cmp %o0, 0
2008ebc: 12 80 00 5d bne 2009030 <_Heap_Walk+0x534>
2008ec0: 80 a4 c0 16 cmp %l3, %l6
);
return false;
}
if ( block_size < min_block_size ) {
2008ec4: 18 80 00 65 bgu 2009058 <_Heap_Walk+0x55c>
2008ec8: 80 a4 00 11 cmp %l0, %l1
);
return false;
}
if ( next_block_begin <= block_begin ) {
2008ecc: 3a 80 00 6e bcc,a 2009084 <_Heap_Walk+0x588>
2008ed0: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
2008ed4: c2 04 60 04 ld [ %l1 + 4 ], %g1
2008ed8: 80 88 60 01 btst 1, %g1
2008edc: 12 80 00 40 bne 2008fdc <_Heap_Walk+0x4e0>
2008ee0: 80 a5 40 11 cmp %l5, %l1
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
2008ee4: e8 04 20 04 ld [ %l0 + 4 ], %l4
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008ee8: d8 04 20 0c ld [ %l0 + 0xc ], %o4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008eec: c2 06 20 08 ld [ %i0 + 8 ], %g1
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2008ef0: ac 0d 3f fe and %l4, -2, %l6
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008ef4: 1b 00 80 7b sethi %hi(0x201ec00), %o5
2008ef8: 80 a0 40 0c cmp %g1, %o4
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_last( Heap_Control *heap )
{
return _Heap_Free_list_tail(heap)->prev;
2008efc: c6 06 20 0c ld [ %i0 + 0xc ], %g3
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
2008f00: ae 04 00 16 add %l0, %l6, %l7
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008f04: 02 80 00 07 be 2008f20 <_Heap_Walk+0x424>
2008f08: 9a 13 63 88 or %o5, 0x388, %o5
"block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n",
block,
block->prev,
block->prev == first_free_block ?
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
2008f0c: 1b 00 80 7b sethi %hi(0x201ec00), %o5
2008f10: 80 a3 00 18 cmp %o4, %i0
2008f14: 02 80 00 03 be 2008f20 <_Heap_Walk+0x424>
2008f18: 9a 13 63 a0 or %o5, 0x3a0, %o5
2008f1c: 9a 10 00 1c mov %i4, %o5
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008f20: c2 04 20 08 ld [ %l0 + 8 ], %g1
2008f24: 05 00 80 7b sethi %hi(0x201ec00), %g2
2008f28: 80 a0 c0 01 cmp %g3, %g1
2008f2c: 02 80 00 07 be 2008f48 <_Heap_Walk+0x44c>
2008f30: 84 10 a3 b0 or %g2, 0x3b0, %g2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008f34: 05 00 80 7b sethi %hi(0x201ec00), %g2
2008f38: 80 a0 40 18 cmp %g1, %i0
2008f3c: 02 80 00 03 be 2008f48 <_Heap_Walk+0x44c>
2008f40: 84 10 a3 c0 or %g2, 0x3c0, %g2
2008f44: 84 10 00 1c mov %i4, %g2
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008f48: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
2008f4c: c4 23 a0 60 st %g2, [ %sp + 0x60 ]
2008f50: 90 10 00 19 mov %i1, %o0
2008f54: 92 10 20 00 clr %o1
2008f58: 15 00 80 7b sethi %hi(0x201ec00), %o2
2008f5c: 96 10 00 10 mov %l0, %o3
2008f60: 9f c4 80 00 call %l2
2008f64: 94 12 a3 d0 or %o2, 0x3d0, %o2
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
);
if ( block_size != next_block->prev_size ) {
2008f68: da 05 c0 00 ld [ %l7 ], %o5
2008f6c: 80 a5 80 0d cmp %l6, %o5
2008f70: 02 80 00 0c be 2008fa0 <_Heap_Walk+0x4a4>
2008f74: 90 10 00 19 mov %i1, %o0
(*printer)(
2008f78: ee 23 a0 5c st %l7, [ %sp + 0x5c ]
2008f7c: 96 10 00 10 mov %l0, %o3
2008f80: 98 10 00 16 mov %l6, %o4
2008f84: 92 10 20 01 mov 1, %o1
2008f88: 15 00 80 7c sethi %hi(0x201f000), %o2
2008f8c: b0 10 20 00 clr %i0
2008f90: 9f c4 80 00 call %l2
2008f94: 94 12 a0 00 mov %o2, %o2
2008f98: 81 c7 e0 08 ret
2008f9c: 81 e8 00 00 restore
);
return false;
}
if ( !prev_used ) {
2008fa0: 80 8d 20 01 btst 1, %l4
2008fa4: 02 80 00 1c be 2009014 <_Heap_Walk+0x518>
2008fa8: 96 10 00 10 mov %l0, %o3
2008fac: c2 06 20 08 ld [ %i0 + 8 ], %g1
)
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
2008fb0: 80 a0 40 18 cmp %g1, %i0
2008fb4: 12 80 00 07 bne 2008fd0 <_Heap_Walk+0x4d4> <== ALWAYS TAKEN
2008fb8: 80 a0 40 10 cmp %g1, %l0
return false;
}
if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {
(*printer)(
2008fbc: 10 80 00 0f b 2008ff8 <_Heap_Walk+0x4fc> <== NOT EXECUTED
2008fc0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
)
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
2008fc4: 80 a0 40 18 cmp %g1, %i0
2008fc8: 02 80 00 0a be 2008ff0 <_Heap_Walk+0x4f4>
2008fcc: 80 a0 40 10 cmp %g1, %l0
if ( free_block == block ) {
2008fd0: 32 bf ff fd bne,a 2008fc4 <_Heap_Walk+0x4c8>
2008fd4: c2 00 60 08 ld [ %g1 + 8 ], %g1
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
}
while ( block != last_block ) {
2008fd8: 80 a5 40 11 cmp %l5, %l1
2008fdc: 02 bf fe d8 be 2008b3c <_Heap_Walk+0x40>
2008fe0: a0 10 00 11 mov %l1, %l0
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008fe4: ec 04 60 04 ld [ %l1 + 4 ], %l6
2008fe8: 10 bf ff 8a b 2008e10 <_Heap_Walk+0x314>
2008fec: 82 0d a0 01 and %l6, 1, %g1
return false;
}
if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {
(*printer)(
2008ff0: 90 10 00 19 mov %i1, %o0
2008ff4: 96 10 00 10 mov %l0, %o3
2008ff8: 92 10 20 01 mov 1, %o1
2008ffc: 15 00 80 7c sethi %hi(0x201f000), %o2
2009000: b0 10 20 00 clr %i0
2009004: 9f c4 80 00 call %l2
2009008: 94 12 a0 70 or %o2, 0x70, %o2
200900c: 81 c7 e0 08 ret
2009010: 81 e8 00 00 restore
return false;
}
if ( !prev_used ) {
(*printer)(
2009014: 92 10 20 01 mov 1, %o1
2009018: 15 00 80 7c sethi %hi(0x201f000), %o2
200901c: b0 10 20 00 clr %i0
2009020: 9f c4 80 00 call %l2
2009024: 94 12 a0 40 or %o2, 0x40, %o2
2009028: 81 c7 e0 08 ret
200902c: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_aligned( block_size, page_size ) ) {
(*printer)(
2009030: 90 10 00 19 mov %i1, %o0
2009034: 96 10 00 10 mov %l0, %o3
2009038: 98 10 00 16 mov %l6, %o4
200903c: 92 10 20 01 mov 1, %o1
2009040: 15 00 80 7b sethi %hi(0x201ec00), %o2
2009044: b0 10 20 00 clr %i0
2009048: 9f c4 80 00 call %l2
200904c: 94 12 a2 f0 or %o2, 0x2f0, %o2
"block 0x%08x: block size %u not page aligned\n",
block,
block_size
);
return false;
2009050: 81 c7 e0 08 ret
2009054: 81 e8 00 00 restore
}
if ( block_size < min_block_size ) {
(*printer)(
2009058: 90 10 00 19 mov %i1, %o0
200905c: 96 10 00 10 mov %l0, %o3
2009060: 98 10 00 16 mov %l6, %o4
2009064: 9a 10 00 13 mov %l3, %o5
2009068: 92 10 20 01 mov 1, %o1
200906c: 15 00 80 7b sethi %hi(0x201ec00), %o2
2009070: b0 10 20 00 clr %i0
2009074: 9f c4 80 00 call %l2
2009078: 94 12 a3 20 or %o2, 0x320, %o2
block,
block_size,
min_block_size
);
return false;
200907c: 81 c7 e0 08 ret
2009080: 81 e8 00 00 restore
}
if ( next_block_begin <= block_begin ) {
(*printer)(
2009084: 96 10 00 10 mov %l0, %o3
2009088: 98 10 00 11 mov %l1, %o4
200908c: 92 10 20 01 mov 1, %o1
2009090: 15 00 80 7b sethi %hi(0x201ec00), %o2
2009094: b0 10 20 00 clr %i0
2009098: 9f c4 80 00 call %l2
200909c: 94 12 a3 50 or %o2, 0x350, %o2
"block 0x%08x: next block 0x%08x is not a successor\n",
block,
next_block
);
return false;
20090a0: 81 c7 e0 08 ret
20090a4: 81 e8 00 00 restore
return false;
}
if ( _Heap_Is_free( last_block ) ) {
(*printer)(
20090a8: 92 10 20 01 mov 1, %o1
20090ac: 15 00 80 7b sethi %hi(0x201ec00), %o2
20090b0: b0 10 20 00 clr %i0
20090b4: 9f c4 80 00 call %l2
20090b8: 94 12 a1 c0 or %o2, 0x1c0, %o2
20090bc: 81 c7 e0 08 ret
20090c0: 81 e8 00 00 restore
}
if (
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size )
) {
(*printer)(
20090c4: 96 10 00 17 mov %l7, %o3
20090c8: 92 10 20 01 mov 1, %o1
20090cc: 15 00 80 7b sethi %hi(0x201ec00), %o2
20090d0: b0 10 20 00 clr %i0
20090d4: 9f c4 80 00 call %l2
20090d8: 94 12 a1 f8 or %o2, 0x1f8, %o2
20090dc: 81 c7 e0 08 ret
20090e0: 81 e8 00 00 restore
return false;
}
if ( free_block->prev != prev_block ) {
(*printer)(
20090e4: 90 10 00 19 mov %i1, %o0
20090e8: 96 10 00 17 mov %l7, %o3
20090ec: 98 10 00 11 mov %l1, %o4
20090f0: 92 10 20 01 mov 1, %o1
20090f4: 15 00 80 7b sethi %hi(0x201ec00), %o2
20090f8: b0 10 20 00 clr %i0
20090fc: 9f c4 80 00 call %l2
2009100: 94 12 a2 48 or %o2, 0x248, %o2
2009104: 81 c7 e0 08 ret
2009108: 81 e8 00 00 restore
return false;
}
if ( _Heap_Is_used( free_block ) ) {
(*printer)(
200910c: 96 10 00 17 mov %l7, %o3
2009110: 92 10 20 01 mov 1, %o1
2009114: 15 00 80 7b sethi %hi(0x201ec00), %o2
2009118: b0 10 20 00 clr %i0
200911c: 9f c4 80 00 call %l2
2009120: 94 12 a2 28 or %o2, 0x228, %o2
2009124: 81 c7 e0 08 ret
2009128: 81 e8 00 00 restore
02006f7c <_IO_Initialize_all_drivers>:
*
* Output Parameters: NONE
*/
void _IO_Initialize_all_drivers( void )
{
2006f7c: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major;
for ( major=0 ; major < _IO_Number_of_drivers ; major ++ )
2006f80: 23 00 80 7f sethi %hi(0x201fc00), %l1
2006f84: c2 04 61 0c ld [ %l1 + 0x10c ], %g1 ! 201fd0c <_IO_Number_of_drivers>
2006f88: 80 a0 60 00 cmp %g1, 0
2006f8c: 02 80 00 0c be 2006fbc <_IO_Initialize_all_drivers+0x40> <== NEVER TAKEN
2006f90: a2 14 61 0c or %l1, 0x10c, %l1
2006f94: a0 10 20 00 clr %l0
(void) rtems_io_initialize( major, 0, NULL );
2006f98: 90 10 00 10 mov %l0, %o0
2006f9c: 92 10 20 00 clr %o1
2006fa0: 40 00 1c 1e call 200e018 <rtems_io_initialize>
2006fa4: 94 10 20 00 clr %o2
void _IO_Initialize_all_drivers( void )
{
rtems_device_major_number major;
for ( major=0 ; major < _IO_Number_of_drivers ; major ++ )
2006fa8: c2 04 40 00 ld [ %l1 ], %g1
2006fac: a0 04 20 01 inc %l0
2006fb0: 80 a0 40 10 cmp %g1, %l0
2006fb4: 18 bf ff fa bgu 2006f9c <_IO_Initialize_all_drivers+0x20>
2006fb8: 90 10 00 10 mov %l0, %o0
2006fbc: 81 c7 e0 08 ret
2006fc0: 81 e8 00 00 restore
02006fc4 <_IO_Manager_initialization>:
* workspace.
*
*/
void _IO_Manager_initialization(void)
{
2006fc4: 9d e3 bf a0 save %sp, -96, %sp
uint32_t index;
rtems_driver_address_table *driver_table;
uint32_t drivers_in_table;
uint32_t number_of_drivers;
driver_table = Configuration.Device_driver_table;
2006fc8: 03 00 80 7a sethi %hi(0x201e800), %g1
2006fcc: 82 10 60 68 or %g1, 0x68, %g1 ! 201e868 <Configuration>
drivers_in_table = Configuration.number_of_device_drivers;
number_of_drivers = Configuration.maximum_drivers;
2006fd0: e6 00 60 2c ld [ %g1 + 0x2c ], %l3
rtems_driver_address_table *driver_table;
uint32_t drivers_in_table;
uint32_t number_of_drivers;
driver_table = Configuration.Device_driver_table;
drivers_in_table = Configuration.number_of_device_drivers;
2006fd4: e2 00 60 30 ld [ %g1 + 0x30 ], %l1
/*
* If the user claims there are less drivers than are actually in
* the table, then let's just go with the table's count.
*/
if ( number_of_drivers <= drivers_in_table )
2006fd8: 80 a4 40 13 cmp %l1, %l3
2006fdc: 0a 80 00 08 bcs 2006ffc <_IO_Manager_initialization+0x38>
2006fe0: e0 00 60 34 ld [ %g1 + 0x34 ], %l0
* If the maximum number of driver is the same as the number in the
* table, then we do not have to copy the driver table. They can't
* register any dynamically.
*/
if ( number_of_drivers == drivers_in_table ) {
_IO_Driver_address_table = driver_table;
2006fe4: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006fe8: e0 20 61 10 st %l0, [ %g1 + 0x110 ] ! 201fd10 <_IO_Driver_address_table>
_IO_Number_of_drivers = number_of_drivers;
2006fec: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006ff0: e2 20 61 0c st %l1, [ %g1 + 0x10c ] ! 201fd0c <_IO_Number_of_drivers>
return;
2006ff4: 81 c7 e0 08 ret
2006ff8: 81 e8 00 00 restore
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
2006ffc: 83 2c e0 03 sll %l3, 3, %g1
2007000: a5 2c e0 05 sll %l3, 5, %l2
2007004: a4 24 80 01 sub %l2, %g1, %l2
/*
* The application requested extra slots in the driver table, so we
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
2007008: 40 00 0c dd call 200a37c <_Workspace_Allocate_or_fatal_error>
200700c: 90 10 00 12 mov %l2, %o0
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
2007010: 03 00 80 7f sethi %hi(0x201fc00), %g1
memset(
2007014: 94 10 00 12 mov %l2, %o2
_IO_Driver_address_table = (rtems_driver_address_table *)
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
2007018: e6 20 61 0c st %l3, [ %g1 + 0x10c ]
/*
* The application requested extra slots in the driver table, so we
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
200701c: 25 00 80 7f sethi %hi(0x201fc00), %l2
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
memset(
2007020: 92 10 20 00 clr %o1
2007024: 40 00 2c f1 call 20123e8 <memset>
2007028: d0 24 a1 10 st %o0, [ %l2 + 0x110 ]
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
200702c: 80 a4 60 00 cmp %l1, 0
2007030: 02 bf ff f1 be 2006ff4 <_IO_Manager_initialization+0x30> <== NEVER TAKEN
2007034: da 04 a1 10 ld [ %l2 + 0x110 ], %o5
2007038: 82 10 20 00 clr %g1
200703c: 88 10 20 00 clr %g4
_IO_Driver_address_table[index] = driver_table[index];
2007040: c4 04 00 01 ld [ %l0 + %g1 ], %g2
2007044: 86 04 00 01 add %l0, %g1, %g3
2007048: c4 23 40 01 st %g2, [ %o5 + %g1 ]
200704c: d8 00 e0 04 ld [ %g3 + 4 ], %o4
2007050: 84 03 40 01 add %o5, %g1, %g2
2007054: d8 20 a0 04 st %o4, [ %g2 + 4 ]
2007058: d8 00 e0 08 ld [ %g3 + 8 ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
200705c: 88 01 20 01 inc %g4
_IO_Driver_address_table[index] = driver_table[index];
2007060: d8 20 a0 08 st %o4, [ %g2 + 8 ]
2007064: d8 00 e0 0c ld [ %g3 + 0xc ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007068: 82 00 60 18 add %g1, 0x18, %g1
_IO_Driver_address_table[index] = driver_table[index];
200706c: d8 20 a0 0c st %o4, [ %g2 + 0xc ]
2007070: d8 00 e0 10 ld [ %g3 + 0x10 ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007074: 80 a4 40 04 cmp %l1, %g4
_IO_Driver_address_table[index] = driver_table[index];
2007078: d8 20 a0 10 st %o4, [ %g2 + 0x10 ]
200707c: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007080: 18 bf ff f0 bgu 2007040 <_IO_Manager_initialization+0x7c>
2007084: c6 20 a0 14 st %g3, [ %g2 + 0x14 ]
2007088: 81 c7 e0 08 ret
200708c: 81 e8 00 00 restore
020012c0 <_Message_queue_Manager_initialization>:
#include <rtems/score/wkspace.h>
#include <rtems/score/interr.h>
void _Message_queue_Manager_initialization(void)
{
}
20012c0: 81 c3 e0 08 retl
02007d9c <_Objects_Allocate>:
*/
Objects_Control *_Objects_Allocate(
Objects_Information *information
)
{
2007d9c: 9d e3 bf a0 save %sp, -96, %sp
* If the application is using the optional manager stubs and
* still attempts to create the object, the information block
* should be all zeroed out because it is in the BSS. So let's
* check that code for this manager is even present.
*/
if ( information->size == 0 )
2007da0: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
*/
Objects_Control *_Objects_Allocate(
Objects_Information *information
)
{
2007da4: a0 10 00 18 mov %i0, %l0
* If the application is using the optional manager stubs and
* still attempts to create the object, the information block
* should be all zeroed out because it is in the BSS. So let's
* check that code for this manager is even present.
*/
if ( information->size == 0 )
2007da8: 80 a0 60 00 cmp %g1, 0
2007dac: 02 80 00 19 be 2007e10 <_Objects_Allocate+0x74> <== NEVER TAKEN
2007db0: b0 10 20 00 clr %i0
/*
* OK. The manager should be initialized and configured to have objects.
* With any luck, it is safe to attempt to allocate an object.
*/
the_object = (Objects_Control *) _Chain_Get( &information->Inactive );
2007db4: a2 04 20 20 add %l0, 0x20, %l1
2007db8: 7f ff fd 6d call 200736c <_Chain_Get>
2007dbc: 90 10 00 11 mov %l1, %o0
if ( information->auto_extend ) {
2007dc0: c2 0c 20 12 ldub [ %l0 + 0x12 ], %g1
2007dc4: 80 a0 60 00 cmp %g1, 0
2007dc8: 02 80 00 12 be 2007e10 <_Objects_Allocate+0x74>
2007dcc: b0 10 00 08 mov %o0, %i0
/*
* If the list is empty then we are out of objects and need to
* extend information base.
*/
if ( !the_object ) {
2007dd0: 80 a2 20 00 cmp %o0, 0
2007dd4: 02 80 00 11 be 2007e18 <_Objects_Allocate+0x7c>
2007dd8: 01 00 00 00 nop
}
if ( the_object ) {
uint32_t block;
block = (uint32_t) _Objects_Get_index( the_object->id ) -
2007ddc: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
2007de0: d0 16 20 0a lduh [ %i0 + 0xa ], %o0
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007de4: d2 14 20 14 lduh [ %l0 + 0x14 ], %o1
2007de8: 40 00 4c 58 call 201af48 <.udiv>
2007dec: 90 22 00 01 sub %o0, %g1, %o0
2007df0: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2007df4: 91 2a 20 02 sll %o0, 2, %o0
information->inactive--;
2007df8: c6 14 20 2c lduh [ %l0 + 0x2c ], %g3
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007dfc: c4 00 40 08 ld [ %g1 + %o0 ], %g2
information->inactive--;
2007e00: 86 00 ff ff add %g3, -1, %g3
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007e04: 84 00 bf ff add %g2, -1, %g2
information->inactive--;
2007e08: c6 34 20 2c sth %g3, [ %l0 + 0x2c ]
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007e0c: c4 20 40 08 st %g2, [ %g1 + %o0 ]
information->inactive--;
}
}
return the_object;
}
2007e10: 81 c7 e0 08 ret
2007e14: 81 e8 00 00 restore
* If the list is empty then we are out of objects and need to
* extend information base.
*/
if ( !the_object ) {
_Objects_Extend_information( information );
2007e18: 40 00 00 11 call 2007e5c <_Objects_Extend_information>
2007e1c: 90 10 00 10 mov %l0, %o0
the_object = (Objects_Control *) _Chain_Get( &information->Inactive );
2007e20: 7f ff fd 53 call 200736c <_Chain_Get>
2007e24: 90 10 00 11 mov %l1, %o0
}
if ( the_object ) {
2007e28: b0 92 20 00 orcc %o0, 0, %i0
2007e2c: 32 bf ff ed bne,a 2007de0 <_Objects_Allocate+0x44>
2007e30: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
information->inactive--;
}
}
return the_object;
}
2007e34: 81 c7 e0 08 ret
2007e38: 81 e8 00 00 restore
02007e5c <_Objects_Extend_information>:
*/
void _Objects_Extend_information(
Objects_Information *information
)
{
2007e5c: 9d e3 bf 90 save %sp, -112, %sp
minimum_index = _Objects_Get_index( information->minimum_id );
index_base = minimum_index;
block = 0;
/* if ( information->maximum < minimum_index ) */
if ( information->object_blocks == NULL )
2007e60: e8 06 20 34 ld [ %i0 + 0x34 ], %l4
2007e64: 80 a5 20 00 cmp %l4, 0
2007e68: 02 80 00 ab be 2008114 <_Objects_Extend_information+0x2b8>
2007e6c: e6 16 20 0a lduh [ %i0 + 0xa ], %l3
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
2007e70: ea 16 20 10 lduh [ %i0 + 0x10 ], %l5
2007e74: e4 16 20 14 lduh [ %i0 + 0x14 ], %l2
2007e78: ab 2d 60 10 sll %l5, 0x10, %l5
2007e7c: 92 10 00 12 mov %l2, %o1
2007e80: 40 00 4c 32 call 201af48 <.udiv>
2007e84: 91 35 60 10 srl %l5, 0x10, %o0
2007e88: 91 2a 20 10 sll %o0, 0x10, %o0
2007e8c: b9 32 20 10 srl %o0, 0x10, %i4
for ( ; block < block_count; block++ ) {
2007e90: 80 a7 20 00 cmp %i4, 0
2007e94: 02 80 00 a7 be 2008130 <_Objects_Extend_information+0x2d4><== NEVER TAKEN
2007e98: 90 10 00 12 mov %l2, %o0
if ( information->object_blocks[ block ] == NULL )
2007e9c: c2 05 00 00 ld [ %l4 ], %g1
2007ea0: 80 a0 60 00 cmp %g1, 0
2007ea4: 02 80 00 a4 be 2008134 <_Objects_Extend_information+0x2d8><== NEVER TAKEN
2007ea8: a2 10 00 13 mov %l3, %l1
2007eac: 10 80 00 06 b 2007ec4 <_Objects_Extend_information+0x68>
2007eb0: a0 10 20 00 clr %l0
2007eb4: c2 05 00 01 ld [ %l4 + %g1 ], %g1
2007eb8: 80 a0 60 00 cmp %g1, 0
2007ebc: 22 80 00 08 be,a 2007edc <_Objects_Extend_information+0x80>
2007ec0: ab 35 60 10 srl %l5, 0x10, %l5
if ( information->object_blocks == NULL )
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
2007ec4: a0 04 20 01 inc %l0
if ( information->object_blocks[ block ] == NULL )
break;
else
index_base += information->allocation_size;
2007ec8: a2 04 40 12 add %l1, %l2, %l1
if ( information->object_blocks == NULL )
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
2007ecc: 80 a7 00 10 cmp %i4, %l0
2007ed0: 18 bf ff f9 bgu 2007eb4 <_Objects_Extend_information+0x58>
2007ed4: 83 2c 20 02 sll %l0, 2, %g1
else
index_base += information->allocation_size;
}
}
maximum = (uint32_t) information->maximum + information->allocation_size;
2007ed8: ab 35 60 10 srl %l5, 0x10, %l5
/*
* We need to limit the number of objects to the maximum number
* representable in the index portion of the object Id. In the
* case of 16-bit Ids, this is only 256 object instances.
*/
if ( maximum > OBJECTS_ID_FINAL_INDEX ) {
2007edc: 03 00 00 3f sethi %hi(0xfc00), %g1
else
index_base += information->allocation_size;
}
}
maximum = (uint32_t) information->maximum + information->allocation_size;
2007ee0: aa 05 40 08 add %l5, %o0, %l5
/*
* We need to limit the number of objects to the maximum number
* representable in the index portion of the object Id. In the
* case of 16-bit Ids, this is only 256 object instances.
*/
if ( maximum > OBJECTS_ID_FINAL_INDEX ) {
2007ee4: 82 10 63 ff or %g1, 0x3ff, %g1
2007ee8: 80 a5 40 01 cmp %l5, %g1
2007eec: 18 80 00 96 bgu 2008144 <_Objects_Extend_information+0x2e8><== NEVER TAKEN
2007ef0: 01 00 00 00 nop
/*
* Allocate the name table, and the objects and if it fails either return or
* generate a fatal error depending on auto-extending being active.
*/
block_size = information->allocation_size * information->size;
2007ef4: 40 00 4b db call 201ae60 <.umul>
2007ef8: d2 06 20 18 ld [ %i0 + 0x18 ], %o1
if ( information->auto_extend ) {
2007efc: c2 0e 20 12 ldub [ %i0 + 0x12 ], %g1
2007f00: 80 a0 60 00 cmp %g1, 0
2007f04: 12 80 00 6d bne 20080b8 <_Objects_Extend_information+0x25c>
2007f08: 01 00 00 00 nop
new_object_block = _Workspace_Allocate( block_size );
if ( !new_object_block )
return;
} else {
new_object_block = _Workspace_Allocate_or_fatal_error( block_size );
2007f0c: 40 00 09 1c call 200a37c <_Workspace_Allocate_or_fatal_error>
2007f10: 01 00 00 00 nop
2007f14: a4 10 00 08 mov %o0, %l2
}
/*
* If the index_base is the maximum we need to grow the tables.
*/
if (index_base >= information->maximum ) {
2007f18: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2007f1c: 80 a4 40 01 cmp %l1, %g1
2007f20: 2a 80 00 43 bcs,a 200802c <_Objects_Extend_information+0x1d0>
2007f24: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
*/
/*
* Up the block count and maximum
*/
block_count++;
2007f28: a8 07 20 01 add %i4, 1, %l4
* Allocate the tables and break it up.
*/
block_size = block_count *
(sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) +
((maximum + minimum_index) * sizeof(Objects_Control *));
object_blocks = (void**) _Workspace_Allocate( block_size );
2007f2c: 91 2d 20 01 sll %l4, 1, %o0
2007f30: 90 02 00 14 add %o0, %l4, %o0
2007f34: 90 05 40 08 add %l5, %o0, %o0
2007f38: 90 02 00 13 add %o0, %l3, %o0
2007f3c: 40 00 09 1f call 200a3b8 <_Workspace_Allocate>
2007f40: 91 2a 20 02 sll %o0, 2, %o0
if ( !object_blocks ) {
2007f44: ac 92 20 00 orcc %o0, 0, %l6
2007f48: 02 80 00 7d be 200813c <_Objects_Extend_information+0x2e0>
2007f4c: a9 2d 20 02 sll %l4, 2, %l4
* Take the block count down. Saves all the (block_count - 1)
* in the copies.
*/
block_count--;
if ( information->maximum > minimum_index ) {
2007f50: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2007f54: 80 a4 c0 01 cmp %l3, %g1
RTEMS_INLINE_ROUTINE void *_Addresses_Add_offset (
const void *base,
uintptr_t offset
)
{
return (void *)((uintptr_t)base + offset);
2007f58: ae 05 80 14 add %l6, %l4, %l7
2007f5c: 0a 80 00 5e bcs 20080d4 <_Objects_Extend_information+0x278>
2007f60: a8 05 c0 14 add %l7, %l4, %l4
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007f64: 80 a4 e0 00 cmp %l3, 0
information->object_blocks,
block_count * sizeof(void*) );
memcpy( inactive_per_block,
information->inactive_per_block,
block_count * sizeof(uint32_t) );
memcpy( local_table,
2007f68: 82 10 20 00 clr %g1
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007f6c: 02 80 00 08 be 2007f8c <_Objects_Extend_information+0x130><== NEVER TAKEN
2007f70: bb 2f 20 02 sll %i4, 2, %i5
local_table[ index ] = NULL;
2007f74: 85 28 60 02 sll %g1, 2, %g2
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007f78: 82 00 60 01 inc %g1
2007f7c: 80 a4 c0 01 cmp %l3, %g1
2007f80: 18 bf ff fd bgu 2007f74 <_Objects_Extend_information+0x118><== NEVER TAKEN
2007f84: c0 20 80 14 clr [ %g2 + %l4 ]
2007f88: bb 2f 20 02 sll %i4, 2, %i5
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
2007f8c: c6 16 20 14 lduh [ %i0 + 0x14 ], %g3
/*
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
2007f90: c0 25 c0 1d clr [ %l7 + %i5 ]
for ( index=index_base ;
index < ( information->allocation_size + index_base );
2007f94: 86 04 40 03 add %l1, %g3, %g3
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
2007f98: 80 a4 40 03 cmp %l1, %g3
2007f9c: 1a 80 00 0a bcc 2007fc4 <_Objects_Extend_information+0x168><== NEVER TAKEN
2007fa0: c0 25 80 1d clr [ %l6 + %i5 ]
2007fa4: 85 2c 60 02 sll %l1, 2, %g2
2007fa8: 82 10 00 11 mov %l1, %g1
2007fac: 84 05 00 02 add %l4, %g2, %g2
index < ( information->allocation_size + index_base );
index++ ) {
local_table[ index ] = NULL;
2007fb0: c0 20 80 00 clr [ %g2 ]
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
index++ ) {
2007fb4: 82 00 60 01 inc %g1
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
2007fb8: 80 a0 c0 01 cmp %g3, %g1
2007fbc: 18 bf ff fd bgu 2007fb0 <_Objects_Extend_information+0x154>
2007fc0: 84 00 a0 04 add %g2, 4, %g2
index < ( information->allocation_size + index_base );
index++ ) {
local_table[ index ] = NULL;
}
_ISR_Disable( level );
2007fc4: 7f ff e8 38 call 20020a4 <sparc_disable_interrupts>
2007fc8: 01 00 00 00 nop
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007fcc: c6 06 00 00 ld [ %i0 ], %g3
2007fd0: c4 16 20 04 lduh [ %i0 + 4 ], %g2
old_tables = information->object_blocks;
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
2007fd4: ea 36 20 10 sth %l5, [ %i0 + 0x10 ]
local_table[ index ] = NULL;
}
_ISR_Disable( level );
old_tables = information->object_blocks;
2007fd8: e6 06 20 34 ld [ %i0 + 0x34 ], %l3
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
2007fdc: ee 26 20 30 st %l7, [ %i0 + 0x30 ]
information->local_table = local_table;
2007fe0: e8 26 20 1c st %l4, [ %i0 + 0x1c ]
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007fe4: 87 28 e0 18 sll %g3, 0x18, %g3
2007fe8: 85 28 a0 1b sll %g2, 0x1b, %g2
_ISR_Disable( level );
old_tables = information->object_blocks;
information->object_blocks = object_blocks;
2007fec: ec 26 20 34 st %l6, [ %i0 + 0x34 ]
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007ff0: ab 2d 60 10 sll %l5, 0x10, %l5
2007ff4: 03 00 00 40 sethi %hi(0x10000), %g1
2007ff8: ab 35 60 10 srl %l5, 0x10, %l5
2007ffc: 82 10 c0 01 or %g3, %g1, %g1
2008000: 82 10 40 02 or %g1, %g2, %g1
2008004: 82 10 40 15 or %g1, %l5, %g1
2008008: c2 26 20 0c st %g1, [ %i0 + 0xc ]
information->the_class,
_Objects_Local_node,
information->maximum
);
_ISR_Enable( level );
200800c: 7f ff e8 2a call 20020b4 <sparc_enable_interrupts>
2008010: 01 00 00 00 nop
if ( old_tables )
2008014: 80 a4 e0 00 cmp %l3, 0
2008018: 22 80 00 05 be,a 200802c <_Objects_Extend_information+0x1d0>
200801c: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
_Workspace_Free( old_tables );
2008020: 40 00 08 ef call 200a3dc <_Workspace_Free>
2008024: 90 10 00 13 mov %l3, %o0
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2008028: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
/*
* Initialize objects .. add to a local chain first.
*/
_Chain_Initialize(
200802c: d4 16 20 14 lduh [ %i0 + 0x14 ], %o2
2008030: d6 06 20 18 ld [ %i0 + 0x18 ], %o3
2008034: 92 10 00 12 mov %l2, %o1
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2008038: a1 2c 20 02 sll %l0, 2, %l0
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
200803c: a6 06 20 20 add %i0, 0x20, %l3
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2008040: e4 20 40 10 st %l2, [ %g1 + %l0 ]
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
the_object->id = _Objects_Build_id(
2008044: 29 00 00 40 sethi %hi(0x10000), %l4
information->object_blocks[ block ] = new_object_block;
/*
* Initialize objects .. add to a local chain first.
*/
_Chain_Initialize(
2008048: a4 07 bf f4 add %fp, -12, %l2
200804c: 40 00 18 0a call 200e074 <_Chain_Initialize>
2008050: 90 10 00 12 mov %l2, %o0
/*
* Move from the local chain, initialise, then append to the inactive chain
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
2008054: 30 80 00 0c b,a 2008084 <_Objects_Extend_information+0x228>
the_object->id = _Objects_Build_id(
2008058: c4 16 20 04 lduh [ %i0 + 4 ], %g2
200805c: 83 28 60 18 sll %g1, 0x18, %g1
2008060: 85 28 a0 1b sll %g2, 0x1b, %g2
2008064: 82 10 40 14 or %g1, %l4, %g1
2008068: 82 10 40 02 or %g1, %g2, %g1
200806c: 82 10 40 11 or %g1, %l1, %g1
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
2008070: 92 10 00 08 mov %o0, %o1
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
the_object->id = _Objects_Build_id(
2008074: c2 22 20 08 st %g1, [ %o0 + 8 ]
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
2008078: a2 04 60 01 inc %l1
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
200807c: 7f ff fc a6 call 2007314 <_Chain_Append>
2008080: 90 10 00 13 mov %l3, %o0
/*
* Move from the local chain, initialise, then append to the inactive chain
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
2008084: 7f ff fc ba call 200736c <_Chain_Get>
2008088: 90 10 00 12 mov %l2, %o0
200808c: 80 a2 20 00 cmp %o0, 0
2008090: 32 bf ff f2 bne,a 2008058 <_Objects_Extend_information+0x1fc>
2008094: c2 06 00 00 ld [ %i0 ], %g1
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
information->inactive =
2008098: c2 16 20 2c lduh [ %i0 + 0x2c ], %g1
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
200809c: c8 16 20 14 lduh [ %i0 + 0x14 ], %g4
20080a0: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
information->inactive =
20080a4: 82 01 00 01 add %g4, %g1, %g1
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
20080a8: c8 20 80 10 st %g4, [ %g2 + %l0 ]
information->inactive =
20080ac: c2 36 20 2c sth %g1, [ %i0 + 0x2c ]
20080b0: 81 c7 e0 08 ret
20080b4: 81 e8 00 00 restore
* Allocate the name table, and the objects and if it fails either return or
* generate a fatal error depending on auto-extending being active.
*/
block_size = information->allocation_size * information->size;
if ( information->auto_extend ) {
new_object_block = _Workspace_Allocate( block_size );
20080b8: 40 00 08 c0 call 200a3b8 <_Workspace_Allocate>
20080bc: 01 00 00 00 nop
if ( !new_object_block )
20080c0: a4 92 20 00 orcc %o0, 0, %l2
20080c4: 32 bf ff 96 bne,a 2007f1c <_Objects_Extend_information+0xc0>
20080c8: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
20080cc: 81 c7 e0 08 ret
20080d0: 81 e8 00 00 restore
/*
* Copy each section of the table over. This has to be performed as
* separate parts as size of each block has changed.
*/
memcpy( object_blocks,
20080d4: d2 06 20 34 ld [ %i0 + 0x34 ], %o1
information->object_blocks,
block_count * sizeof(void*) );
20080d8: bb 2f 20 02 sll %i4, 2, %i5
/*
* Copy each section of the table over. This has to be performed as
* separate parts as size of each block has changed.
*/
memcpy( object_blocks,
20080dc: 40 00 28 84 call 20122ec <memcpy>
20080e0: 94 10 00 1d mov %i5, %o2
information->object_blocks,
block_count * sizeof(void*) );
memcpy( inactive_per_block,
20080e4: d2 06 20 30 ld [ %i0 + 0x30 ], %o1
20080e8: 94 10 00 1d mov %i5, %o2
20080ec: 40 00 28 80 call 20122ec <memcpy>
20080f0: 90 10 00 17 mov %l7, %o0
information->inactive_per_block,
block_count * sizeof(uint32_t) );
memcpy( local_table,
20080f4: d4 16 20 10 lduh [ %i0 + 0x10 ], %o2
20080f8: d2 06 20 1c ld [ %i0 + 0x1c ], %o1
20080fc: 94 04 c0 0a add %l3, %o2, %o2
2008100: 90 10 00 14 mov %l4, %o0
2008104: 40 00 28 7a call 20122ec <memcpy>
2008108: 95 2a a0 02 sll %o2, 2, %o2
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
200810c: 10 bf ff a1 b 2007f90 <_Objects_Extend_information+0x134>
2008110: c6 16 20 14 lduh [ %i0 + 0x14 ], %g3
minimum_index = _Objects_Get_index( information->minimum_id );
index_base = minimum_index;
block = 0;
/* if ( information->maximum < minimum_index ) */
if ( information->object_blocks == NULL )
2008114: ea 16 20 10 lduh [ %i0 + 0x10 ], %l5
2008118: d0 16 20 14 lduh [ %i0 + 0x14 ], %o0
200811c: ab 2d 60 10 sll %l5, 0x10, %l5
2008120: a2 10 00 13 mov %l3, %l1
2008124: a0 10 20 00 clr %l0
2008128: 10 bf ff 6c b 2007ed8 <_Objects_Extend_information+0x7c>
200812c: b8 10 20 00 clr %i4
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
if ( information->object_blocks[ block ] == NULL )
2008130: a2 10 00 13 mov %l3, %l1 <== NOT EXECUTED
2008134: 10 bf ff 69 b 2007ed8 <_Objects_Extend_information+0x7c> <== NOT EXECUTED
2008138: a0 10 20 00 clr %l0 <== NOT EXECUTED
(sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) +
((maximum + minimum_index) * sizeof(Objects_Control *));
object_blocks = (void**) _Workspace_Allocate( block_size );
if ( !object_blocks ) {
_Workspace_Free( new_object_block );
200813c: 40 00 08 a8 call 200a3dc <_Workspace_Free>
2008140: 90 10 00 12 mov %l2, %o0
return;
2008144: 81 c7 e0 08 ret
2008148: 81 e8 00 00 restore
020081f8 <_Objects_Get_information>:
Objects_Information *_Objects_Get_information(
Objects_APIs the_api,
uint32_t the_class
)
{
20081f8: 9d e3 bf a0 save %sp, -96, %sp
Objects_Information *info;
int the_class_api_maximum;
if ( !the_class )
20081fc: 80 a6 60 00 cmp %i1, 0
2008200: 12 80 00 04 bne 2008210 <_Objects_Get_information+0x18>
2008204: 01 00 00 00 nop
if ( info->maximum == 0 )
return NULL;
#endif
return info;
}
2008208: 81 c7 e0 08 ret
200820c: 91 e8 20 00 restore %g0, 0, %o0
/*
* This call implicitly validates the_api so we do not call
* _Objects_Is_api_valid above here.
*/
the_class_api_maximum = _Objects_API_maximum_class( the_api );
2008210: 40 00 19 45 call 200e724 <_Objects_API_maximum_class>
2008214: 90 10 00 18 mov %i0, %o0
if ( the_class_api_maximum == 0 )
2008218: 80 a2 20 00 cmp %o0, 0
200821c: 22 80 00 15 be,a 2008270 <_Objects_Get_information+0x78>
2008220: b0 10 20 00 clr %i0
return NULL;
if ( the_class > (uint32_t) the_class_api_maximum )
2008224: 80 a6 40 08 cmp %i1, %o0
2008228: 38 80 00 12 bgu,a 2008270 <_Objects_Get_information+0x78>
200822c: b0 10 20 00 clr %i0
return NULL;
if ( !_Objects_Information_table[ the_api ] )
2008230: b1 2e 20 02 sll %i0, 2, %i0
2008234: 03 00 80 7c sethi %hi(0x201f000), %g1
2008238: 82 10 63 00 or %g1, 0x300, %g1 ! 201f300 <_Objects_Information_table>
200823c: c2 00 40 18 ld [ %g1 + %i0 ], %g1
2008240: 80 a0 60 00 cmp %g1, 0
2008244: 02 80 00 0b be 2008270 <_Objects_Get_information+0x78> <== NEVER TAKEN
2008248: b0 10 20 00 clr %i0
return NULL;
info = _Objects_Information_table[ the_api ][ the_class ];
200824c: b3 2e 60 02 sll %i1, 2, %i1
2008250: f0 00 40 19 ld [ %g1 + %i1 ], %i0
if ( !info )
2008254: 80 a6 20 00 cmp %i0, 0
2008258: 02 80 00 06 be 2008270 <_Objects_Get_information+0x78> <== NEVER TAKEN
200825c: 01 00 00 00 nop
* In a multprocessing configuration, we may access remote objects.
* Thus we may have 0 local instances and still have a valid object
* pointer.
*/
#if !defined(RTEMS_MULTIPROCESSING)
if ( info->maximum == 0 )
2008260: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2008264: 80 a0 60 00 cmp %g1, 0
2008268: 22 80 00 02 be,a 2008270 <_Objects_Get_information+0x78>
200826c: b0 10 20 00 clr %i0
return NULL;
#endif
return info;
}
2008270: 81 c7 e0 08 ret
2008274: 81 e8 00 00 restore
02017f78 <_Objects_Get_name_as_string>:
char *_Objects_Get_name_as_string(
Objects_Id id,
size_t length,
char *name
)
{
2017f78: 9d e3 bf 90 save %sp, -112, %sp
char lname[5];
Objects_Control *the_object;
Objects_Locations location;
Objects_Id tmpId;
if ( length == 0 )
2017f7c: 80 a6 60 00 cmp %i1, 0
2017f80: 12 80 00 05 bne 2017f94 <_Objects_Get_name_as_string+0x1c>
2017f84: 80 a6 a0 00 cmp %i2, 0
}
}
*d = '\0';
_Thread_Enable_dispatch();
return name;
2017f88: b4 10 20 00 clr %i2
}
return NULL; /* unreachable path */
}
2017f8c: 81 c7 e0 08 ret
2017f90: 91 e8 00 1a restore %g0, %i2, %o0
Objects_Id tmpId;
if ( length == 0 )
return NULL;
if ( name == NULL )
2017f94: 02 bf ff fe be 2017f8c <_Objects_Get_name_as_string+0x14>
2017f98: 80 a6 20 00 cmp %i0, 0
return NULL;
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
2017f9c: 12 80 00 04 bne 2017fac <_Objects_Get_name_as_string+0x34>
2017fa0: 03 00 80 c8 sethi %hi(0x2032000), %g1
2017fa4: c2 00 61 90 ld [ %g1 + 0x190 ], %g1 ! 2032190 <_Thread_Executing>
2017fa8: f0 00 60 08 ld [ %g1 + 8 ], %i0
information = _Objects_Get_information_id( tmpId );
2017fac: 7f ff d9 11 call 200e3f0 <_Objects_Get_information_id>
2017fb0: 90 10 00 18 mov %i0, %o0
if ( !information )
2017fb4: a0 92 20 00 orcc %o0, 0, %l0
2017fb8: 22 bf ff f5 be,a 2017f8c <_Objects_Get_name_as_string+0x14>
2017fbc: b4 10 20 00 clr %i2
return NULL;
the_object = _Objects_Get( information, tmpId, &location );
2017fc0: 92 10 00 18 mov %i0, %o1
2017fc4: 7f ff d9 4f call 200e500 <_Objects_Get>
2017fc8: 94 07 bf fc add %fp, -4, %o2
switch ( location ) {
2017fcc: c2 07 bf fc ld [ %fp + -4 ], %g1
2017fd0: 80 a0 60 00 cmp %g1, 0
2017fd4: 32 bf ff ee bne,a 2017f8c <_Objects_Get_name_as_string+0x14>
2017fd8: b4 10 20 00 clr %i2
return NULL;
case OBJECTS_LOCAL:
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
2017fdc: c2 0c 20 38 ldub [ %l0 + 0x38 ], %g1
2017fe0: 80 a0 60 00 cmp %g1, 0
2017fe4: 22 80 00 25 be,a 2018078 <_Objects_Get_name_as_string+0x100>
2017fe8: c2 02 20 0c ld [ %o0 + 0xc ], %g1
s = the_object->name.name_p;
2017fec: c8 02 20 0c ld [ %o0 + 0xc ], %g4
lname[ 4 ] = '\0';
s = lname;
}
d = name;
if ( s ) {
2017ff0: 80 a1 20 00 cmp %g4, 0
2017ff4: 02 80 00 1e be 201806c <_Objects_Get_name_as_string+0xf4>
2017ff8: 86 10 00 1a mov %i2, %g3
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
2017ffc: b2 86 7f ff addcc %i1, -1, %i1
2018000: 02 80 00 1b be 201806c <_Objects_Get_name_as_string+0xf4> <== NEVER TAKEN
2018004: 86 10 00 1a mov %i2, %g3
2018008: c2 49 00 00 ldsb [ %g4 ], %g1
201800c: 80 a0 60 00 cmp %g1, 0
2018010: 02 80 00 17 be 201806c <_Objects_Get_name_as_string+0xf4>
2018014: c4 09 00 00 ldub [ %g4 ], %g2
2018018: 17 00 80 c4 sethi %hi(0x2031000), %o3
201801c: 86 10 00 1a mov %i2, %g3
2018020: 96 12 e0 50 or %o3, 0x50, %o3
2018024: 10 80 00 06 b 201803c <_Objects_Get_name_as_string+0xc4>
2018028: 82 10 20 00 clr %g1
201802c: da 49 00 01 ldsb [ %g4 + %g1 ], %o5
2018030: 80 a3 60 00 cmp %o5, 0
2018034: 02 80 00 0e be 201806c <_Objects_Get_name_as_string+0xf4>
2018038: c4 09 00 01 ldub [ %g4 + %g1 ], %g2
*d = (isprint((unsigned char)*s)) ? *s : '*';
201803c: d8 02 c0 00 ld [ %o3 ], %o4
2018040: 9a 08 a0 ff and %g2, 0xff, %o5
2018044: 9a 03 00 0d add %o4, %o5, %o5
2018048: da 4b 60 01 ldsb [ %o5 + 1 ], %o5
201804c: 80 8b 60 97 btst 0x97, %o5
2018050: 12 80 00 03 bne 201805c <_Objects_Get_name_as_string+0xe4>
2018054: 82 00 60 01 inc %g1
2018058: 84 10 20 2a mov 0x2a, %g2
201805c: c4 28 c0 00 stb %g2, [ %g3 ]
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
2018060: 80 a0 40 19 cmp %g1, %i1
2018064: 0a bf ff f2 bcs 201802c <_Objects_Get_name_as_string+0xb4>
2018068: 86 00 e0 01 inc %g3
*d = (isprint((unsigned char)*s)) ? *s : '*';
}
}
*d = '\0';
_Thread_Enable_dispatch();
201806c: 7f ff db fb call 200f058 <_Thread_Enable_dispatch>
2018070: c0 28 c0 00 clrb [ %g3 ]
return name;
2018074: 30 bf ff c6 b,a 2017f8c <_Objects_Get_name_as_string+0x14>
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
lname[ 4 ] = '\0';
2018078: 88 07 bf f0 add %fp, -16, %g4
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
201807c: 85 30 60 18 srl %g1, 0x18, %g2
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
2018080: c2 2f bf f3 stb %g1, [ %fp + -13 ]
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
2018084: c4 2f bf f0 stb %g2, [ %fp + -16 ]
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
lname[ 4 ] = '\0';
2018088: c0 2f bf f4 clrb [ %fp + -12 ]
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
201808c: 85 30 60 10 srl %g1, 0x10, %g2
lname[ 2 ] = (u32_name >> 8) & 0xff;
2018090: 83 30 60 08 srl %g1, 8, %g1
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
2018094: c4 2f bf f1 stb %g2, [ %fp + -15 ]
lname[ 2 ] = (u32_name >> 8) & 0xff;
2018098: 10 bf ff d9 b 2017ffc <_Objects_Get_name_as_string+0x84>
201809c: c2 2f bf f2 stb %g1, [ %fp + -14 ]
02019714 <_Objects_Get_no_protection>:
/*
* You can't just extract the index portion or you can get tricked
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
2019714: c4 02 20 08 ld [ %o0 + 8 ], %g2
if ( information->maximum >= index ) {
2019718: c2 12 20 10 lduh [ %o0 + 0x10 ], %g1
/*
* You can't just extract the index portion or you can get tricked
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
201971c: 84 22 40 02 sub %o1, %g2, %g2
2019720: 84 00 a0 01 inc %g2
if ( information->maximum >= index ) {
2019724: 80 a0 80 01 cmp %g2, %g1
2019728: 18 80 00 09 bgu 201974c <_Objects_Get_no_protection+0x38>
201972c: 85 28 a0 02 sll %g2, 2, %g2
if ( (the_object = information->local_table[ index ]) != NULL ) {
2019730: c2 02 20 1c ld [ %o0 + 0x1c ], %g1
2019734: d0 00 40 02 ld [ %g1 + %g2 ], %o0
2019738: 80 a2 20 00 cmp %o0, 0
201973c: 02 80 00 05 be 2019750 <_Objects_Get_no_protection+0x3c> <== NEVER TAKEN
2019740: 82 10 20 01 mov 1, %g1
*location = OBJECTS_LOCAL;
return the_object;
2019744: 81 c3 e0 08 retl
2019748: c0 22 80 00 clr [ %o2 ]
/*
* This isn't supported or required yet for Global objects so
* if it isn't local, we don't find it.
*/
*location = OBJECTS_ERROR;
201974c: 82 10 20 01 mov 1, %g1
2019750: 90 10 20 00 clr %o0
return NULL;
}
2019754: 81 c3 e0 08 retl
2019758: c2 22 80 00 st %g1, [ %o2 ]
0200e574 <_Objects_Id_to_name>:
*/
Objects_Name_or_id_lookup_errors _Objects_Id_to_name (
Objects_Id id,
Objects_Name *name
)
{
200e574: 9d e3 bf 98 save %sp, -104, %sp
/*
* Caller is trusted for name != NULL.
*/
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
200e578: 92 96 20 00 orcc %i0, 0, %o1
200e57c: 12 80 00 06 bne 200e594 <_Objects_Id_to_name+0x20>
200e580: 83 32 60 18 srl %o1, 0x18, %g1
200e584: 03 00 80 c8 sethi %hi(0x2032000), %g1
200e588: c2 00 61 90 ld [ %g1 + 0x190 ], %g1 ! 2032190 <_Thread_Executing>
200e58c: d2 00 60 08 ld [ %g1 + 8 ], %o1
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
200e590: 83 32 60 18 srl %o1, 0x18, %g1
200e594: 82 08 60 07 and %g1, 7, %g1
*/
RTEMS_INLINE_ROUTINE bool _Objects_Is_api_valid(
uint32_t the_api
)
{
if ( !the_api || the_api > OBJECTS_APIS_LAST )
200e598: 84 00 7f ff add %g1, -1, %g2
200e59c: 80 a0 a0 03 cmp %g2, 3
200e5a0: 18 80 00 11 bgu 200e5e4 <_Objects_Id_to_name+0x70>
200e5a4: 83 28 60 02 sll %g1, 2, %g1
the_api = _Objects_Get_API( tmpId );
if ( !_Objects_Is_api_valid( the_api ) )
return OBJECTS_INVALID_ID;
if ( !_Objects_Information_table[ the_api ] )
200e5a8: 05 00 80 c8 sethi %hi(0x2032000), %g2
200e5ac: 84 10 a0 30 or %g2, 0x30, %g2 ! 2032030 <_Objects_Information_table>
200e5b0: c2 00 80 01 ld [ %g2 + %g1 ], %g1
200e5b4: 80 a0 60 00 cmp %g1, 0
200e5b8: 02 80 00 0b be 200e5e4 <_Objects_Id_to_name+0x70>
200e5bc: 85 32 60 1b srl %o1, 0x1b, %g2
return OBJECTS_INVALID_ID;
the_class = _Objects_Get_class( tmpId );
information = _Objects_Information_table[ the_api ][ the_class ];
200e5c0: 85 28 a0 02 sll %g2, 2, %g2
200e5c4: d0 00 40 02 ld [ %g1 + %g2 ], %o0
if ( !information )
200e5c8: 80 a2 20 00 cmp %o0, 0
200e5cc: 02 80 00 06 be 200e5e4 <_Objects_Id_to_name+0x70> <== NEVER TAKEN
200e5d0: 01 00 00 00 nop
return OBJECTS_INVALID_ID;
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string )
200e5d4: c2 0a 20 38 ldub [ %o0 + 0x38 ], %g1
200e5d8: 80 a0 60 00 cmp %g1, 0
200e5dc: 02 80 00 04 be 200e5ec <_Objects_Id_to_name+0x78> <== ALWAYS TAKEN
200e5e0: 01 00 00 00 nop
return OBJECTS_INVALID_ID;
*name = the_object->name;
_Thread_Enable_dispatch();
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
}
200e5e4: 81 c7 e0 08 ret
200e5e8: 91 e8 20 03 restore %g0, 3, %o0
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string )
return OBJECTS_INVALID_ID;
#endif
the_object = _Objects_Get( information, tmpId, &ignored_location );
200e5ec: 7f ff ff c5 call 200e500 <_Objects_Get>
200e5f0: 94 07 bf fc add %fp, -4, %o2
if ( !the_object )
200e5f4: 80 a2 20 00 cmp %o0, 0
200e5f8: 02 bf ff fb be 200e5e4 <_Objects_Id_to_name+0x70>
200e5fc: 01 00 00 00 nop
return OBJECTS_INVALID_ID;
*name = the_object->name;
200e600: c2 02 20 0c ld [ %o0 + 0xc ], %g1
_Thread_Enable_dispatch();
200e604: b0 10 20 00 clr %i0
200e608: 40 00 02 94 call 200f058 <_Thread_Enable_dispatch>
200e60c: c2 26 40 00 st %g1, [ %i1 ]
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
200e610: 81 c7 e0 08 ret
200e614: 81 e8 00 00 restore
02008ba0 <_Objects_Set_name>:
bool _Objects_Set_name(
Objects_Information *information,
Objects_Control *the_object,
const char *name
)
{
2008ba0: 9d e3 bf a0 save %sp, -96, %sp
size_t length;
const char *s;
s = name;
length = strnlen( name, information->name_length );
2008ba4: d2 16 20 3a lduh [ %i0 + 0x3a ], %o1
2008ba8: 40 00 2d 1d call 201401c <strnlen>
2008bac: 90 10 00 1a mov %i2, %o0
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
2008bb0: c2 0e 20 38 ldub [ %i0 + 0x38 ], %g1
2008bb4: 80 a0 60 00 cmp %g1, 0
2008bb8: 12 80 00 1d bne 2008c2c <_Objects_Set_name+0x8c>
2008bbc: a0 10 00 08 mov %o0, %l0
d[length] = '\0';
the_object->name.name_p = d;
} else
#endif
{
the_object->name.name_u32 = _Objects_Build_name(
2008bc0: c4 4e 80 00 ldsb [ %i2 ], %g2
2008bc4: 80 a2 20 01 cmp %o0, 1
2008bc8: 08 80 00 13 bleu 2008c14 <_Objects_Set_name+0x74>
2008bcc: 85 28 a0 18 sll %g2, 0x18, %g2
2008bd0: c2 4e a0 01 ldsb [ %i2 + 1 ], %g1
2008bd4: 80 a2 20 02 cmp %o0, 2
2008bd8: 83 28 60 10 sll %g1, 0x10, %g1
2008bdc: 02 80 00 10 be 2008c1c <_Objects_Set_name+0x7c>
2008be0: 84 10 40 02 or %g1, %g2, %g2
2008be4: c2 4e a0 02 ldsb [ %i2 + 2 ], %g1
2008be8: 80 a2 20 03 cmp %o0, 3
2008bec: 83 28 60 08 sll %g1, 8, %g1
2008bf0: 84 10 80 01 or %g2, %g1, %g2
2008bf4: 02 80 00 03 be 2008c00 <_Objects_Set_name+0x60>
2008bf8: 82 10 20 20 mov 0x20, %g1
2008bfc: c2 4e a0 03 ldsb [ %i2 + 3 ], %g1
2008c00: 82 10 80 01 or %g2, %g1, %g1
2008c04: b0 10 20 01 mov 1, %i0
2008c08: c2 26 60 0c st %g1, [ %i1 + 0xc ]
);
}
return true;
}
2008c0c: 81 c7 e0 08 ret
2008c10: 81 e8 00 00 restore
d[length] = '\0';
the_object->name.name_p = d;
} else
#endif
{
the_object->name.name_u32 = _Objects_Build_name(
2008c14: 03 00 08 00 sethi %hi(0x200000), %g1
2008c18: 84 10 80 01 or %g2, %g1, %g2
2008c1c: 03 00 00 08 sethi %hi(0x2000), %g1
2008c20: 84 10 80 01 or %g2, %g1, %g2
2008c24: 10 bf ff f7 b 2008c00 <_Objects_Set_name+0x60>
2008c28: 82 10 20 20 mov 0x20, %g1
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string ) {
char *d;
d = _Workspace_Allocate( length + 1 );
2008c2c: 90 02 20 01 inc %o0
2008c30: 40 00 07 a8 call 200aad0 <_Workspace_Allocate>
2008c34: b0 10 20 00 clr %i0
if ( !d )
2008c38: a2 92 20 00 orcc %o0, 0, %l1
2008c3c: 02 bf ff f4 be 2008c0c <_Objects_Set_name+0x6c> <== NEVER TAKEN
2008c40: 01 00 00 00 nop
return false;
if ( the_object->name.name_p ) {
2008c44: d0 06 60 0c ld [ %i1 + 0xc ], %o0
2008c48: 80 a2 20 00 cmp %o0, 0
2008c4c: 02 80 00 06 be 2008c64 <_Objects_Set_name+0xc4>
2008c50: 92 10 00 1a mov %i2, %o1
_Workspace_Free( (void *)the_object->name.name_p );
2008c54: 40 00 07 a8 call 200aaf4 <_Workspace_Free>
2008c58: 01 00 00 00 nop
the_object->name.name_p = NULL;
2008c5c: c0 26 60 0c clr [ %i1 + 0xc ]
}
strncpy( d, name, length );
2008c60: 92 10 00 1a mov %i2, %o1
2008c64: 90 10 00 11 mov %l1, %o0
2008c68: 40 00 2c b2 call 2013f30 <strncpy>
2008c6c: 94 10 00 10 mov %l0, %o2
d[length] = '\0';
2008c70: c0 2c 40 10 clrb [ %l1 + %l0 ]
the_object->name.name_p = d;
2008c74: e2 26 60 0c st %l1, [ %i1 + 0xc ]
2008c78: 81 c7 e0 08 ret
2008c7c: 91 e8 20 01 restore %g0, 1, %o0
02008568 <_Objects_Shrink_information>:
*/
void _Objects_Shrink_information(
Objects_Information *information
)
{
2008568: 9d e3 bf a0 save %sp, -96, %sp
/*
* Search the list to find block or chunk with all objects inactive.
*/
index_base = _Objects_Get_index( information->minimum_id );
200856c: e0 16 20 0a lduh [ %i0 + 0xa ], %l0
block_count = (information->maximum - index_base) /
2008570: e2 16 20 14 lduh [ %i0 + 0x14 ], %l1
2008574: d0 16 20 10 lduh [ %i0 + 0x10 ], %o0
2008578: 92 10 00 11 mov %l1, %o1
200857c: 40 00 4a 73 call 201af48 <.udiv>
2008580: 90 22 00 10 sub %o0, %l0, %o0
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
2008584: 80 a2 20 00 cmp %o0, 0
2008588: 02 80 00 12 be 20085d0 <_Objects_Shrink_information+0x68> <== NEVER TAKEN
200858c: a4 10 20 04 mov 4, %l2
if ( information->inactive_per_block[ block ] ==
2008590: c6 06 20 30 ld [ %i0 + 0x30 ], %g3
2008594: c4 00 c0 00 ld [ %g3 ], %g2
2008598: 80 a4 40 02 cmp %l1, %g2
200859c: 12 80 00 09 bne 20085c0 <_Objects_Shrink_information+0x58><== ALWAYS TAKEN
20085a0: 82 10 20 00 clr %g1
20085a4: 10 80 00 0d b 20085d8 <_Objects_Shrink_information+0x70> <== NOT EXECUTED
20085a8: a4 10 20 00 clr %l2 <== NOT EXECUTED
information->inactive -= information->allocation_size;
return;
}
index_base += information->allocation_size;
20085ac: a0 04 00 11 add %l0, %l1, %l0
index_base = _Objects_Get_index( information->minimum_id );
block_count = (information->maximum - index_base) /
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
if ( information->inactive_per_block[ block ] ==
20085b0: 80 a4 40 02 cmp %l1, %g2
20085b4: 02 80 00 09 be 20085d8 <_Objects_Shrink_information+0x70>
20085b8: 84 04 a0 04 add %l2, 4, %g2
20085bc: a4 10 00 02 mov %g2, %l2
index_base = _Objects_Get_index( information->minimum_id );
block_count = (information->maximum - index_base) /
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
20085c0: 82 00 60 01 inc %g1
20085c4: 80 a2 00 01 cmp %o0, %g1
20085c8: 38 bf ff f9 bgu,a 20085ac <_Objects_Shrink_information+0x44>
20085cc: c4 00 c0 12 ld [ %g3 + %l2 ], %g2
20085d0: 81 c7 e0 08 ret
20085d4: 81 e8 00 00 restore
information->allocation_size ) {
/*
* Assume the Inactive chain is never empty at this point
*/
the_object = (Objects_Control *) information->Inactive.first;
20085d8: 10 80 00 06 b 20085f0 <_Objects_Shrink_information+0x88>
20085dc: d0 06 20 20 ld [ %i0 + 0x20 ], %o0
if ((index >= index_base) &&
(index < (index_base + information->allocation_size))) {
_Chain_Extract( &extract_me->Node );
}
}
while ( the_object );
20085e0: 80 a4 60 00 cmp %l1, 0
20085e4: 22 80 00 12 be,a 200862c <_Objects_Shrink_information+0xc4>
20085e8: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
20085ec: 90 10 00 11 mov %l1, %o0
* Assume the Inactive chain is never empty at this point
*/
the_object = (Objects_Control *) information->Inactive.first;
do {
index = _Objects_Get_index( the_object->id );
20085f0: c2 12 20 0a lduh [ %o0 + 0xa ], %g1
/*
* Get the next node before the node is extracted
*/
extract_me = the_object;
the_object = (Objects_Control *) the_object->Node.next;
if ((index >= index_base) &&
20085f4: 80 a0 40 10 cmp %g1, %l0
20085f8: 0a bf ff fa bcs 20085e0 <_Objects_Shrink_information+0x78>
20085fc: e2 02 00 00 ld [ %o0 ], %l1
(index < (index_base + information->allocation_size))) {
2008600: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2
2008604: 84 04 00 02 add %l0, %g2, %g2
2008608: 80 a0 40 02 cmp %g1, %g2
200860c: 1a bf ff f6 bcc 20085e4 <_Objects_Shrink_information+0x7c>
2008610: 80 a4 60 00 cmp %l1, 0
_Chain_Extract( &extract_me->Node );
2008614: 7f ff fb 4c call 2007344 <_Chain_Extract>
2008618: 01 00 00 00 nop
}
}
while ( the_object );
200861c: 80 a4 60 00 cmp %l1, 0
2008620: 12 bf ff f4 bne 20085f0 <_Objects_Shrink_information+0x88><== ALWAYS TAKEN
2008624: 90 10 00 11 mov %l1, %o0
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
2008628: c2 06 20 34 ld [ %i0 + 0x34 ], %g1 <== NOT EXECUTED
200862c: 40 00 07 6c call 200a3dc <_Workspace_Free>
2008630: d0 00 40 12 ld [ %g1 + %l2 ], %o0
information->object_blocks[ block ] = NULL;
information->inactive_per_block[ block ] = 0;
information->inactive -= information->allocation_size;
2008634: c6 16 20 2c lduh [ %i0 + 0x2c ], %g3
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
2008638: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
information->inactive_per_block[ block ] = 0;
200863c: c8 06 20 30 ld [ %i0 + 0x30 ], %g4
information->inactive -= information->allocation_size;
2008640: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
information->inactive_per_block[ block ] = 0;
2008644: c0 21 00 12 clr [ %g4 + %l2 ]
information->inactive -= information->allocation_size;
2008648: 84 20 c0 02 sub %g3, %g2, %g2
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
200864c: c0 20 40 12 clr [ %g1 + %l2 ]
information->inactive_per_block[ block ] = 0;
information->inactive -= information->allocation_size;
2008650: c4 36 20 2c sth %g2, [ %i0 + 0x2c ]
return;
2008654: 81 c7 e0 08 ret
2008658: 81 e8 00 00 restore
0200788c <_POSIX_Condition_variables_Wait_support>:
pthread_cond_t *cond,
pthread_mutex_t *mutex,
Watchdog_Interval timeout,
bool already_timedout
)
{
200788c: 9d e3 bf 98 save %sp, -104, %sp
register POSIX_Condition_variables_Control *the_cond;
Objects_Locations location;
int status;
int mutex_status;
if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
2007890: a0 07 bf fc add %fp, -4, %l0
2007894: 90 10 00 19 mov %i1, %o0
2007898: 40 00 00 7f call 2007a94 <_POSIX_Mutex_Get>
200789c: 92 10 00 10 mov %l0, %o1
20078a0: 80 a2 20 00 cmp %o0, 0
20078a4: 22 80 00 18 be,a 2007904 <_POSIX_Condition_variables_Wait_support+0x78>
20078a8: b0 10 20 16 mov 0x16, %i0
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
20078ac: 03 00 80 88 sethi %hi(0x2022000), %g1
20078b0: c4 00 62 40 ld [ %g1 + 0x240 ], %g2 ! 2022240 <_Thread_Dispatch_disable_level>
return EINVAL;
}
_Thread_Unnest_dispatch();
the_cond = _POSIX_Condition_variables_Get( cond, &location );
20078b4: 92 10 00 10 mov %l0, %o1
20078b8: 84 00 bf ff add %g2, -1, %g2
20078bc: 90 10 00 18 mov %i0, %o0
20078c0: c4 20 62 40 st %g2, [ %g1 + 0x240 ]
20078c4: 7f ff ff 69 call 2007668 <_POSIX_Condition_variables_Get>
20078c8: 01 00 00 00 nop
switch ( location ) {
20078cc: c2 07 bf fc ld [ %fp + -4 ], %g1
20078d0: 80 a0 60 00 cmp %g1, 0
20078d4: 12 80 00 1a bne 200793c <_POSIX_Condition_variables_Wait_support+0xb0>
20078d8: a0 10 00 08 mov %o0, %l0
case OBJECTS_LOCAL:
if ( the_cond->Mutex && ( the_cond->Mutex != *mutex ) ) {
20078dc: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
20078e0: 80 a0 60 00 cmp %g1, 0
20078e4: 02 80 00 0a be 200790c <_POSIX_Condition_variables_Wait_support+0x80>
20078e8: 01 00 00 00 nop
20078ec: c4 06 40 00 ld [ %i1 ], %g2
20078f0: 80 a0 40 02 cmp %g1, %g2
20078f4: 02 80 00 06 be 200790c <_POSIX_Condition_variables_Wait_support+0x80>
20078f8: 01 00 00 00 nop
_Thread_Enable_dispatch();
20078fc: 40 00 0d c5 call 200b010 <_Thread_Enable_dispatch>
2007900: b0 10 20 16 mov 0x16, %i0 ! 16 <PROM_START+0x16>
return EINVAL;
2007904: 81 c7 e0 08 ret
2007908: 81 e8 00 00 restore
}
(void) pthread_mutex_unlock( mutex );
200790c: 40 00 00 f5 call 2007ce0 <pthread_mutex_unlock>
2007910: 90 10 00 19 mov %i1, %o0
_Thread_Enable_dispatch();
return EINVAL;
}
*/
if ( !already_timedout ) {
2007914: 80 8e e0 ff btst 0xff, %i3
2007918: 22 80 00 0b be,a 2007944 <_POSIX_Condition_variables_Wait_support+0xb8>
200791c: c4 06 40 00 ld [ %i1 ], %g2
status = _Thread_Executing->Wait.return_code;
if ( status && status != ETIMEDOUT )
return status;
} else {
_Thread_Enable_dispatch();
2007920: 40 00 0d bc call 200b010 <_Thread_Enable_dispatch>
2007924: b0 10 20 74 mov 0x74, %i0
/*
* When we get here the dispatch disable level is 0.
*/
mutex_status = pthread_mutex_lock( mutex );
2007928: 40 00 00 cd call 2007c5c <pthread_mutex_lock>
200792c: 90 10 00 19 mov %i1, %o0
if ( mutex_status )
2007930: 80 a2 20 00 cmp %o0, 0
2007934: 02 80 00 1c be 20079a4 <_POSIX_Condition_variables_Wait_support+0x118>
2007938: 01 00 00 00 nop
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
200793c: 81 c7 e0 08 ret
2007940: 91 e8 20 16 restore %g0, 0x16, %o0
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
2007944: 23 00 80 88 sethi %hi(0x2022000), %l1
2007948: c2 04 63 00 ld [ %l1 + 0x300 ], %g1 ! 2022300 <_Thread_Executing>
return EINVAL;
}
*/
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
200794c: c4 24 20 14 st %g2, [ %l0 + 0x14 ]
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
2007950: c0 20 60 34 clr [ %g1 + 0x34 ]
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
_Thread_Executing->Wait.id = *cond;
2007954: c6 06 00 00 ld [ %i0 ], %g3
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
2007958: 84 04 20 18 add %l0, 0x18, %g2
_Thread_Executing->Wait.id = *cond;
200795c: c6 20 60 20 st %g3, [ %g1 + 0x20 ]
if ( !already_timedout ) {
the_cond->Mutex = *mutex;
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue );
_Thread_Executing->Wait.return_code = 0;
_Thread_Executing->Wait.queue = &the_cond->Wait_queue;
2007960: c4 20 60 44 st %g2, [ %g1 + 0x44 ]
_Thread_Executing->Wait.id = *cond;
_Thread_queue_Enqueue( &the_cond->Wait_queue, timeout );
2007964: 92 10 00 1a mov %i2, %o1
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2007968: 82 10 20 01 mov 1, %g1
200796c: 90 10 00 02 mov %g2, %o0
2007970: 15 00 80 2e sethi %hi(0x200b800), %o2
2007974: 94 12 a2 28 or %o2, 0x228, %o2 ! 200ba28 <_Thread_queue_Timeout>
2007978: 40 00 0f 19 call 200b5dc <_Thread_queue_Enqueue_with_handler>
200797c: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
_Thread_Enable_dispatch();
2007980: 40 00 0d a4 call 200b010 <_Thread_Enable_dispatch>
2007984: 01 00 00 00 nop
/*
* Switch ourself out because we blocked as a result of the
* _Thread_queue_Enqueue.
*/
status = _Thread_Executing->Wait.return_code;
2007988: c2 04 63 00 ld [ %l1 + 0x300 ], %g1
200798c: f0 00 60 34 ld [ %g1 + 0x34 ], %i0
if ( status && status != ETIMEDOUT )
2007990: 80 a6 20 74 cmp %i0, 0x74
2007994: 02 bf ff e5 be 2007928 <_POSIX_Condition_variables_Wait_support+0x9c>
2007998: 80 a6 20 00 cmp %i0, 0
200799c: 02 bf ff e3 be 2007928 <_POSIX_Condition_variables_Wait_support+0x9c><== ALWAYS TAKEN
20079a0: 01 00 00 00 nop
20079a4: 81 c7 e0 08 ret
20079a8: 81 e8 00 00 restore
02010944 <_POSIX_Keys_Run_destructors>:
*/
void _POSIX_Keys_Run_destructors(
Thread_Control *thread
)
{
2010944: 9d e3 bf a0 save %sp, -96, %sp
Objects_Maximum thread_index = _Objects_Get_index( thread->Object.id );
2010948: c2 06 20 08 ld [ %i0 + 8 ], %g1
201094c: 21 00 80 7e sethi %hi(0x201f800), %l0
for ( index = 1 ; index <= max ; ++index ) {
POSIX_Keys_Control *key = (POSIX_Keys_Control *)
_POSIX_Keys_Information.local_table [ index ];
if ( key != NULL && key->destructor != NULL ) {
void *value = key->Values [ thread_api ][ thread_index ];
2010950: a7 28 60 10 sll %g1, 0x10, %l3
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
2010954: a9 30 60 18 srl %g1, 0x18, %l4
2010958: a0 14 20 08 or %l0, 8, %l0
201095c: a8 0d 20 07 and %l4, 7, %l4
2010960: a7 34 e0 0e srl %l3, 0xe, %l3
2010964: a8 05 20 04 add %l4, 4, %l4
2010968: a9 2d 20 02 sll %l4, 2, %l4
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
done = true;
for ( index = 1 ; index <= max ; ++index ) {
201096c: e4 14 20 10 lduh [ %l0 + 0x10 ], %l2
2010970: 80 a4 a0 00 cmp %l2, 0
2010974: 02 80 00 1e be 20109ec <_POSIX_Keys_Run_destructors+0xa8>
2010978: a2 10 20 01 mov 1, %l1
201097c: 84 10 20 01 mov 1, %g2
POSIX_Keys_Control *key = (POSIX_Keys_Control *)
_POSIX_Keys_Information.local_table [ index ];
2010980: c6 04 20 1c ld [ %l0 + 0x1c ], %g3
2010984: 83 2c 60 10 sll %l1, 0x10, %g1
2010988: 83 30 60 0e srl %g1, 0xe, %g1
201098c: c2 00 c0 01 ld [ %g3 + %g1 ], %g1
if ( key != NULL && key->destructor != NULL ) {
2010990: 80 a0 60 00 cmp %g1, 0
2010994: 02 80 00 0e be 20109cc <_POSIX_Keys_Run_destructors+0x88>
2010998: 86 00 40 14 add %g1, %l4, %g3
201099c: c2 00 60 10 ld [ %g1 + 0x10 ], %g1
20109a0: 80 a0 60 00 cmp %g1, 0
20109a4: 22 80 00 0b be,a 20109d0 <_POSIX_Keys_Run_destructors+0x8c>
20109a8: a2 04 60 01 inc %l1
void *value = key->Values [ thread_api ][ thread_index ];
20109ac: c6 00 e0 04 ld [ %g3 + 4 ], %g3
20109b0: d0 00 c0 13 ld [ %g3 + %l3 ], %o0
if ( value != NULL ) {
20109b4: 80 a2 20 00 cmp %o0, 0
20109b8: 22 80 00 06 be,a 20109d0 <_POSIX_Keys_Run_destructors+0x8c><== ALWAYS TAKEN
20109bc: a2 04 60 01 inc %l1
key->Values [ thread_api ][ thread_index ] = NULL;
(*key->destructor)( value );
20109c0: 9f c0 40 00 call %g1 <== NOT EXECUTED
20109c4: c0 20 c0 13 clr [ %g3 + %l3 ] <== NOT EXECUTED
20109c8: 84 10 20 00 clr %g2 <== NOT EXECUTED
Objects_Maximum index = 0;
Objects_Maximum max = _POSIX_Keys_Information.maximum;
done = true;
for ( index = 1 ; index <= max ; ++index ) {
20109cc: a2 04 60 01 inc %l1
20109d0: 83 2c 60 10 sll %l1, 0x10, %g1
20109d4: 83 30 60 10 srl %g1, 0x10, %g1
20109d8: 80 a4 80 01 cmp %l2, %g1
20109dc: 1a bf ff e9 bcc 2010980 <_POSIX_Keys_Run_destructors+0x3c>
20109e0: 80 88 a0 ff btst 0xff, %g2
* number of iterations. An infinite loop may happen if destructors set
* thread specific data. This can be considered dubious.
*
* Reference: 17.1.1.2 P1003.1c/Draft 10, p. 163, line 99.
*/
while ( !done ) {
20109e4: 22 bf ff e3 be,a 2010970 <_POSIX_Keys_Run_destructors+0x2c><== NEVER TAKEN
20109e8: e4 14 20 10 lduh [ %l0 + 0x10 ], %l2 <== NOT EXECUTED
20109ec: 81 c7 e0 08 ret
20109f0: 81 e8 00 00 restore
0200b9e8 <_POSIX_Message_queue_Receive_support>:
size_t msg_len,
unsigned int *msg_prio,
bool wait,
Watchdog_Interval timeout
)
{
200b9e8: 9d e3 bf 98 save %sp, -104, %sp
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *_POSIX_Message_queue_Get_fd (
mqd_t id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control_fd *) _Objects_Get(
200b9ec: 11 00 80 a6 sethi %hi(0x2029800), %o0
200b9f0: 92 10 00 18 mov %i0, %o1
200b9f4: 90 12 23 7c or %o0, 0x37c, %o0
200b9f8: 40 00 0d 4a call 200ef20 <_Objects_Get>
200b9fc: 94 07 bf fc add %fp, -4, %o2
Objects_Locations location;
size_t length_out;
bool do_wait;
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
200ba00: c2 07 bf fc ld [ %fp + -4 ], %g1
200ba04: 80 a0 60 00 cmp %g1, 0
200ba08: 22 80 00 08 be,a 200ba28 <_POSIX_Message_queue_Receive_support+0x40>
200ba0c: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
200ba10: 40 00 34 23 call 2018a9c <__errno>
200ba14: b0 10 3f ff mov -1, %i0
200ba18: 82 10 20 09 mov 9, %g1
200ba1c: c2 22 00 00 st %g1, [ %o0 ]
}
200ba20: 81 c7 e0 08 ret
200ba24: 81 e8 00 00 restore
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_WRONLY ) {
200ba28: 84 08 60 03 and %g1, 3, %g2
200ba2c: 80 a0 a0 01 cmp %g2, 1
200ba30: 02 80 00 46 be 200bb48 <_POSIX_Message_queue_Receive_support+0x160>
200ba34: 01 00 00 00 nop
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EBADF );
}
the_mq = the_mq_fd->Queue;
200ba38: d0 02 20 10 ld [ %o0 + 0x10 ], %o0
if ( msg_len < the_mq->Message_queue.maximum_message_size ) {
200ba3c: c4 02 20 68 ld [ %o0 + 0x68 ], %g2
200ba40: 80 a0 80 1a cmp %g2, %i2
200ba44: 18 80 00 30 bgu 200bb04 <_POSIX_Message_queue_Receive_support+0x11c>
200ba48: 80 8f 20 ff btst 0xff, %i4
length_out = -1;
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
200ba4c: 12 80 00 1c bne 200babc <_POSIX_Message_queue_Receive_support+0xd4><== ALWAYS TAKEN
200ba50: 98 10 20 00 clr %o4
/*
* Now if something goes wrong, we return a "length" of -1
* to indicate an error.
*/
length_out = -1;
200ba54: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
200ba58: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
200ba5c: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
200ba60: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
200ba64: 9a 10 00 1d mov %i5, %o5 <== NOT EXECUTED
200ba68: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
200ba6c: 40 00 08 d4 call 200ddbc <_CORE_message_queue_Seize> <== NOT EXECUTED
200ba70: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
&length_out,
do_wait,
timeout
);
_Thread_Enable_dispatch();
200ba74: 40 00 0f bc call 200f964 <_Thread_Enable_dispatch> <== NOT EXECUTED
200ba78: 01 00 00 00 nop <== NOT EXECUTED
if (msg_prio) {
200ba7c: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
200ba80: 02 80 00 1f be 200bafc <_POSIX_Message_queue_Receive_support+0x114><== NOT EXECUTED
200ba84: 3b 00 80 a5 sethi %hi(0x2029400), %i5 <== NOT EXECUTED
*msg_prio = _POSIX_Message_queue_Priority_from_core(
_Thread_Executing->Wait.count
200ba88: c2 07 63 20 ld [ %i5 + 0x320 ], %g1 ! 2029720 <_Thread_Executing>
timeout
);
_Thread_Enable_dispatch();
if (msg_prio) {
*msg_prio = _POSIX_Message_queue_Priority_from_core(
200ba8c: c6 00 60 24 ld [ %g1 + 0x24 ], %g3
200ba90: 85 38 e0 1f sra %g3, 0x1f, %g2
200ba94: 86 18 80 03 xor %g2, %g3, %g3
200ba98: 84 20 c0 02 sub %g3, %g2, %g2
200ba9c: c4 26 c0 00 st %g2, [ %i3 ]
_Thread_Executing->Wait.count
);
}
if ( !_Thread_Executing->Wait.return_code )
200baa0: c2 00 60 34 ld [ %g1 + 0x34 ], %g1
200baa4: 80 a0 60 00 cmp %g1, 0
200baa8: 12 80 00 1f bne 200bb24 <_POSIX_Message_queue_Receive_support+0x13c>
200baac: 01 00 00 00 nop
return length_out;
200bab0: f0 07 bf f8 ld [ %fp + -8 ], %i0
200bab4: 81 c7 e0 08 ret
200bab8: 81 e8 00 00 restore
length_out = -1;
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
200babc: 99 30 60 0e srl %g1, 0xe, %o4
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
200bac0: 90 02 20 1c add %o0, 0x1c, %o0
/*
* Now if something goes wrong, we return a "length" of -1
* to indicate an error.
*/
length_out = -1;
200bac4: 82 10 3f ff mov -1, %g1
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
200bac8: 92 10 00 18 mov %i0, %o1
200bacc: 94 10 00 19 mov %i1, %o2
200bad0: 9a 10 00 1d mov %i5, %o5
200bad4: 96 07 bf f8 add %fp, -8, %o3
length_out = -1;
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
200bad8: 98 1b 20 01 xor %o4, 1, %o4
200badc: 98 0b 20 01 and %o4, 1, %o4
do_wait = wait;
/*
* Now perform the actual message receive
*/
_CORE_message_queue_Seize(
200bae0: 40 00 08 b7 call 200ddbc <_CORE_message_queue_Seize>
200bae4: c2 27 bf f8 st %g1, [ %fp + -8 ]
&length_out,
do_wait,
timeout
);
_Thread_Enable_dispatch();
200bae8: 40 00 0f 9f call 200f964 <_Thread_Enable_dispatch>
200baec: 01 00 00 00 nop
if (msg_prio) {
200baf0: 80 a6 e0 00 cmp %i3, 0
200baf4: 12 bf ff e5 bne 200ba88 <_POSIX_Message_queue_Receive_support+0xa0><== ALWAYS TAKEN
200baf8: 3b 00 80 a5 sethi %hi(0x2029400), %i5
200bafc: 10 bf ff e9 b 200baa0 <_POSIX_Message_queue_Receive_support+0xb8><== NOT EXECUTED
200bb00: c2 07 63 20 ld [ %i5 + 0x320 ], %g1 ! 2029720 <_Thread_Executing><== NOT EXECUTED
}
the_mq = the_mq_fd->Queue;
if ( msg_len < the_mq->Message_queue.maximum_message_size ) {
_Thread_Enable_dispatch();
200bb04: 40 00 0f 98 call 200f964 <_Thread_Enable_dispatch>
200bb08: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( EMSGSIZE );
200bb0c: 40 00 33 e4 call 2018a9c <__errno>
200bb10: 01 00 00 00 nop
200bb14: 82 10 20 7a mov 0x7a, %g1 ! 7a <PROM_START+0x7a>
200bb18: c2 22 00 00 st %g1, [ %o0 ]
200bb1c: 81 c7 e0 08 ret
200bb20: 81 e8 00 00 restore
}
if ( !_Thread_Executing->Wait.return_code )
return length_out;
rtems_set_errno_and_return_minus_one(
200bb24: 40 00 33 de call 2018a9c <__errno>
200bb28: b0 10 3f ff mov -1, %i0
200bb2c: c2 07 63 20 ld [ %i5 + 0x320 ], %g1
200bb30: b6 10 00 08 mov %o0, %i3
200bb34: 40 00 00 b0 call 200bdf4 <_POSIX_Message_queue_Translate_core_message_queue_return_code>
200bb38: d0 00 60 34 ld [ %g1 + 0x34 ], %o0
200bb3c: d0 26 c0 00 st %o0, [ %i3 ]
200bb40: 81 c7 e0 08 ret
200bb44: 81 e8 00 00 restore
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_WRONLY ) {
_Thread_Enable_dispatch();
200bb48: 40 00 0f 87 call 200f964 <_Thread_Enable_dispatch>
200bb4c: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( EBADF );
200bb50: 40 00 33 d3 call 2018a9c <__errno>
200bb54: 01 00 00 00 nop
200bb58: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
200bb5c: c2 22 00 00 st %g1, [ %o0 ]
200bb60: 81 c7 e0 08 ret
200bb64: 81 e8 00 00 restore
0200bb80 <_POSIX_Message_queue_Send_support>:
size_t msg_len,
uint32_t msg_prio,
bool wait,
Watchdog_Interval timeout
)
{
200bb80: 9d e3 bf 90 save %sp, -112, %sp
/*
* Validate the priority.
* XXX - Do not validate msg_prio is not less than 0.
*/
if ( msg_prio > MQ_PRIO_MAX )
200bb84: 80 a6 e0 20 cmp %i3, 0x20
200bb88: 18 80 00 47 bgu 200bca4 <_POSIX_Message_queue_Send_support+0x124>
200bb8c: 11 00 80 a6 sethi %hi(0x2029800), %o0
200bb90: 92 10 00 18 mov %i0, %o1
200bb94: 90 12 23 7c or %o0, 0x37c, %o0
200bb98: 40 00 0c e2 call 200ef20 <_Objects_Get>
200bb9c: 94 07 bf fc add %fp, -4, %o2
rtems_set_errno_and_return_minus_one( EINVAL );
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
200bba0: c2 07 bf fc ld [ %fp + -4 ], %g1
200bba4: 80 a0 60 00 cmp %g1, 0
200bba8: 12 80 00 31 bne 200bc6c <_POSIX_Message_queue_Send_support+0xec>
200bbac: 01 00 00 00 nop
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_RDONLY ) {
200bbb0: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
200bbb4: 80 88 60 03 btst 3, %g1
200bbb8: 02 80 00 41 be 200bcbc <_POSIX_Message_queue_Send_support+0x13c>
200bbbc: 80 8f 20 ff btst 0xff, %i4
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EBADF );
}
the_mq = the_mq_fd->Queue;
200bbc0: d0 02 20 10 ld [ %o0 + 0x10 ], %o0
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
200bbc4: 12 80 00 15 bne 200bc18 <_POSIX_Message_queue_Send_support+0x98>
200bbc8: 84 10 20 00 clr %g2
do_wait = wait;
/*
* Now perform the actual message receive
*/
msg_status = _CORE_message_queue_Submit(
200bbcc: c4 23 a0 5c st %g2, [ %sp + 0x5c ]
200bbd0: fa 23 a0 60 st %i5, [ %sp + 0x60 ]
200bbd4: 92 10 00 19 mov %i1, %o1
200bbd8: 94 10 00 1a mov %i2, %o2
200bbdc: 96 10 00 18 mov %i0, %o3
200bbe0: 9a 20 00 1b neg %i3, %o5
200bbe4: 98 10 20 00 clr %o4
200bbe8: 40 00 08 b4 call 200deb8 <_CORE_message_queue_Submit>
200bbec: 90 02 20 1c add %o0, 0x1c, %o0
_POSIX_Message_queue_Priority_to_core( msg_prio ),
do_wait,
timeout /* no timeout */
);
_Thread_Enable_dispatch();
200bbf0: 40 00 0f 5d call 200f964 <_Thread_Enable_dispatch>
200bbf4: ba 10 00 08 mov %o0, %i5
* after it wakes up. The returned status is correct for
* non-blocking operations but if we blocked, then we need
* to look at the status in our TCB.
*/
if ( msg_status == CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT )
200bbf8: 80 a7 60 07 cmp %i5, 7
200bbfc: 02 80 00 19 be 200bc60 <_POSIX_Message_queue_Send_support+0xe0><== NEVER TAKEN
200bc00: 03 00 80 a5 sethi %hi(0x2029400), %g1
msg_status = _Thread_Executing->Wait.return_code;
if ( !msg_status )
200bc04: 80 a7 60 00 cmp %i5, 0
200bc08: 12 80 00 1f bne 200bc84 <_POSIX_Message_queue_Send_support+0x104>
200bc0c: b0 10 20 00 clr %i0
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
}
200bc10: 81 c7 e0 08 ret
200bc14: 81 e8 00 00 restore
the_mq = the_mq_fd->Queue;
/*
* A timed receive with a bad time will do a poll regardless.
*/
if ( wait )
200bc18: 85 30 60 0e srl %g1, 0xe, %g2
200bc1c: 84 18 a0 01 xor %g2, 1, %g2
200bc20: 84 08 a0 01 and %g2, 1, %g2
do_wait = wait;
/*
* Now perform the actual message receive
*/
msg_status = _CORE_message_queue_Submit(
200bc24: fa 23 a0 60 st %i5, [ %sp + 0x60 ]
200bc28: c4 23 a0 5c st %g2, [ %sp + 0x5c ]
200bc2c: 92 10 00 19 mov %i1, %o1
200bc30: 94 10 00 1a mov %i2, %o2
200bc34: 96 10 00 18 mov %i0, %o3
200bc38: 9a 20 00 1b neg %i3, %o5
200bc3c: 98 10 20 00 clr %o4
200bc40: 40 00 08 9e call 200deb8 <_CORE_message_queue_Submit>
200bc44: 90 02 20 1c add %o0, 0x1c, %o0
_POSIX_Message_queue_Priority_to_core( msg_prio ),
do_wait,
timeout /* no timeout */
);
_Thread_Enable_dispatch();
200bc48: 40 00 0f 47 call 200f964 <_Thread_Enable_dispatch>
200bc4c: ba 10 00 08 mov %o0, %i5
* after it wakes up. The returned status is correct for
* non-blocking operations but if we blocked, then we need
* to look at the status in our TCB.
*/
if ( msg_status == CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT )
200bc50: 80 a7 60 07 cmp %i5, 7
200bc54: 12 bf ff ed bne 200bc08 <_POSIX_Message_queue_Send_support+0x88>
200bc58: 80 a7 60 00 cmp %i5, 0
msg_status = _Thread_Executing->Wait.return_code;
200bc5c: 03 00 80 a5 sethi %hi(0x2029400), %g1
200bc60: c2 00 63 20 ld [ %g1 + 0x320 ], %g1 ! 2029720 <_Thread_Executing>
200bc64: 10 bf ff e8 b 200bc04 <_POSIX_Message_queue_Send_support+0x84>
200bc68: fa 00 60 34 ld [ %g1 + 0x34 ], %i5
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EBADF );
200bc6c: 40 00 33 8c call 2018a9c <__errno>
200bc70: b0 10 3f ff mov -1, %i0
200bc74: 82 10 20 09 mov 9, %g1
200bc78: c2 22 00 00 st %g1, [ %o0 ]
}
200bc7c: 81 c7 e0 08 ret
200bc80: 81 e8 00 00 restore
msg_status = _Thread_Executing->Wait.return_code;
if ( !msg_status )
return msg_status;
rtems_set_errno_and_return_minus_one(
200bc84: 40 00 33 86 call 2018a9c <__errno>
200bc88: b0 10 3f ff mov -1, %i0
200bc8c: b8 10 00 08 mov %o0, %i4
200bc90: 40 00 00 59 call 200bdf4 <_POSIX_Message_queue_Translate_core_message_queue_return_code>
200bc94: 90 10 00 1d mov %i5, %o0
200bc98: d0 27 00 00 st %o0, [ %i4 ]
200bc9c: 81 c7 e0 08 ret
200bca0: 81 e8 00 00 restore
* Validate the priority.
* XXX - Do not validate msg_prio is not less than 0.
*/
if ( msg_prio > MQ_PRIO_MAX )
rtems_set_errno_and_return_minus_one( EINVAL );
200bca4: 40 00 33 7e call 2018a9c <__errno>
200bca8: b0 10 3f ff mov -1, %i0
200bcac: 82 10 20 16 mov 0x16, %g1
200bcb0: c2 22 00 00 st %g1, [ %o0 ]
200bcb4: 81 c7 e0 08 ret
200bcb8: 81 e8 00 00 restore
the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( (the_mq_fd->oflag & O_ACCMODE) == O_RDONLY ) {
_Thread_Enable_dispatch();
200bcbc: 40 00 0f 2a call 200f964 <_Thread_Enable_dispatch>
200bcc0: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( EBADF );
200bcc4: 40 00 33 76 call 2018a9c <__errno>
200bcc8: 01 00 00 00 nop
200bccc: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
200bcd0: c2 22 00 00 st %g1, [ %o0 ]
200bcd4: 81 c7 e0 08 ret
200bcd8: 81 e8 00 00 restore
0200d664 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch>:
Thread_Control *the_thread
)
{
POSIX_API_Control *thread_support;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
200d664: c2 02 21 6c ld [ %o0 + 0x16c ], %g1
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
200d668: c4 00 60 d4 ld [ %g1 + 0xd4 ], %g2
200d66c: 80 a0 a0 00 cmp %g2, 0
200d670: 12 80 00 06 bne 200d688 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x24><== NEVER TAKEN
200d674: 01 00 00 00 nop
thread_support->cancelability_type == PTHREAD_CANCEL_ASYNCHRONOUS &&
200d678: c4 00 60 d8 ld [ %g1 + 0xd8 ], %g2
200d67c: 80 a0 a0 01 cmp %g2, 1
200d680: 22 80 00 05 be,a 200d694 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x30>
200d684: c2 00 60 dc ld [ %g1 + 0xdc ], %g1
thread_support->cancelation_requested ) {
_Thread_Unnest_dispatch();
_POSIX_Thread_Exit( the_thread, PTHREAD_CANCELED );
} else
_Thread_Enable_dispatch();
200d688: 82 13 c0 00 mov %o7, %g1
200d68c: 7f ff ee 99 call 20090f0 <_Thread_Enable_dispatch>
200d690: 9e 10 40 00 mov %g1, %o7
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
thread_support->cancelability_type == PTHREAD_CANCEL_ASYNCHRONOUS &&
thread_support->cancelation_requested ) {
200d694: 80 a0 60 00 cmp %g1, 0
200d698: 02 bf ff fc be 200d688 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x24>
200d69c: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
200d6a0: 03 00 80 82 sethi %hi(0x2020800), %g1
200d6a4: c4 00 62 10 ld [ %g1 + 0x210 ], %g2 ! 2020a10 <_Thread_Dispatch_disable_level>
_Thread_Unnest_dispatch();
_POSIX_Thread_Exit( the_thread, PTHREAD_CANCELED );
200d6a8: 92 10 3f ff mov -1, %o1
200d6ac: 84 00 bf ff add %g2, -1, %g2
200d6b0: c4 20 62 10 st %g2, [ %g1 + 0x210 ]
200d6b4: 82 13 c0 00 mov %o7, %g1
200d6b8: 40 00 01 e8 call 200de58 <_POSIX_Thread_Exit>
200d6bc: 9e 10 40 00 mov %g1, %o7
0200ecbc <_POSIX_Thread_Translate_sched_param>:
int policy,
struct sched_param *param,
Thread_CPU_budget_algorithms *budget_algorithm,
Thread_CPU_budget_algorithm_callout *budget_callout
)
{
200ecbc: 9d e3 bf a0 save %sp, -96, %sp
if ( !_POSIX_Priority_Is_valid( param->sched_priority ) )
200ecc0: 7f ff ff f2 call 200ec88 <_POSIX_Priority_Is_valid>
200ecc4: d0 06 40 00 ld [ %i1 ], %o0
200ecc8: 80 8a 20 ff btst 0xff, %o0
200eccc: 02 80 00 0c be 200ecfc <_POSIX_Thread_Translate_sched_param+0x40><== NEVER TAKEN
200ecd0: 80 a6 20 00 cmp %i0, 0
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
200ecd4: c0 26 80 00 clr [ %i2 ]
*budget_callout = NULL;
if ( policy == SCHED_OTHER ) {
200ecd8: 02 80 00 0b be 200ed04 <_POSIX_Thread_Translate_sched_param+0x48>
200ecdc: c0 26 c0 00 clr [ %i3 ]
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
return 0;
}
if ( policy == SCHED_FIFO ) {
200ece0: 80 a6 20 01 cmp %i0, 1
200ece4: 02 80 00 2e be 200ed9c <_POSIX_Thread_Translate_sched_param+0xe0>
200ece8: 80 a6 20 02 cmp %i0, 2
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
return 0;
}
if ( policy == SCHED_RR ) {
200ecec: 02 80 00 2f be 200eda8 <_POSIX_Thread_Translate_sched_param+0xec>
200ecf0: 80 a6 20 04 cmp %i0, 4
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE;
return 0;
}
if ( policy == SCHED_SPORADIC ) {
200ecf4: 22 80 00 08 be,a 200ed14 <_POSIX_Thread_Translate_sched_param+0x58>
200ecf8: c2 06 60 08 ld [ %i1 + 8 ], %g1
*budget_callout = _POSIX_Threads_Sporadic_budget_callout;
return 0;
}
return EINVAL;
}
200ecfc: 81 c7 e0 08 ret
200ed00: 91 e8 20 16 restore %g0, 0x16, %o0
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
*budget_callout = NULL;
if ( policy == SCHED_OTHER ) {
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
200ed04: 82 10 20 01 mov 1, %g1
200ed08: c2 26 80 00 st %g1, [ %i2 ]
return 0;
200ed0c: 81 c7 e0 08 ret
200ed10: 81 e8 00 00 restore
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE;
return 0;
}
if ( policy == SCHED_SPORADIC ) {
if ( (param->sched_ss_repl_period.tv_sec == 0) &&
200ed14: 80 a0 60 00 cmp %g1, 0
200ed18: 32 80 00 07 bne,a 200ed34 <_POSIX_Thread_Translate_sched_param+0x78>
200ed1c: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
(param->sched_ss_repl_period.tv_nsec == 0) )
200ed20: c2 06 60 0c ld [ %i1 + 0xc ], %g1
200ed24: 80 a0 60 00 cmp %g1, 0
200ed28: 02 bf ff f5 be 200ecfc <_POSIX_Thread_Translate_sched_param+0x40>
200ed2c: 01 00 00 00 nop
return EINVAL;
if ( (param->sched_ss_init_budget.tv_sec == 0) &&
200ed30: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
200ed34: 80 a0 60 00 cmp %g1, 0
200ed38: 12 80 00 06 bne 200ed50 <_POSIX_Thread_Translate_sched_param+0x94>
200ed3c: 01 00 00 00 nop
(param->sched_ss_init_budget.tv_nsec == 0) )
200ed40: c2 06 60 14 ld [ %i1 + 0x14 ], %g1
200ed44: 80 a0 60 00 cmp %g1, 0
200ed48: 02 bf ff ed be 200ecfc <_POSIX_Thread_Translate_sched_param+0x40>
200ed4c: 01 00 00 00 nop
return EINVAL;
if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <
200ed50: 7f ff f0 e5 call 200b0e4 <_Timespec_To_ticks>
200ed54: 90 06 60 08 add %i1, 8, %o0
200ed58: b0 10 00 08 mov %o0, %i0
200ed5c: 7f ff f0 e2 call 200b0e4 <_Timespec_To_ticks>
200ed60: 90 06 60 10 add %i1, 0x10, %o0
200ed64: 80 a6 00 08 cmp %i0, %o0
200ed68: 0a bf ff e5 bcs 200ecfc <_POSIX_Thread_Translate_sched_param+0x40>
200ed6c: 01 00 00 00 nop
_Timespec_To_ticks( ¶m->sched_ss_init_budget ) )
return EINVAL;
if ( !_POSIX_Priority_Is_valid( param->sched_ss_low_priority ) )
200ed70: 7f ff ff c6 call 200ec88 <_POSIX_Priority_Is_valid>
200ed74: d0 06 60 04 ld [ %i1 + 4 ], %o0
200ed78: 80 8a 20 ff btst 0xff, %o0
200ed7c: 02 bf ff e0 be 200ecfc <_POSIX_Thread_Translate_sched_param+0x40>
200ed80: 82 10 20 03 mov 3, %g1
return EINVAL;
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_CALLOUT;
200ed84: c2 26 80 00 st %g1, [ %i2 ]
*budget_callout = _POSIX_Threads_Sporadic_budget_callout;
200ed88: 03 00 80 1c sethi %hi(0x2007000), %g1
200ed8c: 82 10 61 bc or %g1, 0x1bc, %g1 ! 20071bc <_POSIX_Threads_Sporadic_budget_callout>
200ed90: c2 26 c0 00 st %g1, [ %i3 ]
return 0;
200ed94: 81 c7 e0 08 ret
200ed98: 91 e8 20 00 restore %g0, 0, %o0
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
return 0;
}
if ( policy == SCHED_FIFO ) {
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
200ed9c: c0 26 80 00 clr [ %i2 ]
return 0;
200eda0: 81 c7 e0 08 ret
200eda4: 91 e8 20 00 restore %g0, 0, %o0
}
if ( policy == SCHED_RR ) {
*budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE;
200eda8: f0 26 80 00 st %i0, [ %i2 ]
return 0;
200edac: 81 c7 e0 08 ret
200edb0: 91 e8 20 00 restore %g0, 0, %o0
0200d7d4 <_POSIX_Threads_Delete_extension>:
*/
void _POSIX_Threads_Delete_extension(
Thread_Control *executing __attribute__((unused)),
Thread_Control *deleted
)
{
200d7d4: 9d e3 bf a0 save %sp, -96, %sp
Thread_Control *the_thread;
POSIX_API_Control *api;
void **value_ptr;
api = deleted->API_Extensions[ THREAD_API_POSIX ];
200d7d8: f0 06 61 6c ld [ %i1 + 0x16c ], %i0
/*
* Run the POSIX cancellation handlers
*/
_POSIX_Threads_cancel_run( deleted );
200d7dc: 40 00 0c 3e call 20108d4 <_POSIX_Threads_cancel_run>
200d7e0: 90 10 00 19 mov %i1, %o0
/*
* Run all the key destructors
*/
_POSIX_Keys_Run_destructors( deleted );
200d7e4: 90 10 00 19 mov %i1, %o0
200d7e8: 40 00 0c 57 call 2010944 <_POSIX_Keys_Run_destructors>
200d7ec: a0 06 20 40 add %i0, 0x40, %l0
/*
* Wakeup all the tasks which joined with this one
*/
value_ptr = (void **) deleted->Wait.return_argument;
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
200d7f0: 10 80 00 03 b 200d7fc <_POSIX_Threads_Delete_extension+0x28>
200d7f4: e2 06 60 28 ld [ %i1 + 0x28 ], %l1
*(void **)the_thread->Wait.return_argument = value_ptr;
200d7f8: e2 20 40 00 st %l1, [ %g1 ] <== NOT EXECUTED
/*
* Wakeup all the tasks which joined with this one
*/
value_ptr = (void **) deleted->Wait.return_argument;
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
200d7fc: 7f ff ee 7a call 20091e4 <_Thread_queue_Dequeue>
200d800: 90 10 00 10 mov %l0, %o0
200d804: 80 a2 20 00 cmp %o0, 0
200d808: 32 bf ff fc bne,a 200d7f8 <_POSIX_Threads_Delete_extension+0x24><== NEVER TAKEN
200d80c: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED
*(void **)the_thread->Wait.return_argument = value_ptr;
if ( api->schedpolicy == SCHED_SPORADIC )
200d810: c2 06 20 80 ld [ %i0 + 0x80 ], %g1
200d814: 80 a0 60 04 cmp %g1, 4
200d818: 02 80 00 05 be 200d82c <_POSIX_Threads_Delete_extension+0x58>
200d81c: 01 00 00 00 nop
(void) _Watchdog_Remove( &api->Sporadic_timer );
deleted->API_Extensions[ THREAD_API_POSIX ] = NULL;
200d820: c0 26 61 6c clr [ %i1 + 0x16c ]
(void) _Workspace_Free( api );
200d824: 7f ff f2 ee call 200a3dc <_Workspace_Free>
200d828: 81 e8 00 00 restore
while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )
*(void **)the_thread->Wait.return_argument = value_ptr;
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
200d82c: 7f ff f2 74 call 200a1fc <_Watchdog_Remove>
200d830: 90 06 20 a4 add %i0, 0xa4, %o0
deleted->API_Extensions[ THREAD_API_POSIX ] = NULL;
200d834: c0 26 61 6c clr [ %i1 + 0x16c ]
(void) _Workspace_Free( api );
200d838: 7f ff f2 e9 call 200a3dc <_Workspace_Free>
200d83c: 81 e8 00 00 restore
02006ee0 <_POSIX_Threads_Initialize_user_threads_body>:
*
* Output parameters: NONE
*/
void _POSIX_Threads_Initialize_user_threads_body(void)
{
2006ee0: 9d e3 bf 60 save %sp, -160, %sp
uint32_t maximum;
posix_initialization_threads_table *user_threads;
pthread_t thread_id;
pthread_attr_t attr;
user_threads = Configuration_POSIX_API.User_initialization_threads_table;
2006ee4: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006ee8: 82 10 62 3c or %g1, 0x23c, %g1 ! 201fe3c <Configuration_POSIX_API>
maximum = Configuration_POSIX_API.number_of_initialization_threads;
2006eec: e6 00 60 30 ld [ %g1 + 0x30 ], %l3
if ( !user_threads || maximum == 0 )
2006ef0: 80 a4 e0 00 cmp %l3, 0
2006ef4: 02 80 00 1a be 2006f5c <_POSIX_Threads_Initialize_user_threads_body+0x7c><== NEVER TAKEN
2006ef8: e2 00 60 34 ld [ %g1 + 0x34 ], %l1
2006efc: 80 a4 60 00 cmp %l1, 0
2006f00: 02 80 00 17 be 2006f5c <_POSIX_Threads_Initialize_user_threads_body+0x7c><== NEVER TAKEN
2006f04: a4 10 20 00 clr %l2
2006f08: a0 07 bf c0 add %fp, -64, %l0
2006f0c: a8 07 bf fc add %fp, -4, %l4
for ( index=0 ; index < maximum ; index++ ) {
/*
* There is no way for these calls to fail in this situation.
*/
(void) pthread_attr_init( &attr );
2006f10: 40 00 1f a9 call 200edb4 <pthread_attr_init>
2006f14: 90 10 00 10 mov %l0, %o0
(void) pthread_attr_setinheritsched( &attr, PTHREAD_EXPLICIT_SCHED );
2006f18: 92 10 20 02 mov 2, %o1
2006f1c: 40 00 1f b2 call 200ede4 <pthread_attr_setinheritsched>
2006f20: 90 10 00 10 mov %l0, %o0
(void) pthread_attr_setstacksize(&attr, user_threads[ index ].stack_size);
2006f24: d2 04 60 04 ld [ %l1 + 4 ], %o1
2006f28: 40 00 1f c0 call 200ee28 <pthread_attr_setstacksize>
2006f2c: 90 10 00 10 mov %l0, %o0
status = pthread_create(
2006f30: d4 04 40 00 ld [ %l1 ], %o2
2006f34: 90 10 00 14 mov %l4, %o0
2006f38: 92 10 00 10 mov %l0, %o1
2006f3c: 7f ff fe f0 call 2006afc <pthread_create>
2006f40: 96 10 20 00 clr %o3
&thread_id,
&attr,
user_threads[ index ].thread_entry,
NULL
);
if ( status )
2006f44: 80 a2 20 00 cmp %o0, 0
2006f48: 12 80 00 07 bne 2006f64 <_POSIX_Threads_Initialize_user_threads_body+0x84>
2006f4c: a4 04 a0 01 inc %l2
*
* Setting the attributes explicitly is critical, since we don't want
* to inherit the idle tasks attributes.
*/
for ( index=0 ; index < maximum ; index++ ) {
2006f50: 80 a4 c0 12 cmp %l3, %l2
2006f54: 18 bf ff ef bgu 2006f10 <_POSIX_Threads_Initialize_user_threads_body+0x30><== NEVER TAKEN
2006f58: a2 04 60 08 add %l1, 8, %l1
2006f5c: 81 c7 e0 08 ret
2006f60: 81 e8 00 00 restore
&attr,
user_threads[ index ].thread_entry,
NULL
);
if ( status )
_Internal_error_Occurred( INTERNAL_ERROR_POSIX_API, true, status );
2006f64: 94 10 00 08 mov %o0, %o2
2006f68: 92 10 20 01 mov 1, %o1
2006f6c: 40 00 08 41 call 2009070 <_Internal_error_Occurred>
2006f70: 90 10 20 02 mov 2, %o0
0200d9cc <_POSIX_Threads_Sporadic_budget_TSR>:
*/
void _POSIX_Threads_Sporadic_budget_TSR(
Objects_Id id __attribute__((unused)),
void *argument
)
{
200d9cc: 9d e3 bf a0 save %sp, -96, %sp
Thread_Control *the_thread;
POSIX_API_Control *api;
the_thread = argument;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200d9d0: e0 06 61 6c ld [ %i1 + 0x16c ], %l0
/* ticks is guaranteed to be at least one */
ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_init_budget );
200d9d4: 40 00 04 83 call 200ebe0 <_Timespec_To_ticks>
200d9d8: 90 04 20 94 add %l0, 0x94, %o0
200d9dc: 03 00 80 7a sethi %hi(0x201e800), %g1
200d9e0: c4 04 20 84 ld [ %l0 + 0x84 ], %g2
200d9e4: d2 08 60 64 ldub [ %g1 + 0x64 ], %o1
*/
#if 0
printk( "TSR %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
200d9e8: c2 06 60 1c ld [ %i1 + 0x1c ], %g1
200d9ec: 92 22 40 02 sub %o1, %g2, %o1
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
/* ticks is guaranteed to be at least one */
ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_init_budget );
the_thread->cpu_time_budget = ticks;
200d9f0: d0 26 60 78 st %o0, [ %i1 + 0x78 ]
*/
#if 0
printk( "TSR %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
200d9f4: 80 a0 60 00 cmp %g1, 0
200d9f8: 12 80 00 06 bne 200da10 <_POSIX_Threads_Sporadic_budget_TSR+0x44><== NEVER TAKEN
200d9fc: d2 26 60 18 st %o1, [ %i1 + 0x18 ]
/*
* If this would make them less important, then do not change it.
*/
if ( the_thread->current_priority > new_priority ) {
200da00: c2 06 60 14 ld [ %i1 + 0x14 ], %g1
200da04: 80 a0 40 09 cmp %g1, %o1
200da08: 38 80 00 09 bgu,a 200da2c <_POSIX_Threads_Sporadic_budget_TSR+0x60>
200da0c: 90 10 00 19 mov %i1, %o0
#endif
}
}
/* ticks is guaranteed to be at least one */
ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_repl_period );
200da10: 40 00 04 74 call 200ebe0 <_Timespec_To_ticks>
200da14: 90 04 20 8c add %l0, 0x8c, %o0
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
200da18: 31 00 80 7d sethi %hi(0x201f400), %i0
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
200da1c: d0 24 20 b0 st %o0, [ %l0 + 0xb0 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
200da20: b2 04 20 a4 add %l0, 0xa4, %i1
200da24: 7f ff f1 8d call 200a058 <_Watchdog_Insert>
200da28: 91 ee 20 80 restore %i0, 0x80, %o0
if ( the_thread->resource_count == 0 ) {
/*
* If this would make them less important, then do not change it.
*/
if ( the_thread->current_priority > new_priority ) {
_Thread_Change_priority( the_thread, new_priority, true );
200da2c: 7f ff eb 3f call 2008728 <_Thread_Change_priority>
200da30: 94 10 20 01 mov 1, %o2
#endif
}
}
/* ticks is guaranteed to be at least one */
ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_repl_period );
200da34: 40 00 04 6b call 200ebe0 <_Timespec_To_ticks>
200da38: 90 04 20 8c add %l0, 0x8c, %o0
200da3c: 31 00 80 7d sethi %hi(0x201f400), %i0
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
200da40: d0 24 20 b0 st %o0, [ %l0 + 0xb0 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
200da44: b2 04 20 a4 add %l0, 0xa4, %i1
200da48: 7f ff f1 84 call 200a058 <_Watchdog_Insert>
200da4c: 91 ee 20 80 restore %i0, 0x80, %o0
0200d978 <_POSIX_Threads_Sporadic_budget_callout>:
)
{
POSIX_API_Control *api;
uint32_t new_priority;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200d978: c4 02 21 6c ld [ %o0 + 0x16c ], %g2
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(
int priority
)
{
return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
200d97c: c6 00 a0 88 ld [ %g2 + 0x88 ], %g3
200d980: 05 00 80 7a sethi %hi(0x201e800), %g2
200d984: d2 08 a0 64 ldub [ %g2 + 0x64 ], %o1 ! 201e864 <rtems_maximum_priority>
*/
#if 0
printk( "callout %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
200d988: c4 02 20 1c ld [ %o0 + 0x1c ], %g2
200d98c: 92 22 40 03 sub %o1, %g3, %o1
/*
* This will prevent the thread from consuming its entire "budget"
* while at low priority.
*/
the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
200d990: 86 10 3f ff mov -1, %g3
new_priority = _POSIX_Priority_To_core(api->schedparam.sched_ss_low_priority);
the_thread->real_priority = new_priority;
200d994: d2 22 20 18 st %o1, [ %o0 + 0x18 ]
*/
#if 0
printk( "callout %d %d %d\n", the_thread->resource_count,
the_thread->current_priority, new_priority );
#endif
if ( the_thread->resource_count == 0 ) {
200d998: 80 a0 a0 00 cmp %g2, 0
200d99c: 12 80 00 06 bne 200d9b4 <_POSIX_Threads_Sporadic_budget_callout+0x3c><== NEVER TAKEN
200d9a0: c6 22 20 78 st %g3, [ %o0 + 0x78 ]
/*
* Make sure we are actually lowering it. If they have lowered it
* to logically lower than sched_ss_low_priority, then we do not want to
* change it.
*/
if ( the_thread->current_priority < new_priority ) {
200d9a4: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
200d9a8: 80 a0 40 09 cmp %g1, %o1
200d9ac: 0a 80 00 04 bcs 200d9bc <_POSIX_Threads_Sporadic_budget_callout+0x44><== ALWAYS TAKEN
200d9b0: 94 10 20 01 mov 1, %o2
200d9b4: 81 c3 e0 08 retl <== NOT EXECUTED
200d9b8: 01 00 00 00 nop <== NOT EXECUTED
_Thread_Change_priority( the_thread, new_priority, true );
200d9bc: 82 13 c0 00 mov %o7, %g1
200d9c0: 7f ff eb 5a call 2008728 <_Thread_Change_priority>
200d9c4: 9e 10 40 00 mov %g1, %o7
020108d4 <_POSIX_Threads_cancel_run>:
#include <rtems/posix/threadsup.h>
void _POSIX_Threads_cancel_run(
Thread_Control *the_thread
)
{
20108d4: 9d e3 bf a0 save %sp, -96, %sp
POSIX_Cancel_Handler_control *handler;
Chain_Control *handler_stack;
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
20108d8: e4 06 21 6c ld [ %i0 + 0x16c ], %l2
handler_stack = &thread_support->Cancellation_Handlers;
thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE;
20108dc: 84 10 20 01 mov 1, %g2
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
handler_stack = &thread_support->Cancellation_Handlers;
20108e0: c2 04 a0 e0 ld [ %l2 + 0xe0 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
20108e4: a2 04 a0 e4 add %l2, 0xe4, %l1
20108e8: 80 a0 40 11 cmp %g1, %l1
20108ec: 02 80 00 14 be 201093c <_POSIX_Threads_cancel_run+0x68>
20108f0: c4 24 a0 d4 st %g2, [ %l2 + 0xd4 ]
thread_support->cancelability_state = PTHREAD_CANCEL_DISABLE;
while ( !_Chain_Is_empty( handler_stack ) ) {
_ISR_Disable( level );
20108f4: 7f ff c5 ec call 20020a4 <sparc_disable_interrupts>
20108f8: 01 00 00 00 nop
handler = (POSIX_Cancel_Handler_control *)
20108fc: e0 04 60 04 ld [ %l1 + 4 ], %l0
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
2010900: c2 04 00 00 ld [ %l0 ], %g1
previous = the_node->previous;
2010904: c4 04 20 04 ld [ %l0 + 4 ], %g2
next->previous = previous;
previous->next = next;
2010908: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
201090c: c4 20 60 04 st %g2, [ %g1 + 4 ]
_Chain_Tail( handler_stack )->previous;
_Chain_Extract_unprotected( &handler->Node );
_ISR_Enable( level );
2010910: 7f ff c5 e9 call 20020b4 <sparc_enable_interrupts>
2010914: 01 00 00 00 nop
(*handler->routine)( handler->arg );
2010918: c2 04 20 08 ld [ %l0 + 8 ], %g1
201091c: 9f c0 40 00 call %g1
2010920: d0 04 20 0c ld [ %l0 + 0xc ], %o0
_Workspace_Free( handler );
2010924: 7f ff e6 ae call 200a3dc <_Workspace_Free>
2010928: 90 10 00 10 mov %l0, %o0
POSIX_API_Control *thread_support;
ISR_Level level;
thread_support = the_thread->API_Extensions[ THREAD_API_POSIX ];
handler_stack = &thread_support->Cancellation_Handlers;
201092c: c2 04 a0 e0 ld [ %l2 + 0xe0 ], %g1
2010930: 80 a0 40 11 cmp %g1, %l1
2010934: 12 bf ff f0 bne 20108f4 <_POSIX_Threads_cancel_run+0x20> <== NEVER TAKEN
2010938: 01 00 00 00 nop
201093c: 81 c7 e0 08 ret
2010940: 81 e8 00 00 restore
02006ae4 <_POSIX_Timer_TSR>:
* This is the operation that is run when a timer expires
*/
void _POSIX_Timer_TSR(
Objects_Id timer __attribute__((unused)),
void *data)
{
2006ae4: 9d e3 bf a0 save %sp, -96, %sp
bool activated;
ptimer = (POSIX_Timer_Control *)data;
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
2006ae8: c4 06 60 68 ld [ %i1 + 0x68 ], %g2
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
2006aec: c2 06 60 54 ld [ %i1 + 0x54 ], %g1
bool activated;
ptimer = (POSIX_Timer_Control *)data;
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
2006af0: 84 00 a0 01 inc %g2
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
2006af4: 80 a0 60 00 cmp %g1, 0
2006af8: 12 80 00 0e bne 2006b30 <_POSIX_Timer_TSR+0x4c>
2006afc: c4 26 60 68 st %g2, [ %i1 + 0x68 ]
( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) {
2006b00: c2 06 60 58 ld [ %i1 + 0x58 ], %g1
2006b04: 80 a0 60 00 cmp %g1, 0
2006b08: 32 80 00 0b bne,a 2006b34 <_POSIX_Timer_TSR+0x50> <== ALWAYS TAKEN
2006b0c: d2 06 60 64 ld [ %i1 + 0x64 ], %o1
/* The state really did not change but just to be safe */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
} else {
/* Indicates that the timer is stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
2006b10: 82 10 20 04 mov 4, %g1 <== NOT EXECUTED
2006b14: c2 2e 60 3c stb %g1, [ %i1 + 0x3c ] <== NOT EXECUTED
/*
* The sending of the signal to the process running the handling function
* specified for that signal is simulated
*/
if ( pthread_kill ( ptimer->thread_id, ptimer->inf.sigev_signo ) ) {
2006b18: d0 06 60 38 ld [ %i1 + 0x38 ], %o0
2006b1c: 40 00 1e 09 call 200e340 <pthread_kill>
2006b20: d2 06 60 44 ld [ %i1 + 0x44 ], %o1
}
/* After the signal handler returns, the count of expirations of the
* timer must be set to 0.
*/
ptimer->overrun = 0;
2006b24: c0 26 60 68 clr [ %i1 + 0x68 ]
2006b28: 81 c7 e0 08 ret
2006b2c: 81 e8 00 00 restore
ptimer->overrun = ptimer->overrun + 1;
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) {
activated = _POSIX_Timer_Insert_helper(
2006b30: d2 06 60 64 ld [ %i1 + 0x64 ], %o1
2006b34: d4 06 60 08 ld [ %i1 + 8 ], %o2
2006b38: 90 06 60 10 add %i1, 0x10, %o0
2006b3c: 17 00 80 1a sethi %hi(0x2006800), %o3
2006b40: 98 10 00 19 mov %i1, %o4
2006b44: 40 00 1f 2b call 200e7f0 <_POSIX_Timer_Insert_helper>
2006b48: 96 12 e2 e4 or %o3, 0x2e4, %o3
ptimer->ticks,
ptimer->Object.id,
_POSIX_Timer_TSR,
ptimer
);
if ( !activated )
2006b4c: 80 8a 20 ff btst 0xff, %o0
2006b50: 02 bf ff f6 be 2006b28 <_POSIX_Timer_TSR+0x44> <== NEVER TAKEN
2006b54: 01 00 00 00 nop
return;
/* Store the time when the timer was started again */
_TOD_Get( &ptimer->time );
2006b58: 40 00 05 f3 call 2008324 <_TOD_Get>
2006b5c: 90 06 60 6c add %i1, 0x6c, %o0
/* The state really did not change but just to be safe */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
2006b60: 82 10 20 03 mov 3, %g1
/* Increment the number of expirations. */
ptimer->overrun = ptimer->overrun + 1;
/* The timer must be reprogrammed */
if ( ( ptimer->timer_data.it_interval.tv_sec != 0 ) ||
2006b64: 10 bf ff ed b 2006b18 <_POSIX_Timer_TSR+0x34>
2006b68: c2 2e 60 3c stb %g1, [ %i1 + 0x3c ]
02010d2c <_POSIX_signals_Check_signal>:
bool _POSIX_signals_Check_signal(
POSIX_API_Control *api,
int signo,
bool is_global
)
{
2010d2c: 9d e3 bf 90 save %sp, -112, %sp
siginfo_t siginfo_struct;
sigset_t saved_signals_blocked;
if ( ! _POSIX_signals_Clear_signals( api, signo, &siginfo_struct,
2010d30: 98 10 20 01 mov 1, %o4
2010d34: 96 0e a0 ff and %i2, 0xff, %o3
2010d38: a0 07 bf f4 add %fp, -12, %l0
2010d3c: 90 10 00 18 mov %i0, %o0
2010d40: 92 10 00 19 mov %i1, %o1
2010d44: 40 00 00 23 call 2010dd0 <_POSIX_signals_Clear_signals>
2010d48: 94 10 00 10 mov %l0, %o2
2010d4c: 80 8a 20 ff btst 0xff, %o0
2010d50: 02 80 00 1e be 2010dc8 <_POSIX_signals_Check_signal+0x9c>
2010d54: 83 2e 60 02 sll %i1, 2, %g1
#endif
/*
* Just to prevent sending a signal which is currently being ignored.
*/
if ( _POSIX_signals_Vectors[ signo ].sa_handler == SIG_IGN )
2010d58: 07 00 80 7e sethi %hi(0x201f800), %g3
2010d5c: 85 2e 60 04 sll %i1, 4, %g2
2010d60: 86 10 e1 28 or %g3, 0x128, %g3
2010d64: 84 20 80 01 sub %g2, %g1, %g2
2010d68: 88 00 c0 02 add %g3, %g2, %g4
2010d6c: c2 01 20 08 ld [ %g4 + 8 ], %g1
2010d70: 80 a0 60 01 cmp %g1, 1
2010d74: 02 80 00 15 be 2010dc8 <_POSIX_signals_Check_signal+0x9c> <== NEVER TAKEN
2010d78: 01 00 00 00 nop
/*
* Block the signals requested in sa_mask
*/
saved_signals_blocked = api->signals_blocked;
api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;
2010d7c: c8 01 20 04 ld [ %g4 + 4 ], %g4
return false;
/*
* Block the signals requested in sa_mask
*/
saved_signals_blocked = api->signals_blocked;
2010d80: e2 06 20 cc ld [ %i0 + 0xcc ], %l1
api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;
/*
* Here, the signal handler function executes
*/
switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {
2010d84: c4 00 c0 02 ld [ %g3 + %g2 ], %g2
/*
* Block the signals requested in sa_mask
*/
saved_signals_blocked = api->signals_blocked;
api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;
2010d88: 86 11 00 11 or %g4, %l1, %g3
/*
* Here, the signal handler function executes
*/
switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {
2010d8c: 80 a0 a0 02 cmp %g2, 2
2010d90: 02 80 00 07 be 2010dac <_POSIX_signals_Check_signal+0x80>
2010d94: c6 26 20 cc st %g3, [ %i0 + 0xcc ]
&siginfo_struct,
NULL /* context is undefined per 1003.1b-1993, p. 66 */
);
break;
default:
(*_POSIX_signals_Vectors[ signo ].sa_handler)( signo );
2010d98: 9f c0 40 00 call %g1
2010d9c: 90 10 00 19 mov %i1, %o0
}
/*
* Restore the previous set of blocked signals
*/
api->signals_blocked = saved_signals_blocked;
2010da0: e2 26 20 cc st %l1, [ %i0 + 0xcc ]
return true;
2010da4: 81 c7 e0 08 ret
2010da8: 91 e8 20 01 restore %g0, 1, %o0
/*
* Here, the signal handler function executes
*/
switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {
case SA_SIGINFO:
(*_POSIX_signals_Vectors[ signo ].sa_sigaction)(
2010dac: 90 10 00 19 mov %i1, %o0
2010db0: 92 10 00 10 mov %l0, %o1
2010db4: 9f c0 40 00 call %g1
2010db8: 94 10 20 00 clr %o2
}
/*
* Restore the previous set of blocked signals
*/
api->signals_blocked = saved_signals_blocked;
2010dbc: e2 26 20 cc st %l1, [ %i0 + 0xcc ]
return true;
2010dc0: 81 c7 e0 08 ret
2010dc4: 91 e8 20 01 restore %g0, 1, %o0
}
2010dc8: 81 c7 e0 08 ret
2010dcc: 91 e8 20 00 restore %g0, 0, %o0
020118b8 <_POSIX_signals_Clear_process_signals>:
*/
void _POSIX_signals_Clear_process_signals(
int signo
)
{
20118b8: 9d e3 bf a0 save %sp, -96, %sp
clear_signal = true;
mask = signo_to_mask( signo );
ISR_Level level;
_ISR_Disable( level );
20118bc: 7f ff c1 fa call 20020a4 <sparc_disable_interrupts>
20118c0: 01 00 00 00 nop
if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) {
20118c4: 85 2e 20 04 sll %i0, 4, %g2
20118c8: 83 2e 20 02 sll %i0, 2, %g1
20118cc: 82 20 80 01 sub %g2, %g1, %g1
20118d0: 05 00 80 7e sethi %hi(0x201f800), %g2
20118d4: 84 10 a1 28 or %g2, 0x128, %g2 ! 201f928 <_POSIX_signals_Vectors>
20118d8: c4 00 80 01 ld [ %g2 + %g1 ], %g2
20118dc: 80 a0 a0 02 cmp %g2, 2
20118e0: 02 80 00 11 be 2011924 <_POSIX_signals_Clear_process_signals+0x6c>
20118e4: 05 00 80 7e sethi %hi(0x201f800), %g2
if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) )
clear_signal = false;
}
if ( clear_signal ) {
_POSIX_signals_Pending &= ~mask;
20118e8: 05 00 80 7e sethi %hi(0x201f800), %g2
20118ec: c6 00 a3 1c ld [ %g2 + 0x31c ], %g3 ! 201fb1c <_POSIX_signals_Pending>
20118f0: b0 06 3f ff add %i0, -1, %i0
20118f4: 82 10 20 01 mov 1, %g1
20118f8: 83 28 40 18 sll %g1, %i0, %g1
20118fc: 82 28 c0 01 andn %g3, %g1, %g1
if ( !_POSIX_signals_Pending )
2011900: 80 a0 60 00 cmp %g1, 0
2011904: 12 80 00 06 bne 201191c <_POSIX_signals_Clear_process_signals+0x64><== NEVER TAKEN
2011908: c2 20 a3 1c st %g1, [ %g2 + 0x31c ]
_Thread_Do_post_task_switch_extension--;
201190c: 03 00 80 7d sethi %hi(0x201f400), %g1
2011910: c4 00 60 44 ld [ %g1 + 0x44 ], %g2 ! 201f444 <_Thread_Do_post_task_switch_extension>
2011914: 84 00 bf ff add %g2, -1, %g2
2011918: c4 20 60 44 st %g2, [ %g1 + 0x44 ]
}
_ISR_Enable( level );
201191c: 7f ff c1 e6 call 20020b4 <sparc_enable_interrupts>
2011920: 91 e8 00 08 restore %g0, %o0, %o0
ISR_Level level;
_ISR_Disable( level );
if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) {
if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) )
2011924: 84 10 a3 20 or %g2, 0x320, %g2
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2011928: c6 00 40 02 ld [ %g1 + %g2 ], %g3
201192c: 82 00 40 02 add %g1, %g2, %g1
2011930: 82 00 60 04 add %g1, 4, %g1
2011934: 80 a0 c0 01 cmp %g3, %g1
2011938: 02 bf ff ed be 20118ec <_POSIX_signals_Clear_process_signals+0x34><== ALWAYS TAKEN
201193c: 05 00 80 7e sethi %hi(0x201f800), %g2
if ( clear_signal ) {
_POSIX_signals_Pending &= ~mask;
if ( !_POSIX_signals_Pending )
_Thread_Do_post_task_switch_extension--;
}
_ISR_Enable( level );
2011940: 7f ff c1 dd call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2011944: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02007720 <_POSIX_signals_Get_highest>:
#include <rtems/score/isr.h>
int _POSIX_signals_Get_highest(
sigset_t set
)
{
2007720: 82 10 20 1b mov 0x1b, %g1 ! 1b <PROM_START+0x1b>
int signo;
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
if ( set & signo_to_mask( signo ) ) {
2007724: 86 10 20 01 mov 1, %g3
2007728: 84 00 7f ff add %g1, -1, %g2
200772c: 85 28 c0 02 sll %g3, %g2, %g2
2007730: 80 88 80 08 btst %g2, %o0
2007734: 12 80 00 11 bne 2007778 <_POSIX_signals_Get_highest+0x58> <== NEVER TAKEN
2007738: 01 00 00 00 nop
sigset_t set
)
{
int signo;
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
200773c: 82 00 60 01 inc %g1
2007740: 80 a0 60 20 cmp %g1, 0x20
2007744: 12 bf ff fa bne 200772c <_POSIX_signals_Get_highest+0xc>
2007748: 84 00 7f ff add %g1, -1, %g2
200774c: 82 10 20 01 mov 1, %g1
#if (SIGHUP != 1)
#error "Assumption that SIGHUP==1 violated!!"
#endif
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
if ( set & signo_to_mask( signo ) ) {
2007750: 10 80 00 05 b 2007764 <_POSIX_signals_Get_highest+0x44>
2007754: 86 10 20 01 mov 1, %g3
*/
#if (SIGHUP != 1)
#error "Assumption that SIGHUP==1 violated!!"
#endif
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
2007758: 80 a0 60 1b cmp %g1, 0x1b
200775c: 02 80 00 07 be 2007778 <_POSIX_signals_Get_highest+0x58> <== NEVER TAKEN
2007760: 01 00 00 00 nop
if ( set & signo_to_mask( signo ) ) {
2007764: 84 00 7f ff add %g1, -1, %g2
2007768: 85 28 c0 02 sll %g3, %g2, %g2
200776c: 80 88 80 08 btst %g2, %o0
2007770: 22 bf ff fa be,a 2007758 <_POSIX_signals_Get_highest+0x38>
2007774: 82 00 60 01 inc %g1
* a return 0. This routine will NOT be called unless a signal
* is pending in the set passed in.
*/
found_it:
return signo;
}
2007778: 81 c3 e0 08 retl
200777c: 90 10 00 01 mov %g1, %o0
0200d600 <_POSIX_signals_Post_switch_extension>:
*/
void _POSIX_signals_Post_switch_extension(
Thread_Control *the_thread
)
{
200d600: 9d e3 bf a0 save %sp, -96, %sp
/*
* We need to ensure that if the signal handler executes a call
* which overwrites the unblocking status, we restore it.
*/
hold_errno = _Thread_Executing->Wait.return_code;
200d604: 27 00 80 7d sethi %hi(0x201f400), %l3
POSIX_API_Control *api;
int signo;
ISR_Level level;
int hold_errno;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200d608: e2 06 21 6c ld [ %i0 + 0x16c ], %l1
/*
* We need to ensure that if the signal handler executes a call
* which overwrites the unblocking status, we restore it.
*/
hold_errno = _Thread_Executing->Wait.return_code;
200d60c: c2 04 e0 60 ld [ %l3 + 0x60 ], %g1
/*
* api may be NULL in case of a thread close in progress
*/
if ( !api )
200d610: 80 a4 60 00 cmp %l1, 0
200d614: 02 80 00 34 be 200d6e4 <_POSIX_signals_Post_switch_extension+0xe4><== NEVER TAKEN
200d618: e8 00 60 34 ld [ %g1 + 0x34 ], %l4
*
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
200d61c: 7f ff d2 a2 call 20020a4 <sparc_disable_interrupts>
200d620: 25 00 80 7e sethi %hi(0x201f800), %l2
200d624: a4 14 a3 1c or %l2, 0x31c, %l2 ! 201fb1c <_POSIX_signals_Pending>
if ( !(~api->signals_blocked &
(api->signals_pending | _POSIX_signals_Pending)) ) {
200d628: c6 04 80 00 ld [ %l2 ], %g3
200d62c: c2 04 60 d0 ld [ %l1 + 0xd0 ], %g1
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
if ( !(~api->signals_blocked &
200d630: c4 04 60 cc ld [ %l1 + 0xcc ], %g2
(api->signals_pending | _POSIX_signals_Pending)) ) {
200d634: 82 10 c0 01 or %g3, %g1, %g1
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
if ( !(~api->signals_blocked &
200d638: 80 a8 40 02 andncc %g1, %g2, %g0
200d63c: 02 80 00 26 be 200d6d4 <_POSIX_signals_Post_switch_extension+0xd4>
200d640: 01 00 00 00 nop
(api->signals_pending | _POSIX_signals_Pending)) ) {
_ISR_Enable( level );
break;
}
_ISR_Enable( level );
200d644: 7f ff d2 9c call 20020b4 <sparc_enable_interrupts>
200d648: a0 10 20 1b mov 0x1b, %l0 ! 1b <PROM_START+0x1b>
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
_POSIX_signals_Check_signal( api, signo, false );
200d64c: 92 10 00 10 mov %l0, %o1
200d650: 94 10 20 00 clr %o2
200d654: 40 00 0d b6 call 2010d2c <_POSIX_signals_Check_signal>
200d658: 90 10 00 11 mov %l1, %o0
_POSIX_signals_Check_signal( api, signo, true );
200d65c: 92 10 00 10 mov %l0, %o1
200d660: 90 10 00 11 mov %l1, %o0
200d664: 40 00 0d b2 call 2010d2c <_POSIX_signals_Check_signal>
200d668: 94 10 20 01 mov 1, %o2
_ISR_Enable( level );
break;
}
_ISR_Enable( level );
for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
200d66c: a0 04 20 01 inc %l0
200d670: 80 a4 20 20 cmp %l0, 0x20
200d674: 12 bf ff f7 bne 200d650 <_POSIX_signals_Post_switch_extension+0x50>
200d678: 92 10 00 10 mov %l0, %o1
200d67c: a0 10 20 01 mov 1, %l0
_POSIX_signals_Check_signal( api, signo, true );
}
/* Unfortunately - nothing like __SIGFIRSTNOTRT in newlib signal .h */
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
_POSIX_signals_Check_signal( api, signo, false );
200d680: 92 10 00 10 mov %l0, %o1
200d684: 94 10 20 00 clr %o2
200d688: 40 00 0d a9 call 2010d2c <_POSIX_signals_Check_signal>
200d68c: 90 10 00 11 mov %l1, %o0
_POSIX_signals_Check_signal( api, signo, true );
200d690: 92 10 00 10 mov %l0, %o1
200d694: 90 10 00 11 mov %l1, %o0
200d698: 40 00 0d a5 call 2010d2c <_POSIX_signals_Check_signal>
200d69c: 94 10 20 01 mov 1, %o2
_POSIX_signals_Check_signal( api, signo, false );
_POSIX_signals_Check_signal( api, signo, true );
}
/* Unfortunately - nothing like __SIGFIRSTNOTRT in newlib signal .h */
for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {
200d6a0: a0 04 20 01 inc %l0
200d6a4: 80 a4 20 1b cmp %l0, 0x1b
200d6a8: 12 bf ff f7 bne 200d684 <_POSIX_signals_Post_switch_extension+0x84>
200d6ac: 92 10 00 10 mov %l0, %o1
*
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
200d6b0: 7f ff d2 7d call 20020a4 <sparc_disable_interrupts>
200d6b4: 01 00 00 00 nop
if ( !(~api->signals_blocked &
(api->signals_pending | _POSIX_signals_Pending)) ) {
200d6b8: c6 04 80 00 ld [ %l2 ], %g3
200d6bc: c2 04 60 d0 ld [ %l1 + 0xd0 ], %g1
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
if ( !(~api->signals_blocked &
200d6c0: c4 04 60 cc ld [ %l1 + 0xcc ], %g2
(api->signals_pending | _POSIX_signals_Pending)) ) {
200d6c4: 82 10 c0 01 or %g3, %g1, %g1
* The first thing done is to check there are any signals to be
* processed at all. No point in doing this loop otherwise.
*/
while (1) {
_ISR_Disable( level );
if ( !(~api->signals_blocked &
200d6c8: 80 a8 40 02 andncc %g1, %g2, %g0
200d6cc: 12 bf ff de bne 200d644 <_POSIX_signals_Post_switch_extension+0x44><== NEVER TAKEN
200d6d0: 01 00 00 00 nop
(api->signals_pending | _POSIX_signals_Pending)) ) {
_ISR_Enable( level );
200d6d4: 7f ff d2 78 call 20020b4 <sparc_enable_interrupts>
200d6d8: 01 00 00 00 nop
_POSIX_signals_Check_signal( api, signo, false );
_POSIX_signals_Check_signal( api, signo, true );
}
}
_Thread_Executing->Wait.return_code = hold_errno;
200d6dc: c2 04 e0 60 ld [ %l3 + 0x60 ], %g1
200d6e0: e8 20 60 34 st %l4, [ %g1 + 0x34 ]
200d6e4: 81 c7 e0 08 ret
200d6e8: 81 e8 00 00 restore
02010f58 <_POSIX_signals_Unblock_thread>:
bool _POSIX_signals_Unblock_thread(
Thread_Control *the_thread,
int signo,
siginfo_t *info
)
{
2010f58: 9d e3 bf a0 save %sp, -96, %sp
/*
* Is the thread is specifically waiting for a signal?
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
2010f5c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1
2010f60: 05 04 00 20 sethi %hi(0x10008000), %g2
2010f64: 88 06 7f ff add %i1, -1, %g4
2010f68: 9a 08 40 02 and %g1, %g2, %o5
2010f6c: 86 10 20 01 mov 1, %g3
2010f70: 80 a3 40 02 cmp %o5, %g2
2010f74: 89 28 c0 04 sll %g3, %g4, %g4
2010f78: 02 80 00 28 be 2011018 <_POSIX_signals_Unblock_thread+0xc0>
2010f7c: c4 06 21 6c ld [ %i0 + 0x16c ], %g2
}
/*
* Thread is not waiting due to a sigwait.
*/
if ( ~api->signals_blocked & mask ) {
2010f80: c4 00 a0 cc ld [ %g2 + 0xcc ], %g2
2010f84: 80 a9 00 02 andncc %g4, %g2, %g0
2010f88: 02 80 00 22 be 2011010 <_POSIX_signals_Unblock_thread+0xb8>
2010f8c: 05 04 00 00 sethi %hi(0x10000000), %g2
* + Any other combination, do nothing.
*/
the_thread->do_post_task_switch_extension = true;
if ( _States_Is_interruptible_by_signal( the_thread->current_state ) ) {
2010f90: 80 88 40 02 btst %g1, %g2
2010f94: 02 80 00 14 be 2010fe4 <_POSIX_signals_Unblock_thread+0x8c>
2010f98: c6 2e 20 74 stb %g3, [ %i0 + 0x74 ]
the_thread->Wait.return_code = EINTR;
2010f9c: 84 10 20 04 mov 4, %g2
2010fa0: c4 26 20 34 st %g2, [ %i0 + 0x34 ]
/*
* In pthread_cond_wait, a thread will be blocking on a thread
* queue, but is also interruptible by a POSIX signal.
*/
if ( _States_Is_waiting_on_thread_queue(the_thread->current_state) )
2010fa4: 05 00 00 ef sethi %hi(0x3bc00), %g2
2010fa8: 84 10 a2 e0 or %g2, 0x2e0, %g2 ! 3bee0 <PROM_START+0x3bee0>
2010fac: 80 88 40 02 btst %g1, %g2
2010fb0: 12 80 00 32 bne 2011078 <_POSIX_signals_Unblock_thread+0x120>
2010fb4: 80 88 60 08 btst 8, %g1
_Thread_queue_Extract_with_proxy( the_thread );
else if ( _States_Is_delaying(the_thread->current_state) ){
2010fb8: 02 80 00 16 be 2011010 <_POSIX_signals_Unblock_thread+0xb8><== NEVER TAKEN
2010fbc: 01 00 00 00 nop
(void) _Watchdog_Remove( &the_thread->Timer );
2010fc0: 7f ff e4 8f call 200a1fc <_Watchdog_Remove>
2010fc4: 90 06 20 48 add %i0, 0x48, %o0
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
2010fc8: 90 10 00 18 mov %i0, %o0
2010fcc: 13 04 00 ff sethi %hi(0x1003fc00), %o1
2010fd0: b0 10 20 00 clr %i0
2010fd4: 7f ff de 59 call 2008938 <_Thread_Clear_state>
2010fd8: 92 12 63 f8 or %o1, 0x3f8, %o1
2010fdc: 81 c7 e0 08 ret
2010fe0: 81 e8 00 00 restore
_Thread_Unblock( the_thread );
}
} else if ( the_thread->current_state == STATES_READY ) {
2010fe4: 80 a0 60 00 cmp %g1, 0
2010fe8: 12 80 00 0a bne 2011010 <_POSIX_signals_Unblock_thread+0xb8><== NEVER TAKEN
2010fec: 03 00 80 7d sethi %hi(0x201f400), %g1
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2010ff0: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 ! 201f43c <_ISR_Nest_level>
2010ff4: 80 a0 60 00 cmp %g1, 0
2010ff8: 02 80 00 06 be 2011010 <_POSIX_signals_Unblock_thread+0xb8>
2010ffc: 03 00 80 7d sethi %hi(0x201f400), %g1
2011000: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
2011004: 80 a6 00 01 cmp %i0, %g1
2011008: 02 80 00 26 be 20110a0 <_POSIX_signals_Unblock_thread+0x148><== ALWAYS TAKEN
201100c: 03 00 80 7d sethi %hi(0x201f400), %g1
_ISR_Signals_to_thread_executing = true;
}
}
return false;
}
2011010: 81 c7 e0 08 ret
2011014: 91 e8 20 00 restore %g0, 0, %o0
* Is the thread is specifically waiting for a signal?
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) {
2011018: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
201101c: 80 89 00 01 btst %g4, %g1
2011020: 22 80 00 12 be,a 2011068 <_POSIX_signals_Unblock_thread+0x110>
2011024: c2 00 a0 cc ld [ %g2 + 0xcc ], %g1
the_thread->Wait.return_code = EINTR;
2011028: 82 10 20 04 mov 4, %g1
201102c: c2 26 20 34 st %g1, [ %i0 + 0x34 ]
the_info = (siginfo_t *) the_thread->Wait.return_argument;
if ( !info ) {
2011030: 80 a6 a0 00 cmp %i2, 0
2011034: 02 80 00 16 be 201108c <_POSIX_signals_Unblock_thread+0x134>
2011038: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
the_info->si_signo = signo;
the_info->si_code = SI_USER;
the_info->si_value.sival_int = 0;
} else {
*the_info = *info;
201103c: c4 06 80 00 ld [ %i2 ], %g2
2011040: c4 20 40 00 st %g2, [ %g1 ]
2011044: c4 06 a0 04 ld [ %i2 + 4 ], %g2
2011048: c4 20 60 04 st %g2, [ %g1 + 4 ]
201104c: c4 06 a0 08 ld [ %i2 + 8 ], %g2
2011050: c4 20 60 08 st %g2, [ %g1 + 8 ]
}
_Thread_queue_Extract_with_proxy( the_thread );
2011054: 90 10 00 18 mov %i0, %o0
2011058: 7f ff e1 6f call 2009614 <_Thread_queue_Extract_with_proxy>
201105c: b0 10 20 01 mov 1, %i0
return true;
2011060: 81 c7 e0 08 ret
2011064: 81 e8 00 00 restore
* Is the thread is specifically waiting for a signal?
*/
if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) {
2011068: 80 a9 00 01 andncc %g4, %g1, %g0
201106c: 12 bf ff f0 bne 201102c <_POSIX_signals_Unblock_thread+0xd4>
2011070: 82 10 20 04 mov 4, %g1
2011074: 30 bf ff e7 b,a 2011010 <_POSIX_signals_Unblock_thread+0xb8>
/*
* In pthread_cond_wait, a thread will be blocking on a thread
* queue, but is also interruptible by a POSIX signal.
*/
if ( _States_Is_waiting_on_thread_queue(the_thread->current_state) )
_Thread_queue_Extract_with_proxy( the_thread );
2011078: 90 10 00 18 mov %i0, %o0
201107c: 7f ff e1 66 call 2009614 <_Thread_queue_Extract_with_proxy>
2011080: b0 10 20 00 clr %i0
2011084: 81 c7 e0 08 ret
2011088: 81 e8 00 00 restore
the_info = (siginfo_t *) the_thread->Wait.return_argument;
if ( !info ) {
the_info->si_signo = signo;
the_info->si_code = SI_USER;
201108c: 84 10 20 01 mov 1, %g2
the_thread->Wait.return_code = EINTR;
the_info = (siginfo_t *) the_thread->Wait.return_argument;
if ( !info ) {
the_info->si_signo = signo;
2011090: f2 20 40 00 st %i1, [ %g1 ]
the_info->si_code = SI_USER;
the_info->si_value.sival_int = 0;
2011094: c0 20 60 08 clr [ %g1 + 8 ]
the_info = (siginfo_t *) the_thread->Wait.return_argument;
if ( !info ) {
the_info->si_signo = signo;
the_info->si_code = SI_USER;
2011098: 10 bf ff ef b 2011054 <_POSIX_signals_Unblock_thread+0xfc>
201109c: c4 20 60 04 st %g2, [ %g1 + 4 ]
_Thread_Unblock( the_thread );
}
} else if ( the_thread->current_state == STATES_READY ) {
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
_ISR_Signals_to_thread_executing = true;
20110a0: c6 28 60 f8 stb %g3, [ %g1 + 0xf8 ]
20110a4: 81 c7 e0 08 ret
20110a8: 91 e8 20 00 restore %g0, 0, %o0
020012c8 <_Partition_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Partition_Manager_initialization(void)
{
}
20012c8: 81 c3 e0 08 retl
02006ca8 <_RTEMS_tasks_Initialize_user_tasks_body>:
*
* Output parameters: NONE
*/
void _RTEMS_tasks_Initialize_user_tasks_body( void )
{
2006ca8: 9d e3 bf 98 save %sp, -104, %sp
rtems_initialization_tasks_table *user_tasks;
/*
* Move information into local variables
*/
user_tasks = Configuration_RTEMS_API.User_initialization_tasks_table;
2006cac: 03 00 80 7a sethi %hi(0x201e800), %g1
2006cb0: 82 10 60 30 or %g1, 0x30, %g1 ! 201e830 <Configuration_RTEMS_API>
2006cb4: e0 00 60 2c ld [ %g1 + 0x2c ], %l0
maximum = Configuration_RTEMS_API.number_of_initialization_tasks;
/*
* Verify that we have a set of user tasks to iterate
*/
if ( !user_tasks )
2006cb8: 80 a4 20 00 cmp %l0, 0
2006cbc: 02 80 00 1a be 2006d24 <_RTEMS_tasks_Initialize_user_tasks_body+0x7c>
2006cc0: e4 00 60 28 ld [ %g1 + 0x28 ], %l2
return;
/*
* Now iterate over the initialization tasks and create/start them.
*/
for ( index=0 ; index < maximum ; index++ ) {
2006cc4: 80 a4 a0 00 cmp %l2, 0
2006cc8: 02 80 00 17 be 2006d24 <_RTEMS_tasks_Initialize_user_tasks_body+0x7c><== NEVER TAKEN
2006ccc: a2 10 20 00 clr %l1
2006cd0: a6 07 bf fc add %fp, -4, %l3
return_value = rtems_task_create(
2006cd4: d0 04 00 00 ld [ %l0 ], %o0
2006cd8: d2 04 20 08 ld [ %l0 + 8 ], %o1
2006cdc: d4 04 20 04 ld [ %l0 + 4 ], %o2
2006ce0: d6 04 20 14 ld [ %l0 + 0x14 ], %o3
2006ce4: d8 04 20 0c ld [ %l0 + 0xc ], %o4
2006ce8: 7f ff ff 6e call 2006aa0 <rtems_task_create>
2006cec: 9a 10 00 13 mov %l3, %o5
user_tasks[ index ].stack_size,
user_tasks[ index ].mode_set,
user_tasks[ index ].attribute_set,
&id
);
if ( !rtems_is_status_successful( return_value ) )
2006cf0: 80 a2 20 00 cmp %o0, 0
2006cf4: 12 80 00 0f bne 2006d30 <_RTEMS_tasks_Initialize_user_tasks_body+0x88>
2006cf8: 94 10 00 08 mov %o0, %o2
_Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, true, return_value );
return_value = rtems_task_start(
2006cfc: d0 07 bf fc ld [ %fp + -4 ], %o0
2006d00: d2 04 20 10 ld [ %l0 + 0x10 ], %o1
2006d04: 40 00 00 0f call 2006d40 <rtems_task_start>
2006d08: d4 04 20 18 ld [ %l0 + 0x18 ], %o2
id,
user_tasks[ index ].entry_point,
user_tasks[ index ].argument
);
if ( !rtems_is_status_successful( return_value ) )
2006d0c: 80 a2 20 00 cmp %o0, 0
2006d10: 12 80 00 07 bne 2006d2c <_RTEMS_tasks_Initialize_user_tasks_body+0x84>
2006d14: a2 04 60 01 inc %l1
return;
/*
* Now iterate over the initialization tasks and create/start them.
*/
for ( index=0 ; index < maximum ; index++ ) {
2006d18: 80 a4 80 11 cmp %l2, %l1
2006d1c: 18 bf ff ee bgu 2006cd4 <_RTEMS_tasks_Initialize_user_tasks_body+0x2c><== NEVER TAKEN
2006d20: a0 04 20 1c add %l0, 0x1c, %l0
2006d24: 81 c7 e0 08 ret
2006d28: 81 e8 00 00 restore
id,
user_tasks[ index ].entry_point,
user_tasks[ index ].argument
);
if ( !rtems_is_status_successful( return_value ) )
_Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, true, return_value );
2006d2c: 94 10 00 08 mov %o0, %o2
2006d30: 92 10 20 01 mov 1, %o1
2006d34: 40 00 03 eb call 2007ce0 <_Internal_error_Occurred>
2006d38: 90 10 20 01 mov 1, %o0
0200de24 <_RTEMS_tasks_Post_switch_extension>:
*/
void _RTEMS_tasks_Post_switch_extension(
Thread_Control *executing
)
{
200de24: 9d e3 bf 98 save %sp, -104, %sp
RTEMS_API_Control *api;
ASR_Information *asr;
rtems_signal_set signal_set;
Modes_Control prev_mode;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
200de28: e0 06 21 68 ld [ %i0 + 0x168 ], %l0
if ( !api )
200de2c: 80 a4 20 00 cmp %l0, 0
200de30: 02 80 00 1f be 200deac <_RTEMS_tasks_Post_switch_extension+0x88><== NEVER TAKEN
200de34: 01 00 00 00 nop
* Signal Processing
*/
asr = &api->Signal;
_ISR_Disable( level );
200de38: 7f ff d0 9b call 20020a4 <sparc_disable_interrupts>
200de3c: 01 00 00 00 nop
signal_set = asr->signals_posted;
200de40: e2 04 20 14 ld [ %l0 + 0x14 ], %l1
asr->signals_posted = 0;
200de44: c0 24 20 14 clr [ %l0 + 0x14 ]
_ISR_Enable( level );
200de48: 7f ff d0 9b call 20020b4 <sparc_enable_interrupts>
200de4c: 01 00 00 00 nop
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
200de50: 80 a4 60 00 cmp %l1, 0
200de54: 32 80 00 04 bne,a 200de64 <_RTEMS_tasks_Post_switch_extension+0x40>
200de58: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200de5c: 81 c7 e0 08 ret
200de60: 81 e8 00 00 restore
return;
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200de64: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
return;
asr->nest_level += 1;
200de68: 82 00 60 01 inc %g1
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200de6c: a4 07 bf fc add %fp, -4, %l2
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
return;
asr->nest_level += 1;
200de70: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200de74: 94 10 00 12 mov %l2, %o2
200de78: 27 00 00 3f sethi %hi(0xfc00), %l3
200de7c: 40 00 0d 18 call 20112dc <rtems_task_mode>
200de80: 92 14 e3 ff or %l3, 0x3ff, %o1 ! ffff <PROM_START+0xffff>
(*asr->handler)( signal_set );
200de84: c2 04 20 0c ld [ %l0 + 0xc ], %g1
200de88: 9f c0 40 00 call %g1
200de8c: 90 10 00 11 mov %l1, %o0
asr->nest_level -= 1;
200de90: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200de94: d0 07 bf fc ld [ %fp + -4 ], %o0
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
(*asr->handler)( signal_set );
asr->nest_level -= 1;
200de98: 82 00 7f ff add %g1, -1, %g1
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200de9c: 92 14 e3 ff or %l3, 0x3ff, %o1
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
(*asr->handler)( signal_set );
asr->nest_level -= 1;
200dea0: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200dea4: 40 00 0d 0e call 20112dc <rtems_task_mode>
200dea8: 94 10 00 12 mov %l2, %o2
200deac: 81 c7 e0 08 ret
200deb0: 81 e8 00 00 restore
0200dd48 <_RTEMS_tasks_Switch_extension>:
/*
* Per Task Variables
*/
tvp = executing->task_variables;
200dd48: c2 02 21 78 ld [ %o0 + 0x178 ], %g1
while (tvp) {
200dd4c: 80 a0 60 00 cmp %g1, 0
200dd50: 22 80 00 0b be,a 200dd7c <_RTEMS_tasks_Switch_extension+0x34>
200dd54: c2 02 61 78 ld [ %o1 + 0x178 ], %g1
tvp->tval = *tvp->ptr;
200dd58: c4 00 60 04 ld [ %g1 + 4 ], %g2
*tvp->ptr = tvp->gval;
200dd5c: c6 00 60 08 ld [ %g1 + 8 ], %g3
* Per Task Variables
*/
tvp = executing->task_variables;
while (tvp) {
tvp->tval = *tvp->ptr;
200dd60: c8 00 80 00 ld [ %g2 ], %g4
200dd64: c8 20 60 0c st %g4, [ %g1 + 0xc ]
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
200dd68: c2 00 40 00 ld [ %g1 ], %g1
/*
* Per Task Variables
*/
tvp = executing->task_variables;
while (tvp) {
200dd6c: 80 a0 60 00 cmp %g1, 0
200dd70: 12 bf ff fa bne 200dd58 <_RTEMS_tasks_Switch_extension+0x10><== NEVER TAKEN
200dd74: c6 20 80 00 st %g3, [ %g2 ]
tvp->tval = *tvp->ptr;
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
200dd78: c2 02 61 78 ld [ %o1 + 0x178 ], %g1
while (tvp) {
200dd7c: 80 a0 60 00 cmp %g1, 0
200dd80: 02 80 00 0a be 200dda8 <_RTEMS_tasks_Switch_extension+0x60>
200dd84: 01 00 00 00 nop
tvp->gval = *tvp->ptr;
200dd88: c4 00 60 04 ld [ %g1 + 4 ], %g2
*tvp->ptr = tvp->tval;
200dd8c: c6 00 60 0c ld [ %g1 + 0xc ], %g3
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
while (tvp) {
tvp->gval = *tvp->ptr;
200dd90: c8 00 80 00 ld [ %g2 ], %g4
200dd94: c8 20 60 08 st %g4, [ %g1 + 8 ]
*tvp->ptr = tvp->tval;
tvp = (rtems_task_variable_t *)tvp->next;
200dd98: c2 00 40 00 ld [ %g1 ], %g1
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
while (tvp) {
200dd9c: 80 a0 60 00 cmp %g1, 0
200dda0: 12 bf ff fa bne 200dd88 <_RTEMS_tasks_Switch_extension+0x40><== NEVER TAKEN
200dda4: c6 20 80 00 st %g3, [ %g2 ]
200dda8: 81 c3 e0 08 retl
020012e8 <_Rate_monotonic_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/ratemon.h>
void _Rate_monotonic_Manager_initialization(void)
{
}
20012e8: 81 c3 e0 08 retl
0204706c <_Rate_monotonic_Timeout>:
void _Rate_monotonic_Timeout(
Objects_Id id,
void *ignored
)
{
204706c: 9d e3 bf 98 save %sp, -104, %sp
2047070: 11 00 81 d6 sethi %hi(0x2075800), %o0
2047074: 92 10 00 18 mov %i0, %o1
2047078: 90 12 21 68 or %o0, 0x168, %o0
204707c: 7f ff 21 36 call 200f554 <_Objects_Get>
2047080: 94 07 bf fc add %fp, -4, %o2
/*
* When we get here, the Timer is already off the chain so we do not
* have to worry about that -- hence no _Watchdog_Remove().
*/
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
2047084: c2 07 bf fc ld [ %fp + -4 ], %g1
2047088: 80 a0 60 00 cmp %g1, 0
204708c: 12 80 00 16 bne 20470e4 <_Rate_monotonic_Timeout+0x78> <== NEVER TAKEN
2047090: a0 10 00 08 mov %o0, %l0
case OBJECTS_LOCAL:
the_thread = the_period->owner;
2047094: d0 02 20 40 ld [ %o0 + 0x40 ], %o0
if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
2047098: 03 00 00 10 sethi %hi(0x4000), %g1
204709c: c4 02 20 10 ld [ %o0 + 0x10 ], %g2
20470a0: 80 88 80 01 btst %g2, %g1
20470a4: 22 80 00 08 be,a 20470c4 <_Rate_monotonic_Timeout+0x58>
20470a8: c2 04 20 38 ld [ %l0 + 0x38 ], %g1
the_thread->Wait.id == the_period->Object.id ) {
20470ac: c4 02 20 20 ld [ %o0 + 0x20 ], %g2
20470b0: c2 04 20 08 ld [ %l0 + 8 ], %g1
20470b4: 80 a0 80 01 cmp %g2, %g1
20470b8: 02 80 00 19 be 204711c <_Rate_monotonic_Timeout+0xb0>
20470bc: 13 04 00 ff sethi %hi(0x1003fc00), %o1
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
20470c0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1
20470c4: 80 a0 60 01 cmp %g1, 1
20470c8: 02 80 00 09 be 20470ec <_Rate_monotonic_Timeout+0x80>
20470cc: 82 10 20 04 mov 4, %g1
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else
the_period->state = RATE_MONOTONIC_EXPIRED;
20470d0: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
20470d4: 03 00 81 d3 sethi %hi(0x2074c00), %g1
20470d8: c4 00 62 40 ld [ %g1 + 0x240 ], %g2 ! 2074e40 <_Thread_Dispatch_disable_level>
20470dc: 84 00 bf ff add %g2, -1, %g2
20470e0: c4 20 62 40 st %g2, [ %g1 + 0x240 ]
20470e4: 81 c7 e0 08 ret
20470e8: 81 e8 00 00 restore
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;
20470ec: 82 10 20 03 mov 3, %g1
_Rate_monotonic_Initiate_statistics( the_period );
20470f0: 90 10 00 10 mov %l0, %o0
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;
20470f4: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
_Rate_monotonic_Initiate_statistics( the_period );
20470f8: 7f ff fe e5 call 2046c8c <_Rate_monotonic_Initiate_statistics>
20470fc: 01 00 00 00 nop
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2047100: c2 04 20 3c ld [ %l0 + 0x3c ], %g1
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2047104: 92 04 20 10 add %l0, 0x10, %o1
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2047108: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
204710c: 11 00 81 d3 sethi %hi(0x2074c00), %o0
2047110: 7f ff 28 7e call 2011308 <_Watchdog_Insert>
2047114: 90 12 23 20 or %o0, 0x320, %o0 ! 2074f20 <_Watchdog_Ticks_chain>
2047118: 30 bf ff ef b,a 20470d4 <_Rate_monotonic_Timeout+0x68>
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
204711c: 7f ff 22 9d call 200fb90 <_Thread_Clear_state>
2047120: 92 12 63 f8 or %o1, 0x3f8, %o1
the_thread = the_period->owner;
if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
the_thread->Wait.id == the_period->Object.id ) {
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
2047124: 10 bf ff f5 b 20470f8 <_Rate_monotonic_Timeout+0x8c>
2047128: 90 10 00 10 mov %l0, %o0
020012d0 <_Region_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Region_Manager_initialization(void)
{
}
20012d0: 81 c3 e0 08 retl
02007958 <_TOD_Validate>:
*/
bool _TOD_Validate(
const rtems_time_of_day *the_tod
)
{
2007958: 9d e3 bf a0 save %sp, -96, %sp
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
200795c: 03 00 80 94 sethi %hi(0x2025000), %g1
if ((!the_tod) ||
2007960: 80 a6 20 00 cmp %i0, 0
2007964: 02 80 00 2e be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
2007968: d2 00 60 74 ld [ %g1 + 0x74 ], %o1
200796c: 11 00 03 d0 sethi %hi(0xf4000), %o0
2007970: 40 00 62 b2 call 2020438 <.udiv>
2007974: 90 12 22 40 or %o0, 0x240, %o0 ! f4240 <PROM_START+0xf4240>
(the_tod->ticks >= ticks_per_second) ||
2007978: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
200797c: 80 a2 00 01 cmp %o0, %g1
2007980: 08 80 00 27 bleu 2007a1c <_TOD_Validate+0xc4>
2007984: 01 00 00 00 nop
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
2007988: c2 06 20 14 ld [ %i0 + 0x14 ], %g1
200798c: 80 a0 60 3b cmp %g1, 0x3b
2007990: 18 80 00 23 bgu 2007a1c <_TOD_Validate+0xc4>
2007994: 01 00 00 00 nop
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
2007998: c2 06 20 10 ld [ %i0 + 0x10 ], %g1
200799c: 80 a0 60 3b cmp %g1, 0x3b
20079a0: 18 80 00 1f bgu 2007a1c <_TOD_Validate+0xc4>
20079a4: 01 00 00 00 nop
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
20079a8: c2 06 20 0c ld [ %i0 + 0xc ], %g1
20079ac: 80 a0 60 17 cmp %g1, 0x17
20079b0: 18 80 00 1b bgu 2007a1c <_TOD_Validate+0xc4>
20079b4: 01 00 00 00 nop
(the_tod->month == 0) ||
20079b8: c2 06 20 04 ld [ %i0 + 4 ], %g1
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079bc: 80 a0 60 00 cmp %g1, 0
20079c0: 02 80 00 17 be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
20079c4: 80 a0 60 0c cmp %g1, 0xc
20079c8: 18 80 00 15 bgu 2007a1c <_TOD_Validate+0xc4>
20079cc: 01 00 00 00 nop
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
20079d0: c4 06 00 00 ld [ %i0 ], %g2
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079d4: 80 a0 a7 c3 cmp %g2, 0x7c3
20079d8: 08 80 00 11 bleu 2007a1c <_TOD_Validate+0xc4>
20079dc: 01 00 00 00 nop
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
20079e0: c6 06 20 08 ld [ %i0 + 8 ], %g3
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079e4: 80 a0 e0 00 cmp %g3, 0
20079e8: 02 80 00 0d be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
20079ec: 80 88 a0 03 btst 3, %g2
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
return false;
if ( (the_tod->year % 4) == 0 )
20079f0: 32 80 00 0d bne,a 2007a24 <_TOD_Validate+0xcc>
20079f4: 83 28 60 02 sll %g1, 2, %g1
days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];
20079f8: 82 00 60 0d add %g1, 0xd, %g1
20079fc: 05 00 80 8d sethi %hi(0x2023400), %g2
2007a00: 83 28 60 02 sll %g1, 2, %g1
2007a04: 84 10 a1 b4 or %g2, 0x1b4, %g2
2007a08: c2 00 80 01 ld [ %g2 + %g1 ], %g1
* false - if the the_tod is invalid
*
* NOTE: This routine only works for leap-years through 2099.
*/
bool _TOD_Validate(
2007a0c: 80 a0 40 03 cmp %g1, %g3
2007a10: b0 60 3f ff subx %g0, -1, %i0
2007a14: 81 c7 e0 08 ret
2007a18: 81 e8 00 00 restore
if ( the_tod->day > days_in_month )
return false;
return true;
}
2007a1c: 81 c7 e0 08 ret
2007a20: 91 e8 20 00 restore %g0, 0, %o0
return false;
if ( (the_tod->year % 4) == 0 )
days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];
else
days_in_month = _TOD_Days_per_month[ 0 ][ the_tod->month ];
2007a24: 05 00 80 8d sethi %hi(0x2023400), %g2
2007a28: 84 10 a1 b4 or %g2, 0x1b4, %g2 ! 20235b4 <_TOD_Days_per_month>
2007a2c: 10 bf ff f8 b 2007a0c <_TOD_Validate+0xb4>
2007a30: c2 00 80 01 ld [ %g2 + %g1 ], %g1
02008728 <_Thread_Change_priority>:
void _Thread_Change_priority(
Thread_Control *the_thread,
Priority_Control new_priority,
bool prepend_it
)
{
2008728: 9d e3 bf a0 save %sp, -96, %sp
*/
/*
* Save original state
*/
original_state = the_thread->current_state;
200872c: e2 06 20 10 ld [ %i0 + 0x10 ], %l1
/*
* Set a transient state for the thread so it is pulled off the Ready chains.
* This will prevent it from being scheduled no matter what happens in an
* ISR.
*/
_Thread_Set_transient( the_thread );
2008730: 40 00 04 90 call 2009970 <_Thread_Set_transient>
2008734: 90 10 00 18 mov %i0, %o0
/*
* Do not bother recomputing all the priority related information if
* we are not REALLY changing priority.
*/
if ( the_thread->current_priority != new_priority )
2008738: c2 06 20 14 ld [ %i0 + 0x14 ], %g1
200873c: 80 a0 40 19 cmp %g1, %i1
2008740: 02 80 00 05 be 2008754 <_Thread_Change_priority+0x2c>
2008744: a0 10 00 18 mov %i0, %l0
_Thread_Set_priority( the_thread, new_priority );
2008748: 92 10 00 19 mov %i1, %o1
200874c: 40 00 04 0d call 2009780 <_Thread_Set_priority>
2008750: 90 10 00 18 mov %i0, %o0
_ISR_Disable( level );
2008754: 7f ff e6 54 call 20020a4 <sparc_disable_interrupts>
2008758: 01 00 00 00 nop
200875c: b0 10 00 08 mov %o0, %i0
/*
* If the thread has more than STATES_TRANSIENT set, then it is blocked,
* If it is blocked on a thread queue, then we need to requeue it.
*/
state = the_thread->current_state;
2008760: e4 04 20 10 ld [ %l0 + 0x10 ], %l2
if ( state != STATES_TRANSIENT ) {
2008764: 80 a4 a0 04 cmp %l2, 4
2008768: 02 80 00 18 be 20087c8 <_Thread_Change_priority+0xa0>
200876c: 80 8c 60 04 btst 4, %l1
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) )
2008770: 02 80 00 0b be 200879c <_Thread_Change_priority+0x74> <== ALWAYS TAKEN
2008774: 82 0c bf fb and %l2, -5, %g1
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
_ISR_Enable( level );
2008778: 7f ff e6 4f call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
200877c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ( _States_Is_waiting_on_thread_queue( state ) ) {
2008780: 03 00 00 ef sethi %hi(0x3bc00), %g1 <== NOT EXECUTED
2008784: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0><== NOT EXECUTED
2008788: 80 8c 80 01 btst %l2, %g1 <== NOT EXECUTED
200878c: 32 80 00 0d bne,a 20087c0 <_Thread_Change_priority+0x98> <== NOT EXECUTED
2008790: f0 04 20 44 ld [ %l0 + 0x44 ], %i0 <== NOT EXECUTED
2008794: 81 c7 e0 08 ret
2008798: 81 e8 00 00 restore
*/
state = the_thread->current_state;
if ( state != STATES_TRANSIENT ) {
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) )
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
200879c: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
_ISR_Enable( level );
20087a0: 7f ff e6 45 call 20020b4 <sparc_enable_interrupts>
20087a4: 90 10 00 18 mov %i0, %o0
if ( _States_Is_waiting_on_thread_queue( state ) ) {
20087a8: 03 00 00 ef sethi %hi(0x3bc00), %g1
20087ac: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0>
20087b0: 80 8c 80 01 btst %l2, %g1
20087b4: 02 bf ff f8 be 2008794 <_Thread_Change_priority+0x6c>
20087b8: 01 00 00 00 nop
_Thread_queue_Requeue( the_thread->Wait.queue, the_thread );
20087bc: f0 04 20 44 ld [ %l0 + 0x44 ], %i0
20087c0: 40 00 03 c0 call 20096c0 <_Thread_queue_Requeue>
20087c4: 93 e8 00 10 restore %g0, %l0, %o1
}
return;
}
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) ) {
20087c8: 12 80 00 14 bne 2008818 <_Thread_Change_priority+0xf0> <== NEVER TAKEN
20087cc: 23 00 80 7d sethi %hi(0x201f400), %l1
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
20087d0: c2 04 20 90 ld [ %l0 + 0x90 ], %g1
20087d4: c4 14 20 96 lduh [ %l0 + 0x96 ], %g2
20087d8: c6 10 40 00 lduh [ %g1 ], %g3
* Interrupts are STILL disabled.
* We now know the thread will be in the READY state when we remove
* the TRANSIENT state. So we have to place it on the appropriate
* Ready Queue with interrupts off.
*/
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
20087dc: c0 24 20 10 clr [ %l0 + 0x10 ]
20087e0: 84 10 c0 02 or %g3, %g2, %g2
20087e4: c4 30 40 00 sth %g2, [ %g1 ]
_Priority_Major_bit_map |= the_priority_map->ready_major;
20087e8: c4 14 60 54 lduh [ %l1 + 0x54 ], %g2
20087ec: c2 14 20 94 lduh [ %l0 + 0x94 ], %g1
_Priority_Add_to_bit_map( &the_thread->Priority_map );
if ( prepend_it )
20087f0: 80 8e a0 ff btst 0xff, %i2
20087f4: 82 10 80 01 or %g2, %g1, %g1
20087f8: c2 34 60 54 sth %g1, [ %l1 + 0x54 ]
20087fc: 02 80 00 48 be 200891c <_Thread_Change_priority+0x1f4>
2008800: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
)
{
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
2008804: c4 00 40 00 ld [ %g1 ], %g2
Chain_Node *the_node
)
{
Chain_Node *before_node;
the_node->previous = after_node;
2008808: c2 24 20 04 st %g1, [ %l0 + 4 ]
before_node = after_node->next;
after_node->next = the_node;
200880c: e0 20 40 00 st %l0, [ %g1 ]
the_node->next = before_node;
before_node->previous = the_node;
2008810: e0 20 a0 04 st %l0, [ %g2 + 4 ]
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
after_node->next = the_node;
the_node->next = before_node;
2008814: c4 24 00 00 st %g2, [ %l0 ]
_Chain_Prepend_unprotected( the_thread->ready, &the_thread->Object.Node );
else
_Chain_Append_unprotected( the_thread->ready, &the_thread->Object.Node );
}
_ISR_Flash( level );
2008818: 7f ff e6 27 call 20020b4 <sparc_enable_interrupts>
200881c: 90 10 00 18 mov %i0, %o0
2008820: 7f ff e6 21 call 20020a4 <sparc_disable_interrupts>
2008824: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
2008828: c2 14 60 54 lduh [ %l1 + 0x54 ], %g1
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
_Thread_Ready_chain[ _Priority_Get_highest() ].first;
200882c: 05 00 80 7c sethi %hi(0x201f000), %g2
2008830: 83 28 60 10 sll %g1, 0x10, %g1
2008834: da 00 a2 f4 ld [ %g2 + 0x2f4 ], %o5
2008838: 85 30 60 10 srl %g1, 0x10, %g2
200883c: 80 a0 a0 ff cmp %g2, 0xff
2008840: 08 80 00 27 bleu 20088dc <_Thread_Change_priority+0x1b4>
2008844: 07 00 80 75 sethi %hi(0x201d400), %g3
2008848: 83 30 60 18 srl %g1, 0x18, %g1
200884c: 86 10 e2 28 or %g3, 0x228, %g3
2008850: c4 08 c0 01 ldub [ %g3 + %g1 ], %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
2008854: 09 00 80 7d sethi %hi(0x201f400), %g4
2008858: 85 28 a0 10 sll %g2, 0x10, %g2
200885c: 88 11 20 d0 or %g4, 0xd0, %g4
2008860: 83 30 a0 0f srl %g2, 0xf, %g1
2008864: c2 11 00 01 lduh [ %g4 + %g1 ], %g1
2008868: 83 28 60 10 sll %g1, 0x10, %g1
200886c: 89 30 60 10 srl %g1, 0x10, %g4
2008870: 80 a1 20 ff cmp %g4, 0xff
2008874: 18 80 00 28 bgu 2008914 <_Thread_Change_priority+0x1ec>
2008878: 83 30 60 18 srl %g1, 0x18, %g1
200887c: c2 08 c0 04 ldub [ %g3 + %g4 ], %g1
2008880: 82 00 60 08 add %g1, 8, %g1
* ready thread.
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
2008884: 85 30 a0 0c srl %g2, 0xc, %g2
2008888: 83 28 60 10 sll %g1, 0x10, %g1
200888c: 83 30 60 10 srl %g1, 0x10, %g1
2008890: 82 00 40 02 add %g1, %g2, %g1
2008894: 85 28 60 04 sll %g1, 4, %g2
2008898: 83 28 60 02 sll %g1, 2, %g1
200889c: 82 20 80 01 sub %g2, %g1, %g1
20088a0: c2 03 40 01 ld [ %o5 + %g1 ], %g1
* is also the heir thread, and false otherwise.
*/
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing_also_the_heir( void )
{
return ( _Thread_Executing == _Thread_Heir );
20088a4: 05 00 80 7d sethi %hi(0x201f400), %g2
20088a8: c4 00 a0 60 ld [ %g2 + 0x60 ], %g2 ! 201f460 <_Thread_Executing>
* ready thread.
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
20088ac: 07 00 80 7d sethi %hi(0x201f400), %g3
* We altered the set of thread priorities. So let's figure out
* who is the heir and if we need to switch to them.
*/
_Thread_Calculate_heir();
if ( !_Thread_Is_executing_also_the_heir() &&
20088b0: 80 a0 40 02 cmp %g1, %g2
20088b4: 02 80 00 08 be 20088d4 <_Thread_Change_priority+0x1ac>
20088b8: c2 20 e0 30 st %g1, [ %g3 + 0x30 ]
_Thread_Executing->is_preemptible )
20088bc: c2 08 a0 75 ldub [ %g2 + 0x75 ], %g1
20088c0: 80 a0 60 00 cmp %g1, 0
20088c4: 02 80 00 04 be 20088d4 <_Thread_Change_priority+0x1ac>
20088c8: 84 10 20 01 mov 1, %g2
_Context_Switch_necessary = true;
20088cc: 03 00 80 7d sethi %hi(0x201f400), %g1
20088d0: c4 28 60 70 stb %g2, [ %g1 + 0x70 ] ! 201f470 <_Context_Switch_necessary>
_ISR_Enable( level );
20088d4: 7f ff e5 f8 call 20020b4 <sparc_enable_interrupts>
20088d8: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
20088dc: 86 10 e2 28 or %g3, 0x228, %g3
20088e0: c4 08 c0 02 ldub [ %g3 + %g2 ], %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
20088e4: 09 00 80 7d sethi %hi(0x201f400), %g4
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
20088e8: 84 00 a0 08 add %g2, 8, %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
20088ec: 88 11 20 d0 or %g4, 0xd0, %g4
20088f0: 85 28 a0 10 sll %g2, 0x10, %g2
20088f4: 83 30 a0 0f srl %g2, 0xf, %g1
20088f8: c2 11 00 01 lduh [ %g4 + %g1 ], %g1
20088fc: 83 28 60 10 sll %g1, 0x10, %g1
2008900: 89 30 60 10 srl %g1, 0x10, %g4
2008904: 80 a1 20 ff cmp %g4, 0xff
2008908: 28 bf ff de bleu,a 2008880 <_Thread_Change_priority+0x158>
200890c: c2 08 c0 04 ldub [ %g3 + %g4 ], %g1
2008910: 83 30 60 18 srl %g1, 0x18, %g1
2008914: 10 bf ff dc b 2008884 <_Thread_Change_priority+0x15c>
2008918: c2 08 c0 01 ldub [ %g3 + %g1 ], %g1
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
200891c: 84 00 60 04 add %g1, 4, %g2
2008920: c4 24 00 00 st %g2, [ %l0 ]
old_last_node = the_chain->last;
2008924: c4 00 60 08 ld [ %g1 + 8 ], %g2
the_chain->last = the_node;
2008928: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
200892c: c4 24 20 04 st %g2, [ %l0 + 4 ]
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
2008930: 10 bf ff ba b 2008818 <_Thread_Change_priority+0xf0>
2008934: e0 20 80 00 st %l0, [ %g2 ]
02008938 <_Thread_Clear_state>:
void _Thread_Clear_state(
Thread_Control *the_thread,
States_Control state
)
{
2008938: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
States_Control current_state;
_ISR_Disable( level );
200893c: 7f ff e5 da call 20020a4 <sparc_disable_interrupts>
2008940: a0 10 00 18 mov %i0, %l0
2008944: b0 10 00 08 mov %o0, %i0
current_state = the_thread->current_state;
2008948: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
if ( current_state & state ) {
200894c: 80 8e 40 01 btst %i1, %g1
2008950: 02 80 00 06 be 2008968 <_Thread_Clear_state+0x30>
2008954: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE States_Control _States_Clear (
States_Control states_to_clear,
States_Control current_state
)
{
return (current_state & ~states_to_clear);
2008958: b2 28 40 19 andn %g1, %i1, %i1
current_state =
the_thread->current_state = _States_Clear( state, current_state );
if ( _States_Is_ready( current_state ) ) {
200895c: 80 a6 60 00 cmp %i1, 0
2008960: 02 80 00 04 be 2008970 <_Thread_Clear_state+0x38>
2008964: f2 24 20 10 st %i1, [ %l0 + 0x10 ]
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
}
}
}
_ISR_Enable( level );
2008968: 7f ff e5 d3 call 20020b4 <sparc_enable_interrupts>
200896c: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
2008970: c4 04 20 90 ld [ %l0 + 0x90 ], %g2
if ( _States_Is_ready( current_state ) ) {
_Priority_Add_to_bit_map( &the_thread->Priority_map );
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
2008974: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
2008978: c8 10 80 00 lduh [ %g2 ], %g4
200897c: c6 14 20 96 lduh [ %l0 + 0x96 ], %g3
2008980: 86 11 00 03 or %g4, %g3, %g3
2008984: c6 30 80 00 sth %g3, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
2008988: 84 00 60 04 add %g1, 4, %g2
_Priority_Major_bit_map |= the_priority_map->ready_major;
200898c: c8 14 20 94 lduh [ %l0 + 0x94 ], %g4
2008990: c4 24 00 00 st %g2, [ %l0 ]
2008994: 07 00 80 7d sethi %hi(0x201f400), %g3
old_last_node = the_chain->last;
2008998: c4 00 60 08 ld [ %g1 + 8 ], %g2
200899c: da 10 e0 54 lduh [ %g3 + 0x54 ], %o5
the_chain->last = the_node;
20089a0: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
20089a4: c4 24 20 04 st %g2, [ %l0 + 4 ]
20089a8: 82 13 40 04 or %o5, %g4, %g1
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
20089ac: e0 20 80 00 st %l0, [ %g2 ]
20089b0: c2 30 e0 54 sth %g1, [ %g3 + 0x54 ]
_ISR_Flash( level );
20089b4: 7f ff e5 c0 call 20020b4 <sparc_enable_interrupts>
20089b8: 01 00 00 00 nop
20089bc: 7f ff e5 ba call 20020a4 <sparc_disable_interrupts>
20089c0: 01 00 00 00 nop
* a context switch.
* Pseudo-ISR case:
* Even if the thread isn't preemptible, if the new heir is
* a pseudo-ISR system task, we need to do a context switch.
*/
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
20089c4: 03 00 80 7d sethi %hi(0x201f400), %g1
20089c8: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 ! 201f430 <_Thread_Heir>
20089cc: c4 04 20 14 ld [ %l0 + 0x14 ], %g2
20089d0: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
20089d4: 80 a0 80 03 cmp %g2, %g3
20089d8: 1a bf ff e4 bcc 2008968 <_Thread_Clear_state+0x30>
20089dc: 07 00 80 7d sethi %hi(0x201f400), %g3
_Thread_Heir = the_thread;
if ( _Thread_Executing->is_preemptible ||
20089e0: c6 00 e0 60 ld [ %g3 + 0x60 ], %g3 ! 201f460 <_Thread_Executing>
* Pseudo-ISR case:
* Even if the thread isn't preemptible, if the new heir is
* a pseudo-ISR system task, we need to do a context switch.
*/
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
_Thread_Heir = the_thread;
20089e4: e0 20 60 30 st %l0, [ %g1 + 0x30 ]
if ( _Thread_Executing->is_preemptible ||
20089e8: c2 08 e0 75 ldub [ %g3 + 0x75 ], %g1
20089ec: 80 a0 60 00 cmp %g1, 0
20089f0: 32 80 00 05 bne,a 2008a04 <_Thread_Clear_state+0xcc>
20089f4: 84 10 20 01 mov 1, %g2
20089f8: 80 a0 a0 00 cmp %g2, 0
20089fc: 12 bf ff db bne 2008968 <_Thread_Clear_state+0x30> <== ALWAYS TAKEN
2008a00: 84 10 20 01 mov 1, %g2
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
2008a04: 03 00 80 7d sethi %hi(0x201f400), %g1
2008a08: c4 28 60 70 stb %g2, [ %g1 + 0x70 ] ! 201f470 <_Context_Switch_necessary>
}
}
}
_ISR_Enable( level );
2008a0c: 7f ff e5 aa call 20020b4 <sparc_enable_interrupts>
2008a10: 81 e8 00 00 restore
02008bc0 <_Thread_Delay_ended>:
void _Thread_Delay_ended(
Objects_Id id,
void *ignored __attribute__((unused))
)
{
2008bc0: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
2008bc4: 90 10 00 18 mov %i0, %o0
2008bc8: 40 00 00 84 call 2008dd8 <_Thread_Get>
2008bcc: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2008bd0: c2 07 bf fc ld [ %fp + -4 ], %g1
2008bd4: 80 a0 60 00 cmp %g1, 0
2008bd8: 12 80 00 08 bne 2008bf8 <_Thread_Delay_ended+0x38> <== NEVER TAKEN
2008bdc: 13 04 00 00 sethi %hi(0x10000000), %o1
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_Clear_state(
2008be0: 7f ff ff 56 call 2008938 <_Thread_Clear_state>
2008be4: 92 12 60 18 or %o1, 0x18, %o1 ! 10000018 <RAM_END+0xdc00018>
2008be8: 03 00 80 7c sethi %hi(0x201f000), %g1
2008bec: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
2008bf0: 84 00 bf ff add %g2, -1, %g2
2008bf4: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
2008bf8: 81 c7 e0 08 ret
2008bfc: 81 e8 00 00 restore
02008c00 <_Thread_Dispatch>:
* dispatch thread
* no dispatch thread
*/
void _Thread_Dispatch( void )
{
2008c00: 9d e3 bf 90 save %sp, -112, %sp
Thread_Control *executing;
Thread_Control *heir;
ISR_Level level;
executing = _Thread_Executing;
2008c04: 2b 00 80 7d sethi %hi(0x201f400), %l5
_ISR_Disable( level );
2008c08: 7f ff e5 27 call 20020a4 <sparc_disable_interrupts>
2008c0c: e0 05 60 60 ld [ %l5 + 0x60 ], %l0 ! 201f460 <_Thread_Executing>
while ( _Context_Switch_necessary == true ) {
2008c10: 2d 00 80 7d sethi %hi(0x201f400), %l6
2008c14: c2 0d a0 70 ldub [ %l6 + 0x70 ], %g1 ! 201f470 <_Context_Switch_necessary>
2008c18: 80 a0 60 00 cmp %g1, 0
2008c1c: 02 80 00 50 be 2008d5c <_Thread_Dispatch+0x15c>
2008c20: 33 00 80 7d sethi %hi(0x201f400), %i1
2008c24: 25 00 80 7d sethi %hi(0x201f400), %l2
2008c28: 35 00 80 7d sethi %hi(0x201f400), %i2
2008c2c: a4 14 a0 68 or %l2, 0x68, %l2
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
2008c30: 31 00 80 7c sethi %hi(0x201f000), %i0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
RTEMS_INLINE_ROUTINE bool _Thread_Is_allocated_fp (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Allocated_fp );
2008c34: 2f 00 80 7d sethi %hi(0x201f400), %l7
2008c38: 03 00 80 7c sethi %hi(0x201f000), %g1
2008c3c: ac 15 a0 70 or %l6, 0x70, %l6
2008c40: aa 15 60 60 or %l5, 0x60, %l5
2008c44: b2 16 60 30 or %i1, 0x30, %i1
2008c48: b4 16 a0 2c or %i2, 0x2c, %i2
2008c4c: b0 16 22 f8 or %i0, 0x2f8, %i0
2008c50: ae 15 e0 28 or %l7, 0x28, %l7
2008c54: b6 10 63 a0 or %g1, 0x3a0, %i3
2008c58: a8 07 bf f8 add %fp, -8, %l4
2008c5c: a6 07 bf f0 add %fp, -16, %l3
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
heir = _Thread_Heir;
_Thread_Dispatch_disable_level = 1;
2008c60: b8 10 20 01 mov 1, %i4
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
{
Timestamp_Control uptime, ran;
_TOD_Get_uptime( &uptime );
_Timestamp_Subtract(
2008c64: 10 80 00 34 b 2008d34 <_Thread_Dispatch+0x134>
2008c68: ba 10 00 12 mov %l2, %i5
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
_ISR_Enable( level );
2008c6c: 7f ff e5 12 call 20020b4 <sparc_enable_interrupts>
2008c70: 01 00 00 00 nop
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
{
Timestamp_Control uptime, ran;
_TOD_Get_uptime( &uptime );
2008c74: 40 00 15 9d call 200e2e8 <_TOD_Get_uptime>
2008c78: 90 10 00 14 mov %l4, %o0
_Timestamp_Subtract(
2008c7c: 90 10 00 1d mov %i5, %o0
2008c80: 92 10 00 14 mov %l4, %o1
2008c84: 40 00 04 21 call 2009d08 <_Timespec_Subtract>
2008c88: 94 10 00 13 mov %l3, %o2
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
2008c8c: 92 10 00 13 mov %l3, %o1
2008c90: 40 00 04 05 call 2009ca4 <_Timespec_Add_to>
2008c94: 90 04 20 84 add %l0, 0x84, %o0
_Thread_Time_of_last_context_switch = uptime;
2008c98: c4 07 bf f8 ld [ %fp + -8 ], %g2
#endif
/*
* Switch libc's task specific data.
*/
if ( _Thread_libc_reent ) {
2008c9c: c2 06 80 00 ld [ %i2 ], %g1
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
_Thread_Time_of_last_context_switch = uptime;
2008ca0: c4 24 80 00 st %g2, [ %l2 ]
2008ca4: c4 07 bf fc ld [ %fp + -4 ], %g2
if ( _Thread_libc_reent ) {
executing->libc_reent = *_Thread_libc_reent;
*_Thread_libc_reent = heir->libc_reent;
}
_User_extensions_Thread_switch( executing, heir );
2008ca8: 90 10 00 10 mov %l0, %o0
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
_Thread_Time_of_last_context_switch = uptime;
2008cac: c4 24 a0 04 st %g2, [ %l2 + 4 ]
#endif
/*
* Switch libc's task specific data.
*/
if ( _Thread_libc_reent ) {
2008cb0: 80 a0 60 00 cmp %g1, 0
2008cb4: 02 80 00 06 be 2008ccc <_Thread_Dispatch+0xcc> <== NEVER TAKEN
2008cb8: 92 10 00 11 mov %l1, %o1
executing->libc_reent = *_Thread_libc_reent;
2008cbc: c4 00 40 00 ld [ %g1 ], %g2
2008cc0: c4 24 21 64 st %g2, [ %l0 + 0x164 ]
*_Thread_libc_reent = heir->libc_reent;
2008cc4: c4 04 61 64 ld [ %l1 + 0x164 ], %g2
2008cc8: c4 20 40 00 st %g2, [ %g1 ]
}
_User_extensions_Thread_switch( executing, heir );
2008ccc: 40 00 04 d1 call 200a010 <_User_extensions_Thread_switch>
2008cd0: 01 00 00 00 nop
if ( executing->fp_context != NULL )
_Context_Save_fp( &executing->fp_context );
#endif
#endif
_Context_Switch( &executing->Registers, &heir->Registers );
2008cd4: 92 04 60 d8 add %l1, 0xd8, %o1
2008cd8: 40 00 06 1e call 200a550 <_CPU_Context_switch>
2008cdc: 90 04 20 d8 add %l0, 0xd8, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
#if ( CPU_USE_DEFERRED_FP_SWITCH == TRUE )
if ( (executing->fp_context != NULL) &&
2008ce0: c2 04 21 60 ld [ %l0 + 0x160 ], %g1
2008ce4: 80 a0 60 00 cmp %g1, 0
2008ce8: 02 80 00 0d be 2008d1c <_Thread_Dispatch+0x11c>
2008cec: 01 00 00 00 nop
2008cf0: d0 05 c0 00 ld [ %l7 ], %o0
2008cf4: 80 a4 00 08 cmp %l0, %o0
2008cf8: 02 80 00 09 be 2008d1c <_Thread_Dispatch+0x11c>
2008cfc: 80 a2 20 00 cmp %o0, 0
!_Thread_Is_allocated_fp( executing ) ) {
if ( _Thread_Allocated_fp != NULL )
2008d00: 02 80 00 04 be 2008d10 <_Thread_Dispatch+0x110>
2008d04: 01 00 00 00 nop
_Context_Save_fp( &_Thread_Allocated_fp->fp_context );
2008d08: 40 00 05 d8 call 200a468 <_CPU_Context_save_fp>
2008d0c: 90 02 21 60 add %o0, 0x160, %o0
_Context_Restore_fp( &executing->fp_context );
2008d10: 40 00 05 f3 call 200a4dc <_CPU_Context_restore_fp>
2008d14: 90 04 21 60 add %l0, 0x160, %o0
_Thread_Allocated_fp = executing;
2008d18: e0 25 c0 00 st %l0, [ %l7 ]
#endif
#endif
executing = _Thread_Executing;
_ISR_Disable( level );
2008d1c: 7f ff e4 e2 call 20020a4 <sparc_disable_interrupts>
2008d20: e0 05 40 00 ld [ %l5 ], %l0
Thread_Control *heir;
ISR_Level level;
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
2008d24: c2 0d 80 00 ldub [ %l6 ], %g1
2008d28: 80 a0 60 00 cmp %g1, 0
2008d2c: 02 80 00 0d be 2008d60 <_Thread_Dispatch+0x160>
2008d30: 03 00 80 7c sethi %hi(0x201f000), %g1
heir = _Thread_Heir;
2008d34: e2 06 40 00 ld [ %i1 ], %l1
_Thread_Dispatch_disable_level = 1;
2008d38: f8 26 c0 00 st %i4, [ %i3 ]
_Thread_Executing = heir;
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
2008d3c: c2 04 60 7c ld [ %l1 + 0x7c ], %g1
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
heir = _Thread_Heir;
_Thread_Dispatch_disable_level = 1;
_Context_Switch_necessary = false;
2008d40: c0 2d 80 00 clrb [ %l6 ]
_Thread_Executing = heir;
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
2008d44: 80 a0 60 01 cmp %g1, 1
2008d48: 12 bf ff c9 bne 2008c6c <_Thread_Dispatch+0x6c>
2008d4c: e2 25 40 00 st %l1, [ %l5 ]
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
2008d50: c2 06 00 00 ld [ %i0 ], %g1
2008d54: 10 bf ff c6 b 2008c6c <_Thread_Dispatch+0x6c>
2008d58: c2 24 60 78 st %g1, [ %l1 + 0x78 ]
executing = _Thread_Executing;
_ISR_Disable( level );
}
_Thread_Dispatch_disable_level = 0;
2008d5c: 03 00 80 7c sethi %hi(0x201f000), %g1
2008d60: c0 20 63 a0 clr [ %g1 + 0x3a0 ] ! 201f3a0 <_Thread_Dispatch_disable_level>
_ISR_Enable( level );
2008d64: 7f ff e4 d4 call 20020b4 <sparc_enable_interrupts>
2008d68: 01 00 00 00 nop
if ( _Thread_Do_post_task_switch_extension ||
2008d6c: 03 00 80 7d sethi %hi(0x201f400), %g1
2008d70: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 201f444 <_Thread_Do_post_task_switch_extension>
2008d74: 80 a0 60 00 cmp %g1, 0
2008d78: 12 80 00 06 bne 2008d90 <_Thread_Dispatch+0x190>
2008d7c: 01 00 00 00 nop
executing->do_post_task_switch_extension ) {
2008d80: c2 0c 20 74 ldub [ %l0 + 0x74 ], %g1
2008d84: 80 a0 60 00 cmp %g1, 0
2008d88: 02 80 00 04 be 2008d98 <_Thread_Dispatch+0x198>
2008d8c: 01 00 00 00 nop
executing->do_post_task_switch_extension = false;
_API_extensions_Run_postswitch();
2008d90: 7f ff f9 0e call 20071c8 <_API_extensions_Run_postswitch>
2008d94: c0 2c 20 74 clrb [ %l0 + 0x74 ]
2008d98: 81 c7 e0 08 ret
2008d9c: 81 e8 00 00 restore
02011680 <_Thread_Evaluate_mode>:
bool _Thread_Evaluate_mode( void )
{
Thread_Control *executing;
executing = _Thread_Executing;
2011680: 03 00 80 7d sethi %hi(0x201f400), %g1
2011684: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
if ( !_States_Is_ready( executing->current_state ) ||
2011688: c4 00 60 10 ld [ %g1 + 0x10 ], %g2
201168c: 80 a0 a0 00 cmp %g2, 0
2011690: 12 80 00 0b bne 20116bc <_Thread_Evaluate_mode+0x3c> <== NEVER TAKEN
2011694: 84 10 20 01 mov 1, %g2
2011698: 05 00 80 7d sethi %hi(0x201f400), %g2
201169c: c4 00 a0 30 ld [ %g2 + 0x30 ], %g2 ! 201f430 <_Thread_Heir>
20116a0: 80 a0 40 02 cmp %g1, %g2
20116a4: 02 80 00 0b be 20116d0 <_Thread_Evaluate_mode+0x50>
20116a8: 01 00 00 00 nop
( !_Thread_Is_heir( executing ) && executing->is_preemptible ) ) {
20116ac: c2 08 60 75 ldub [ %g1 + 0x75 ], %g1
20116b0: 80 a0 60 00 cmp %g1, 0
20116b4: 02 80 00 07 be 20116d0 <_Thread_Evaluate_mode+0x50> <== NEVER TAKEN
20116b8: 84 10 20 01 mov 1, %g2
_Context_Switch_necessary = true;
20116bc: 03 00 80 7d sethi %hi(0x201f400), %g1
20116c0: 90 10 20 01 mov 1, %o0
20116c4: c4 28 60 70 stb %g2, [ %g1 + 0x70 ]
return true;
20116c8: 81 c3 e0 08 retl
20116cc: 01 00 00 00 nop
}
return false;
}
20116d0: 81 c3 e0 08 retl
20116d4: 90 10 20 00 clr %o0 ! 0 <PROM_START>
020116d8 <_Thread_Handler>:
*
* Output parameters: NONE
*/
void _Thread_Handler( void )
{
20116d8: 9d e3 bf a0 save %sp, -96, %sp
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
static char doneConstructors;
char doneCons;
#endif
executing = _Thread_Executing;
20116dc: 03 00 80 7d sethi %hi(0x201f400), %g1
20116e0: e0 00 60 60 ld [ %g1 + 0x60 ], %l0 ! 201f460 <_Thread_Executing>
/*
* Some CPUs need to tinker with the call frame or registers when the
* thread actually begins to execute for the first time. This is a
* hook point where the port gets a shot at doing whatever it requires.
*/
_Context_Initialization_at_thread_begin();
20116e4: 3f 00 80 45 sethi %hi(0x2011400), %i7
20116e8: be 17 e2 d8 or %i7, 0x2d8, %i7 ! 20116d8 <_Thread_Handler>
/*
* have to put level into a register for those cpu's that use
* inline asm here
*/
level = executing->Start.isr_level;
20116ec: d0 04 20 b8 ld [ %l0 + 0xb8 ], %o0
_ISR_Set_level(level);
20116f0: 7f ff c2 71 call 20020b4 <sparc_enable_interrupts>
20116f4: 91 2a 20 08 sll %o0, 8, %o0
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
doneCons = doneConstructors;
20116f8: 03 00 80 7c sethi %hi(0x201f000), %g1
doneConstructors = 1;
20116fc: 84 10 20 01 mov 1, %g2
level = executing->Start.isr_level;
_ISR_Set_level(level);
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
doneCons = doneConstructors;
2011700: e4 08 60 52 ldub [ %g1 + 0x52 ], %l2
doneConstructors = 1;
2011704: c4 28 60 52 stb %g2, [ %g1 + 0x52 ]
#endif
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
#if ( CPU_USE_DEFERRED_FP_SWITCH == TRUE )
if ( (executing->fp_context != NULL) &&
2011708: c2 04 21 60 ld [ %l0 + 0x160 ], %g1
201170c: 80 a0 60 00 cmp %g1, 0
2011710: 02 80 00 0b be 201173c <_Thread_Handler+0x64>
2011714: 23 00 80 7d sethi %hi(0x201f400), %l1
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
RTEMS_INLINE_ROUTINE bool _Thread_Is_allocated_fp (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Allocated_fp );
2011718: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 ! 201f428 <_Thread_Allocated_fp>
201171c: 80 a4 00 08 cmp %l0, %o0
2011720: 02 80 00 07 be 201173c <_Thread_Handler+0x64>
2011724: 80 a2 20 00 cmp %o0, 0
!_Thread_Is_allocated_fp( executing ) ) {
if ( _Thread_Allocated_fp != NULL )
2011728: 22 80 00 05 be,a 201173c <_Thread_Handler+0x64>
201172c: e0 24 60 28 st %l0, [ %l1 + 0x28 ]
_Context_Save_fp( &_Thread_Allocated_fp->fp_context );
2011730: 7f ff e3 4e call 200a468 <_CPU_Context_save_fp>
2011734: 90 02 21 60 add %o0, 0x160, %o0
_Thread_Allocated_fp = executing;
2011738: e0 24 60 28 st %l0, [ %l1 + 0x28 ]
/*
* Take care that 'begin' extensions get to complete before
* 'switch' extensions can run. This means must keep dispatch
* disabled until all 'begin' extensions complete.
*/
_User_extensions_Thread_begin( executing );
201173c: 7f ff e1 b7 call 2009e18 <_User_extensions_Thread_begin>
2011740: 90 10 00 10 mov %l0, %o0
/*
* At this point, the dispatch disable level BETTER be 1.
*/
_Thread_Enable_dispatch();
2011744: 7f ff dd 97 call 2008da0 <_Thread_Enable_dispatch>
2011748: a5 2c a0 18 sll %l2, 0x18, %l2
/*
* _init could be a weak symbol and we SHOULD test it but it isn't
* in any configuration I know of and it generates a warning on every
* RTEMS target configuration. --joel (12 May 2007)
*/
if (!doneCons) /* && (volatile void *)_init) */ {
201174c: 80 a4 a0 00 cmp %l2, 0
2011750: 02 80 00 0f be 201178c <_Thread_Handler+0xb4>
2011754: 01 00 00 00 nop
INIT_NAME ();
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
2011758: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
201175c: 80 a0 60 00 cmp %g1, 0
2011760: 22 80 00 12 be,a 20117a8 <_Thread_Handler+0xd0>
2011764: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
(*(Thread_Entry_numeric) executing->Start.entry_point)(
executing->Start.numeric_argument
);
}
#if defined(RTEMS_POSIX_API)
else if ( executing->Start.prototype == THREAD_START_POINTER ) {
2011768: 80 a0 60 01 cmp %g1, 1
201176c: 22 80 00 13 be,a 20117b8 <_Thread_Handler+0xe0> <== ALWAYS TAKEN
2011770: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
* was placed in return_argument. This assumed that if it returned
* anything (which is not supporting in all APIs), then it would be
* able to fit in a (void *).
*/
_User_extensions_Thread_exitted( executing );
2011774: 7f ff e1 bd call 2009e68 <_User_extensions_Thread_exitted>
2011778: 90 10 00 10 mov %l0, %o0
_Internal_error_Occurred(
201177c: 90 10 20 00 clr %o0
2011780: 92 10 20 01 mov 1, %o1
2011784: 7f ff d9 57 call 2007ce0 <_Internal_error_Occurred>
2011788: 94 10 20 06 mov 6, %o2
* _init could be a weak symbol and we SHOULD test it but it isn't
* in any configuration I know of and it generates a warning on every
* RTEMS target configuration. --joel (12 May 2007)
*/
if (!doneCons) /* && (volatile void *)_init) */ {
INIT_NAME ();
201178c: 40 00 33 f7 call 201e768 <_init>
2011790: 01 00 00 00 nop
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
2011794: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
2011798: 80 a0 60 00 cmp %g1, 0
201179c: 12 bf ff f4 bne 201176c <_Thread_Handler+0x94>
20117a0: 80 a0 60 01 cmp %g1, 1
executing->Wait.return_argument =
(*(Thread_Entry_numeric) executing->Start.entry_point)(
20117a4: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
20117a8: 9f c0 40 00 call %g1
20117ac: d0 04 20 a8 ld [ %l0 + 0xa8 ], %o0
INIT_NAME ();
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
executing->Wait.return_argument =
20117b0: 10 bf ff f1 b 2011774 <_Thread_Handler+0x9c>
20117b4: d0 24 20 28 st %o0, [ %l0 + 0x28 ]
);
}
#if defined(RTEMS_POSIX_API)
else if ( executing->Start.prototype == THREAD_START_POINTER ) {
executing->Wait.return_argument =
(*(Thread_Entry_pointer) executing->Start.entry_point)(
20117b8: 9f c0 40 00 call %g1
20117bc: d0 04 20 a4 ld [ %l0 + 0xa4 ], %o0
executing->Start.numeric_argument
);
}
#if defined(RTEMS_POSIX_API)
else if ( executing->Start.prototype == THREAD_START_POINTER ) {
executing->Wait.return_argument =
20117c0: 10 bf ff ed b 2011774 <_Thread_Handler+0x9c>
20117c4: d0 24 20 28 st %o0, [ %l0 + 0x28 ]
02008e84 <_Thread_Initialize>:
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008e84: 9d e3 bf a0 save %sp, -96, %sp
2008e88: 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;
2008e8c: c0 26 61 68 clr [ %i1 + 0x168 ]
2008e90: c0 26 61 6c clr [ %i1 + 0x16c ]
2008e94: c0 26 61 70 clr [ %i1 + 0x170 ]
extensions_area = NULL;
the_thread->libc_reent = NULL;
2008e98: c0 26 61 64 clr [ %i1 + 0x164 ]
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008e9c: e0 00 40 00 ld [ %g1 ], %l0
if ( !actual_stack_size || actual_stack_size < stack_size )
return false; /* stack allocation failed */
stack = the_thread->Start.stack;
#else
if ( !stack_area ) {
2008ea0: 80 a6 a0 00 cmp %i2, 0
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008ea4: e2 07 a0 60 ld [ %fp + 0x60 ], %l1
if ( !actual_stack_size || actual_stack_size < stack_size )
return false; /* stack allocation failed */
stack = the_thread->Start.stack;
#else
if ( !stack_area ) {
2008ea8: 02 80 00 82 be 20090b0 <_Thread_Initialize+0x22c>
2008eac: e4 0f a0 5f ldub [ %fp + 0x5f ], %l2
stack = the_thread->Start.stack;
the_thread->Start.core_allocated_stack = true;
} else {
stack = stack_area;
actual_stack_size = stack_size;
the_thread->Start.core_allocated_stack = false;
2008eb0: c0 2e 60 c0 clrb [ %i1 + 0xc0 ]
2008eb4: 90 10 00 1b mov %i3, %o0
Stack_Control *the_stack,
void *starting_address,
size_t size
)
{
the_stack->area = starting_address;
2008eb8: f4 26 60 c8 st %i2, [ %i1 + 0xc8 ]
the_stack->size = size;
2008ebc: d0 26 60 c4 st %o0, [ %i1 + 0xc4 ]
/*
* Allocate the floating point area for this thread
*/
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( is_fp ) {
2008ec0: 80 8f 20 ff btst 0xff, %i4
2008ec4: 82 10 20 00 clr %g1
2008ec8: 12 80 00 56 bne 2009020 <_Thread_Initialize+0x19c>
2008ecc: b4 10 20 00 clr %i2
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008ed0: 39 00 80 7d sethi %hi(0x201f400), %i4
2008ed4: c4 07 20 40 ld [ %i4 + 0x40 ], %g2 ! 201f440 <_Thread_Maximum_extensions>
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
the_thread->Start.fp_context = fp_area;
2008ed8: c2 26 60 cc st %g1, [ %i1 + 0xcc ]
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;
2008edc: c2 26 61 60 st %g1, [ %i1 + 0x160 ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2008ee0: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
2008ee4: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2008ee8: c0 26 60 68 clr [ %i1 + 0x68 ]
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008eec: 80 a0 a0 00 cmp %g2, 0
2008ef0: 12 80 00 5c bne 2009060 <_Thread_Initialize+0x1dc>
2008ef4: c0 26 60 6c clr [ %i1 + 0x6c ]
(_Thread_Maximum_extensions + 1) * sizeof( void * )
);
if ( !extensions_area )
goto failed;
}
the_thread->extensions = (void **) extensions_area;
2008ef8: c0 26 61 74 clr [ %i1 + 0x174 ]
2008efc: b6 10 20 00 clr %i3
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
the_thread->Start.budget_callout = budget_callout;
2008f00: c2 07 a0 64 ld [ %fp + 0x64 ], %g1
/*
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
2008f04: e4 2e 60 ac stb %l2, [ %i1 + 0xac ]
the_thread->Start.budget_algorithm = budget_algorithm;
the_thread->Start.budget_callout = budget_callout;
2008f08: c2 26 60 b4 st %g1, [ %i1 + 0xb4 ]
switch ( budget_algorithm ) {
2008f0c: 80 a4 60 02 cmp %l1, 2
2008f10: 12 80 00 05 bne 2008f24 <_Thread_Initialize+0xa0>
2008f14: e2 26 60 b0 st %l1, [ %i1 + 0xb0 ]
case THREAD_CPU_BUDGET_ALGORITHM_NONE:
case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE:
break;
#if defined(RTEMS_SCORE_THREAD_ENABLE_EXHAUST_TIMESLICE)
case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE:
the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
2008f18: 03 00 80 7c sethi %hi(0x201f000), %g1
2008f1c: c2 00 62 f8 ld [ %g1 + 0x2f8 ], %g1 ! 201f2f8 <_Thread_Ticks_per_timeslice>
2008f20: c2 26 60 78 st %g1, [ %i1 + 0x78 ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
break;
#endif
}
the_thread->Start.isr_level = isr_level;
2008f24: c2 07 a0 68 ld [ %fp + 0x68 ], %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 );
2008f28: 92 10 00 1d mov %i5, %o1
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
break;
#endif
}
the_thread->Start.isr_level = isr_level;
2008f2c: c2 26 60 b8 st %g1, [ %i1 + 0xb8 ]
the_thread->current_state = STATES_DORMANT;
2008f30: 82 10 20 01 mov 1, %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 );
2008f34: 90 10 00 19 mov %i1, %o0
#endif
}
the_thread->Start.isr_level = isr_level;
the_thread->current_state = STATES_DORMANT;
2008f38: c2 26 60 10 st %g1, [ %i1 + 0x10 ]
the_thread->Wait.queue = NULL;
2008f3c: c0 26 60 44 clr [ %i1 + 0x44 ]
the_thread->resource_count = 0;
2008f40: c0 26 60 1c clr [ %i1 + 0x1c ]
#if defined(RTEMS_ITRON_API)
the_thread->suspend_count = 0;
#endif
the_thread->real_priority = priority;
2008f44: fa 26 60 18 st %i5, [ %i1 + 0x18 ]
the_thread->Start.initial_priority = priority;
_Thread_Set_priority( the_thread, priority );
2008f48: 40 00 02 0e call 2009780 <_Thread_Set_priority>
2008f4c: fa 26 60 bc st %i5, [ %i1 + 0xbc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2008f50: c2 16 60 0a lduh [ %i1 + 0xa ], %g1
2008f54: c4 06 20 1c ld [ %i0 + 0x1c ], %g2
2008f58: 83 28 60 02 sll %g1, 2, %g1
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
2008f5c: e0 26 60 0c st %l0, [ %i1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2008f60: 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 );
2008f64: c0 26 60 84 clr [ %i1 + 0x84 ]
2008f68: 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 );
2008f6c: 90 10 00 19 mov %i1, %o0
2008f70: 40 00 03 e5 call 2009f04 <_User_extensions_Thread_create>
2008f74: b0 10 20 01 mov 1, %i0
if ( extension_status )
2008f78: 80 8a 20 ff btst 0xff, %o0
2008f7c: 12 80 00 27 bne 2009018 <_Thread_Initialize+0x194>
2008f80: 01 00 00 00 nop
return true;
failed:
if ( the_thread->libc_reent )
2008f84: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
2008f88: 80 a2 20 00 cmp %o0, 0
2008f8c: 22 80 00 05 be,a 2008fa0 <_Thread_Initialize+0x11c>
2008f90: d0 06 61 68 ld [ %i1 + 0x168 ], %o0
_Workspace_Free( the_thread->libc_reent );
2008f94: 40 00 05 12 call 200a3dc <_Workspace_Free>
2008f98: 01 00 00 00 nop
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
if ( the_thread->API_Extensions[i] )
2008f9c: d0 06 61 68 ld [ %i1 + 0x168 ], %o0
2008fa0: 80 a2 20 00 cmp %o0, 0
2008fa4: 22 80 00 05 be,a 2008fb8 <_Thread_Initialize+0x134>
2008fa8: d0 06 61 6c ld [ %i1 + 0x16c ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2008fac: 40 00 05 0c call 200a3dc <_Workspace_Free>
2008fb0: 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] )
2008fb4: d0 06 61 6c ld [ %i1 + 0x16c ], %o0
2008fb8: 80 a2 20 00 cmp %o0, 0
2008fbc: 22 80 00 05 be,a 2008fd0 <_Thread_Initialize+0x14c>
2008fc0: d0 06 61 70 ld [ %i1 + 0x170 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2008fc4: 40 00 05 06 call 200a3dc <_Workspace_Free>
2008fc8: 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] )
2008fcc: d0 06 61 70 ld [ %i1 + 0x170 ], %o0
2008fd0: 80 a2 20 00 cmp %o0, 0
2008fd4: 02 80 00 05 be 2008fe8 <_Thread_Initialize+0x164> <== ALWAYS TAKEN
2008fd8: 80 a6 e0 00 cmp %i3, 0
_Workspace_Free( the_thread->API_Extensions[i] );
2008fdc: 40 00 05 00 call 200a3dc <_Workspace_Free> <== NOT EXECUTED
2008fe0: 01 00 00 00 nop <== NOT EXECUTED
if ( extensions_area )
2008fe4: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2008fe8: 02 80 00 05 be 2008ffc <_Thread_Initialize+0x178>
2008fec: 80 a6 a0 00 cmp %i2, 0
(void) _Workspace_Free( extensions_area );
2008ff0: 40 00 04 fb call 200a3dc <_Workspace_Free>
2008ff4: 90 10 00 1b mov %i3, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( fp_area )
2008ff8: 80 a6 a0 00 cmp %i2, 0
2008ffc: 02 80 00 05 be 2009010 <_Thread_Initialize+0x18c>
2009000: 90 10 00 19 mov %i1, %o0
(void) _Workspace_Free( fp_area );
2009004: 40 00 04 f6 call 200a3dc <_Workspace_Free>
2009008: 90 10 00 1a mov %i2, %o0
#endif
_Thread_Stack_Free( the_thread );
200900c: 90 10 00 19 mov %i1, %o0
2009010: 40 00 02 97 call 2009a6c <_Thread_Stack_Free>
2009014: b0 10 20 00 clr %i0
return false;
}
2009018: 81 c7 e0 08 ret
200901c: 81 e8 00 00 restore
/*
* Allocate the floating point area for this thread
*/
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( is_fp ) {
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
2009020: 40 00 04 e6 call 200a3b8 <_Workspace_Allocate>
2009024: 90 10 20 88 mov 0x88, %o0
if ( !fp_area )
2009028: b6 10 20 00 clr %i3
200902c: b4 92 20 00 orcc %o0, 0, %i2
2009030: 02 bf ff d5 be 2008f84 <_Thread_Initialize+0x100>
2009034: 82 10 00 1a mov %i2, %g1
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2009038: 39 00 80 7d sethi %hi(0x201f400), %i4
200903c: c4 07 20 40 ld [ %i4 + 0x40 ], %g2 ! 201f440 <_Thread_Maximum_extensions>
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
the_thread->Start.fp_context = fp_area;
2009040: c2 26 60 cc st %g1, [ %i1 + 0xcc ]
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;
2009044: c2 26 61 60 st %g1, [ %i1 + 0x160 ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2009048: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
200904c: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2009050: c0 26 60 68 clr [ %i1 + 0x68 ]
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2009054: 80 a0 a0 00 cmp %g2, 0
2009058: 02 bf ff a8 be 2008ef8 <_Thread_Initialize+0x74>
200905c: c0 26 60 6c clr [ %i1 + 0x6c ]
extensions_area = _Workspace_Allocate(
2009060: 84 00 a0 01 inc %g2
2009064: 40 00 04 d5 call 200a3b8 <_Workspace_Allocate>
2009068: 91 28 a0 02 sll %g2, 2, %o0
(_Thread_Maximum_extensions + 1) * sizeof( void * )
);
if ( !extensions_area )
200906c: b6 92 20 00 orcc %o0, 0, %i3
2009070: 02 bf ff c5 be 2008f84 <_Thread_Initialize+0x100>
2009074: c8 07 20 40 ld [ %i4 + 0x40 ], %g4
goto failed;
}
the_thread->extensions = (void **) extensions_area;
2009078: f6 26 61 74 st %i3, [ %i1 + 0x174 ]
200907c: 86 10 00 1b mov %i3, %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++ )
2009080: 84 10 20 00 clr %g2
2009084: 10 80 00 03 b 2009090 <_Thread_Initialize+0x20c>
2009088: 82 10 20 00 clr %g1
200908c: c6 06 61 74 ld [ %i1 + 0x174 ], %g3
the_thread->extensions[i] = NULL;
2009090: 85 28 a0 02 sll %g2, 2, %g2
2009094: c0 20 c0 02 clr [ %g3 + %g2 ]
* 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++ )
2009098: 82 00 60 01 inc %g1
200909c: 80 a1 00 01 cmp %g4, %g1
20090a0: 1a bf ff fb bcc 200908c <_Thread_Initialize+0x208>
20090a4: 84 10 00 01 mov %g1, %g2
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
the_thread->Start.budget_callout = budget_callout;
20090a8: 10 bf ff 97 b 2008f04 <_Thread_Initialize+0x80>
20090ac: c2 07 a0 64 ld [ %fp + 0x64 ], %g1
return false; /* stack allocation failed */
stack = the_thread->Start.stack;
#else
if ( !stack_area ) {
actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
20090b0: 90 10 00 19 mov %i1, %o0
20090b4: 40 00 02 53 call 2009a00 <_Thread_Stack_Allocate>
20090b8: 92 10 00 1b mov %i3, %o1
if ( !actual_stack_size || actual_stack_size < stack_size )
20090bc: 80 a6 c0 08 cmp %i3, %o0
20090c0: 18 80 00 07 bgu 20090dc <_Thread_Initialize+0x258>
20090c4: 80 a2 20 00 cmp %o0, 0
20090c8: 02 80 00 05 be 20090dc <_Thread_Initialize+0x258> <== NEVER TAKEN
20090cc: 82 10 20 01 mov 1, %g1
return false; /* stack allocation failed */
stack = the_thread->Start.stack;
20090d0: f4 06 60 d0 ld [ %i1 + 0xd0 ], %i2
the_thread->Start.core_allocated_stack = true;
20090d4: 10 bf ff 79 b 2008eb8 <_Thread_Initialize+0x34>
20090d8: c2 2e 60 c0 stb %g1, [ %i1 + 0xc0 ]
stack = the_thread->Start.stack;
#else
if ( !stack_area ) {
actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
if ( !actual_stack_size || actual_stack_size < stack_size )
20090dc: 81 c7 e0 08 ret
20090e0: 91 e8 20 00 restore %g0, 0, %o0
0200d178 <_Thread_Resume>:
void _Thread_Resume(
Thread_Control *the_thread,
bool force
)
{
200d178: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
States_Control current_state;
_ISR_Disable( level );
200d17c: 7f ff d4 1a call 20021e4 <sparc_disable_interrupts>
200d180: a0 10 00 18 mov %i0, %l0
200d184: b0 10 00 08 mov %o0, %i0
_ISR_Enable( level );
return;
}
#endif
current_state = the_thread->current_state;
200d188: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
if ( current_state & STATES_SUSPENDED ) {
200d18c: 80 88 60 02 btst 2, %g1
200d190: 02 80 00 05 be 200d1a4 <_Thread_Resume+0x2c> <== NEVER TAKEN
200d194: 82 08 7f fd and %g1, -3, %g1
current_state =
the_thread->current_state = _States_Clear(STATES_SUSPENDED, current_state);
if ( _States_Is_ready( current_state ) ) {
200d198: 80 a0 60 00 cmp %g1, 0
200d19c: 02 80 00 04 be 200d1ac <_Thread_Resume+0x34>
200d1a0: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
_Context_Switch_necessary = true;
}
}
}
_ISR_Enable( level );
200d1a4: 7f ff d4 14 call 20021f4 <sparc_enable_interrupts>
200d1a8: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
200d1ac: c4 04 20 90 ld [ %l0 + 0x90 ], %g2
if ( _States_Is_ready( current_state ) ) {
_Priority_Add_to_bit_map( &the_thread->Priority_map );
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
200d1b0: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
200d1b4: c8 10 80 00 lduh [ %g2 ], %g4
200d1b8: c6 14 20 96 lduh [ %l0 + 0x96 ], %g3
200d1bc: 86 11 00 03 or %g4, %g3, %g3
200d1c0: c6 30 80 00 sth %g3, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
200d1c4: 84 00 60 04 add %g1, 4, %g2
_Priority_Major_bit_map |= the_priority_map->ready_major;
200d1c8: c8 14 20 94 lduh [ %l0 + 0x94 ], %g4
200d1cc: c4 24 00 00 st %g2, [ %l0 ]
200d1d0: 07 00 80 8c sethi %hi(0x2023000), %g3
old_last_node = the_chain->last;
200d1d4: c4 00 60 08 ld [ %g1 + 8 ], %g2
200d1d8: da 10 e1 94 lduh [ %g3 + 0x194 ], %o5
the_chain->last = the_node;
200d1dc: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
200d1e0: c4 24 20 04 st %g2, [ %l0 + 4 ]
200d1e4: 82 13 40 04 or %o5, %g4, %g1
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
200d1e8: e0 20 80 00 st %l0, [ %g2 ]
200d1ec: c2 30 e1 94 sth %g1, [ %g3 + 0x194 ]
_ISR_Flash( level );
200d1f0: 7f ff d4 01 call 20021f4 <sparc_enable_interrupts>
200d1f4: 01 00 00 00 nop
200d1f8: 7f ff d3 fb call 20021e4 <sparc_disable_interrupts>
200d1fc: 01 00 00 00 nop
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
200d200: 03 00 80 8c sethi %hi(0x2023000), %g1
200d204: c6 00 61 70 ld [ %g1 + 0x170 ], %g3 ! 2023170 <_Thread_Heir>
200d208: c4 04 20 14 ld [ %l0 + 0x14 ], %g2
200d20c: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
200d210: 80 a0 80 03 cmp %g2, %g3
200d214: 1a bf ff e4 bcc 200d1a4 <_Thread_Resume+0x2c>
200d218: 07 00 80 8c sethi %hi(0x2023000), %g3
_Thread_Heir = the_thread;
if ( _Thread_Executing->is_preemptible ||
200d21c: c6 00 e1 a0 ld [ %g3 + 0x1a0 ], %g3 ! 20231a0 <_Thread_Executing>
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
_ISR_Flash( level );
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
_Thread_Heir = the_thread;
200d220: e0 20 61 70 st %l0, [ %g1 + 0x170 ]
if ( _Thread_Executing->is_preemptible ||
200d224: c2 08 e0 75 ldub [ %g3 + 0x75 ], %g1
200d228: 80 a0 60 00 cmp %g1, 0
200d22c: 32 80 00 05 bne,a 200d240 <_Thread_Resume+0xc8>
200d230: 84 10 20 01 mov 1, %g2
200d234: 80 a0 a0 00 cmp %g2, 0
200d238: 12 bf ff db bne 200d1a4 <_Thread_Resume+0x2c> <== ALWAYS TAKEN
200d23c: 84 10 20 01 mov 1, %g2
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
200d240: 03 00 80 8c sethi %hi(0x2023000), %g1
200d244: c4 28 61 b0 stb %g2, [ %g1 + 0x1b0 ] ! 20231b0 <_Context_Switch_necessary>
}
}
}
_ISR_Enable( level );
200d248: 7f ff d3 eb call 20021f4 <sparc_enable_interrupts>
200d24c: 81 e8 00 00 restore
02009a6c <_Thread_Stack_Free>:
*/
void _Thread_Stack_Free(
Thread_Control *the_thread
)
{
2009a6c: 9d e3 bf a0 save %sp, -96, %sp
#if defined(RTEMS_SCORE_THREAD_ENABLE_USER_PROVIDED_STACK_VIA_API)
/*
* If the API provided the stack space, then don't free it.
*/
if ( !the_thread->Start.core_allocated_stack )
2009a70: c2 0e 20 c0 ldub [ %i0 + 0xc0 ], %g1
2009a74: 80 a0 60 00 cmp %g1, 0
2009a78: 02 80 00 08 be 2009a98 <_Thread_Stack_Free+0x2c> <== NEVER TAKEN
2009a7c: 03 00 80 7a sethi %hi(0x201e800), %g1
* Call ONLY the CPU table stack free hook, or the
* the RTEMS workspace free. This is so the free
* routine properly matches the allocation of the stack.
*/
if ( Configuration.stack_free_hook )
2009a80: c2 00 60 8c ld [ %g1 + 0x8c ], %g1 ! 201e88c <Configuration+0x24>
2009a84: 80 a0 60 00 cmp %g1, 0
2009a88: 22 80 00 06 be,a 2009aa0 <_Thread_Stack_Free+0x34>
2009a8c: f0 06 20 c8 ld [ %i0 + 0xc8 ], %i0
(*Configuration.stack_free_hook)( the_thread->Start.Initial_stack.area );
2009a90: 9f c0 40 00 call %g1
2009a94: d0 06 20 c8 ld [ %i0 + 0xc8 ], %o0
2009a98: 81 c7 e0 08 ret
2009a9c: 81 e8 00 00 restore
else
_Workspace_Free( the_thread->Start.Initial_stack.area );
2009aa0: 40 00 02 4f call 200a3dc <_Workspace_Free>
2009aa4: 81 e8 00 00 restore
02009b4c <_Thread_Tickle_timeslice>:
*
* Output parameters: NONE
*/
void _Thread_Tickle_timeslice( void )
{
2009b4c: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *executing;
executing = _Thread_Executing;
2009b50: 03 00 80 7d sethi %hi(0x201f400), %g1
2009b54: d0 00 60 60 ld [ %g1 + 0x60 ], %o0 ! 201f460 <_Thread_Executing>
/*
* If the thread is not preemptible or is not ready, then
* just return.
*/
if ( !executing->is_preemptible )
2009b58: c2 0a 20 75 ldub [ %o0 + 0x75 ], %g1
2009b5c: 80 a0 60 00 cmp %g1, 0
2009b60: 02 80 00 24 be 2009bf0 <_Thread_Tickle_timeslice+0xa4>
2009b64: 01 00 00 00 nop
return;
if ( !_States_Is_ready( executing->current_state ) )
2009b68: c2 02 20 10 ld [ %o0 + 0x10 ], %g1
2009b6c: 80 a0 60 00 cmp %g1, 0
2009b70: 12 80 00 20 bne 2009bf0 <_Thread_Tickle_timeslice+0xa4>
2009b74: 01 00 00 00 nop
/*
* The cpu budget algorithm determines what happens next.
*/
switch ( executing->budget_algorithm ) {
2009b78: c2 02 20 7c ld [ %o0 + 0x7c ], %g1
2009b7c: 80 a0 60 01 cmp %g1, 1
2009b80: 0a 80 00 07 bcs 2009b9c <_Thread_Tickle_timeslice+0x50>
2009b84: 80 a0 60 02 cmp %g1, 2
2009b88: 28 80 00 10 bleu,a 2009bc8 <_Thread_Tickle_timeslice+0x7c>
2009b8c: c2 02 20 78 ld [ %o0 + 0x78 ], %g1
2009b90: 80 a0 60 03 cmp %g1, 3
2009b94: 22 80 00 04 be,a 2009ba4 <_Thread_Tickle_timeslice+0x58> <== ALWAYS TAKEN
2009b98: c2 02 20 78 ld [ %o0 + 0x78 ], %g1
2009b9c: 81 c7 e0 08 ret
2009ba0: 81 e8 00 00 restore
}
break;
#if defined(RTEMS_SCORE_THREAD_ENABLE_SCHEDULER_CALLOUT)
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
if ( --executing->cpu_time_budget == 0 )
2009ba4: 82 00 7f ff add %g1, -1, %g1
2009ba8: 80 a0 60 00 cmp %g1, 0
2009bac: 12 bf ff fc bne 2009b9c <_Thread_Tickle_timeslice+0x50>
2009bb0: c2 22 20 78 st %g1, [ %o0 + 0x78 ]
(*executing->budget_callout)( executing );
2009bb4: c2 02 20 80 ld [ %o0 + 0x80 ], %g1
2009bb8: 9f c0 40 00 call %g1
2009bbc: 01 00 00 00 nop
2009bc0: 81 c7 e0 08 ret
2009bc4: 81 e8 00 00 restore
case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE:
#if defined(RTEMS_SCORE_THREAD_ENABLE_EXHAUST_TIMESLICE)
case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE:
#endif
if ( (int)(--executing->cpu_time_budget) <= 0 ) {
2009bc8: 82 00 7f ff add %g1, -1, %g1
2009bcc: 80 a0 60 00 cmp %g1, 0
2009bd0: 14 bf ff f3 bg 2009b9c <_Thread_Tickle_timeslice+0x50>
2009bd4: c2 22 20 78 st %g1, [ %o0 + 0x78 ]
_Thread_Reset_timeslice();
2009bd8: 40 00 13 de call 200eb50 <_Thread_Reset_timeslice>
2009bdc: d0 27 bf fc st %o0, [ %fp + -4 ]
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
2009be0: 03 00 80 7c sethi %hi(0x201f000), %g1
2009be4: d0 07 bf fc ld [ %fp + -4 ], %o0
2009be8: c2 00 62 f8 ld [ %g1 + 0x2f8 ], %g1
2009bec: c2 22 20 78 st %g1, [ %o0 + 0x78 ]
2009bf0: 81 c7 e0 08 ret
2009bf4: 81 e8 00 00 restore
02009bf8 <_Thread_Yield_processor>:
* ready chain
* select heir
*/
void _Thread_Yield_processor( void )
{
2009bf8: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Thread_Control *executing;
Chain_Control *ready;
executing = _Thread_Executing;
2009bfc: 03 00 80 7d sethi %hi(0x201f400), %g1
2009c00: e0 00 60 60 ld [ %g1 + 0x60 ], %l0 ! 201f460 <_Thread_Executing>
ready = executing->ready;
_ISR_Disable( level );
2009c04: 7f ff e1 28 call 20020a4 <sparc_disable_interrupts>
2009c08: e2 04 20 8c ld [ %l0 + 0x8c ], %l1
2009c0c: b0 10 00 08 mov %o0, %i0
if ( !_Chain_Has_only_one_node( ready ) ) {
2009c10: c4 04 40 00 ld [ %l1 ], %g2
2009c14: c2 04 60 08 ld [ %l1 + 8 ], %g1
2009c18: 80 a0 80 01 cmp %g2, %g1
2009c1c: 02 80 00 19 be 2009c80 <_Thread_Yield_processor+0x88>
2009c20: 86 04 60 04 add %l1, 4, %g3
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
2009c24: c2 04 00 00 ld [ %l0 ], %g1
previous = the_node->previous;
2009c28: c4 04 20 04 ld [ %l0 + 4 ], %g2
next->previous = previous;
previous->next = next;
2009c2c: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
2009c30: c6 24 00 00 st %g3, [ %l0 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
2009c34: c4 20 60 04 st %g2, [ %g1 + 4 ]
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
2009c38: c2 04 60 08 ld [ %l1 + 8 ], %g1
the_chain->last = the_node;
2009c3c: e0 24 60 08 st %l0, [ %l1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
2009c40: c2 24 20 04 st %g1, [ %l0 + 4 ]
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
2009c44: e0 20 40 00 st %l0, [ %g1 ]
_Chain_Extract_unprotected( &executing->Object.Node );
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
2009c48: 7f ff e1 1b call 20020b4 <sparc_enable_interrupts>
2009c4c: 01 00 00 00 nop
2009c50: 7f ff e1 15 call 20020a4 <sparc_disable_interrupts>
2009c54: 01 00 00 00 nop
if ( _Thread_Is_heir( executing ) )
2009c58: 03 00 80 7d sethi %hi(0x201f400), %g1
2009c5c: c4 00 60 30 ld [ %g1 + 0x30 ], %g2 ! 201f430 <_Thread_Heir>
2009c60: 80 a4 00 02 cmp %l0, %g2
2009c64: 22 80 00 0e be,a 2009c9c <_Thread_Yield_processor+0xa4> <== ALWAYS TAKEN
2009c68: c4 04 40 00 ld [ %l1 ], %g2
_Thread_Heir = (Thread_Control *) ready->first;
_Context_Switch_necessary = true;
}
else if ( !_Thread_Is_heir( executing ) )
_Context_Switch_necessary = true;
2009c6c: 84 10 20 01 mov 1, %g2
2009c70: 03 00 80 7d sethi %hi(0x201f400), %g1
2009c74: c4 28 60 70 stb %g2, [ %g1 + 0x70 ] ! 201f470 <_Context_Switch_necessary>
_ISR_Enable( level );
2009c78: 7f ff e1 0f call 20020b4 <sparc_enable_interrupts>
2009c7c: 81 e8 00 00 restore
if ( _Thread_Is_heir( executing ) )
_Thread_Heir = (Thread_Control *) ready->first;
_Context_Switch_necessary = true;
}
else if ( !_Thread_Is_heir( executing ) )
2009c80: 03 00 80 7d sethi %hi(0x201f400), %g1
2009c84: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 ! 201f430 <_Thread_Heir>
2009c88: 80 a4 00 01 cmp %l0, %g1
2009c8c: 32 bf ff f9 bne,a 2009c70 <_Thread_Yield_processor+0x78> <== NEVER TAKEN
2009c90: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
_Context_Switch_necessary = true;
_ISR_Enable( level );
2009c94: 7f ff e1 08 call 20020b4 <sparc_enable_interrupts>
2009c98: 81 e8 00 00 restore
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
if ( _Thread_Is_heir( executing ) )
_Thread_Heir = (Thread_Control *) ready->first;
2009c9c: 10 bf ff f4 b 2009c6c <_Thread_Yield_processor+0x74>
2009ca0: c4 20 60 30 st %g2, [ %g1 + 0x30 ]
02009404 <_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
)
{
2009404: 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;
2009408: 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);
200940c: 82 06 60 3c add %i1, 0x3c, %g1
the_chain->permanent_null = NULL;
2009410: 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);
2009414: c2 26 60 38 st %g1, [ %i1 + 0x38 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2009418: 82 06 60 38 add %i1, 0x38, %g1
200941c: c2 26 60 40 st %g1, [ %i1 + 0x40 ]
2009420: 2d 00 80 7a sethi %hi(0x201e800), %l6
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
2009424: 83 34 20 06 srl %l0, 6, %g1
block_state = the_thread_queue->state;
if ( _Thread_queue_Is_reverse_search( priority ) )
2009428: 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 ];
200942c: ab 28 60 04 sll %g1, 4, %l5
2009430: ac 15 a0 64 or %l6, 0x64, %l6
2009434: 83 28 60 02 sll %g1, 2, %g1
block_state = the_thread_queue->state;
2009438: e8 06 20 38 ld [ %i0 + 0x38 ], %l4
_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 ];
200943c: aa 25 40 01 sub %l5, %g1, %l5
block_state = the_thread_queue->state;
if ( _Thread_queue_Is_reverse_search( priority ) )
2009440: 12 80 00 24 bne 20094d0 <_Thread_queue_Enqueue_priority+0xcc>
2009444: aa 06 00 15 add %i0, %l5, %l5
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2009448: ac 05 60 04 add %l5, 4, %l6
goto restart_reverse_search;
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
_ISR_Disable( level );
200944c: 7f ff e3 16 call 20020a4 <sparc_disable_interrupts>
2009450: 01 00 00 00 nop
2009454: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->first;
2009458: c2 05 40 00 ld [ %l5 ], %g1
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
200945c: 80 a0 40 16 cmp %g1, %l6
2009460: 02 80 00 3a be 2009548 <_Thread_queue_Enqueue_priority+0x144>
2009464: a2 10 00 01 mov %g1, %l1
search_priority = search_thread->current_priority;
2009468: e6 00 60 14 ld [ %g1 + 0x14 ], %l3
if ( priority <= search_priority )
200946c: 80 a4 00 13 cmp %l0, %l3
2009470: 18 80 00 0b bgu 200949c <_Thread_queue_Enqueue_priority+0x98>
2009474: 01 00 00 00 nop
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
}
if ( the_thread_queue->sync_state !=
2009478: 10 80 00 36 b 2009550 <_Thread_queue_Enqueue_priority+0x14c>
200947c: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
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 ) ) {
2009480: 80 a4 40 16 cmp %l1, %l6
2009484: 02 80 00 32 be 200954c <_Thread_queue_Enqueue_priority+0x148>
2009488: 82 10 00 11 mov %l1, %g1
search_priority = search_thread->current_priority;
200948c: e6 04 60 14 ld [ %l1 + 0x14 ], %l3
if ( priority <= search_priority )
2009490: 80 a4 00 13 cmp %l0, %l3
2009494: 28 80 00 2f bleu,a 2009550 <_Thread_queue_Enqueue_priority+0x14c>
2009498: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
break;
search_priority = search_thread->current_priority;
if ( priority <= search_priority )
break;
#endif
_ISR_Flash( level );
200949c: 7f ff e3 06 call 20020b4 <sparc_enable_interrupts>
20094a0: 90 10 00 12 mov %l2, %o0
20094a4: 7f ff e3 00 call 20020a4 <sparc_disable_interrupts>
20094a8: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
20094ac: c2 04 60 10 ld [ %l1 + 0x10 ], %g1
20094b0: 80 8d 00 01 btst %l4, %g1
20094b4: 32 bf ff f3 bne,a 2009480 <_Thread_queue_Enqueue_priority+0x7c><== ALWAYS TAKEN
20094b8: e2 04 40 00 ld [ %l1 ], %l1
_ISR_Enable( level );
20094bc: 7f ff e2 fe call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
20094c0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
goto restart_forward_search;
20094c4: 30 bf ff e2 b,a 200944c <_Thread_queue_Enqueue_priority+0x48><== NOT EXECUTED
if ( priority >= search_priority )
break;
#endif
_ISR_Flash( level );
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
_ISR_Enable( level );
20094c8: 7f ff e2 fb call 20020b4 <sparc_enable_interrupts>
20094cc: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
_ISR_Disable( level );
20094d0: 7f ff e2 f5 call 20020a4 <sparc_disable_interrupts>
20094d4: e6 0d 80 00 ldub [ %l6 ], %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;
20094d8: a6 04 e0 01 inc %l3
_ISR_Disable( level );
20094dc: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->last;
20094e0: c2 05 60 08 ld [ %l5 + 8 ], %g1
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
20094e4: 80 a0 40 15 cmp %g1, %l5
20094e8: 02 80 00 20 be 2009568 <_Thread_queue_Enqueue_priority+0x164>
20094ec: a2 10 00 01 mov %g1, %l1
search_priority = search_thread->current_priority;
20094f0: e6 00 60 14 ld [ %g1 + 0x14 ], %l3
if ( priority >= search_priority )
20094f4: 80 a4 00 13 cmp %l0, %l3
20094f8: 0a 80 00 0b bcs 2009524 <_Thread_queue_Enqueue_priority+0x120>
20094fc: 01 00 00 00 nop
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
}
if ( the_thread_queue->sync_state !=
2009500: 10 80 00 1b b 200956c <_Thread_queue_Enqueue_priority+0x168>
2009504: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
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 ) ) {
2009508: 80 a4 40 15 cmp %l1, %l5
200950c: 02 80 00 17 be 2009568 <_Thread_queue_Enqueue_priority+0x164>
2009510: 82 10 00 11 mov %l1, %g1
search_priority = search_thread->current_priority;
2009514: e6 04 60 14 ld [ %l1 + 0x14 ], %l3
if ( priority >= search_priority )
2009518: 80 a4 00 13 cmp %l0, %l3
200951c: 3a 80 00 14 bcc,a 200956c <_Thread_queue_Enqueue_priority+0x168>
2009520: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
break;
search_priority = search_thread->current_priority;
if ( priority >= search_priority )
break;
#endif
_ISR_Flash( level );
2009524: 7f ff e2 e4 call 20020b4 <sparc_enable_interrupts>
2009528: 90 10 00 12 mov %l2, %o0
200952c: 7f ff e2 de call 20020a4 <sparc_disable_interrupts>
2009530: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
2009534: c2 04 60 10 ld [ %l1 + 0x10 ], %g1
2009538: 80 8d 00 01 btst %l4, %g1
200953c: 32 bf ff f3 bne,a 2009508 <_Thread_queue_Enqueue_priority+0x104>
2009540: e2 04 60 04 ld [ %l1 + 4 ], %l1
2009544: 30 bf ff e1 b,a 20094c8 <_Thread_queue_Enqueue_priority+0xc4>
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 ) ) {
2009548: a6 10 3f ff mov -1, %l3
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
}
if ( the_thread_queue->sync_state !=
200954c: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
2009550: 80 a0 a0 01 cmp %g2, 1
2009554: 02 80 00 17 be 20095b0 <_Thread_queue_Enqueue_priority+0x1ac>
2009558: 80 a4 00 13 cmp %l0, %l3
* 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;
200955c: e4 26 80 00 st %l2, [ %i2 ]
return the_thread_queue->sync_state;
}
2009560: 81 c7 e0 08 ret
2009564: 91 e8 00 02 restore %g0, %g2, %o0
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
}
if ( the_thread_queue->sync_state !=
2009568: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
200956c: 80 a0 a0 01 cmp %g2, 1
2009570: 32 bf ff fc bne,a 2009560 <_Thread_queue_Enqueue_priority+0x15c>
2009574: e4 26 80 00 st %l2, [ %i2 ]
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( priority == search_priority )
2009578: 80 a4 00 13 cmp %l0, %l3
200957c: 02 80 00 1a be 20095e4 <_Thread_queue_Enqueue_priority+0x1e0>
2009580: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority;
search_node = (Chain_Node *) search_thread;
next_node = search_node->next;
2009584: c4 00 40 00 ld [ %g1 ], %g2
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
the_node->previous = search_node;
2009588: c2 26 60 04 st %g1, [ %i1 + 4 ]
search_node = (Chain_Node *) search_thread;
next_node = search_node->next;
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
200958c: c4 26 40 00 st %g2, [ %i1 ]
the_node->previous = search_node;
search_node->next = the_node;
next_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
2009590: 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;
2009594: f2 20 40 00 st %i1, [ %g1 ]
next_node->previous = the_node;
2009598: f2 20 a0 04 st %i1, [ %g2 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
200959c: b0 10 20 01 mov 1, %i0
20095a0: 7f ff e2 c5 call 20020b4 <sparc_enable_interrupts>
20095a4: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
20095a8: 81 c7 e0 08 ret
20095ac: 81 e8 00 00 restore
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( priority == search_priority )
20095b0: 02 80 00 0d be 20095e4 <_Thread_queue_Enqueue_priority+0x1e0>
20095b4: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority;
search_node = (Chain_Node *) search_thread;
previous_node = search_node->previous;
20095b8: c4 00 60 04 ld [ %g1 + 4 ], %g2
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
20095bc: c2 26 40 00 st %g1, [ %i1 ]
the_node->previous = previous_node;
20095c0: c4 26 60 04 st %g2, [ %i1 + 4 ]
previous_node->next = the_node;
search_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
20095c4: 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;
20095c8: f2 20 80 00 st %i1, [ %g2 ]
search_node->previous = the_node;
20095cc: f2 20 60 04 st %i1, [ %g1 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
20095d0: b0 10 20 01 mov 1, %i0
20095d4: 7f ff e2 b8 call 20020b4 <sparc_enable_interrupts>
20095d8: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
20095dc: 81 c7 e0 08 ret
20095e0: 81 e8 00 00 restore
20095e4: a2 04 60 3c add %l1, 0x3c, %l1
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
equal_priority: /* add at end of priority group */
search_node = _Chain_Tail( &search_thread->Wait.Block2n );
previous_node = search_node->previous;
20095e8: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
20095ec: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
20095f0: 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;
20095f4: 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;
20095f8: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
20095fc: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
2009600: b0 10 20 01 mov 1, %i0
2009604: 7f ff e2 ac call 20020b4 <sparc_enable_interrupts>
2009608: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
200960c: 81 c7 e0 08 ret
2009610: 81 e8 00 00 restore
020096c0 <_Thread_queue_Requeue>:
void _Thread_queue_Requeue(
Thread_queue_Control *the_thread_queue,
Thread_Control *the_thread
)
{
20096c0: 9d e3 bf 98 save %sp, -104, %sp
/*
* Just in case the thread really wasn't blocked on a thread queue
* when we get here.
*/
if ( !the_thread_queue )
20096c4: 80 a6 20 00 cmp %i0, 0
20096c8: 02 80 00 13 be 2009714 <_Thread_queue_Requeue+0x54> <== NEVER TAKEN
20096cc: 01 00 00 00 nop
/*
* If queueing by FIFO, there is nothing to do. This only applies to
* priority blocking discipline.
*/
if ( the_thread_queue->discipline == THREAD_QUEUE_DISCIPLINE_PRIORITY ) {
20096d0: e2 06 20 34 ld [ %i0 + 0x34 ], %l1
20096d4: 80 a4 60 01 cmp %l1, 1
20096d8: 02 80 00 04 be 20096e8 <_Thread_queue_Requeue+0x28> <== ALWAYS TAKEN
20096dc: 01 00 00 00 nop
20096e0: 81 c7 e0 08 ret <== NOT EXECUTED
20096e4: 81 e8 00 00 restore <== NOT EXECUTED
Thread_queue_Control *tq = the_thread_queue;
ISR_Level level;
ISR_Level level_ignored;
_ISR_Disable( level );
20096e8: 7f ff e2 6f call 20020a4 <sparc_disable_interrupts>
20096ec: 01 00 00 00 nop
20096f0: a0 10 00 08 mov %o0, %l0
if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
20096f4: c4 06 60 10 ld [ %i1 + 0x10 ], %g2
20096f8: 03 00 00 ef sethi %hi(0x3bc00), %g1
20096fc: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0>
2009700: 80 88 80 01 btst %g2, %g1
2009704: 12 80 00 06 bne 200971c <_Thread_queue_Requeue+0x5c> <== ALWAYS TAKEN
2009708: 90 10 00 18 mov %i0, %o0
_Thread_queue_Enter_critical_section( tq );
_Thread_queue_Extract_priority_helper( tq, the_thread, true );
(void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored );
}
_ISR_Enable( level );
200970c: 7f ff e2 6a call 20020b4 <sparc_enable_interrupts>
2009710: 90 10 00 10 mov %l0, %o0
2009714: 81 c7 e0 08 ret
2009718: 81 e8 00 00 restore
ISR_Level level_ignored;
_ISR_Disable( level );
if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
_Thread_queue_Enter_critical_section( tq );
_Thread_queue_Extract_priority_helper( tq, the_thread, true );
200971c: 92 10 00 19 mov %i1, %o1
2009720: e2 26 20 30 st %l1, [ %i0 + 0x30 ]
2009724: 40 00 14 6b call 200e8d0 <_Thread_queue_Extract_priority_helper>
2009728: 94 10 20 01 mov 1, %o2
(void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored );
200972c: 90 10 00 18 mov %i0, %o0
2009730: 92 10 00 19 mov %i1, %o1
2009734: 7f ff ff 34 call 2009404 <_Thread_queue_Enqueue_priority>
2009738: 94 07 bf fc add %fp, -4, %o2
200973c: 30 bf ff f4 b,a 200970c <_Thread_queue_Requeue+0x4c>
02009740 <_Thread_queue_Timeout>:
void _Thread_queue_Timeout(
Objects_Id id,
void *ignored __attribute__((unused))
)
{
2009740: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
2009744: 90 10 00 18 mov %i0, %o0
2009748: 7f ff fd a4 call 2008dd8 <_Thread_Get>
200974c: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2009750: c2 07 bf fc ld [ %fp + -4 ], %g1
2009754: 80 a0 60 00 cmp %g1, 0
2009758: 12 80 00 08 bne 2009778 <_Thread_queue_Timeout+0x38> <== NEVER TAKEN
200975c: 01 00 00 00 nop
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_queue_Process_timeout( the_thread );
2009760: 40 00 14 95 call 200e9b4 <_Thread_queue_Process_timeout>
2009764: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
2009768: 03 00 80 7c sethi %hi(0x201f000), %g1
200976c: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
2009770: 84 00 bf ff add %g2, -1, %g2
2009774: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
2009778: 81 c7 e0 08 ret
200977c: 81 e8 00 00 restore
020012e0 <_Timer_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/timer.h>
void _Timer_Manager_initialization(void)
{
}
20012e0: 81 c3 e0 08 retl
02016f7c <_Timer_server_Body>:
* @a arg points to the corresponding timer server control block.
*/
static rtems_task _Timer_server_Body(
rtems_task_argument arg
)
{
2016f7c: 9d e3 bf 88 save %sp, -120, %sp
2016f80: 2d 00 81 03 sethi %hi(0x2040c00), %l6
2016f84: ba 07 bf f4 add %fp, -12, %i5
2016f88: a8 07 bf f8 add %fp, -8, %l4
2016f8c: a4 07 bf e8 add %fp, -24, %l2
2016f90: ae 07 bf ec add %fp, -20, %l7
2016f94: 2b 00 81 03 sethi %hi(0x2040c00), %l5
2016f98: 39 00 81 03 sethi %hi(0x2040c00), %i4
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2016f9c: c0 27 bf f8 clr [ %fp + -8 ]
2016fa0: c0 27 bf ec clr [ %fp + -20 ]
the_chain->last = _Chain_Head(the_chain);
2016fa4: fa 27 bf fc st %i5, [ %fp + -4 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2016fa8: e8 27 bf f4 st %l4, [ %fp + -12 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2016fac: e4 27 bf f0 st %l2, [ %fp + -16 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2016fb0: ee 27 bf e8 st %l7, [ %fp + -24 ]
2016fb4: ac 15 a2 34 or %l6, 0x234, %l6
2016fb8: aa 15 61 74 or %l5, 0x174, %l5
2016fbc: b8 17 20 e0 or %i4, 0xe0, %i4
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fc0: a2 06 20 30 add %i0, 0x30, %l1
/*
* 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 );
2016fc4: a6 06 20 68 add %i0, 0x68, %l3
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2016fc8: b2 06 20 08 add %i0, 8, %i1
static void _Timer_server_Stop_tod_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2016fcc: b4 06 20 40 add %i0, 0x40, %i2
_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;
2016fd0: b6 10 20 01 mov 1, %i3
{
/*
* 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;
2016fd4: fa 26 20 78 st %i5, [ %i0 + 0x78 ]
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2016fd8: c2 05 80 00 ld [ %l6 ], %g1
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
2016fdc: d2 06 20 3c ld [ %i0 + 0x3c ], %o1
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fe0: 90 10 00 11 mov %l1, %o0
2016fe4: 92 20 40 09 sub %g1, %o1, %o1
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
2016fe8: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fec: 40 00 12 9c call 201ba5c <_Watchdog_Adjust_to_chain>
2016ff0: 94 10 00 12 mov %l2, %o2
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
2016ff4: d2 06 20 74 ld [ %i0 + 0x74 ], %o1
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
2016ff8: e0 05 40 00 ld [ %l5 ], %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 ) {
2016ffc: 80 a4 00 09 cmp %l0, %o1
2017000: 38 80 00 2f bgu,a 20170bc <_Timer_server_Body+0x140>
2017004: 92 24 00 09 sub %l0, %o1, %o1
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
} else if ( snapshot < last_snapshot ) {
2017008: 80 a4 00 09 cmp %l0, %o1
201700c: 0a 80 00 30 bcs 20170cc <_Timer_server_Body+0x150>
2017010: 94 22 40 10 sub %o1, %l0, %o2
*/
delta = last_snapshot - snapshot;
_Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
}
watchdogs->last_snapshot = snapshot;
2017014: 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 );
2017018: d0 06 20 78 ld [ %i0 + 0x78 ], %o0
201701c: 40 00 02 b1 call 2017ae0 <_Chain_Get>
2017020: 01 00 00 00 nop
if ( timer == NULL ) {
2017024: 80 a2 20 00 cmp %o0, 0
2017028: 02 80 00 10 be 2017068 <_Timer_server_Body+0xec>
201702c: 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 ) {
2017030: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
2017034: 80 a0 60 01 cmp %g1, 1
2017038: 02 80 00 29 be 20170dc <_Timer_server_Body+0x160>
201703c: 80 a0 60 03 cmp %g1, 3
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {
2017040: 12 bf ff f6 bne 2017018 <_Timer_server_Body+0x9c> <== NEVER TAKEN
2017044: 92 02 20 10 add %o0, 0x10, %o1
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
2017048: 40 00 12 bb call 201bb34 <_Watchdog_Insert>
201704c: 90 10 00 13 mov %l3, %o0
}
static void _Timer_server_Process_insertions( Timer_server_Control *ts )
{
while ( true ) {
Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
2017050: d0 06 20 78 ld [ %i0 + 0x78 ], %o0
2017054: 40 00 02 a3 call 2017ae0 <_Chain_Get>
2017058: 01 00 00 00 nop
if ( timer == NULL ) {
201705c: 80 a2 20 00 cmp %o0, 0
2017060: 32 bf ff f5 bne,a 2017034 <_Timer_server_Body+0xb8> <== NEVER TAKEN
2017064: c2 02 20 38 ld [ %o0 + 0x38 ], %g1 <== NOT EXECUTED
* of zero it will be processed in the next iteration of the timer server
* body loop.
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
2017068: 7f ff e0 f4 call 200f438 <sparc_disable_interrupts>
201706c: 01 00 00 00 nop
if ( _Chain_Is_empty( insert_chain ) ) {
2017070: c2 07 bf f4 ld [ %fp + -12 ], %g1
2017074: 80 a5 00 01 cmp %l4, %g1
2017078: 02 80 00 1d be 20170ec <_Timer_server_Body+0x170> <== ALWAYS TAKEN
201707c: 01 00 00 00 nop
ts->insert_chain = NULL;
_ISR_Enable( level );
break;
} else {
_ISR_Enable( level );
2017080: 7f ff e0 f2 call 200f448 <sparc_enable_interrupts> <== NOT EXECUTED
2017084: 01 00 00 00 nop <== NOT EXECUTED
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2017088: c2 05 80 00 ld [ %l6 ], %g1 <== NOT EXECUTED
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
201708c: d2 06 20 3c ld [ %i0 + 0x3c ], %o1 <== NOT EXECUTED
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2017090: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2017094: 92 20 40 09 sub %g1, %o1, %o1 <== NOT EXECUTED
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
2017098: c2 26 20 3c st %g1, [ %i0 + 0x3c ] <== NOT EXECUTED
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
201709c: 40 00 12 70 call 201ba5c <_Watchdog_Adjust_to_chain> <== NOT EXECUTED
20170a0: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
20170a4: d2 06 20 74 ld [ %i0 + 0x74 ], %o1 <== NOT EXECUTED
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
20170a8: e0 05 40 00 ld [ %l5 ], %l0 <== NOT EXECUTED
/*
* Process the seconds chain. Start by checking that the Time
* of Day (TOD) has not been set backwards. If it has then
* we want to adjust the watchdogs->Chain to indicate this.
*/
if ( snapshot > last_snapshot ) {
20170ac: 80 a4 00 09 cmp %l0, %o1 <== NOT EXECUTED
20170b0: 08 bf ff d7 bleu 201700c <_Timer_server_Body+0x90> <== NOT EXECUTED
20170b4: 01 00 00 00 nop <== NOT EXECUTED
/*
* This path is for normal forward movement and cases where the
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20170b8: 92 24 00 09 sub %l0, %o1, %o1 <== NOT EXECUTED
20170bc: 90 10 00 13 mov %l3, %o0
20170c0: 40 00 12 67 call 201ba5c <_Watchdog_Adjust_to_chain>
20170c4: 94 10 00 12 mov %l2, %o2
20170c8: 30 bf ff d3 b,a 2017014 <_Timer_server_Body+0x98>
/*
* 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 );
20170cc: 90 10 00 13 mov %l3, %o0
20170d0: 40 00 12 33 call 201b99c <_Watchdog_Adjust>
20170d4: 92 10 20 01 mov 1, %o1
20170d8: 30 bf ff cf b,a 2017014 <_Timer_server_Body+0x98>
Timer_server_Control *ts,
Timer_Control *timer
)
{
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
20170dc: 92 02 20 10 add %o0, 0x10, %o1
20170e0: 40 00 12 95 call 201bb34 <_Watchdog_Insert>
20170e4: 90 10 00 11 mov %l1, %o0
20170e8: 30 bf ff cc b,a 2017018 <_Timer_server_Body+0x9c>
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
if ( _Chain_Is_empty( insert_chain ) ) {
ts->insert_chain = NULL;
20170ec: c0 26 20 78 clr [ %i0 + 0x78 ]
_ISR_Enable( level );
20170f0: 7f ff e0 d6 call 200f448 <sparc_enable_interrupts>
20170f4: 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 ) ) {
20170f8: c2 07 bf e8 ld [ %fp + -24 ], %g1
20170fc: 80 a5 c0 01 cmp %l7, %g1
2017100: 12 80 00 0c bne 2017130 <_Timer_server_Body+0x1b4>
2017104: 01 00 00 00 nop
2017108: 30 80 00 13 b,a 2017154 <_Timer_server_Body+0x1d8>
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
if ( watchdog != NULL ) {
watchdog->state = WATCHDOG_INACTIVE;
201710c: c0 24 20 08 clr [ %l0 + 8 ]
Chain_Node *return_node;
Chain_Node *new_first;
return_node = the_chain->first;
new_first = return_node->next;
the_chain->first = new_first;
2017110: c2 27 bf e8 st %g1, [ %fp + -24 ]
new_first->previous = _Chain_Head(the_chain);
2017114: e4 20 60 04 st %l2, [ %g1 + 4 ]
_ISR_Enable( level );
2017118: 7f ff e0 cc call 200f448 <sparc_enable_interrupts>
201711c: 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 );
2017120: d2 04 20 24 ld [ %l0 + 0x24 ], %o1
2017124: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
2017128: 9f c0 40 00 call %g1
201712c: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
/*
* It is essential that interrupts are disable here since an interrupt
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
2017130: 7f ff e0 c2 call 200f438 <sparc_disable_interrupts>
2017134: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
2017138: 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))
201713c: 80 a5 c0 10 cmp %l7, %l0
2017140: 32 bf ff f3 bne,a 201710c <_Timer_server_Body+0x190>
2017144: c2 04 00 00 ld [ %l0 ], %g1
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
if ( watchdog != NULL ) {
watchdog->state = WATCHDOG_INACTIVE;
_ISR_Enable( level );
} else {
_ISR_Enable( level );
2017148: 7f ff e0 c0 call 200f448 <sparc_enable_interrupts>
201714c: 01 00 00 00 nop
2017150: 30 bf ff a1 b,a 2016fd4 <_Timer_server_Body+0x58>
* the active flag of the timer server is true.
*/
(*watchdog->routine)( watchdog->id, watchdog->user_data );
}
} else {
ts->active = false;
2017154: c0 2e 20 7c clrb [ %i0 + 0x7c ]
2017158: c2 07 00 00 ld [ %i4 ], %g1
201715c: 82 00 60 01 inc %g1
2017160: c2 27 00 00 st %g1, [ %i4 ]
/*
* Block until there is something to do.
*/
_Thread_Disable_dispatch();
_Thread_Set_state( ts->thread, STATES_DELAYING );
2017164: d0 06 00 00 ld [ %i0 ], %o0
2017168: 40 00 0f 55 call 201aebc <_Thread_Set_state>
201716c: 92 10 20 08 mov 8, %o1
_Timer_server_Reset_interval_system_watchdog( ts );
2017170: 7f ff ff 59 call 2016ed4 <_Timer_server_Reset_interval_system_watchdog>
2017174: 90 10 00 18 mov %i0, %o0
_Timer_server_Reset_tod_system_watchdog( ts );
2017178: 7f ff ff 6c call 2016f28 <_Timer_server_Reset_tod_system_watchdog>
201717c: 90 10 00 18 mov %i0, %o0
_Thread_Enable_dispatch();
2017180: 40 00 0c 4d call 201a2b4 <_Thread_Enable_dispatch>
2017184: 01 00 00 00 nop
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2017188: 90 10 00 19 mov %i1, %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;
201718c: f6 2e 20 7c stb %i3, [ %i0 + 0x7c ]
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2017190: 40 00 12 d2 call 201bcd8 <_Watchdog_Remove>
2017194: 01 00 00 00 nop
static void _Timer_server_Stop_tod_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2017198: 40 00 12 d0 call 201bcd8 <_Watchdog_Remove>
201719c: 90 10 00 1a mov %i2, %o0
20171a0: 30 bf ff 8d b,a 2016fd4 <_Timer_server_Body+0x58>
02009eb4 <_User_extensions_Fatal>:
void _User_extensions_Fatal (
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
2009eb4: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009eb8: 23 00 80 7d sethi %hi(0x201f400), %l1
2009ebc: a2 14 61 d8 or %l1, 0x1d8, %l1 ! 201f5d8 <_User_extensions_List>
2009ec0: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009ec4: 80 a4 00 11 cmp %l0, %l1
2009ec8: 02 80 00 0d be 2009efc <_User_extensions_Fatal+0x48> <== NEVER TAKEN
2009ecc: b2 0e 60 ff and %i1, 0xff, %i1
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
2009ed0: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2009ed4: 80 a0 60 00 cmp %g1, 0
2009ed8: 02 80 00 05 be 2009eec <_User_extensions_Fatal+0x38>
2009edc: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
2009ee0: 92 10 00 19 mov %i1, %o1
2009ee4: 9f c0 40 00 call %g1
2009ee8: 94 10 00 1a mov %i2, %o2
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009eec: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009ef0: 80 a4 00 11 cmp %l0, %l1
2009ef4: 32 bf ff f8 bne,a 2009ed4 <_User_extensions_Fatal+0x20>
2009ef8: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2009efc: 81 c7 e0 08 ret
2009f00: 81 e8 00 00 restore
02009d60 <_User_extensions_Handler_initialization>:
#include <rtems/score/userext.h>
#include <rtems/score/wkspace.h>
#include <string.h>
void _User_extensions_Handler_initialization(void)
{
2009d60: 9d e3 bf a0 save %sp, -96, %sp
User_extensions_Control *extension;
uint32_t i;
uint32_t number_of_extensions;
User_extensions_Table *initial_extensions;
number_of_extensions = Configuration.number_of_initial_extensions;
2009d64: 07 00 80 7a sethi %hi(0x201e800), %g3
2009d68: 86 10 e0 68 or %g3, 0x68, %g3 ! 201e868 <Configuration>
initial_extensions = Configuration.User_extension_table;
2009d6c: e6 00 e0 3c ld [ %g3 + 0x3c ], %l3
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2009d70: 1b 00 80 7d sethi %hi(0x201f400), %o5
2009d74: 09 00 80 7c sethi %hi(0x201f000), %g4
2009d78: 84 13 61 d8 or %o5, 0x1d8, %g2
2009d7c: 82 11 23 a4 or %g4, 0x3a4, %g1
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2009d80: c4 20 a0 08 st %g2, [ %g2 + 8 ]
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2009d84: c0 20 a0 04 clr [ %g2 + 4 ]
the_chain->last = _Chain_Head(the_chain);
2009d88: c2 20 60 08 st %g1, [ %g1 + 8 ]
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2009d8c: c0 20 60 04 clr [ %g1 + 4 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2009d90: 84 00 a0 04 add %g2, 4, %g2
2009d94: 82 00 60 04 add %g1, 4, %g1
2009d98: c4 23 61 d8 st %g2, [ %o5 + 0x1d8 ]
2009d9c: c2 21 23 a4 st %g1, [ %g4 + 0x3a4 ]
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
2009da0: 80 a4 e0 00 cmp %l3, 0
2009da4: 02 80 00 1b be 2009e10 <_User_extensions_Handler_initialization+0xb0>
2009da8: e4 00 e0 38 ld [ %g3 + 0x38 ], %l2
extension = (User_extensions_Control *)
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
2009dac: 83 2c a0 02 sll %l2, 2, %g1
2009db0: a3 2c a0 04 sll %l2, 4, %l1
2009db4: a2 24 40 01 sub %l1, %g1, %l1
2009db8: a2 04 40 12 add %l1, %l2, %l1
2009dbc: a3 2c 60 02 sll %l1, 2, %l1
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
extension = (User_extensions_Control *)
2009dc0: 40 00 01 6f call 200a37c <_Workspace_Allocate_or_fatal_error>
2009dc4: 90 10 00 11 mov %l1, %o0
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
);
memset (
2009dc8: 94 10 00 11 mov %l1, %o2
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
extension = (User_extensions_Control *)
2009dcc: a0 10 00 08 mov %o0, %l0
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
);
memset (
2009dd0: 40 00 21 86 call 20123e8 <memset>
2009dd4: 92 10 20 00 clr %o1
extension,
0,
number_of_extensions * sizeof( User_extensions_Control )
);
for ( i = 0 ; i < number_of_extensions ; i++ ) {
2009dd8: 80 a4 a0 00 cmp %l2, 0
2009ddc: 02 80 00 0d be 2009e10 <_User_extensions_Handler_initialization+0xb0><== NEVER TAKEN
2009de0: a2 10 20 00 clr %l1
RTEMS_INLINE_ROUTINE void _User_extensions_Add_set_with_table(
User_extensions_Control *extension,
const User_extensions_Table *extension_table
)
{
extension->Callouts = *extension_table;
2009de4: 93 2c 60 05 sll %l1, 5, %o1
2009de8: 94 10 20 20 mov 0x20, %o2
2009dec: 92 04 c0 09 add %l3, %o1, %o1
2009df0: 40 00 21 3f call 20122ec <memcpy>
2009df4: 90 04 20 14 add %l0, 0x14, %o0
_User_extensions_Add_set( extension );
2009df8: 40 00 13 9b call 200ec64 <_User_extensions_Add_set>
2009dfc: 90 10 00 10 mov %l0, %o0
2009e00: a2 04 60 01 inc %l1
2009e04: 80 a4 80 11 cmp %l2, %l1
2009e08: 18 bf ff f7 bgu 2009de4 <_User_extensions_Handler_initialization+0x84>
2009e0c: a0 04 20 34 add %l0, 0x34, %l0
2009e10: 81 c7 e0 08 ret
2009e14: 81 e8 00 00 restore
02009e18 <_User_extensions_Thread_begin>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_begin (
Thread_Control *executing
)
{
2009e18: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009e1c: 23 00 80 7d sethi %hi(0x201f400), %l1
2009e20: e0 04 61 d8 ld [ %l1 + 0x1d8 ], %l0 ! 201f5d8 <_User_extensions_List>
2009e24: a2 14 61 d8 or %l1, 0x1d8, %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2009e28: a2 04 60 04 add %l1, 4, %l1
2009e2c: 80 a4 00 11 cmp %l0, %l1
2009e30: 02 80 00 0c be 2009e60 <_User_extensions_Thread_begin+0x48><== NEVER TAKEN
2009e34: 01 00 00 00 nop
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_begin != NULL )
2009e38: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
2009e3c: 80 a0 60 00 cmp %g1, 0
2009e40: 02 80 00 04 be 2009e50 <_User_extensions_Thread_begin+0x38>
2009e44: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.thread_begin)( executing );
2009e48: 9f c0 40 00 call %g1
2009e4c: 01 00 00 00 nop
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009e50: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009e54: 80 a4 00 11 cmp %l0, %l1
2009e58: 32 bf ff f9 bne,a 2009e3c <_User_extensions_Thread_begin+0x24>
2009e5c: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
2009e60: 81 c7 e0 08 ret
2009e64: 81 e8 00 00 restore
02009f04 <_User_extensions_Thread_create>:
#include <rtems/score/userext.h>
bool _User_extensions_Thread_create (
Thread_Control *the_thread
)
{
2009f04: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
2009f08: 23 00 80 7d sethi %hi(0x201f400), %l1
2009f0c: e0 04 61 d8 ld [ %l1 + 0x1d8 ], %l0 ! 201f5d8 <_User_extensions_List>
2009f10: a2 14 61 d8 or %l1, 0x1d8, %l1
2009f14: a2 04 60 04 add %l1, 4, %l1
2009f18: 80 a4 00 11 cmp %l0, %l1
2009f1c: 02 80 00 10 be 2009f5c <_User_extensions_Thread_create+0x58><== NEVER TAKEN
2009f20: 25 00 80 7d sethi %hi(0x201f400), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_create != NULL ) {
status = (*the_extension->Callouts.thread_create)(
2009f24: a4 14 a0 60 or %l2, 0x60, %l2 ! 201f460 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_create != NULL ) {
2009f28: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
2009f2c: 80 a0 60 00 cmp %g1, 0
2009f30: 02 80 00 07 be 2009f4c <_User_extensions_Thread_create+0x48>
2009f34: 92 10 00 18 mov %i0, %o1
status = (*the_extension->Callouts.thread_create)(
2009f38: 9f c0 40 00 call %g1
2009f3c: d0 04 80 00 ld [ %l2 ], %o0
_Thread_Executing,
the_thread
);
if ( !status )
2009f40: 80 8a 20 ff btst 0xff, %o0
2009f44: 02 80 00 08 be 2009f64 <_User_extensions_Thread_create+0x60>
2009f48: 01 00 00 00 nop
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009f4c: e0 04 00 00 ld [ %l0 ], %l0
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
2009f50: 80 a4 00 11 cmp %l0, %l1
2009f54: 32 bf ff f6 bne,a 2009f2c <_User_extensions_Thread_create+0x28>
2009f58: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
return false;
}
}
return true;
}
2009f5c: 81 c7 e0 08 ret
2009f60: 91 e8 20 01 restore %g0, 1, %o0
if ( the_extension->Callouts.thread_create != NULL ) {
status = (*the_extension->Callouts.thread_create)(
_Thread_Executing,
the_thread
);
if ( !status )
2009f64: 81 c7 e0 08 ret
2009f68: 91 e8 20 00 restore %g0, 0, %o0
02009f6c <_User_extensions_Thread_delete>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_delete (
Thread_Control *the_thread
)
{
2009f6c: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009f70: 23 00 80 7d sethi %hi(0x201f400), %l1
2009f74: a2 14 61 d8 or %l1, 0x1d8, %l1 ! 201f5d8 <_User_extensions_List>
2009f78: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009f7c: 80 a4 00 11 cmp %l0, %l1
2009f80: 02 80 00 0d be 2009fb4 <_User_extensions_Thread_delete+0x48><== NEVER TAKEN
2009f84: 25 00 80 7d sethi %hi(0x201f400), %l2
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_delete != NULL )
(*the_extension->Callouts.thread_delete)(
2009f88: a4 14 a0 60 or %l2, 0x60, %l2 ! 201f460 <_Thread_Executing>
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_delete != NULL )
2009f8c: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2009f90: 80 a0 60 00 cmp %g1, 0
2009f94: 02 80 00 04 be 2009fa4 <_User_extensions_Thread_delete+0x38>
2009f98: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_delete)(
2009f9c: 9f c0 40 00 call %g1
2009fa0: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009fa4: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009fa8: 80 a4 00 11 cmp %l0, %l1
2009fac: 32 bf ff f9 bne,a 2009f90 <_User_extensions_Thread_delete+0x24>
2009fb0: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2009fb4: 81 c7 e0 08 ret
2009fb8: 81 e8 00 00 restore
02009e68 <_User_extensions_Thread_exitted>:
}
void _User_extensions_Thread_exitted (
Thread_Control *executing
)
{
2009e68: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009e6c: 23 00 80 7d sethi %hi(0x201f400), %l1
2009e70: a2 14 61 d8 or %l1, 0x1d8, %l1 ! 201f5d8 <_User_extensions_List>
2009e74: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009e78: 80 a4 00 11 cmp %l0, %l1
2009e7c: 02 80 00 0c be 2009eac <_User_extensions_Thread_exitted+0x44><== NEVER TAKEN
2009e80: 01 00 00 00 nop
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_exitted != NULL )
2009e84: c2 04 20 2c ld [ %l0 + 0x2c ], %g1
2009e88: 80 a0 60 00 cmp %g1, 0
2009e8c: 02 80 00 04 be 2009e9c <_User_extensions_Thread_exitted+0x34>
2009e90: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.thread_exitted)( executing );
2009e94: 9f c0 40 00 call %g1
2009e98: 01 00 00 00 nop
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009e9c: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009ea0: 80 a4 00 11 cmp %l0, %l1
2009ea4: 32 bf ff f9 bne,a 2009e88 <_User_extensions_Thread_exitted+0x20>
2009ea8: c2 04 20 2c ld [ %l0 + 0x2c ], %g1
2009eac: 81 c7 e0 08 ret
2009eb0: 81 e8 00 00 restore
0200acc4 <_User_extensions_Thread_restart>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_restart (
Thread_Control *the_thread
)
{
200acc4: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
200acc8: 23 00 80 8f sethi %hi(0x2023c00), %l1
200accc: e0 04 63 78 ld [ %l1 + 0x378 ], %l0 ! 2023f78 <_User_extensions_List>
200acd0: a2 14 63 78 or %l1, 0x378, %l1
200acd4: a2 04 60 04 add %l1, 4, %l1
200acd8: 80 a4 00 11 cmp %l0, %l1
200acdc: 02 80 00 0d be 200ad10 <_User_extensions_Thread_restart+0x4c><== NEVER TAKEN
200ace0: 25 00 80 8f sethi %hi(0x2023c00), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_restart != NULL )
(*the_extension->Callouts.thread_restart)(
200ace4: a4 14 a2 00 or %l2, 0x200, %l2 ! 2023e00 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_restart != NULL )
200ace8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200acec: 80 a0 60 00 cmp %g1, 0
200acf0: 02 80 00 04 be 200ad00 <_User_extensions_Thread_restart+0x3c>
200acf4: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_restart)(
200acf8: 9f c0 40 00 call %g1
200acfc: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
200ad00: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
200ad04: 80 a4 00 11 cmp %l0, %l1
200ad08: 32 bf ff f9 bne,a 200acec <_User_extensions_Thread_restart+0x28>
200ad0c: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200ad10: 81 c7 e0 08 ret
200ad14: 81 e8 00 00 restore
02009fbc <_User_extensions_Thread_start>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_start (
Thread_Control *the_thread
)
{
2009fbc: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009fc0: 23 00 80 7d sethi %hi(0x201f400), %l1
2009fc4: e0 04 61 d8 ld [ %l1 + 0x1d8 ], %l0 ! 201f5d8 <_User_extensions_List>
2009fc8: a2 14 61 d8 or %l1, 0x1d8, %l1
2009fcc: a2 04 60 04 add %l1, 4, %l1
2009fd0: 80 a4 00 11 cmp %l0, %l1
2009fd4: 02 80 00 0d be 200a008 <_User_extensions_Thread_start+0x4c><== NEVER TAKEN
2009fd8: 25 00 80 7d sethi %hi(0x201f400), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_start != NULL )
(*the_extension->Callouts.thread_start)(
2009fdc: a4 14 a0 60 or %l2, 0x60, %l2 ! 201f460 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_start != NULL )
2009fe0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
2009fe4: 80 a0 60 00 cmp %g1, 0
2009fe8: 02 80 00 04 be 2009ff8 <_User_extensions_Thread_start+0x3c>
2009fec: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_start)(
2009ff0: 9f c0 40 00 call %g1
2009ff4: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009ff8: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009ffc: 80 a4 00 11 cmp %l0, %l1
200a000: 32 bf ff f9 bne,a 2009fe4 <_User_extensions_Thread_start+0x28>
200a004: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
200a008: 81 c7 e0 08 ret
200a00c: 81 e8 00 00 restore
0200a010 <_User_extensions_Thread_switch>:
void _User_extensions_Thread_switch (
Thread_Control *executing,
Thread_Control *heir
)
{
200a010: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
200a014: 23 00 80 7c sethi %hi(0x201f000), %l1
200a018: e0 04 63 a4 ld [ %l1 + 0x3a4 ], %l0 ! 201f3a4 <_User_extensions_Switches_list>
200a01c: a2 14 63 a4 or %l1, 0x3a4, %l1
200a020: a2 04 60 04 add %l1, 4, %l1
200a024: 80 a4 00 11 cmp %l0, %l1
200a028: 02 80 00 0a be 200a050 <_User_extensions_Thread_switch+0x40><== NEVER TAKEN
200a02c: 01 00 00 00 nop
!_Chain_Is_tail( &_User_extensions_Switches_list, the_node ) ;
the_node = the_node->next ) {
the_extension_switch = (User_extensions_Switch_control *) the_node;
(*the_extension_switch->thread_switch)( executing, heir );
200a030: c2 04 20 08 ld [ %l0 + 8 ], %g1
200a034: 90 10 00 18 mov %i0, %o0
200a038: 9f c0 40 00 call %g1
200a03c: 92 10 00 19 mov %i1, %o1
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
!_Chain_Is_tail( &_User_extensions_Switches_list, the_node ) ;
the_node = the_node->next ) {
200a040: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
200a044: 80 a4 00 11 cmp %l0, %l1
200a048: 32 bf ff fb bne,a 200a034 <_User_extensions_Thread_switch+0x24>
200a04c: c2 04 20 08 ld [ %l0 + 8 ], %g1
200a050: 81 c7 e0 08 ret
200a054: 81 e8 00 00 restore
0200c2a4 <_Watchdog_Adjust>:
void _Watchdog_Adjust(
Chain_Control *header,
Watchdog_Adjust_directions direction,
Watchdog_Interval units
)
{
200c2a4: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
_ISR_Disable( level );
200c2a8: 7f ff db 5c call 2003018 <sparc_disable_interrupts>
200c2ac: a0 10 00 18 mov %i0, %l0
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200c2b0: c2 06 00 00 ld [ %i0 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200c2b4: a2 06 20 04 add %i0, 4, %l1
* hence the compiler must not assume *header to remain
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
200c2b8: 80 a0 40 11 cmp %g1, %l1
200c2bc: 02 80 00 1f be 200c338 <_Watchdog_Adjust+0x94>
200c2c0: 80 a6 60 00 cmp %i1, 0
switch ( direction ) {
200c2c4: 12 80 00 1f bne 200c340 <_Watchdog_Adjust+0x9c>
200c2c8: 80 a6 60 01 cmp %i1, 1
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
break;
case WATCHDOG_FORWARD:
while ( units ) {
200c2cc: 80 a6 a0 00 cmp %i2, 0
200c2d0: 02 80 00 1a be 200c338 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c2d4: 01 00 00 00 nop
if ( units < _Watchdog_First( header )->delta_interval ) {
200c2d8: f2 00 60 10 ld [ %g1 + 0x10 ], %i1
200c2dc: 80 a6 80 19 cmp %i2, %i1
200c2e0: 1a 80 00 0b bcc 200c30c <_Watchdog_Adjust+0x68> <== ALWAYS TAKEN
200c2e4: a4 10 20 01 mov 1, %l2
_Watchdog_First( header )->delta_interval -= units;
200c2e8: 10 80 00 1d b 200c35c <_Watchdog_Adjust+0xb8> <== NOT EXECUTED
200c2ec: b4 26 40 1a sub %i1, %i2, %i2 <== NOT EXECUTED
switch ( direction ) {
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
break;
case WATCHDOG_FORWARD:
while ( units ) {
200c2f0: b4 a6 80 19 subcc %i2, %i1, %i2
200c2f4: 02 80 00 11 be 200c338 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c2f8: 01 00 00 00 nop
if ( units < _Watchdog_First( header )->delta_interval ) {
200c2fc: f2 00 60 10 ld [ %g1 + 0x10 ], %i1
200c300: 80 a6 40 1a cmp %i1, %i2
200c304: 38 80 00 16 bgu,a 200c35c <_Watchdog_Adjust+0xb8>
200c308: b4 26 40 1a sub %i1, %i2, %i2
_Watchdog_First( header )->delta_interval -= units;
break;
} else {
units -= _Watchdog_First( header )->delta_interval;
_Watchdog_First( header )->delta_interval = 1;
200c30c: e4 20 60 10 st %l2, [ %g1 + 0x10 ]
_ISR_Enable( level );
200c310: 7f ff db 46 call 2003028 <sparc_enable_interrupts>
200c314: 01 00 00 00 nop
_Watchdog_Tickle( header );
200c318: 40 00 00 b2 call 200c5e0 <_Watchdog_Tickle>
200c31c: 90 10 00 10 mov %l0, %o0
_ISR_Disable( level );
200c320: 7f ff db 3e call 2003018 <sparc_disable_interrupts>
200c324: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200c328: c4 04 00 00 ld [ %l0 ], %g2
if ( _Chain_Is_empty( header ) )
200c32c: 80 a4 40 02 cmp %l1, %g2
200c330: 12 bf ff f0 bne 200c2f0 <_Watchdog_Adjust+0x4c>
200c334: 82 10 00 02 mov %g2, %g1
}
break;
}
}
_ISR_Enable( level );
200c338: 7f ff db 3c call 2003028 <sparc_enable_interrupts>
200c33c: 91 e8 00 08 restore %g0, %o0, %o0
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
switch ( direction ) {
200c340: 12 bf ff fe bne 200c338 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c344: 01 00 00 00 nop
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
200c348: c4 00 60 10 ld [ %g1 + 0x10 ], %g2
200c34c: b4 00 80 1a add %g2, %i2, %i2
200c350: f4 20 60 10 st %i2, [ %g1 + 0x10 ]
}
break;
}
}
_ISR_Enable( level );
200c354: 7f ff db 35 call 2003028 <sparc_enable_interrupts>
200c358: 91 e8 00 08 restore %g0, %o0, %o0
break;
case WATCHDOG_FORWARD:
while ( units ) {
if ( units < _Watchdog_First( header )->delta_interval ) {
_Watchdog_First( header )->delta_interval -= units;
break;
200c35c: 10 bf ff f7 b 200c338 <_Watchdog_Adjust+0x94>
200c360: f4 20 60 10 st %i2, [ %g1 + 0x10 ]
0200a1fc <_Watchdog_Remove>:
*/
Watchdog_States _Watchdog_Remove(
Watchdog_Control *the_watchdog
)
{
200a1fc: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Watchdog_States previous_state;
Watchdog_Control *next_watchdog;
_ISR_Disable( level );
200a200: 7f ff df a9 call 20020a4 <sparc_disable_interrupts>
200a204: 01 00 00 00 nop
previous_state = the_watchdog->state;
200a208: e0 06 20 08 ld [ %i0 + 8 ], %l0
switch ( previous_state ) {
200a20c: 80 a4 20 01 cmp %l0, 1
200a210: 02 80 00 2a be 200a2b8 <_Watchdog_Remove+0xbc>
200a214: 03 00 80 7d sethi %hi(0x201f400), %g1
200a218: 1a 80 00 09 bcc 200a23c <_Watchdog_Remove+0x40>
200a21c: 80 a4 20 03 cmp %l0, 3
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a220: 03 00 80 7d sethi %hi(0x201f400), %g1
200a224: c2 00 60 f4 ld [ %g1 + 0xf4 ], %g1 ! 201f4f4 <_Watchdog_Ticks_since_boot>
200a228: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a22c: 7f ff df a2 call 20020b4 <sparc_enable_interrupts>
200a230: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a234: 81 c7 e0 08 ret
200a238: 81 e8 00 00 restore
Watchdog_States previous_state;
Watchdog_Control *next_watchdog;
_ISR_Disable( level );
previous_state = the_watchdog->state;
switch ( previous_state ) {
200a23c: 18 bf ff fa bgu 200a224 <_Watchdog_Remove+0x28> <== NEVER TAKEN
200a240: 03 00 80 7d sethi %hi(0x201f400), %g1
RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_Next(
Watchdog_Control *the_watchdog
)
{
return ( (Watchdog_Control *) the_watchdog->Node.next );
200a244: c2 06 00 00 ld [ %i0 ], %g1
break;
case WATCHDOG_ACTIVE:
case WATCHDOG_REMOVE_IT:
the_watchdog->state = WATCHDOG_INACTIVE;
200a248: c0 26 20 08 clr [ %i0 + 8 ]
next_watchdog = _Watchdog_Next( the_watchdog );
if ( _Watchdog_Next(next_watchdog) )
200a24c: c4 00 40 00 ld [ %g1 ], %g2
200a250: 80 a0 a0 00 cmp %g2, 0
200a254: 02 80 00 07 be 200a270 <_Watchdog_Remove+0x74>
200a258: 05 00 80 7d sethi %hi(0x201f400), %g2
next_watchdog->delta_interval += the_watchdog->delta_interval;
200a25c: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
200a260: c4 06 20 10 ld [ %i0 + 0x10 ], %g2
200a264: 84 00 c0 02 add %g3, %g2, %g2
200a268: c4 20 60 10 st %g2, [ %g1 + 0x10 ]
if ( _Watchdog_Sync_count )
200a26c: 05 00 80 7d sethi %hi(0x201f400), %g2
200a270: c4 00 a0 f0 ld [ %g2 + 0xf0 ], %g2 ! 201f4f0 <_Watchdog_Sync_count>
200a274: 80 a0 a0 00 cmp %g2, 0
200a278: 22 80 00 07 be,a 200a294 <_Watchdog_Remove+0x98>
200a27c: c4 06 20 04 ld [ %i0 + 4 ], %g2
_Watchdog_Sync_level = _ISR_Nest_level;
200a280: 05 00 80 7d sethi %hi(0x201f400), %g2
200a284: c6 00 a0 3c ld [ %g2 + 0x3c ], %g3 ! 201f43c <_ISR_Nest_level>
200a288: 05 00 80 7d sethi %hi(0x201f400), %g2
200a28c: c6 20 a0 5c st %g3, [ %g2 + 0x5c ] ! 201f45c <_Watchdog_Sync_level>
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
200a290: c4 06 20 04 ld [ %i0 + 4 ], %g2
next->previous = previous;
previous->next = next;
200a294: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
200a298: c4 20 60 04 st %g2, [ %g1 + 4 ]
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a29c: 03 00 80 7d sethi %hi(0x201f400), %g1
200a2a0: c2 00 60 f4 ld [ %g1 + 0xf4 ], %g1 ! 201f4f4 <_Watchdog_Ticks_since_boot>
200a2a4: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a2a8: 7f ff df 83 call 20020b4 <sparc_enable_interrupts>
200a2ac: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a2b0: 81 c7 e0 08 ret
200a2b4: 81 e8 00 00 restore
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a2b8: c2 00 60 f4 ld [ %g1 + 0xf4 ], %g1
/*
* It is not actually on the chain so just change the state and
* the Insert operation we interrupted will be aborted.
*/
the_watchdog->state = WATCHDOG_INACTIVE;
200a2bc: c0 26 20 08 clr [ %i0 + 8 ]
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a2c0: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a2c4: 7f ff df 7c call 20020b4 <sparc_enable_interrupts>
200a2c8: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a2cc: 81 c7 e0 08 ret
200a2d0: 81 e8 00 00 restore
0200ba50 <_Watchdog_Report_chain>:
void _Watchdog_Report_chain(
const char *name,
Chain_Control *header
)
{
200ba50: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Chain_Node *node;
_ISR_Disable( level );
200ba54: 7f ff dc 38 call 2002b34 <sparc_disable_interrupts>
200ba58: a0 10 00 18 mov %i0, %l0
200ba5c: b0 10 00 08 mov %o0, %i0
printk( "Watchdog Chain: %s %p\n", name, header );
200ba60: 11 00 80 8b sethi %hi(0x2022c00), %o0
200ba64: 94 10 00 19 mov %i1, %o2
200ba68: 90 12 23 e0 or %o0, 0x3e0, %o0
200ba6c: 7f ff e4 07 call 2004a88 <printk>
200ba70: 92 10 00 10 mov %l0, %o1
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200ba74: e2 06 40 00 ld [ %i1 ], %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200ba78: b2 06 60 04 add %i1, 4, %i1
if ( !_Chain_Is_empty( header ) ) {
200ba7c: 80 a4 40 19 cmp %l1, %i1
200ba80: 02 80 00 0f be 200babc <_Watchdog_Report_chain+0x6c>
200ba84: 11 00 80 8c sethi %hi(0x2023000), %o0
node != _Chain_Tail(header) ;
node = node->next )
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
200ba88: 92 10 00 11 mov %l1, %o1
200ba8c: 40 00 00 11 call 200bad0 <_Watchdog_Report>
200ba90: 90 10 20 00 clr %o0
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = header->first ;
node != _Chain_Tail(header) ;
node = node->next )
200ba94: e2 04 40 00 ld [ %l1 ], %l1
Chain_Node *node;
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = header->first ;
200ba98: 80 a4 40 19 cmp %l1, %i1
200ba9c: 12 bf ff fc bne 200ba8c <_Watchdog_Report_chain+0x3c> <== NEVER TAKEN
200baa0: 92 10 00 11 mov %l1, %o1
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
}
printk( "== end of %s \n", name );
200baa4: 92 10 00 10 mov %l0, %o1
200baa8: 11 00 80 8b sethi %hi(0x2022c00), %o0
200baac: 7f ff e3 f7 call 2004a88 <printk>
200bab0: 90 12 23 f8 or %o0, 0x3f8, %o0 ! 2022ff8 <_Status_Object_name_errors_to_status+0x30>
} else {
printk( "Chain is empty\n" );
}
_ISR_Enable( level );
200bab4: 7f ff dc 24 call 2002b44 <sparc_enable_interrupts>
200bab8: 81 e8 00 00 restore
_Watchdog_Report( NULL, watch );
}
printk( "== end of %s \n", name );
} else {
printk( "Chain is empty\n" );
200babc: 7f ff e3 f3 call 2004a88 <printk>
200bac0: 90 12 20 08 or %o0, 8, %o0
}
_ISR_Enable( level );
200bac4: 7f ff dc 20 call 2002b44 <sparc_enable_interrupts>
200bac8: 81 e8 00 00 restore
0201c6e8 <_exit>:
/*
* If the toolset uses init/fini sections, then we need to
* run the global destructors now.
*/
#if defined(__USE_INIT_FINI__)
FINI_SYMBOL();
201c6e8: 9d e3 bf a0 save %sp, -96, %sp
201c6ec: 40 00 08 26 call 201e784 <_fini>
201c6f0: 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();
201c6f4: 7f ff ff e2 call 201c67c <libc_wrapup>
201c6f8: 01 00 00 00 nop
rtems_shutdown_executive(status);
201c6fc: 40 00 00 50 call 201c83c <rtems_shutdown_executive>
201c700: 90 10 00 18 mov %i0, %o0
201c704: 30 80 00 00 b,a 201c704 <_exit+0x1c> <== NOT EXECUTED
02029c18 <_fat_block_read>:
uint32_t start,
uint32_t offset,
uint32_t count,
void *buff
)
{
2029c18: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
2029c1c: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while (count > 0)
2029c20: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2029c24: 02 80 00 1d be 2029c98 <_fat_block_read+0x80> <== NOT EXECUTED
2029c28: b0 10 20 00 clr %i0 <== NOT EXECUTED
int rc = RC_OK;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
ssize_t cmpltd = 0;
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
2029c2c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
2029c30: 10 80 00 10 b 2029c70 <_fat_block_read+0x58> <== NOT EXECUTED
2029c34: a2 07 bf fc add %fp, -4, %l1 <== NOT EXECUTED
{
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return -1;
c = MIN(count, (fs_info->vol.bps - ofs));
2029c38: e4 14 00 00 lduh [ %l0 ], %l2 <== NOT EXECUTED
2029c3c: a4 24 80 1a sub %l2, %i2, %l2 <== NOT EXECUTED
2029c40: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2029c44: 08 80 00 03 bleu 2029c50 <_fat_block_read+0x38> <== NOT EXECUTED
2029c48: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2029c4c: a4 10 00 1b mov %i3, %l2 <== NOT EXECUTED
memcpy((buff + cmpltd), (block->buffer + ofs), c);
2029c50: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2029c54: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2029c58: 40 00 8f 56 call 204d9b0 <memcpy> <== NOT EXECUTED
2029c5c: 92 02 40 1a add %o1, %i2, %o1 <== NOT EXECUTED
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while (count > 0)
2029c60: b6 a6 c0 12 subcc %i3, %l2, %i3 <== NOT EXECUTED
2029c64: 02 80 00 0d be 2029c98 <_fat_block_read+0x80> <== NOT EXECUTED
2029c68: b0 04 80 18 add %l2, %i0, %i0 <== NOT EXECUTED
c = MIN(count, (fs_info->vol.bps - ofs));
memcpy((buff + cmpltd), (block->buffer + ofs), c);
count -= c;
cmpltd += c;
blk++;
2029c6c: b4 10 20 00 clr %i2 <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while (count > 0)
{
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
2029c70: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2029c74: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
2029c78: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2029c7c: 7f ff fe 6c call 202962c <fat_buf_access> <== NOT EXECUTED
2029c80: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
c = MIN(count, (fs_info->vol.bps - ofs));
memcpy((buff + cmpltd), (block->buffer + ofs), c);
count -= c;
cmpltd += c;
blk++;
2029c84: b2 06 60 01 inc %i1 <== NOT EXECUTED
uint32_t c = 0;
while (count > 0)
{
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
2029c88: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029c8c: 02 bf ff eb be 2029c38 <_fat_block_read+0x20> <== NOT EXECUTED
2029c90: 90 07 00 18 add %i4, %i0, %o0 <== NOT EXECUTED
c = MIN(count, (fs_info->vol.bps - ofs));
memcpy((buff + cmpltd), (block->buffer + ofs), c);
count -= c;
cmpltd += c;
blk++;
2029c94: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
ofs = 0;
}
return cmpltd;
}
2029c98: 81 c7 e0 08 ret <== NOT EXECUTED
2029c9c: 81 e8 00 00 restore <== NOT EXECUTED
02029618 <_fat_block_release>:
int
_fat_block_release(
rtems_filesystem_mount_table_entry_t *mt_entry)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
return fat_buf_release(fs_info);
2029618: d0 02 20 34 ld [ %o0 + 0x34 ], %o0 <== NOT EXECUTED
202961c: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2029620: 7f ff ff 9c call 2029490 <fat_buf_release> <== NOT EXECUTED
2029624: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0202984c <_fat_block_write>:
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t start,
uint32_t offset,
uint32_t count,
const void *buff)
{
202984c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
2029850: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while(count > 0)
2029854: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2029858: 02 80 00 2a be 2029900 <_fat_block_write+0xb4> <== NOT EXECUTED
202985c: b0 10 20 00 clr %i0 <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
ssize_t cmpltd = 0;
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
2029860: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
2029864: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
}
static inline void
fat_buf_mark_modified(fat_fs_info_t *fs_info)
{
fs_info->c.modified = true;
2029868: 10 80 00 13 b 20298b4 <_fat_block_write+0x68> <== NOT EXECUTED
202986c: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
c = MIN(count, (fs_info->vol.bps - ofs));
if (c == fs_info->vol.bps)
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_GET, &block);
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
2029870: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
2029874: 7f ff ff 6e call 202962c <fat_buf_access> <== NOT EXECUTED
2029878: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
if (rc != RC_OK)
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);
202987c: 92 07 00 18 add %i4, %i0, %o1 <== NOT EXECUTED
if (c == fs_info->vol.bps)
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_GET, &block);
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
2029880: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029884: 12 80 00 1e bne 20298fc <_fat_block_write+0xb0> <== NOT EXECUTED
2029888: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);
202988c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
count -= c;
cmpltd +=c;
2029890: b0 04 00 18 add %l0, %i0, %i0 <== NOT EXECUTED
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);
2029894: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
count -= c;
cmpltd +=c;
blk++;
2029898: b2 06 60 01 inc %i1 <== NOT EXECUTED
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);
202989c: 40 00 90 45 call 204d9b0 <memcpy> <== NOT EXECUTED
20298a0: 90 02 00 1a add %o0, %i2, %o0 <== NOT EXECUTED
uint32_t blk = start;
uint32_t ofs = offset;
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while(count > 0)
20298a4: b6 a6 c0 10 subcc %i3, %l0, %i3 <== NOT EXECUTED
20298a8: 02 80 00 16 be 2029900 <_fat_block_write+0xb4> <== NOT EXECUTED
20298ac: e6 2c 60 84 stb %l3, [ %l1 + 0x84 ] <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
count -= c;
cmpltd +=c;
blk++;
20298b0: b4 10 20 00 clr %i2 <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
uint32_t c = 0;
while(count > 0)
{
c = MIN(count, (fs_info->vol.bps - ofs));
20298b4: c2 14 40 00 lduh [ %l1 ], %g1 <== NOT EXECUTED
20298b8: a0 20 40 1a sub %g1, %i2, %l0 <== NOT EXECUTED
20298bc: 80 a4 00 1b cmp %l0, %i3 <== NOT EXECUTED
20298c0: 08 80 00 03 bleu 20298cc <_fat_block_write+0x80> <== NOT EXECUTED
20298c4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20298c8: a0 10 00 1b mov %i3, %l0 <== NOT EXECUTED
if (c == fs_info->vol.bps)
20298cc: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
20298d0: 32 bf ff e8 bne,a 2029870 <_fat_block_write+0x24> <== NOT EXECUTED
20298d4: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_GET, &block);
20298d8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20298dc: 94 10 20 02 mov 2, %o2 <== NOT EXECUTED
20298e0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20298e4: 7f ff ff 52 call 202962c <fat_buf_access> <== NOT EXECUTED
20298e8: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);
20298ec: 92 07 00 18 add %i4, %i0, %o1 <== NOT EXECUTED
if (c == fs_info->vol.bps)
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_GET, &block);
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
20298f0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20298f4: 02 bf ff e6 be 202988c <_fat_block_write+0x40> <== NOT EXECUTED
20298f8: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
count -= c;
cmpltd +=c;
blk++;
20298fc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
ofs = 0;
}
return cmpltd;
}
2029900: 81 c7 e0 08 ret <== NOT EXECUTED
2029904: 81 e8 00 00 restore <== NOT EXECUTED
02045f30 <_fcntl_r>:
int fd,
int cmd,
int arg
)
{
return fcntl( fd, cmd, arg );
2045f30: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
2045f34: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
2045f38: 94 10 00 0b mov %o3, %o2 <== NOT EXECUTED
2045f3c: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2045f40: 7f ff ff 69 call 2045ce4 <fcntl> <== NOT EXECUTED
2045f44: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200cb50 <_getpid_r>:
pid_t _getpid_r(
struct _reent *ptr __attribute__((unused))
)
{
return getpid();
}
200cb50: 81 c3 e0 08 retl <== NOT EXECUTED
200cb54: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
02002dfc <_gettimeofday>:
int _gettimeofday(
struct timeval *tp,
struct timezone *tzp
)
{
return gettimeofday( tp, tzp );
2002dfc: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2002e00: 7f ff ff e6 call 2002d98 <gettimeofday> <== NOT EXECUTED
2002e04: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0202d9c0 <_link_r>:
struct _reent *ptr __attribute__((unused)),
const char *existing,
const char *new
)
{
return link( existing, new );
202d9c0: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
202d9c4: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
202d9c8: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202d9cc: 7f ff ff 70 call 202d78c <link> <== NOT EXECUTED
202d9d0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0202dc98 <_lstat_r>:
struct _reent *ptr __attribute__((unused)),
const char *path,
struct stat *buf
)
{
return _STAT_NAME( path, buf );
202dc98: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
202dc9c: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
202dca0: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202dca4: 7f ff ff b1 call 202db68 <lstat> <== NOT EXECUTED
202dca8: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0201c808 <_realloc_r>:
struct _reent *ignored __attribute__((unused)),
void *ptr,
size_t size
)
{
return realloc( ptr, size );
201c808: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
201c80c: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
201c810: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
201c814: 40 00 00 17 call 201c870 <realloc> <== NOT EXECUTED
201c818: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02064084 <_rename_r>:
int _rename_r(
struct _reent *ptr __attribute__((unused)),
const char *old,
const char *new
)
{
2064084: 9d e3 bf 58 save %sp, -168, %sp
/*
* Get the parent node of the old path to be renamed. Find the parent path.
*/
old_parent_pathlen = rtems_filesystem_dirname ( old );
2064088: 7f fe 91 a2 call 2008710 <rtems_filesystem_dirname>
206408c: 90 10 00 19 mov %i1, %o0
if ( old_parent_pathlen == 0 )
2064090: 80 a2 20 00 cmp %o0, 0
2064094: 12 80 00 9d bne 2064308 <_rename_r+0x284>
2064098: a0 07 bf d0 add %fp, -48, %l0
rtems_filesystem_get_start_loc( old, &i, &old_parent_loc );
206409c: 90 10 00 19 mov %i1, %o0
20640a0: 92 07 bf fc add %fp, -4, %o1
20640a4: 94 10 00 10 mov %l0, %o2
20640a8: 7f fe 99 10 call 200a4e8 <rtems_filesystem_get_start_loc>
20640ac: a2 10 20 00 clr %l1
20640b0: a4 10 20 00 clr %l2
/*
* Start from the parent to find the node that should be under it.
*/
old_loc = old_parent_loc;
20640b4: c2 07 bf d0 ld [ %fp + -48 ], %g1
name = old + old_parent_pathlen;
20640b8: b2 06 40 11 add %i1, %l1, %i1
/*
* Start from the parent to find the node that should be under it.
*/
old_loc = old_parent_loc;
20640bc: c2 27 bf e4 st %g1, [ %fp + -28 ]
20640c0: c2 07 bf d4 ld [ %fp + -44 ], %g1
name = old + old_parent_pathlen;
20640c4: f2 27 bf f8 st %i1, [ %fp + -8 ]
/*
* Start from the parent to find the node that should be under it.
*/
old_loc = old_parent_loc;
20640c8: c2 27 bf e8 st %g1, [ %fp + -24 ]
20640cc: c2 07 bf d8 ld [ %fp + -40 ], %g1
name = old + old_parent_pathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
20640d0: 90 10 00 19 mov %i1, %o0
/*
* Start from the parent to find the node that should be under it.
*/
old_loc = old_parent_loc;
20640d4: c2 27 bf ec st %g1, [ %fp + -20 ]
20640d8: c2 07 bf dc ld [ %fp + -36 ], %g1
20640dc: c2 27 bf f0 st %g1, [ %fp + -16 ]
20640e0: c2 07 bf e0 ld [ %fp + -32 ], %g1
name = old + old_parent_pathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
20640e4: 7f ff b4 a3 call 2051370 <strlen>
20640e8: c2 27 bf f4 st %g1, [ %fp + -12 ]
20640ec: 92 10 00 08 mov %o0, %o1
20640f0: 7f fe 91 6d call 20086a4 <rtems_filesystem_prefix_separators>
20640f4: 90 10 00 19 mov %i1, %o0
20640f8: b2 06 40 08 add %i1, %o0, %i1
20640fc: f2 27 bf f8 st %i1, [ %fp + -8 ]
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
2064100: 7f ff b4 9c call 2051370 <strlen>
2064104: 90 10 00 19 mov %i1, %o0
2064108: 94 10 20 00 clr %o2
206410c: 92 10 00 08 mov %o0, %o1
2064110: 98 10 20 00 clr %o4
2064114: 90 10 00 19 mov %i1, %o0
2064118: b2 07 bf e4 add %fp, -28, %i1
206411c: 7f fe 91 90 call 200875c <rtems_filesystem_evaluate_relative_path>
2064120: 96 10 00 19 mov %i1, %o3
0, &old_loc, false );
if ( result != 0 ) {
2064124: 80 a2 20 00 cmp %o0, 0
2064128: 12 80 00 41 bne 206422c <_rename_r+0x1a8>
206412c: a2 07 bf bc add %fp, -68, %l1
/*
* Get the parent of the new node we are renaming to.
*/
rtems_filesystem_get_start_loc( new, &i, &new_parent_loc );
2064130: 90 10 00 1a mov %i2, %o0
2064134: 92 07 bf fc add %fp, -4, %o1
2064138: 7f fe 98 ec call 200a4e8 <rtems_filesystem_get_start_loc>
206413c: 94 10 00 11 mov %l1, %o2
if ( !new_parent_loc.ops->evalformake_h ) {
2064140: c2 07 bf c8 ld [ %fp + -56 ], %g1
2064144: c2 00 60 04 ld [ %g1 + 4 ], %g1
2064148: 80 a0 60 00 cmp %g1, 0
206414c: 02 80 00 a4 be 20643dc <_rename_r+0x358>
2064150: 92 10 00 11 mov %l1, %o1
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 );
2064154: d0 07 bf fc ld [ %fp + -4 ], %o0
2064158: 90 06 80 08 add %i2, %o0, %o0
206415c: 9f c0 40 00 call %g1
2064160: 94 07 bf f8 add %fp, -8, %o2
if ( result != 0 ) {
2064164: 80 a2 20 00 cmp %o0, 0
2064168: 12 80 00 74 bne 2064338 <_rename_r+0x2b4>
206416c: c2 07 bf cc ld [ %fp + -52 ], %g1
/*
* 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 ) {
2064170: c4 07 bf e0 ld [ %fp + -32 ], %g2
2064174: 80 a0 80 01 cmp %g2, %g1
2064178: 12 80 00 32 bne 2064240 <_rename_r+0x1bc>
206417c: c4 07 bf c8 ld [ %fp + -56 ], %g2
rtems_filesystem_freenode( &old_parent_loc );
rtems_filesystem_freenode( &old_loc );
rtems_set_errno_and_return_minus_one( EXDEV );
}
if ( !new_parent_loc.ops->rename_h ) {
2064180: c2 00 a0 40 ld [ %g2 + 0x40 ], %g1
2064184: 80 a0 60 00 cmp %g1, 0
2064188: 02 80 00 8f be 20643c4 <_rename_r+0x340>
206418c: d6 07 bf f8 ld [ %fp + -8 ], %o3
rtems_filesystem_freenode( &old_parent_loc );
rtems_filesystem_freenode( &old_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*new_parent_loc.ops->rename_h)( &old_parent_loc, &old_loc, &new_parent_loc, name );
2064190: 90 10 00 10 mov %l0, %o0
2064194: 92 10 00 19 mov %i1, %o1
2064198: 9f c0 40 00 call %g1
206419c: 94 10 00 11 mov %l1, %o2
rtems_filesystem_freenode( &new_parent_loc );
20641a0: c2 07 bf c8 ld [ %fp + -56 ], %g1
20641a4: 80 a0 60 00 cmp %g1, 0
20641a8: 02 80 00 08 be 20641c8 <_rename_r+0x144> <== NEVER TAKEN
20641ac: b0 10 00 08 mov %o0, %i0
20641b0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20641b4: 80 a0 60 00 cmp %g1, 0
20641b8: 02 80 00 05 be 20641cc <_rename_r+0x148> <== NEVER TAKEN
20641bc: 80 8c a0 ff btst 0xff, %l2
20641c0: 9f c0 40 00 call %g1
20641c4: 90 10 00 11 mov %l1, %o0
if ( free_old_parentloc )
20641c8: 80 8c a0 ff btst 0xff, %l2
20641cc: 02 80 00 0d be 2064200 <_rename_r+0x17c>
20641d0: c2 07 bf f0 ld [ %fp + -16 ], %g1
rtems_filesystem_freenode( &old_parent_loc );
20641d4: c2 07 bf dc ld [ %fp + -36 ], %g1
20641d8: 80 a0 60 00 cmp %g1, 0
20641dc: 22 80 00 09 be,a 2064200 <_rename_r+0x17c> <== NEVER TAKEN
20641e0: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
20641e4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20641e8: 80 a0 60 00 cmp %g1, 0
20641ec: 22 80 00 05 be,a 2064200 <_rename_r+0x17c> <== NEVER TAKEN
20641f0: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
20641f4: 9f c0 40 00 call %g1
20641f8: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &old_loc );
20641fc: c2 07 bf f0 ld [ %fp + -16 ], %g1
2064200: 80 a0 60 00 cmp %g1, 0
2064204: 02 80 00 91 be 2064448 <_rename_r+0x3c4> <== NEVER TAKEN
2064208: 01 00 00 00 nop
206420c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2064210: 80 a0 60 00 cmp %g1, 0
2064214: 02 80 00 8d be 2064448 <_rename_r+0x3c4> <== NEVER TAKEN
2064218: 01 00 00 00 nop
206421c: 9f c0 40 00 call %g1
2064220: 90 10 00 19 mov %i1, %o0
2064224: 81 c7 e0 08 ret
2064228: 81 e8 00 00 restore
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
0, &old_loc, false );
if ( result != 0 ) {
if ( free_old_parentloc )
206422c: 80 8c a0 ff btst 0xff, %l2
2064230: 12 80 00 2b bne 20642dc <_rename_r+0x258> <== ALWAYS TAKEN
2064234: c2 07 bf dc ld [ %fp + -36 ], %g1
if ( free_old_parentloc )
rtems_filesystem_freenode( &old_parent_loc );
rtems_filesystem_freenode( &old_loc );
return result;
}
2064238: 81 c7 e0 08 ret <== NOT EXECUTED
206423c: 91 e8 3f ff restore %g0, -1, %o0 <== 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 ) {
rtems_filesystem_freenode( &new_parent_loc );
2064240: c2 07 bf c8 ld [ %fp + -56 ], %g1
2064244: 80 a0 60 00 cmp %g1, 0
2064248: 02 80 00 09 be 206426c <_rename_r+0x1e8> <== NEVER TAKEN
206424c: 80 8c a0 ff btst 0xff, %l2
2064250: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2064254: 80 a0 60 00 cmp %g1, 0
2064258: 02 80 00 05 be 206426c <_rename_r+0x1e8> <== NEVER TAKEN
206425c: 80 8c a0 ff btst 0xff, %l2
2064260: 9f c0 40 00 call %g1
2064264: 90 10 00 11 mov %l1, %o0
if ( free_old_parentloc )
2064268: 80 8c a0 ff btst 0xff, %l2
206426c: 02 80 00 0d be 20642a0 <_rename_r+0x21c>
2064270: c2 07 bf f0 ld [ %fp + -16 ], %g1
rtems_filesystem_freenode( &old_parent_loc );
2064274: c2 07 bf dc ld [ %fp + -36 ], %g1
2064278: 80 a0 60 00 cmp %g1, 0
206427c: 22 80 00 09 be,a 20642a0 <_rename_r+0x21c> <== NEVER TAKEN
2064280: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
2064284: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2064288: 80 a0 60 00 cmp %g1, 0
206428c: 22 80 00 05 be,a 20642a0 <_rename_r+0x21c> <== NEVER TAKEN
2064290: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
2064294: 9f c0 40 00 call %g1
2064298: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &old_loc );
206429c: c2 07 bf f0 ld [ %fp + -16 ], %g1
20642a0: 80 a0 60 00 cmp %g1, 0
20642a4: 02 80 00 08 be 20642c4 <_rename_r+0x240> <== NEVER TAKEN
20642a8: 01 00 00 00 nop
20642ac: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20642b0: 80 a0 60 00 cmp %g1, 0
20642b4: 02 80 00 04 be 20642c4 <_rename_r+0x240> <== NEVER TAKEN
20642b8: 01 00 00 00 nop
20642bc: 9f c0 40 00 call %g1
20642c0: 90 10 00 19 mov %i1, %o0
rtems_set_errno_and_return_minus_one( EXDEV );
20642c4: 7f ff 98 6f call 204a480 <__errno>
20642c8: b0 10 3f ff mov -1, %i0
20642cc: 82 10 20 12 mov 0x12, %g1
20642d0: c2 22 00 00 st %g1, [ %o0 ]
20642d4: 81 c7 e0 08 ret
20642d8: 81 e8 00 00 restore
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
0, &old_loc, false );
if ( result != 0 ) {
if ( free_old_parentloc )
rtems_filesystem_freenode( &old_parent_loc );
20642dc: 80 a0 60 00 cmp %g1, 0
20642e0: 02 bf ff d1 be 2064224 <_rename_r+0x1a0> <== NEVER TAKEN
20642e4: b0 10 3f ff mov -1, %i0
20642e8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20642ec: 80 a0 60 00 cmp %g1, 0
20642f0: 02 bf ff cd be 2064224 <_rename_r+0x1a0> <== NEVER TAKEN
20642f4: 90 10 00 10 mov %l0, %o0
20642f8: 9f c0 40 00 call %g1
20642fc: 01 00 00 00 nop
2064300: 81 c7 e0 08 ret
2064304: 81 e8 00 00 restore
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,
2064308: a2 10 00 08 mov %o0, %l1
206430c: 90 10 00 19 mov %i1, %o0
2064310: 92 10 00 11 mov %l1, %o1
2064314: 94 10 20 02 mov 2, %o2
2064318: 96 10 00 10 mov %l0, %o3
206431c: 7f fe 91 51 call 2008860 <rtems_filesystem_evaluate_path>
2064320: 98 10 20 00 clr %o4
RTEMS_LIBIO_PERMS_WRITE,
&old_parent_loc,
false );
if ( result != 0 )
2064324: 80 a2 20 00 cmp %o0, 0
2064328: 12 bf ff c4 bne 2064238 <_rename_r+0x1b4> <== NEVER TAKEN
206432c: a4 10 20 01 mov 1, %l2
/*
* Start from the parent to find the node that should be under it.
*/
old_loc = old_parent_loc;
2064330: 10 bf ff 62 b 20640b8 <_rename_r+0x34>
2064334: c2 07 bf d0 ld [ %fp + -48 ], %g1
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*new_parent_loc.ops->evalformake_h)( &new[i], &new_parent_loc, &name );
if ( result != 0 ) {
rtems_filesystem_freenode( &new_parent_loc );
2064338: c2 07 bf c8 ld [ %fp + -56 ], %g1
206433c: 80 a0 60 00 cmp %g1, 0
2064340: 02 80 00 09 be 2064364 <_rename_r+0x2e0> <== NEVER TAKEN
2064344: 80 8c a0 ff btst 0xff, %l2
2064348: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
206434c: 80 a0 60 00 cmp %g1, 0
2064350: 02 80 00 05 be 2064364 <_rename_r+0x2e0> <== NEVER TAKEN
2064354: 80 8c a0 ff btst 0xff, %l2
2064358: 9f c0 40 00 call %g1
206435c: 90 10 00 11 mov %l1, %o0
if ( free_old_parentloc )
2064360: 80 8c a0 ff btst 0xff, %l2
2064364: 02 80 00 0d be 2064398 <_rename_r+0x314> <== NEVER TAKEN
2064368: c2 07 bf f0 ld [ %fp + -16 ], %g1
rtems_filesystem_freenode( &old_parent_loc );
206436c: c2 07 bf dc ld [ %fp + -36 ], %g1
2064370: 80 a0 60 00 cmp %g1, 0
2064374: 22 80 00 09 be,a 2064398 <_rename_r+0x314> <== NEVER TAKEN
2064378: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
206437c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2064380: 80 a0 60 00 cmp %g1, 0
2064384: 22 80 00 05 be,a 2064398 <_rename_r+0x314> <== NEVER TAKEN
2064388: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
206438c: 9f c0 40 00 call %g1
2064390: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &old_loc );
2064394: c2 07 bf f0 ld [ %fp + -16 ], %g1
2064398: 80 a0 60 00 cmp %g1, 0
206439c: 02 bf ff a2 be 2064224 <_rename_r+0x1a0> <== NEVER TAKEN
20643a0: b0 10 3f ff mov -1, %i0
20643a4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20643a8: 80 a0 60 00 cmp %g1, 0
20643ac: 02 bf ff 9e be 2064224 <_rename_r+0x1a0> <== NEVER TAKEN
20643b0: 90 10 00 19 mov %i1, %o0
20643b4: 9f c0 40 00 call %g1
20643b8: 01 00 00 00 nop
20643bc: 81 c7 e0 08 ret
20643c0: 81 e8 00 00 restore
rtems_filesystem_freenode( &old_loc );
rtems_set_errno_and_return_minus_one( EXDEV );
}
if ( !new_parent_loc.ops->rename_h ) {
rtems_filesystem_freenode( &new_parent_loc );
20643c4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1
20643c8: 80 a0 60 00 cmp %g1, 0
20643cc: 02 80 00 05 be 20643e0 <_rename_r+0x35c> <== NEVER TAKEN
20643d0: 80 8c a0 ff btst 0xff, %l2
20643d4: 9f c0 40 00 call %g1
20643d8: 90 10 00 11 mov %l1, %o0
if ( free_old_parentloc )
20643dc: 80 8c a0 ff btst 0xff, %l2
20643e0: 02 80 00 0d be 2064414 <_rename_r+0x390> <== NEVER TAKEN
20643e4: c2 07 bf f0 ld [ %fp + -16 ], %g1
rtems_filesystem_freenode( &old_parent_loc );
20643e8: c2 07 bf dc ld [ %fp + -36 ], %g1
20643ec: 80 a0 60 00 cmp %g1, 0
20643f0: 22 80 00 09 be,a 2064414 <_rename_r+0x390> <== NEVER TAKEN
20643f4: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
20643f8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20643fc: 80 a0 60 00 cmp %g1, 0
2064400: 22 80 00 05 be,a 2064414 <_rename_r+0x390> <== NEVER TAKEN
2064404: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
2064408: 9f c0 40 00 call %g1
206440c: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &old_loc );
2064410: c2 07 bf f0 ld [ %fp + -16 ], %g1
2064414: 80 a0 60 00 cmp %g1, 0
2064418: 02 80 00 08 be 2064438 <_rename_r+0x3b4> <== NEVER TAKEN
206441c: 01 00 00 00 nop
2064420: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2064424: 80 a0 60 00 cmp %g1, 0
2064428: 02 80 00 04 be 2064438 <_rename_r+0x3b4> <== NEVER TAKEN
206442c: 01 00 00 00 nop
2064430: 9f c0 40 00 call %g1
2064434: 90 10 00 19 mov %i1, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
2064438: 7f ff 98 12 call 204a480 <__errno>
206443c: b0 10 3f ff mov -1, %i0
2064440: 82 10 20 86 mov 0x86, %g1
2064444: c2 22 00 00 st %g1, [ %o0 ]
2064448: 81 c7 e0 08 ret
206444c: 81 e8 00 00 restore
0200a4d0 <_stat_r>:
struct _reent *ptr __attribute__((unused)),
const char *path,
struct stat *buf
)
{
return _STAT_NAME( path, buf );
200a4d0: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
200a4d4: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
200a4d8: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
200a4dc: 7f ff ff b1 call 200a3a0 <stat> <== NOT EXECUTED
200a4e0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020108c0 <_unlink_r>:
int _unlink_r(
struct _reent *ptr __attribute__((unused)),
const char *path
)
{
return unlink( path );
20108c0: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
20108c4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
20108c8: 7f ff ff 5d call 201063c <unlink> <== NOT EXECUTED
20108cc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02006804 <adjtime>:
int adjtime(
struct timeval *delta,
struct timeval *olddelta
)
{
2006804: 9d e3 bf 98 save %sp, -104, %sp
long adjustment;
/*
* Simple validations
*/
if ( !delta )
2006808: a0 96 20 00 orcc %i0, 0, %l0
200680c: 02 80 00 55 be 2006960 <adjtime+0x15c>
2006810: 03 00 03 d0 sethi %hi(0xf4000), %g1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( delta->tv_usec >= TOD_MICROSECONDS_PER_SECOND )
2006814: c4 04 20 04 ld [ %l0 + 4 ], %g2
2006818: 82 10 62 3f or %g1, 0x23f, %g1
200681c: 80 a0 80 01 cmp %g2, %g1
2006820: 18 80 00 50 bgu 2006960 <adjtime+0x15c>
2006824: 80 a6 60 00 cmp %i1, 0
rtems_set_errno_and_return_minus_one( EINVAL );
if ( olddelta ) {
2006828: 22 80 00 06 be,a 2006840 <adjtime+0x3c>
200682c: c2 04 00 00 ld [ %l0 ], %g1
olddelta->tv_sec = 0;
olddelta->tv_usec = 0;
2006830: c0 26 60 04 clr [ %i1 + 4 ]
2006834: c4 04 20 04 ld [ %l0 + 4 ], %g2
if ( delta->tv_usec >= TOD_MICROSECONDS_PER_SECOND )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( olddelta ) {
olddelta->tv_sec = 0;
2006838: c0 26 40 00 clr [ %i1 ]
olddelta->tv_usec = 0;
}
/* convert delta to microseconds */
adjustment = (delta->tv_sec * TOD_MICROSECONDS_PER_SECOND);
200683c: c2 04 00 00 ld [ %l0 ], %g1
adjustment += delta->tv_usec;
/* too small to account for */
if ( adjustment < rtems_configuration_get_microseconds_per_tick() )
2006840: 07 00 80 80 sethi %hi(0x2020000), %g3
2006844: c8 00 e1 14 ld [ %g3 + 0x114 ], %g4 ! 2020114 <Configuration+0xc>
olddelta->tv_sec = 0;
olddelta->tv_usec = 0;
}
/* convert delta to microseconds */
adjustment = (delta->tv_sec * TOD_MICROSECONDS_PER_SECOND);
2006848: 9b 28 60 08 sll %g1, 8, %o5
200684c: 87 28 60 03 sll %g1, 3, %g3
2006850: 86 23 40 03 sub %o5, %g3, %g3
2006854: 9b 28 e0 06 sll %g3, 6, %o5
2006858: 86 23 40 03 sub %o5, %g3, %g3
200685c: 82 00 c0 01 add %g3, %g1, %g1
2006860: 83 28 60 06 sll %g1, 6, %g1
adjustment += delta->tv_usec;
/* too small to account for */
if ( adjustment < rtems_configuration_get_microseconds_per_tick() )
2006864: 84 00 80 01 add %g2, %g1, %g2
2006868: 80 a0 80 04 cmp %g2, %g4
200686c: 1a 80 00 04 bcc 200687c <adjtime+0x78>
2006870: 03 00 80 83 sethi %hi(0x2020c00), %g1
/* set the user's output */
if ( olddelta )
*olddelta = *delta;
return 0;
}
2006874: 81 c7 e0 08 ret
2006878: 91 e8 20 00 restore %g0, 0, %o0
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
200687c: c4 00 61 70 ld [ %g1 + 0x170 ], %g2
2006880: 84 00 a0 01 inc %g2
2006884: c4 20 61 70 st %g2, [ %g1 + 0x170 ]
* This prevents context switches while we are adjusting the TOD
*/
_Thread_Disable_dispatch();
_TOD_Get( &ts );
2006888: a2 07 bf f8 add %fp, -8, %l1
200688c: 40 00 06 81 call 2008290 <_TOD_Get>
2006890: 90 10 00 11 mov %l1, %o0
ts.tv_sec += delta->tv_sec;
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
2006894: c2 04 20 04 ld [ %l0 + 4 ], %g1
_Thread_Disable_dispatch();
_TOD_Get( &ts );
ts.tv_sec += delta->tv_sec;
2006898: c4 04 00 00 ld [ %l0 ], %g2
200689c: c8 07 bf f8 ld [ %fp + -8 ], %g4
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
20068a0: 87 28 60 02 sll %g1, 2, %g3
_Thread_Disable_dispatch();
_TOD_Get( &ts );
ts.tv_sec += delta->tv_sec;
20068a4: 84 01 00 02 add %g4, %g2, %g2
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
20068a8: 89 28 60 07 sll %g1, 7, %g4
20068ac: 86 21 00 03 sub %g4, %g3, %g3
20068b0: 82 00 c0 01 add %g3, %g1, %g1
20068b4: c6 07 bf fc ld [ %fp + -4 ], %g3
20068b8: 83 28 60 03 sll %g1, 3, %g1
_Thread_Disable_dispatch();
_TOD_Get( &ts );
ts.tv_sec += delta->tv_sec;
20068bc: c4 27 bf f8 st %g2, [ %fp + -8 ]
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
20068c0: 82 00 40 03 add %g1, %g3, %g1
/* if adjustment is too much positive */
while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
20068c4: 09 0e e6 b2 sethi %hi(0x3b9ac800), %g4
20068c8: 88 11 21 ff or %g4, 0x1ff, %g4 ! 3b9ac9ff <RAM_END+0x395ac9ff>
20068cc: 80 a0 40 04 cmp %g1, %g4
20068d0: 08 80 00 0a bleu 20068f8 <adjtime+0xf4>
20068d4: c2 27 bf fc st %g1, [ %fp + -4 ]
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
20068d8: 07 31 19 4d sethi %hi(0xc4653400), %g3
20068dc: 86 10 e2 00 or %g3, 0x200, %g3 ! c4653600 <RAM_END+0xc2253600>
20068e0: 82 00 40 03 add %g1, %g3, %g1
ts.tv_sec += delta->tv_sec;
ts.tv_nsec += delta->tv_usec * TOD_NANOSECONDS_PER_MICROSECOND;
/* if adjustment is too much positive */
while ( ts.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
20068e4: 80 a0 40 04 cmp %g1, %g4
20068e8: 18 bf ff fe bgu 20068e0 <adjtime+0xdc> <== NEVER TAKEN
20068ec: 84 00 a0 01 inc %g2
20068f0: c4 27 bf f8 st %g2, [ %fp + -8 ]
20068f4: c2 27 bf fc st %g1, [ %fp + -4 ]
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
20068f8: 09 31 19 4d sethi %hi(0xc4653400), %g4
20068fc: 88 11 22 00 or %g4, 0x200, %g4 ! c4653600 <RAM_END+0xc2253600>
2006900: 80 a0 40 04 cmp %g1, %g4
2006904: 18 80 00 0a bgu 200692c <adjtime+0x128> <== NEVER TAKEN
2006908: c4 07 bf f8 ld [ %fp + -8 ], %g2
ts.tv_nsec += TOD_NANOSECONDS_PER_SECOND;
200690c: 07 0e e6 b2 sethi %hi(0x3b9ac800), %g3
2006910: 86 10 e2 00 or %g3, 0x200, %g3 ! 3b9aca00 <RAM_END+0x395aca00>
2006914: 82 00 40 03 add %g1, %g3, %g1
ts.tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec++;
}
/* if adjustment is too much negative */
while ( ts.tv_nsec <= (-1 * TOD_NANOSECONDS_PER_SECOND) ) {
2006918: 80 a0 40 04 cmp %g1, %g4
200691c: 08 bf ff fe bleu 2006914 <adjtime+0x110>
2006920: 84 00 bf ff add %g2, -1, %g2
2006924: c2 27 bf fc st %g1, [ %fp + -4 ]
2006928: c4 27 bf f8 st %g2, [ %fp + -8 ]
ts.tv_nsec += TOD_NANOSECONDS_PER_SECOND;
ts.tv_sec--;
}
_TOD_Set( &ts );
200692c: 40 00 06 85 call 2008340 <_TOD_Set>
2006930: 90 10 00 11 mov %l1, %o0
_Thread_Enable_dispatch();
2006934: 40 00 0b be call 200982c <_Thread_Enable_dispatch>
2006938: 01 00 00 00 nop
/* set the user's output */
if ( olddelta )
200693c: 80 a6 60 00 cmp %i1, 0
2006940: 02 bf ff cd be 2006874 <adjtime+0x70> <== NEVER TAKEN
2006944: 01 00 00 00 nop
*olddelta = *delta;
2006948: c2 04 00 00 ld [ %l0 ], %g1
200694c: c2 26 40 00 st %g1, [ %i1 ]
2006950: c2 04 20 04 ld [ %l0 + 4 ], %g1
2006954: c2 26 60 04 st %g1, [ %i1 + 4 ]
2006958: 81 c7 e0 08 ret
200695c: 91 e8 20 00 restore %g0, 0, %o0
*/
if ( !delta )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( delta->tv_usec >= TOD_MICROSECONDS_PER_SECOND )
rtems_set_errno_and_return_minus_one( EINVAL );
2006960: 40 00 2f 8e call 2012798 <__errno>
2006964: b0 10 3f ff mov -1, %i0
2006968: 82 10 20 16 mov 0x16, %g1
200696c: c2 22 00 00 st %g1, [ %o0 ]
2006970: 81 c7 e0 08 ret
2006974: 81 e8 00 00 restore
02002a60 <calloc>:
)
{
register char *cptr;
size_t length;
MSBUMP(calloc_calls, 1);
2002a60: 9d e3 bf a0 save %sp, -96, %sp
2002a64: 21 00 80 7c sethi %hi(0x201f000), %l0
2002a68: a0 14 21 e0 or %l0, 0x1e0, %l0 ! 201f1e0 <rtems_malloc_statistics>
2002a6c: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
length = nelem * elsize;
2002a70: 92 10 00 18 mov %i0, %o1
)
{
register char *cptr;
size_t length;
MSBUMP(calloc_calls, 1);
2002a74: 82 00 60 01 inc %g1
length = nelem * elsize;
2002a78: 90 10 00 19 mov %i1, %o0
2002a7c: 40 00 60 f9 call 201ae60 <.umul>
2002a80: c2 24 20 14 st %g1, [ %l0 + 0x14 ]
cptr = malloc( length );
2002a84: 40 00 01 82 call 200308c <malloc>
2002a88: a2 10 00 08 mov %o0, %l1
if ( cptr )
2002a8c: b0 92 20 00 orcc %o0, 0, %i0
2002a90: 02 80 00 04 be 2002aa0 <calloc+0x40> <== NEVER TAKEN
2002a94: 94 10 00 11 mov %l1, %o2
memset( cptr, '\0', length );
2002a98: 40 00 3e 54 call 20123e8 <memset>
2002a9c: 92 10 20 00 clr %o1
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
2002aa0: c2 04 20 04 ld [ %l0 + 4 ], %g1
2002aa4: 82 00 7f ff add %g1, -1, %g1
2002aa8: c2 24 20 04 st %g1, [ %l0 + 4 ]
return cptr;
}
2002aac: 81 c7 e0 08 ret
2002ab0: 81 e8 00 00 restore
0202c56c <chdir>:
#include <rtems/seterr.h>
int chdir(
const char *pathname
)
{
202c56c: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc;
int result;
if ( !pathname )
202c570: 80 a6 20 00 cmp %i0, 0
202c574: 02 80 00 31 be 202c638 <chdir+0xcc>
202c578: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
/*
* Get the node where we wish to go.
*/
result = rtems_filesystem_evaluate_path(
202c57c: 40 00 93 7d call 2051370 <strlen>
202c580: 90 10 00 18 mov %i0, %o0
202c584: a0 07 bf ec add %fp, -20, %l0
202c588: 92 10 00 08 mov %o0, %o1
202c58c: 94 10 20 01 mov 1, %o2
202c590: 90 10 00 18 mov %i0, %o0
202c594: 96 10 00 10 mov %l0, %o3
202c598: 98 10 20 01 mov 1, %o4
202c59c: 7f ff 70 b1 call 2008860 <rtems_filesystem_evaluate_path>
202c5a0: b0 10 3f ff mov -1, %i0
pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true );
if ( result != 0 )
202c5a4: 80 a2 20 00 cmp %o0, 0
202c5a8: 12 80 00 28 bne 202c648 <chdir+0xdc>
202c5ac: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1;
/*
* Verify you can change directory into this node.
*/
if ( !loc.ops->node_type_h ) {
202c5b0: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1
202c5b4: 80 a0 60 00 cmp %g1, 0
202c5b8: 22 80 00 35 be,a 202c68c <chdir+0x120> <== NEVER TAKEN
202c5bc: 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_DIRECTORY ) {
202c5c0: 9f c0 40 00 call %g1
202c5c4: 90 10 00 10 mov %l0, %o0
202c5c8: 80 a2 20 01 cmp %o0, 1
202c5cc: 12 80 00 21 bne 202c650 <chdir+0xe4>
202c5d0: c2 07 bf f8 ld [ %fp + -8 ], %g1
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTDIR );
}
rtems_filesystem_freenode( &rtems_filesystem_current );
202c5d4: 21 00 81 c3 sethi %hi(0x2070c00), %l0
202c5d8: d0 04 22 24 ld [ %l0 + 0x224 ], %o0 ! 2070e24 <rtems_current_user_env>
202c5dc: c2 02 20 10 ld [ %o0 + 0x10 ], %g1
202c5e0: 80 a0 60 00 cmp %g1, 0
202c5e4: 22 80 00 0a be,a 202c60c <chdir+0xa0> <== NEVER TAKEN
202c5e8: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
202c5ec: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202c5f0: 80 a0 60 00 cmp %g1, 0
202c5f4: 22 80 00 06 be,a 202c60c <chdir+0xa0> <== NEVER TAKEN
202c5f8: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
202c5fc: 9f c0 40 00 call %g1
202c600: 90 02 20 04 add %o0, 4, %o0
202c604: d0 04 22 24 ld [ %l0 + 0x224 ], %o0
rtems_filesystem_current = loc;
202c608: c2 07 bf ec ld [ %fp + -20 ], %g1
202c60c: c2 22 20 04 st %g1, [ %o0 + 4 ]
202c610: c2 07 bf f0 ld [ %fp + -16 ], %g1
202c614: c2 22 20 08 st %g1, [ %o0 + 8 ]
202c618: c2 07 bf f4 ld [ %fp + -12 ], %g1
202c61c: c2 22 20 0c st %g1, [ %o0 + 0xc ]
202c620: c2 07 bf f8 ld [ %fp + -8 ], %g1
202c624: c2 22 20 10 st %g1, [ %o0 + 0x10 ]
202c628: c2 07 bf fc ld [ %fp + -4 ], %g1
202c62c: c2 22 20 14 st %g1, [ %o0 + 0x14 ]
return 0;
}
202c630: 81 c7 e0 08 ret
202c634: 91 e8 20 00 restore %g0, 0, %o0
{
rtems_filesystem_location_info_t loc;
int result;
if ( !pathname )
rtems_set_errno_and_return_minus_one( EFAULT );
202c638: 40 00 77 92 call 204a480 <__errno>
202c63c: b0 10 3f ff mov -1, %i0
202c640: 82 10 20 0e mov 0xe, %g1
202c644: c2 22 00 00 st %g1, [ %o0 ]
202c648: 81 c7 e0 08 ret
202c64c: 81 e8 00 00 restore
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
rtems_filesystem_freenode( &loc );
202c650: 80 a0 60 00 cmp %g1, 0
202c654: 02 80 00 08 be 202c674 <chdir+0x108> <== NEVER TAKEN
202c658: 01 00 00 00 nop
202c65c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202c660: 80 a0 60 00 cmp %g1, 0
202c664: 02 80 00 04 be 202c674 <chdir+0x108> <== NEVER TAKEN
202c668: 01 00 00 00 nop
202c66c: 9f c0 40 00 call %g1
202c670: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( ENOTDIR );
202c674: 40 00 77 83 call 204a480 <__errno>
202c678: b0 10 3f ff mov -1, %i0
202c67c: 82 10 20 14 mov 0x14, %g1
202c680: c2 22 00 00 st %g1, [ %o0 ]
202c684: 81 c7 e0 08 ret
202c688: 81 e8 00 00 restore
/*
* Verify you can change directory into this node.
*/
if ( !loc.ops->node_type_h ) {
rtems_filesystem_freenode( &loc );
202c68c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202c690: 02 80 00 04 be 202c6a0 <chdir+0x134> <== NOT EXECUTED
202c694: 01 00 00 00 nop <== NOT EXECUTED
202c698: 9f c0 40 00 call %g1 <== NOT EXECUTED
202c69c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202c6a0: 40 00 77 78 call 204a480 <__errno> <== NOT EXECUTED
202c6a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c6a8: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202c6ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c6b0: 81 c7 e0 08 ret <== NOT EXECUTED
202c6b4: 81 e8 00 00 restore <== NOT EXECUTED
020082a8 <chmod>:
int chmod(
const char *path,
mode_t mode
)
{
20082a8: 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 );
20082ac: 40 01 24 31 call 2051370 <strlen>
20082b0: 90 10 00 18 mov %i0, %o0
20082b4: a0 07 bf ec add %fp, -20, %l0
20082b8: 92 10 00 08 mov %o0, %o1
20082bc: 94 10 20 00 clr %o2
20082c0: 90 10 00 18 mov %i0, %o0
20082c4: 96 10 00 10 mov %l0, %o3
20082c8: 98 10 20 01 mov 1, %o4
20082cc: 40 00 01 65 call 2008860 <rtems_filesystem_evaluate_path>
20082d0: b0 10 3f ff mov -1, %i0
if ( status != 0 )
20082d4: 80 a2 20 00 cmp %o0, 0
20082d8: 12 80 00 15 bne 200832c <chmod+0x84>
20082dc: c2 07 bf f4 ld [ %fp + -12 ], %g1
return -1;
if ( !loc.handlers ){
20082e0: 80 a0 60 00 cmp %g1, 0
20082e4: 22 80 00 24 be,a 2008374 <chmod+0xcc> <== NEVER TAKEN
20082e8: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( EBADF );
}
if ( !loc.handlers->fchmod_h ){
20082ec: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20082f0: 80 a0 60 00 cmp %g1, 0
20082f4: 02 80 00 10 be 2008334 <chmod+0x8c> <== NEVER TAKEN
20082f8: 92 10 00 19 mov %i1, %o1
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.handlers->fchmod_h)( &loc, mode );
20082fc: 9f c0 40 00 call %g1
2008300: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
2008304: c2 07 bf f8 ld [ %fp + -8 ], %g1
2008308: 80 a0 60 00 cmp %g1, 0
200830c: 02 80 00 08 be 200832c <chmod+0x84> <== NEVER TAKEN
2008310: b0 10 00 08 mov %o0, %i0
2008314: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2008318: 80 a0 60 00 cmp %g1, 0
200831c: 02 80 00 23 be 20083a8 <chmod+0x100> <== NEVER TAKEN
2008320: 01 00 00 00 nop
2008324: 9f c0 40 00 call %g1
2008328: 90 10 00 10 mov %l0, %o0
return result;
}
200832c: 81 c7 e0 08 ret
2008330: 81 e8 00 00 restore
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( EBADF );
}
if ( !loc.handlers->fchmod_h ){
rtems_filesystem_freenode( &loc );
2008334: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2008338: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200833c: 02 80 00 08 be 200835c <chmod+0xb4> <== NOT EXECUTED
2008340: 01 00 00 00 nop <== NOT EXECUTED
2008344: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2008348: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200834c: 02 80 00 04 be 200835c <chmod+0xb4> <== NOT EXECUTED
2008350: 01 00 00 00 nop <== NOT EXECUTED
2008354: 9f c0 40 00 call %g1 <== NOT EXECUTED
2008358: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
200835c: 40 01 08 49 call 204a480 <__errno> <== NOT EXECUTED
2008360: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2008364: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2008368: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200836c: 81 c7 e0 08 ret <== NOT EXECUTED
2008370: 81 e8 00 00 restore <== NOT EXECUTED
status = rtems_filesystem_evaluate_path( path, strlen( path ), 0, &loc, true );
if ( status != 0 )
return -1;
if ( !loc.handlers ){
rtems_filesystem_freenode( &loc );
2008374: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2008378: 02 80 00 08 be 2008398 <chmod+0xf0> <== NOT EXECUTED
200837c: 01 00 00 00 nop <== NOT EXECUTED
2008380: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2008384: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2008388: 02 80 00 04 be 2008398 <chmod+0xf0> <== NOT EXECUTED
200838c: 01 00 00 00 nop <== NOT EXECUTED
2008390: 9f c0 40 00 call %g1 <== NOT EXECUTED
2008394: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EBADF );
2008398: 40 01 08 3a call 204a480 <__errno> <== NOT EXECUTED
200839c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20083a0: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
20083a4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20083a8: 81 c7 e0 08 ret <== NOT EXECUTED
20083ac: 81 e8 00 00 restore <== NOT EXECUTED
0202c6b8 <chown>:
int chown(
const char *path,
uid_t owner,
gid_t group
)
{
202c6b8: 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 ) )
202c6bc: 40 00 93 2d call 2051370 <strlen>
202c6c0: 90 10 00 18 mov %i0, %o0
202c6c4: a0 07 bf ec add %fp, -20, %l0
202c6c8: 92 10 00 08 mov %o0, %o1
202c6cc: 94 10 20 00 clr %o2
202c6d0: 90 10 00 18 mov %i0, %o0
202c6d4: 96 10 00 10 mov %l0, %o3
202c6d8: 98 10 20 01 mov 1, %o4
202c6dc: 7f ff 70 61 call 2008860 <rtems_filesystem_evaluate_path>
202c6e0: b0 10 3f ff mov -1, %i0
202c6e4: 80 a2 20 00 cmp %o0, 0
202c6e8: 12 80 00 15 bne 202c73c <chown+0x84>
202c6ec: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1;
if ( !loc.ops->chown_h ) {
202c6f0: c2 00 a0 18 ld [ %g2 + 0x18 ], %g1
202c6f4: 80 a0 60 00 cmp %g1, 0
202c6f8: 02 80 00 13 be 202c744 <chown+0x8c> <== NEVER TAKEN
202c6fc: 93 2e 60 10 sll %i1, 0x10, %o1
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.ops->chown_h)( &loc, owner, group );
202c700: 95 2e a0 10 sll %i2, 0x10, %o2
202c704: 93 32 60 10 srl %o1, 0x10, %o1
202c708: 95 32 a0 10 srl %o2, 0x10, %o2
202c70c: 9f c0 40 00 call %g1
202c710: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
202c714: c2 07 bf f8 ld [ %fp + -8 ], %g1
202c718: 80 a0 60 00 cmp %g1, 0
202c71c: 02 80 00 08 be 202c73c <chown+0x84> <== NEVER TAKEN
202c720: b0 10 00 08 mov %o0, %i0
202c724: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202c728: 80 a0 60 00 cmp %g1, 0
202c72c: 02 80 00 10 be 202c76c <chown+0xb4> <== NEVER TAKEN
202c730: 01 00 00 00 nop
202c734: 9f c0 40 00 call %g1
202c738: 90 10 00 10 mov %l0, %o0
return result;
}
202c73c: 81 c7 e0 08 ret
202c740: 81 e8 00 00 restore
if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &loc, true ) )
return -1;
if ( !loc.ops->chown_h ) {
rtems_filesystem_freenode( &loc );
202c744: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
202c748: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202c74c: 02 80 00 04 be 202c75c <chown+0xa4> <== NOT EXECUTED
202c750: 01 00 00 00 nop <== NOT EXECUTED
202c754: 9f c0 40 00 call %g1 <== NOT EXECUTED
202c758: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202c75c: 40 00 77 49 call 204a480 <__errno> <== NOT EXECUTED
202c760: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c764: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202c768: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c76c: 81 c7 e0 08 ret <== NOT EXECUTED
202c770: 81 e8 00 00 restore <== NOT EXECUTED
0202c774 <chroot>:
#include <rtems/seterr.h>
int chroot(
const char *pathname
)
{
202c774: 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) {
202c778: 21 00 81 c3 sethi %hi(0x2070c00), %l0
202c77c: e2 04 22 24 ld [ %l0 + 0x224 ], %l1 ! 2070e24 <rtems_current_user_env>
202c780: 03 00 81 d3 sethi %hi(0x2074c00), %g1
202c784: 82 10 60 bc or %g1, 0xbc, %g1 ! 2074cbc <rtems_global_user_env>
202c788: 80 a4 40 01 cmp %l1, %g1
202c78c: 02 80 00 28 be 202c82c <chroot+0xb8> <== ALWAYS TAKEN
202c790: 01 00 00 00 nop
rtems_libio_set_private_env(); /* try to set a new private env*/
if (rtems_current_user_env == &rtems_global_user_env) /* not ok */
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = chdir(pathname);
202c794: 7f ff ff 76 call 202c56c <chdir>
202c798: 90 10 00 18 mov %i0, %o0
if (result) {
202c79c: 80 a2 20 00 cmp %o0, 0
202c7a0: 12 80 00 2f bne 202c85c <chroot+0xe8> <== NEVER TAKEN
202c7a4: 11 00 81 ab sethi %hi(0x206ac00), %o0
rtems_set_errno_and_return_minus_one( errno );
}
/* clone the new root location */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
202c7a8: 92 10 20 01 mov 1, %o1
202c7ac: 90 12 21 f8 or %o0, 0x1f8, %o0
202c7b0: 94 10 20 00 clr %o2
202c7b4: 96 07 bf ec add %fp, -20, %o3
202c7b8: 7f ff 70 2a call 2008860 <rtems_filesystem_evaluate_path>
202c7bc: 98 10 20 00 clr %o4
202c7c0: 80 a2 20 00 cmp %o0, 0
202c7c4: 12 80 00 26 bne 202c85c <chroot+0xe8> <== NEVER TAKEN
202c7c8: d0 04 22 24 ld [ %l0 + 0x224 ], %o0
/* our cwd has changed, though - but there is no easy way of return :-( */
rtems_set_errno_and_return_minus_one( errno );
}
rtems_filesystem_freenode(&rtems_filesystem_root);
202c7cc: c2 02 20 24 ld [ %o0 + 0x24 ], %g1
202c7d0: 80 a0 60 00 cmp %g1, 0
202c7d4: 22 80 00 0b be,a 202c800 <chroot+0x8c> <== NEVER TAKEN
202c7d8: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
202c7dc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202c7e0: 80 a0 60 00 cmp %g1, 0
202c7e4: 22 80 00 07 be,a 202c800 <chroot+0x8c> <== NEVER TAKEN
202c7e8: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
202c7ec: 9f c0 40 00 call %g1
202c7f0: 90 02 20 18 add %o0, 0x18, %o0
202c7f4: 03 00 81 c3 sethi %hi(0x2070c00), %g1
202c7f8: d0 00 62 24 ld [ %g1 + 0x224 ], %o0 ! 2070e24 <rtems_current_user_env>
rtems_filesystem_root = loc;
202c7fc: c2 07 bf ec ld [ %fp + -20 ], %g1
202c800: c2 22 20 18 st %g1, [ %o0 + 0x18 ]
202c804: c2 07 bf f0 ld [ %fp + -16 ], %g1
202c808: c2 22 20 1c st %g1, [ %o0 + 0x1c ]
202c80c: c2 07 bf f4 ld [ %fp + -12 ], %g1
202c810: c2 22 20 20 st %g1, [ %o0 + 0x20 ]
202c814: c2 07 bf f8 ld [ %fp + -8 ], %g1
202c818: c2 22 20 24 st %g1, [ %o0 + 0x24 ]
202c81c: c2 07 bf fc ld [ %fp + -4 ], %g1
202c820: c2 22 20 28 st %g1, [ %o0 + 0x28 ]
return 0;
}
202c824: 81 c7 e0 08 ret
202c828: 91 e8 20 00 restore %g0, 0, %o0
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) {
rtems_libio_set_private_env(); /* try to set a new private env*/
202c82c: 40 00 06 79 call 202e210 <rtems_libio_set_private_env>
202c830: 01 00 00 00 nop
if (rtems_current_user_env == &rtems_global_user_env) /* not ok */
202c834: c2 04 22 24 ld [ %l0 + 0x224 ], %g1
202c838: 80 a0 40 11 cmp %g1, %l1
202c83c: 12 bf ff d6 bne 202c794 <chroot+0x20> <== ALWAYS TAKEN
202c840: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
202c844: 40 00 77 0f call 204a480 <__errno> <== NOT EXECUTED
202c848: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
202c84c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202c850: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c854: 81 c7 e0 08 ret <== NOT EXECUTED
202c858: 81 e8 00 00 restore <== NOT EXECUTED
}
/* clone the new root location */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
/* our cwd has changed, though - but there is no easy way of return :-( */
rtems_set_errno_and_return_minus_one( errno );
202c85c: 40 00 77 09 call 204a480 <__errno> <== NOT EXECUTED
202c860: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c864: 40 00 77 07 call 204a480 <__errno> <== NOT EXECUTED
202c868: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
202c86c: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
202c870: c2 24 00 00 st %g1, [ %l0 ] <== NOT EXECUTED
202c874: 81 c7 e0 08 ret <== NOT EXECUTED
202c878: 81 e8 00 00 restore <== NOT EXECUTED
020067f0 <clock_gettime>:
int clock_gettime(
clockid_t clock_id,
struct timespec *tp
)
{
20067f0: 9d e3 bf a0 save %sp, -96, %sp
if ( !tp )
20067f4: 80 a6 60 00 cmp %i1, 0
20067f8: 02 80 00 20 be 2006878 <clock_gettime+0x88>
20067fc: 80 a6 20 01 cmp %i0, 1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
2006800: 02 80 00 19 be 2006864 <clock_gettime+0x74>
2006804: 80 a6 20 04 cmp %i0, 4
_TOD_Get(tp);
return 0;
}
#ifdef CLOCK_MONOTONIC
if ( clock_id == CLOCK_MONOTONIC ) {
2006808: 02 80 00 12 be 2006850 <clock_gettime+0x60> <== NEVER TAKEN
200680c: 80 a6 20 02 cmp %i0, 2
return 0;
}
#endif
#ifdef _POSIX_CPUTIME
if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) {
2006810: 02 80 00 10 be 2006850 <clock_gettime+0x60>
2006814: 80 a6 20 03 cmp %i0, 3
return 0;
}
#endif
#ifdef _POSIX_THREAD_CPUTIME
if ( clock_id == CLOCK_THREAD_CPUTIME_ID )
2006818: 02 80 00 08 be 2006838 <clock_gettime+0x48>
200681c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
rtems_set_errno_and_return_minus_one( EINVAL );
2006820: 40 00 31 45 call 2012d34 <__errno>
2006824: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff>
2006828: 82 10 20 16 mov 0x16, %g1
200682c: c2 22 00 00 st %g1, [ %o0 ]
return 0;
}
2006830: 81 c7 e0 08 ret
2006834: 81 e8 00 00 restore
}
#endif
#ifdef _POSIX_THREAD_CPUTIME
if ( clock_id == CLOCK_THREAD_CPUTIME_ID )
rtems_set_errno_and_return_minus_one( ENOSYS );
2006838: 40 00 31 3f call 2012d34 <__errno>
200683c: b0 10 3f ff mov -1, %i0
2006840: 82 10 20 58 mov 0x58, %g1
2006844: c2 22 00 00 st %g1, [ %o0 ]
2006848: 81 c7 e0 08 ret
200684c: 81 e8 00 00 restore
}
#endif
#ifdef _POSIX_CPUTIME
if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) {
_TOD_Get_uptime_as_timespec( tp );
2006850: 90 10 00 19 mov %i1, %o0
2006854: 40 00 08 69 call 20089f8 <_TOD_Get_uptime_as_timespec>
2006858: b0 10 20 00 clr %i0
return 0;
200685c: 81 c7 e0 08 ret
2006860: 81 e8 00 00 restore
{
if ( !tp )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
_TOD_Get(tp);
2006864: 90 10 00 19 mov %i1, %o0
2006868: 40 00 08 45 call 200897c <_TOD_Get>
200686c: b0 10 20 00 clr %i0
return 0;
2006870: 81 c7 e0 08 ret
2006874: 81 e8 00 00 restore
clockid_t clock_id,
struct timespec *tp
)
{
if ( !tp )
rtems_set_errno_and_return_minus_one( EINVAL );
2006878: 40 00 31 2f call 2012d34 <__errno>
200687c: b0 10 3f ff mov -1, %i0
2006880: 82 10 20 16 mov 0x16, %g1
2006884: c2 22 00 00 st %g1, [ %o0 ]
2006888: 81 c7 e0 08 ret
200688c: 81 e8 00 00 restore
0202ee24 <clock_settime>:
int clock_settime(
clockid_t clock_id,
const struct timespec *tp
)
{
202ee24: 9d e3 bf a0 save %sp, -96, %sp
if ( !tp )
202ee28: 80 a6 60 00 cmp %i1, 0
202ee2c: 02 80 00 24 be 202eebc <clock_settime+0x98> <== NEVER TAKEN
202ee30: 80 a6 20 01 cmp %i0, 1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
202ee34: 02 80 00 0c be 202ee64 <clock_settime+0x40>
202ee38: 80 a6 20 02 cmp %i0, 2
_Thread_Disable_dispatch();
_TOD_Set( tp );
_Thread_Enable_dispatch();
}
#ifdef _POSIX_CPUTIME
else if ( clock_id == CLOCK_PROCESS_CPUTIME_ID )
202ee3c: 02 80 00 1a be 202eea4 <clock_settime+0x80>
202ee40: 80 a6 20 03 cmp %i0, 3
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
#ifdef _POSIX_THREAD_CPUTIME
else if ( clock_id == CLOCK_THREAD_CPUTIME_ID )
202ee44: 02 80 00 18 be 202eea4 <clock_settime+0x80>
202ee48: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
else
rtems_set_errno_and_return_minus_one( EINVAL );
202ee4c: 40 00 6d 8d call 204a480 <__errno>
202ee50: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff>
202ee54: 82 10 20 16 mov 0x16, %g1
202ee58: c2 22 00 00 st %g1, [ %o0 ]
return 0;
}
202ee5c: 81 c7 e0 08 ret
202ee60: 81 e8 00 00 restore
{
if ( !tp )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 )
202ee64: c4 06 40 00 ld [ %i1 ], %g2
202ee68: 03 08 76 b9 sethi %hi(0x21dae400), %g1
202ee6c: 82 10 60 ff or %g1, 0xff, %g1 ! 21dae4ff <RAM_END+0x1f9ae4ff>
202ee70: 80 a0 80 01 cmp %g2, %g1
202ee74: 08 80 00 12 bleu 202eebc <clock_settime+0x98>
202ee78: 03 00 81 d3 sethi %hi(0x2074c00), %g1
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
202ee7c: c4 00 62 40 ld [ %g1 + 0x240 ], %g2 ! 2074e40 <_Thread_Dispatch_disable_level>
202ee80: 84 00 a0 01 inc %g2
202ee84: c4 20 62 40 st %g2, [ %g1 + 0x240 ]
rtems_set_errno_and_return_minus_one( EINVAL );
_Thread_Disable_dispatch();
_TOD_Set( tp );
202ee88: 90 10 00 19 mov %i1, %o0
202ee8c: 40 00 06 85 call 20308a0 <_TOD_Set>
202ee90: b0 10 20 00 clr %i0
_Thread_Enable_dispatch();
202ee94: 7f ff 84 59 call 200fff8 <_Thread_Enable_dispatch>
202ee98: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
else
rtems_set_errno_and_return_minus_one( EINVAL );
return 0;
202ee9c: 81 c7 e0 08 ret
202eea0: 81 e8 00 00 restore
else if ( clock_id == CLOCK_PROCESS_CPUTIME_ID )
rtems_set_errno_and_return_minus_one( ENOSYS );
#endif
#ifdef _POSIX_THREAD_CPUTIME
else if ( clock_id == CLOCK_THREAD_CPUTIME_ID )
rtems_set_errno_and_return_minus_one( ENOSYS );
202eea4: 40 00 6d 77 call 204a480 <__errno>
202eea8: b0 10 3f ff mov -1, %i0
202eeac: 82 10 20 58 mov 0x58, %g1
202eeb0: c2 22 00 00 st %g1, [ %o0 ]
202eeb4: 81 c7 e0 08 ret
202eeb8: 81 e8 00 00 restore
if ( !tp )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( clock_id == CLOCK_REALTIME ) {
if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 )
rtems_set_errno_and_return_minus_one( EINVAL );
202eebc: 40 00 6d 71 call 204a480 <__errno>
202eec0: b0 10 3f ff mov -1, %i0
202eec4: 82 10 20 16 mov 0x16, %g1
202eec8: c2 22 00 00 st %g1, [ %o0 ]
202eecc: 81 c7 e0 08 ret
202eed0: 81 e8 00 00 restore
0200c944 <close>:
#include <rtems/libio_.h>
int close(
int fd
)
{
200c944: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop;
rtems_status_code rc;
rtems_libio_check_fd(fd);
200c948: 03 00 80 79 sethi %hi(0x201e400), %g1
200c94c: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
200c950: 80 a6 00 01 cmp %i0, %g1
200c954: 1a 80 00 21 bcc 200c9d8 <close+0x94>
200c958: 03 00 80 7c sethi %hi(0x201f000), %g1
iop = rtems_libio_iop(fd);
200c95c: e0 00 61 c4 ld [ %g1 + 0x1c4 ], %l0 ! 201f1c4 <rtems_libio_iops>
200c960: 83 2e 20 06 sll %i0, 6, %g1
200c964: b1 2e 20 03 sll %i0, 3, %i0
200c968: b0 06 00 01 add %i0, %g1, %i0
200c96c: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open(iop);
200c970: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
200c974: 80 88 61 00 btst 0x100, %g1
200c978: 02 80 00 18 be 200c9d8 <close+0x94>
200c97c: 01 00 00 00 nop
rc = RTEMS_SUCCESSFUL;
if ( iop->handlers->close_h )
200c980: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
200c984: c2 00 60 04 ld [ %g1 + 4 ], %g1
200c988: 80 a0 60 00 cmp %g1, 0
200c98c: 02 80 00 05 be 200c9a0 <close+0x5c> <== NEVER TAKEN
200c990: b0 10 20 00 clr %i0
rc = (*iop->handlers->close_h)( iop );
200c994: 9f c0 40 00 call %g1
200c998: 90 10 00 10 mov %l0, %o0
200c99c: b0 10 00 08 mov %o0, %i0
rtems_filesystem_freenode( &iop->pathinfo );
200c9a0: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
200c9a4: 80 a0 60 00 cmp %g1, 0
200c9a8: 02 80 00 08 be 200c9c8 <close+0x84> <== NEVER TAKEN
200c9ac: 01 00 00 00 nop
200c9b0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
200c9b4: 80 a0 60 00 cmp %g1, 0
200c9b8: 02 80 00 04 be 200c9c8 <close+0x84>
200c9bc: 01 00 00 00 nop
200c9c0: 9f c0 40 00 call %g1
200c9c4: 90 04 20 1c add %l0, 0x1c, %o0
rtems_libio_free( iop );
200c9c8: 40 00 00 bc call 200ccb8 <rtems_libio_free>
200c9cc: 90 10 00 10 mov %l0, %o0
return rc;
}
200c9d0: 81 c7 e0 08 ret
200c9d4: 81 e8 00 00 restore
rtems_libio_t *iop;
rtems_status_code rc;
rtems_libio_check_fd(fd);
iop = rtems_libio_iop(fd);
rtems_libio_check_is_open(iop);
200c9d8: 40 00 14 09 call 20119fc <__errno>
200c9dc: b0 10 3f ff mov -1, %i0
200c9e0: 82 10 20 09 mov 9, %g1
200c9e4: c2 22 00 00 st %g1, [ %o0 ]
200c9e8: 81 c7 e0 08 ret
200c9ec: 81 e8 00 00 restore
02002f3c <create_disk>:
return disktab [major].minor + minor;
}
static rtems_status_code
create_disk(dev_t dev, const char *name, rtems_disk_device **dd_ptr)
{
2002f3c: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
rtems_filesystem_split_dev_t(dev, major, minor);
if (major >= disktab_size) {
2002f40: 23 00 80 8b sethi %hi(0x2022c00), %l1
2002f44: e4 04 62 5c ld [ %l1 + 0x25c ], %l2 ! 2022e5c <disktab_size>
2002f48: 80 a6 00 12 cmp %i0, %l2
2002f4c: 1a 80 00 4a bcc 2003074 <create_disk+0x138>
2002f50: a0 10 00 18 mov %i0, %l0
2002f54: 29 00 80 8b sethi %hi(0x2022c00), %l4
2002f58: e6 05 22 58 ld [ %l4 + 0x258 ], %l3 ! 2022e58 <disktab>
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
disktab = table;
disktab_size = new_size;
}
if (disktab [major].minor == NULL || minor >= disktab[major].size) {
2002f5c: a3 2c 20 03 sll %l0, 3, %l1
2002f60: e4 04 c0 11 ld [ %l3 + %l1 ], %l2
2002f64: 80 a4 a0 00 cmp %l2, 0
2002f68: 02 80 00 2b be 2003014 <create_disk+0xd8>
2002f6c: a6 04 c0 11 add %l3, %l1, %l3
2002f70: ea 04 e0 04 ld [ %l3 + 4 ], %l5
2002f74: 80 a6 40 15 cmp %i1, %l5
2002f78: 1a 80 00 29 bcc 200301c <create_disk+0xe0> <== NEVER TAKEN
2002f7c: 80 a5 60 00 cmp %l5, 0
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
disktab [major].minor = table;
disktab [major].size = new_size;
}
return disktab [major].minor + minor;
2002f80: 83 2e 60 02 sll %i1, 2, %g1
{
rtems_disk_device **dd_entry = create_disk_table_entry(dev);
rtems_disk_device *dd = NULL;
char *alloc_name = NULL;
if (dd_entry == NULL) {
2002f84: a2 84 80 01 addcc %l2, %g1, %l1
2002f88: 02 80 00 4e be 20030c0 <create_disk+0x184> <== NEVER TAKEN
2002f8c: 01 00 00 00 nop
return RTEMS_NO_MEMORY;
}
if (*dd_entry != NULL) {
2002f90: c2 04 80 01 ld [ %l2 + %g1 ], %g1
2002f94: 80 a0 60 00 cmp %g1, 0
2002f98: 12 80 00 51 bne 20030dc <create_disk+0x1a0>
2002f9c: b0 10 20 0c mov 0xc, %i0
return RTEMS_RESOURCE_IN_USE;
}
dd = malloc(sizeof(*dd));
2002fa0: 40 00 04 64 call 2004130 <malloc>
2002fa4: 90 10 20 38 mov 0x38, %o0
if (dd == NULL) {
2002fa8: a4 92 20 00 orcc %o0, 0, %l2
2002fac: 02 80 00 45 be 20030c0 <create_disk+0x184> <== NEVER TAKEN
2002fb0: 80 a6 a0 00 cmp %i2, 0
return RTEMS_NO_MEMORY;
}
if (name != NULL) {
2002fb4: 02 80 00 0f be 2002ff0 <create_disk+0xb4>
2002fb8: a6 10 20 00 clr %l3
alloc_name = strdup(name);
2002fbc: 40 00 4e 94 call 2016a0c <strdup>
2002fc0: 90 10 00 1a mov %i2, %o0
if (alloc_name == NULL) {
2002fc4: b4 92 20 00 orcc %o0, 0, %i2
2002fc8: 02 80 00 47 be 20030e4 <create_disk+0x1a8> <== NEVER TAKEN
2002fcc: a6 10 00 1a mov %i2, %l3
return RTEMS_NO_MEMORY;
}
}
if (name != NULL) {
if (mknod(alloc_name, 0777 | S_IFBLK, dev) < 0) {
2002fd0: 13 00 00 18 sethi %hi(0x6000), %o1
2002fd4: 94 10 00 10 mov %l0, %o2
2002fd8: 92 12 61 ff or %o1, 0x1ff, %o1
2002fdc: 40 00 04 9d call 2004250 <mknod>
2002fe0: 96 10 00 19 mov %i1, %o3
2002fe4: 80 a2 20 00 cmp %o0, 0
2002fe8: 06 80 00 38 bl 20030c8 <create_disk+0x18c> <== NEVER TAKEN
2002fec: 01 00 00 00 nop
dd->dev = dev;
dd->name = alloc_name;
dd->uses = 0;
dd->deleted = false;
*dd_entry = dd;
2002ff0: e4 24 40 00 st %l2, [ %l1 ]
*dd_ptr = dd;
2002ff4: e4 26 c0 00 st %l2, [ %i3 ]
free(dd);
return RTEMS_UNSATISFIED;
}
}
dd->dev = dev;
2002ff8: e0 24 80 00 st %l0, [ %l2 ]
2002ffc: f2 24 a0 04 st %i1, [ %l2 + 4 ]
dd->name = alloc_name;
2003000: e6 24 a0 10 st %l3, [ %l2 + 0x10 ]
dd->uses = 0;
2003004: c0 24 a0 14 clr [ %l2 + 0x14 ]
dd->deleted = false;
2003008: c0 2c a0 30 clrb [ %l2 + 0x30 ]
*dd_entry = dd;
*dd_ptr = dd;
return RTEMS_SUCCESSFUL;
200300c: 81 c7 e0 08 ret
2003010: 91 e8 20 00 restore %g0, 0, %o0
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
disktab = table;
disktab_size = new_size;
}
if (disktab [major].minor == NULL || minor >= disktab[major].size) {
2003014: ea 04 e0 04 ld [ %l3 + 4 ], %l5
rtems_disk_device **table = disktab [major].minor;
rtems_device_minor_number old_size = disktab [major].size;
rtems_device_minor_number new_size = 0;
if (old_size == 0) {
2003018: 80 a5 60 00 cmp %l5, 0
200301c: 12 80 00 03 bne 2003028 <create_disk+0xec> <== NEVER TAKEN
2003020: a7 2d 60 01 sll %l5, 1, %l3
2003024: a6 10 20 08 mov 8, %l3
new_size = DISKTAB_INITIAL_SIZE;
} else {
new_size = 2 * old_size;
}
if (minor >= new_size) {
2003028: 80 a6 40 13 cmp %i1, %l3
200302c: 3a 80 00 02 bcc,a 2003034 <create_disk+0xf8>
2003030: a6 06 60 01 add %i1, 1, %l3
new_size = minor + 1;
}
table = realloc(table, new_size * sizeof(*table));
2003034: 90 10 00 12 mov %l2, %o0
2003038: 40 00 07 75 call 2004e0c <realloc>
200303c: 93 2c e0 02 sll %l3, 2, %o1
if (table == NULL) {
2003040: a4 92 20 00 orcc %o0, 0, %l2
2003044: 02 80 00 1f be 20030c0 <create_disk+0x184>
2003048: 91 2d 60 02 sll %l5, 2, %o0
return NULL;
}
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
200304c: 94 24 c0 15 sub %l3, %l5, %o2
2003050: 90 04 80 08 add %l2, %o0, %o0
2003054: 95 2a a0 02 sll %o2, 2, %o2
2003058: 40 00 4d 5e call 20165d0 <memset>
200305c: 92 10 20 00 clr %o1
disktab [major].minor = table;
2003060: c2 05 22 58 ld [ %l4 + 0x258 ], %g1
2003064: e4 20 40 11 st %l2, [ %g1 + %l1 ]
2003068: a2 00 40 11 add %g1, %l1, %l1
disktab [major].size = new_size;
200306c: 10 bf ff c5 b 2002f80 <create_disk+0x44>
2003070: e6 24 60 04 st %l3, [ %l1 + 4 ]
rtems_device_minor_number minor = 0;
rtems_filesystem_split_dev_t(dev, major, minor);
if (major >= disktab_size) {
rtems_disk_device_table *table = disktab;
2003074: 29 00 80 8b sethi %hi(0x2022c00), %l4
rtems_device_major_number old_size = disktab_size;
rtems_device_major_number new_size = 2 * old_size;
2003078: ab 2c a0 01 sll %l2, 1, %l5
if (major >= new_size) {
200307c: 80 a6 00 15 cmp %i0, %l5
2003080: 0a 80 00 03 bcs 200308c <create_disk+0x150> <== NEVER TAKEN
2003084: d0 05 22 58 ld [ %l4 + 0x258 ], %o0
new_size = major + 1;
2003088: aa 06 20 01 add %i0, 1, %l5
}
table = realloc(table, new_size * sizeof(*table));
200308c: 40 00 07 60 call 2004e0c <realloc>
2003090: 93 2d 60 03 sll %l5, 3, %o1
if (table == NULL) {
2003094: a6 92 20 00 orcc %o0, 0, %l3
2003098: 02 80 00 0a be 20030c0 <create_disk+0x184> <== ALWAYS TAKEN
200309c: 91 2c a0 03 sll %l2, 3, %o0
return NULL;
}
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
20030a0: 94 25 40 12 sub %l5, %l2, %o2 <== NOT EXECUTED
20030a4: 90 04 c0 08 add %l3, %o0, %o0 <== NOT EXECUTED
20030a8: 95 2a a0 03 sll %o2, 3, %o2 <== NOT EXECUTED
20030ac: 40 00 4d 49 call 20165d0 <memset> <== NOT EXECUTED
20030b0: 92 10 20 00 clr %o1 <== NOT EXECUTED
disktab = table;
disktab_size = new_size;
20030b4: ea 24 62 5c st %l5, [ %l1 + 0x25c ] <== NOT EXECUTED
if (table == NULL) {
return NULL;
}
memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
disktab = table;
20030b8: 10 bf ff a9 b 2002f5c <create_disk+0x20> <== NOT EXECUTED
20030bc: e6 25 22 58 st %l3, [ %l4 + 0x258 ] <== NOT EXECUTED
*dd_entry = dd;
*dd_ptr = dd;
return RTEMS_SUCCESSFUL;
}
20030c0: 81 c7 e0 08 ret
20030c4: 91 e8 20 1a restore %g0, 0x1a, %o0
}
}
if (name != NULL) {
if (mknod(alloc_name, 0777 | S_IFBLK, dev) < 0) {
free(alloc_name);
20030c8: 40 00 03 32 call 2003d90 <free> <== NOT EXECUTED
20030cc: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
free(dd);
20030d0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20030d4: 40 00 03 2f call 2003d90 <free> <== NOT EXECUTED
20030d8: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED
return RTEMS_UNSATISFIED;
20030dc: 81 c7 e0 08 ret
20030e0: 81 e8 00 00 restore
if (name != NULL) {
alloc_name = strdup(name);
if (alloc_name == NULL) {
free(dd);
20030e4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20030e8: 40 00 03 2a call 2003d90 <free> <== NOT EXECUTED
20030ec: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
20030f0: 81 c7 e0 08 ret <== NOT EXECUTED
20030f4: 81 e8 00 00 restore <== NOT EXECUTED
0200a044 <devFS_close>:
#include "devfs.h"
int devFS_close(
rtems_libio_t *iop
)
{
200a044: 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;
200a048: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
args.flags = 0;
200a04c: c0 27 bf f8 clr [ %fp + -8 ]
args.mode = 0;
200a050: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_close(
200a054: d2 00 60 0c ld [ %g1 + 0xc ], %o1
200a058: 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;
200a05c: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = 0;
args.mode = 0;
status = rtems_io_close(
200a060: 94 07 bf f4 add %fp, -12, %o2
200a064: 40 00 06 15 call 200b8b8 <rtems_io_close>
200a068: b0 10 20 00 clr %i0
np->major,
np->minor,
(void *) &args
);
if ( status ) {
200a06c: 80 a2 20 00 cmp %o0, 0
200a070: 12 80 00 04 bne 200a080 <devFS_close+0x3c> <== NEVER TAKEN
200a074: 01 00 00 00 nop
return rtems_deviceio_errno(status);
}
return 0;
}
200a078: 81 c7 e0 08 ret
200a07c: 81 e8 00 00 restore
np->major,
np->minor,
(void *) &args
);
if ( status ) {
return rtems_deviceio_errno(status);
200a080: 40 00 00 48 call 200a1a0 <rtems_deviceio_errno> <== NOT EXECUTED
200a084: 01 00 00 00 nop <== NOT EXECUTED
}
return 0;
}
200a088: 81 c7 e0 08 ret <== NOT EXECUTED
200a08c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0200a09c <devFS_evaluate_path>:
const char *pathname,
size_t pathnamelen,
int flags,
rtems_filesystem_location_info_t *pathloc
)
{
200a09c: 9d e3 bf a0 save %sp, -96, %sp
int i;
rtems_device_name_t *device_name_table;
/* see if 'flags' is valid */
if ( !rtems_libio_is_valid_perms( flags ) )
200a0a0: 80 8e bf f8 btst -8, %i2
200a0a4: 12 80 00 33 bne 200a170 <devFS_evaluate_path+0xd4> <== NEVER TAKEN
200a0a8: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EPERM );
/* get the device name table */
device_name_table = (rtems_device_name_t *)pathloc->node_access;
200a0ac: e4 06 c0 00 ld [ %i3 ], %l2
if (!device_name_table)
200a0b0: 80 a4 a0 00 cmp %l2, 0
200a0b4: 02 80 00 35 be 200a188 <devFS_evaluate_path+0xec> <== NEVER TAKEN
200a0b8: 03 00 80 42 sethi %hi(0x2010800), %g1
rtems_set_errno_and_return_minus_one( EFAULT );
for (i = 0; i < rtems_device_table_size; i++) {
200a0bc: e6 00 62 88 ld [ %g1 + 0x288 ], %l3 ! 2010a88 <rtems_device_table_size>
rtems_set_errno_and_return_minus_one( EPERM );
/* 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 );
200a0c0: a0 10 20 00 clr %l0
for (i = 0; i < rtems_device_table_size; i++) {
200a0c4: 80 a4 e0 00 cmp %l3, 0
200a0c8: 02 80 00 18 be 200a128 <devFS_evaluate_path+0x8c> <== NEVER TAKEN
200a0cc: 82 10 20 00 clr %g1
if (!device_name_table[i].device_name)
200a0d0: 85 28 60 04 sll %g1, 4, %g2
200a0d4: a9 28 60 02 sll %g1, 2, %l4
200a0d8: a8 05 00 02 add %l4, %g2, %l4
200a0dc: e2 04 80 14 ld [ %l2 + %l4 ], %l1
/* 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++) {
200a0e0: a0 04 20 01 inc %l0
if (!device_name_table[i].device_name)
200a0e4: 80 a4 60 00 cmp %l1, 0
200a0e8: 02 80 00 0d be 200a11c <devFS_evaluate_path+0x80>
200a0ec: a8 04 80 14 add %l2, %l4, %l4
continue;
if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0)
200a0f0: 90 10 00 18 mov %i0, %o0
200a0f4: 92 10 00 11 mov %l1, %o1
200a0f8: 40 00 0f 25 call 200dd8c <strncmp>
200a0fc: 94 10 00 19 mov %i1, %o2
200a100: 80 a2 20 00 cmp %o0, 0
200a104: 12 80 00 07 bne 200a120 <devFS_evaluate_path+0x84> <== NEVER TAKEN
200a108: 80 a4 c0 10 cmp %l3, %l0
continue;
if (device_name_table[i].device_name[pathnamelen] != '\0')
200a10c: c2 4c 40 19 ldsb [ %l1 + %i1 ], %g1
200a110: 80 a0 60 00 cmp %g1, 0
200a114: 02 80 00 0b be 200a140 <devFS_evaluate_path+0xa4>
200a118: 03 00 80 43 sethi %hi(0x2010c00), %g1
/* 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++) {
200a11c: 80 a4 c0 10 cmp %l3, %l0
200a120: 18 bf ff ec bgu 200a0d0 <devFS_evaluate_path+0x34>
200a124: 82 10 00 10 mov %l0, %g1
pathloc->mt_entry = rtems_filesystem_root.mt_entry;
return 0;
}
/* no such file or directory */
rtems_set_errno_and_return_minus_one( ENOENT );
200a128: 40 00 0b 78 call 200cf08 <__errno>
200a12c: b0 10 3f ff mov -1, %i0
200a130: 82 10 20 02 mov 2, %g1
200a134: c2 22 00 00 st %g1, [ %o0 ]
}
200a138: 81 c7 e0 08 ret
200a13c: 81 e8 00 00 restore
/* 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;
200a140: c2 00 60 b8 ld [ %g1 + 0xb8 ], %g1
if (device_name_table[i].device_name[pathnamelen] != '\0')
continue;
/* find the device, set proper values */
pathloc->node_access = (void *)&device_name_table[i];
200a144: e8 26 c0 00 st %l4, [ %i3 ]
pathloc->handlers = &devFS_file_handlers;
pathloc->ops = &devFS_ops;
pathloc->mt_entry = rtems_filesystem_root.mt_entry;
200a148: c2 00 60 28 ld [ %g1 + 0x28 ], %g1
200a14c: 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;
200a150: 03 00 80 43 sethi %hi(0x2010c00), %g1
200a154: 82 10 60 60 or %g1, 0x60, %g1 ! 2010c60 <devFS_file_handlers>
200a158: c2 26 e0 08 st %g1, [ %i3 + 8 ]
pathloc->ops = &devFS_ops;
200a15c: 03 00 80 43 sethi %hi(0x2010c00), %g1
200a160: 82 10 60 18 or %g1, 0x18, %g1 ! 2010c18 <devFS_ops>
200a164: c2 26 e0 0c st %g1, [ %i3 + 0xc ]
pathloc->mt_entry = rtems_filesystem_root.mt_entry;
return 0;
200a168: 81 c7 e0 08 ret
200a16c: 91 e8 20 00 restore %g0, 0, %o0
int i;
rtems_device_name_t *device_name_table;
/* see if 'flags' is valid */
if ( !rtems_libio_is_valid_perms( flags ) )
rtems_set_errno_and_return_minus_one( EPERM );
200a170: 40 00 0b 66 call 200cf08 <__errno> <== NOT EXECUTED
200a174: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200a178: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
200a17c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200a180: 81 c7 e0 08 ret <== NOT EXECUTED
200a184: 81 e8 00 00 restore <== NOT EXECUTED
/* 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 );
200a188: 40 00 0b 60 call 200cf08 <__errno> <== NOT EXECUTED
200a18c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200a190: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
200a194: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200a198: 81 c7 e0 08 ret <== NOT EXECUTED
200a19c: 81 e8 00 00 restore <== NOT EXECUTED
02001fd8 <devFS_initialize>:
int devFS_initialize(
rtems_filesystem_mount_table_entry_t *temp_mt_entry,
const void *data
)
{
2001fd8: 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(
2001fdc: 23 00 80 42 sethi %hi(0x2010800), %l1
2001fe0: c2 04 62 88 ld [ %l1 + 0x288 ], %g1 ! 2010a88 <rtems_device_table_size>
2001fe4: 85 28 60 04 sll %g1, 4, %g2
2001fe8: 83 28 60 02 sll %g1, 2, %g1
2001fec: 40 00 1e 46 call 2009904 <_Workspace_Allocate>
2001ff0: 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)
2001ff4: a0 92 20 00 orcc %o0, 0, %l0
2001ff8: 02 80 00 10 be 2002038 <devFS_initialize+0x60> <== NEVER TAKEN
2001ffc: c2 04 62 88 ld [ %l1 + 0x288 ], %g1
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(
2002000: 92 10 20 00 clr %o1
2002004: 85 28 60 04 sll %g1, 4, %g2
2002008: 83 28 60 02 sll %g1, 2, %g1
200200c: 40 00 2e 20 call 200d88c <memset>
2002010: 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;
2002014: 03 00 80 43 sethi %hi(0x2010c00), %g1
2002018: 82 10 60 60 or %g1, 0x60, %g1 ! 2010c60 <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;
200201c: 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;
2002020: c2 26 20 24 st %g1, [ %i0 + 0x24 ]
temp_mt_entry->mt_fs_root.ops = &devFS_ops;
2002024: 03 00 80 43 sethi %hi(0x2010c00), %g1
2002028: 82 10 60 18 or %g1, 0x18, %g1 ! 2010c18 <devFS_ops>
200202c: 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;
}
2002030: 81 c7 e0 08 ret
2002034: 91 e8 20 00 restore %g0, 0, %o0
sizeof( rtems_device_name_t ) * ( rtems_device_table_size )
);
/* no memory for device filesystem */
if (!device_name_table)
rtems_set_errno_and_return_minus_one( ENOMEM );
2002038: 40 00 2b b4 call 200cf08 <__errno> <== NOT EXECUTED
200203c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002040: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
2002044: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002048: 81 c7 e0 08 ret <== NOT EXECUTED
200204c: 81 e8 00 00 restore <== NOT EXECUTED
020021fc <devFS_ioctl>:
int devFS_ioctl(
rtems_libio_t *iop,
uint32_t command,
void *buffer
)
{
20021fc: 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;
2002200: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
args.command = command;
2002204: f2 27 bf f4 st %i1, [ %fp + -12 ]
args.buffer = buffer;
status = rtems_io_control(
2002208: d2 00 60 0c ld [ %g1 + 0xc ], %o1
200220c: 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;
2002210: f0 27 bf f0 st %i0, [ %fp + -16 ]
args.command = command;
args.buffer = buffer;
2002214: f4 27 bf f8 st %i2, [ %fp + -8 ]
status = rtems_io_control(
2002218: 40 00 11 47 call 2006734 <rtems_io_control>
200221c: 94 07 bf f0 add %fp, -16, %o2
np->major,
np->minor,
(void *) &args
);
if ( status )
2002220: 80 a2 20 00 cmp %o0, 0
2002224: 12 80 00 05 bne 2002238 <devFS_ioctl+0x3c> <== NEVER TAKEN
2002228: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return args.ioctl_return;
200222c: f0 07 bf fc ld [ %fp + -4 ], %i0
}
2002230: 81 c7 e0 08 ret
2002234: 81 e8 00 00 restore
np->minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
2002238: 40 00 1f da call 200a1a0 <rtems_deviceio_errno> <== NOT EXECUTED
200223c: 01 00 00 00 nop <== NOT EXECUTED
2002240: 81 c7 e0 08 ret <== NOT EXECUTED
2002244: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02002050 <devFS_mknod>:
const char *path,
mode_t mode,
dev_t dev,
rtems_filesystem_location_info_t *pathloc
)
{
2002050: 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') &&
2002054: c2 4e 00 00 ldsb [ %i0 ], %g1
2002058: 80 a0 60 64 cmp %g1, 0x64
200205c: 02 80 00 43 be 2002168 <devFS_mknod+0x118> <== ALWAYS TAKEN
2002060: a0 10 00 18 mov %i0, %l0
(path[2] == 'v') && (path[3] == '\0'))
return 0;
/* must be a character device or a block device */
if (!S_ISBLK(mode) && !S_ISCHR(mode))
2002064: 03 00 00 3c sethi %hi(0xf000), %g1
2002068: 05 00 00 08 sethi %hi(0x2000), %g2
200206c: 82 0e 40 01 and %i1, %g1, %g1
2002070: 80 a0 40 02 cmp %g1, %g2
2002074: 12 80 00 4b bne 20021a0 <devFS_mknod+0x150> <== NEVER TAKEN
2002078: 05 00 00 18 sethi %hi(0x6000), %g2
rtems_set_errno_and_return_minus_one( EINVAL );
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;
200207c: e4 07 00 00 ld [ %i4 ], %l2
if (!device_name_table)
2002080: 80 a4 a0 00 cmp %l2, 0
2002084: 02 80 00 56 be 20021dc <devFS_mknod+0x18c> <== NEVER TAKEN
2002088: 03 00 80 42 sethi %hi(0x2010800), %g1
rtems_set_errno_and_return_minus_one( EFAULT );
for (slot = -1, i = 0; i < rtems_device_table_size; i++){
200208c: e6 00 62 88 ld [ %g1 + 0x288 ], %l3 ! 2010a88 <rtems_device_table_size>
2002090: 80 a4 e0 00 cmp %l3, 0
2002094: 02 80 00 4c be 20021c4 <devFS_mknod+0x174> <== NEVER TAKEN
2002098: 82 10 20 00 clr %g1
rtems_filesystem_split_dev_t(dev, major, minor);
/* Find an empty slot in device name table */
device_name_table = (rtems_device_name_t *)pathloc->node_access;
if (!device_name_table)
rtems_set_errno_and_return_minus_one( EFAULT );
200209c: a8 10 3f ff mov -1, %l4
20020a0: 10 80 00 0a b 20020c8 <devFS_mknod+0x78>
20020a4: a2 10 20 00 clr %l1
for (slot = -1, i = 0; i < rtems_device_table_size; i++){
if (device_name_table[i].device_name == NULL)
slot = i;
else
if (strcmp(path, device_name_table[i].device_name) == 0)
20020a8: 40 00 2e b3 call 200db74 <strcmp>
20020ac: 01 00 00 00 nop
20020b0: 80 a2 20 00 cmp %o0, 0
20020b4: 02 80 00 27 be 2002150 <devFS_mknod+0x100> <== NEVER TAKEN
20020b8: a2 04 60 01 inc %l1
/* 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++){
20020bc: 80 a4 40 13 cmp %l1, %l3
20020c0: 1a 80 00 0e bcc 20020f8 <devFS_mknod+0xa8> <== ALWAYS TAKEN
20020c4: 82 10 00 11 mov %l1, %g1
if (device_name_table[i].device_name == NULL)
20020c8: 85 28 60 04 sll %g1, 4, %g2
20020cc: 83 28 60 02 sll %g1, 2, %g1
20020d0: 82 00 40 02 add %g1, %g2, %g1
20020d4: d2 04 80 01 ld [ %l2 + %g1 ], %o1
20020d8: 80 a2 60 00 cmp %o1, 0
20020dc: 12 bf ff f3 bne 20020a8 <devFS_mknod+0x58>
20020e0: 90 10 00 10 mov %l0, %o0
slot = i;
else
if (strcmp(path, device_name_table[i].device_name) == 0)
rtems_set_errno_and_return_minus_one( EEXIST );
20020e4: a8 10 00 11 mov %l1, %l4
/* 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++){
20020e8: a2 04 60 01 inc %l1
20020ec: 80 a4 40 13 cmp %l1, %l3
20020f0: 0a bf ff f6 bcs 20020c8 <devFS_mknod+0x78>
20020f4: 82 10 00 11 mov %l1, %g1
else
if (strcmp(path, device_name_table[i].device_name) == 0)
rtems_set_errno_and_return_minus_one( EEXIST );
}
if (slot == -1)
20020f8: 80 a5 3f ff cmp %l4, -1
20020fc: 02 80 00 32 be 20021c4 <devFS_mknod+0x174> <== NEVER TAKEN
2002100: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOMEM );
_ISR_Disable(level);
2002104: 7f ff ff 3e call 2001dfc <sparc_disable_interrupts>
2002108: 01 00 00 00 nop
200210c: a2 10 00 08 mov %o0, %l1
device_name_table[slot].device_name = (char *)path;
2002110: 83 2d 20 04 sll %l4, 4, %g1
device_name_table[slot].device_name_length = strlen(path);
2002114: 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;
2002118: a9 2d 20 02 sll %l4, 2, %l4
200211c: a8 05 00 01 add %l4, %g1, %l4
2002120: e0 24 80 14 st %l0, [ %l2 + %l4 ]
device_name_table[slot].device_name_length = strlen(path);
2002124: 40 00 2e e5 call 200dcb8 <strlen>
2002128: a4 04 80 14 add %l2, %l4, %l2
device_name_table[slot].major = major;
device_name_table[slot].minor = minor;
device_name_table[slot].mode = mode;
200212c: f2 24 a0 10 st %i1, [ %l2 + 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);
2002130: d0 24 a0 04 st %o0, [ %l2 + 4 ]
device_name_table[slot].major = major;
2002134: f4 24 a0 08 st %i2, [ %l2 + 8 ]
device_name_table[slot].minor = minor;
2002138: f6 24 a0 0c st %i3, [ %l2 + 0xc ]
device_name_table[slot].mode = mode;
_ISR_Enable(level);
200213c: b0 10 20 00 clr %i0
2002140: 7f ff ff 33 call 2001e0c <sparc_enable_interrupts>
2002144: 90 10 00 11 mov %l1, %o0
return 0;
}
2002148: 81 c7 e0 08 ret
200214c: 81 e8 00 00 restore
for (slot = -1, i = 0; i < rtems_device_table_size; i++){
if (device_name_table[i].device_name == NULL)
slot = i;
else
if (strcmp(path, device_name_table[i].device_name) == 0)
rtems_set_errno_and_return_minus_one( EEXIST );
2002150: 40 00 2b 6e call 200cf08 <__errno> <== NOT EXECUTED
2002154: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002158: 82 10 20 11 mov 0x11, %g1 <== NOT EXECUTED
200215c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002160: 81 c7 e0 08 ret <== NOT EXECUTED
2002164: 81 e8 00 00 restore <== NOT EXECUTED
* 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') &&
2002168: c2 4e 20 01 ldsb [ %i0 + 1 ], %g1
200216c: 80 a0 60 65 cmp %g1, 0x65
2002170: 12 bf ff be bne 2002068 <devFS_mknod+0x18> <== NEVER TAKEN
2002174: 03 00 00 3c sethi %hi(0xf000), %g1
(path[2] == 'v') && (path[3] == '\0'))
2002178: c2 4e 20 02 ldsb [ %i0 + 2 ], %g1
200217c: 80 a0 60 76 cmp %g1, 0x76
2002180: 12 bf ff ba bne 2002068 <devFS_mknod+0x18> <== NEVER TAKEN
2002184: 03 00 00 3c sethi %hi(0xf000), %g1
2002188: c2 4e 20 03 ldsb [ %i0 + 3 ], %g1
200218c: 80 a0 60 00 cmp %g1, 0
2002190: 12 bf ff b5 bne 2002064 <devFS_mknod+0x14>
2002194: b0 10 20 00 clr %i0
device_name_table[slot].minor = minor;
device_name_table[slot].mode = mode;
_ISR_Enable(level);
return 0;
}
2002198: 81 c7 e0 08 ret
200219c: 81 e8 00 00 restore
if ((path[0] == 'd') && (path[1] == 'e') &&
(path[2] == 'v') && (path[3] == '\0'))
return 0;
/* must be a character device or a block device */
if (!S_ISBLK(mode) && !S_ISCHR(mode))
20021a0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20021a4: 22 bf ff b7 be,a 2002080 <devFS_mknod+0x30> <== NOT EXECUTED
20021a8: e4 07 00 00 ld [ %i4 ], %l2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
20021ac: 40 00 2b 57 call 200cf08 <__errno> <== NOT EXECUTED
20021b0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20021b4: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20021b8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20021bc: 81 c7 e0 08 ret <== NOT EXECUTED
20021c0: 81 e8 00 00 restore <== NOT EXECUTED
if (strcmp(path, device_name_table[i].device_name) == 0)
rtems_set_errno_and_return_minus_one( EEXIST );
}
if (slot == -1)
rtems_set_errno_and_return_minus_one( ENOMEM );
20021c4: 40 00 2b 51 call 200cf08 <__errno> <== NOT EXECUTED
20021c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20021cc: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
20021d0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20021d4: 81 c7 e0 08 ret <== NOT EXECUTED
20021d8: 81 e8 00 00 restore <== NOT EXECUTED
rtems_filesystem_split_dev_t(dev, major, minor);
/* Find an empty slot in device name table */
device_name_table = (rtems_device_name_t *)pathloc->node_access;
if (!device_name_table)
rtems_set_errno_and_return_minus_one( EFAULT );
20021dc: 40 00 2b 4b call 200cf08 <__errno> <== NOT EXECUTED
20021e0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20021e4: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
20021e8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20021ec: 81 c7 e0 08 ret <== NOT EXECUTED
20021f0: 81 e8 00 00 restore <== NOT EXECUTED
02002248 <devFS_open>:
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
2002248: 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;
200224c: 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;
2002250: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
args.flags = iop->flags;
2002254: c4 27 bf f8 st %g2, [ %fp + -8 ]
args.mode = mode;
2002258: f6 27 bf fc st %i3, [ %fp + -4 ]
status = rtems_io_open(
200225c: d2 00 60 0c ld [ %g1 + 0xc ], %o1
2002260: 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;
2002264: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = iop->flags;
args.mode = mode;
status = rtems_io_open(
2002268: 94 07 bf f4 add %fp, -12, %o2
200226c: 40 00 11 8f call 20068a8 <rtems_io_open>
2002270: b0 10 20 00 clr %i0
np->major,
np->minor,
(void *) &args
);
if ( status )
2002274: 80 a2 20 00 cmp %o0, 0
2002278: 12 80 00 04 bne 2002288 <devFS_open+0x40> <== NEVER TAKEN
200227c: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return 0;
}
2002280: 81 c7 e0 08 ret
2002284: 81 e8 00 00 restore
np->major,
np->minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
2002288: 40 00 1f c6 call 200a1a0 <rtems_deviceio_errno> <== NOT EXECUTED
200228c: 01 00 00 00 nop <== NOT EXECUTED
return 0;
}
2002290: 81 c7 e0 08 ret <== NOT EXECUTED
2002294: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02002298 <devFS_read>:
ssize_t devFS_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
2002298: 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;
200229c: 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;
20022a0: 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;
20022a4: 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;
20022a8: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED
args.flags = iop->flags;
args.bytes_moved = 0;
20022ac: 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;
20022b0: 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(
20022b4: d2 00 60 0c ld [ %g1 + 0xc ], %o1 <== NOT EXECUTED
20022b8: 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;
20022bc: c4 3f bf e8 std %g2, [ %fp + -24 ] <== NOT EXECUTED
args.buffer = buffer;
20022c0: 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;
20022c4: 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(
20022c8: 40 00 11 90 call 2006908 <rtems_io_read> <== NOT EXECUTED
20022cc: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED
np->major,
np->minor,
(void *) &args
);
if ( status )
20022d0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20022d4: 12 80 00 05 bne 20022e8 <devFS_read+0x50> <== NOT EXECUTED
20022d8: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno(status);
return (ssize_t) args.bytes_moved;
20022dc: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
20022e0: 81 c7 e0 08 ret <== NOT EXECUTED
20022e4: 81 e8 00 00 restore <== NOT EXECUTED
np->minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
20022e8: 40 00 1f ae call 200a1a0 <rtems_deviceio_errno> <== NOT EXECUTED
20022ec: 01 00 00 00 nop <== NOT EXECUTED
20022f0: 81 c7 e0 08 ret <== NOT EXECUTED
20022f4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020022f8 <devFS_stat>:
int devFS_stat(
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
20022f8: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_name_t *the_dev;
the_dev = (rtems_device_name_t *)loc->node_access;
20022fc: c2 06 00 00 ld [ %i0 ], %g1
if (!the_dev)
2002300: 80 a0 60 00 cmp %g1, 0
2002304: 02 80 00 0a be 200232c <devFS_stat+0x34> <== NEVER TAKEN
2002308: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
buf->st_rdev = rtems_filesystem_make_dev_t( the_dev->major, the_dev->minor );
200230c: c4 00 60 0c ld [ %g1 + 0xc ], %g2
buf->st_mode = the_dev->mode;
2002310: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
2002314: 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 );
2002318: c4 26 60 1c st %g2, [ %i1 + 0x1c ]
buf->st_mode = the_dev->mode;
200231c: 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 );
2002320: c2 26 60 18 st %g1, [ %i1 + 0x18 ]
buf->st_mode = the_dev->mode;
return 0;
}
2002324: 81 c7 e0 08 ret
2002328: 91 e8 20 00 restore %g0, 0, %o0
{
rtems_device_name_t *the_dev;
the_dev = (rtems_device_name_t *)loc->node_access;
if (!the_dev)
rtems_set_errno_and_return_minus_one( EFAULT );
200232c: 40 00 2a f7 call 200cf08 <__errno> <== NOT EXECUTED
2002330: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002334: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
2002338: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200233c: 81 c7 e0 08 ret <== NOT EXECUTED
2002340: 81 e8 00 00 restore <== NOT EXECUTED
02002344 <devFS_write>:
ssize_t devFS_write(
rtems_libio_t *iop,
const void *buffer,
size_t count
)
{
2002344: 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;
2002348: 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;
200234c: 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;
2002350: 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;
2002354: f4 27 bf f4 st %i2, [ %fp + -12 ]
args.flags = iop->flags;
args.bytes_moved = 0;
2002358: 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;
200235c: 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(
2002360: d2 00 60 0c ld [ %g1 + 0xc ], %o1
2002364: 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;
2002368: c4 3f bf e8 std %g2, [ %fp + -24 ]
args.buffer = (void *) buffer;
200236c: 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;
2002370: 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(
2002374: 40 00 11 7d call 2006968 <rtems_io_write>
2002378: 94 07 bf e0 add %fp, -32, %o2
np->major,
np->minor,
(void *) &args
);
if ( status )
200237c: 80 a2 20 00 cmp %o0, 0
2002380: 12 80 00 05 bne 2002394 <devFS_write+0x50> <== NEVER TAKEN
2002384: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return (ssize_t) args.bytes_moved;
2002388: f0 07 bf fc ld [ %fp + -4 ], %i0
}
200238c: 81 c7 e0 08 ret
2002390: 81 e8 00 00 restore
np->minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
2002394: 40 00 1f 83 call 200a1a0 <rtems_deviceio_errno> <== NOT EXECUTED
2002398: 01 00 00 00 nop <== NOT EXECUTED
200239c: 81 c7 e0 08 ret <== NOT EXECUTED
20023a0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02010074 <device_close>:
*/
int device_close(
rtems_libio_t *iop
)
{
2010074: 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;
2010078: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
201007c: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = 0;
2010080: c0 27 bf f8 clr [ %fp + -8 ]
args.mode = 0;
2010084: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_close(
2010088: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0
201008c: 94 07 bf f4 add %fp, -12, %o2
2010090: 40 00 04 fc call 2011480 <rtems_io_close>
2010094: b0 10 20 00 clr %i0
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status ) {
2010098: 80 a2 20 00 cmp %o0, 0
201009c: 12 80 00 04 bne 20100ac <device_close+0x38> <== NEVER TAKEN
20100a0: 01 00 00 00 nop
return rtems_deviceio_errno(status);
}
return 0;
}
20100a4: 81 c7 e0 08 ret
20100a8: 81 e8 00 00 restore
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status ) {
return rtems_deviceio_errno(status);
20100ac: 40 00 05 ec call 201185c <rtems_deviceio_errno> <== NOT EXECUTED
20100b0: 01 00 00 00 nop <== NOT EXECUTED
}
return 0;
}
20100b4: 81 c7 e0 08 ret <== NOT EXECUTED
20100b8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0200ff74 <device_ioctl>:
int device_ioctl(
rtems_libio_t *iop,
uint32_t command,
void *buffer
)
{
200ff74: 9d e3 bf 90 save %sp, -112, %sp
args.iop = iop;
args.command = command;
args.buffer = buffer;
the_jnode = iop->file_info;
200ff78: 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;
200ff7c: f2 27 bf f4 st %i1, [ %fp + -12 ]
args.buffer = buffer;
200ff80: 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;
200ff84: f0 27 bf f0 st %i0, [ %fp + -16 ]
args.command = command;
args.buffer = buffer;
the_jnode = iop->file_info;
status = rtems_io_control(
200ff88: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0
200ff8c: 40 00 05 55 call 20114e0 <rtems_io_control>
200ff90: 94 07 bf f0 add %fp, -16, %o2
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
200ff94: 80 a2 20 00 cmp %o0, 0
200ff98: 12 80 00 05 bne 200ffac <device_ioctl+0x38> <== NEVER TAKEN
200ff9c: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return args.ioctl_return;
200ffa0: f0 07 bf fc ld [ %fp + -4 ], %i0
}
200ffa4: 81 c7 e0 08 ret
200ffa8: 81 e8 00 00 restore
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
200ffac: 40 00 06 2c call 201185c <rtems_deviceio_errno> <== NOT EXECUTED
200ffb0: 01 00 00 00 nop <== NOT EXECUTED
200ffb4: 81 c7 e0 08 ret <== NOT EXECUTED
200ffb8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020100bc <device_open>:
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
20100bc: 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;
20100c0: 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;
20100c4: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
20100c8: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = iop->flags;
20100cc: c4 27 bf f8 st %g2, [ %fp + -8 ]
args.mode = mode;
20100d0: f6 27 bf fc st %i3, [ %fp + -4 ]
status = rtems_io_open(
20100d4: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0
20100d8: 94 07 bf f4 add %fp, -12, %o2
20100dc: 40 00 05 19 call 2011540 <rtems_io_open>
20100e0: b0 10 20 00 clr %i0
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
20100e4: 80 a2 20 00 cmp %o0, 0
20100e8: 12 80 00 04 bne 20100f8 <device_open+0x3c> <== NEVER TAKEN
20100ec: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return 0;
}
20100f0: 81 c7 e0 08 ret
20100f4: 81 e8 00 00 restore
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
20100f8: 40 00 05 d9 call 201185c <rtems_deviceio_errno> <== NOT EXECUTED
20100fc: 01 00 00 00 nop <== NOT EXECUTED
return 0;
}
2010100: 81 c7 e0 08 ret <== NOT EXECUTED
2010104: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02010018 <device_read>:
ssize_t device_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
2010018: 9d e3 bf 80 save %sp, -128, %sp
args.iop = iop;
args.offset = iop->offset;
args.buffer = buffer;
args.count = count;
args.flags = iop->flags;
201001c: 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;
2010020: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
args.offset = iop->offset;
2010024: d8 1e 20 10 ldd [ %i0 + 0x10 ], %o4
args.buffer = buffer;
2010028: 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;
201002c: d8 3f bf e8 std %o4, [ %fp + -24 ]
args.buffer = buffer;
args.count = count;
2010030: f4 27 bf f4 st %i2, [ %fp + -12 ]
args.flags = iop->flags;
2010034: 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;
2010038: f0 27 bf e0 st %i0, [ %fp + -32 ]
args.offset = iop->offset;
args.buffer = buffer;
args.count = count;
args.flags = iop->flags;
args.bytes_moved = 0;
201003c: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_read(
2010040: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0
2010044: 40 00 05 57 call 20115a0 <rtems_io_read>
2010048: 94 07 bf e0 add %fp, -32, %o2
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
201004c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2010050: 12 80 00 05 bne 2010064 <device_read+0x4c> <== NOT EXECUTED
2010054: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno(status);
return (ssize_t) args.bytes_moved;
2010058: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
201005c: 81 c7 e0 08 ret <== NOT EXECUTED
2010060: 81 e8 00 00 restore <== NOT EXECUTED
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
2010064: 40 00 05 fe call 201185c <rtems_deviceio_errno> <== NOT EXECUTED
2010068: 01 00 00 00 nop <== NOT EXECUTED
201006c: 81 c7 e0 08 ret <== NOT EXECUTED
2010070: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0200ffbc <device_write>:
ssize_t device_write(
rtems_libio_t *iop,
const void *buffer,
size_t count
)
{
200ffbc: 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;
200ffc0: 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;
200ffc4: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
args.offset = iop->offset;
200ffc8: d8 1e 20 10 ldd [ %i0 + 0x10 ], %o4
args.buffer = (void *) buffer;
200ffcc: 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;
200ffd0: d8 3f bf e8 std %o4, [ %fp + -24 ]
args.buffer = (void *) buffer;
args.count = count;
200ffd4: f4 27 bf f4 st %i2, [ %fp + -12 ]
args.flags = iop->flags;
200ffd8: 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;
200ffdc: 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;
200ffe0: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_write(
200ffe4: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0
200ffe8: 40 00 05 86 call 2011600 <rtems_io_write>
200ffec: 94 07 bf e0 add %fp, -32, %o2
the_jnode->info.device.major,
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
200fff0: 80 a2 20 00 cmp %o0, 0
200fff4: 12 80 00 05 bne 2010008 <device_write+0x4c> <== NEVER TAKEN
200fff8: 01 00 00 00 nop
return rtems_deviceio_errno(status);
return (ssize_t) args.bytes_moved;
200fffc: f0 07 bf fc ld [ %fp + -4 ], %i0
}
2010000: 81 c7 e0 08 ret
2010004: 81 e8 00 00 restore
the_jnode->info.device.minor,
(void *) &args
);
if ( status )
return rtems_deviceio_errno(status);
2010008: 40 00 06 15 call 201185c <rtems_deviceio_errno> <== NOT EXECUTED
201000c: 01 00 00 00 nop <== NOT EXECUTED
2010010: 81 c7 e0 08 ret <== NOT EXECUTED
2010014: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02002b28 <disk_lock>:
*/
static volatile bool diskdevs_protected;
static rtems_status_code
disk_lock(void)
{
2002b28: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
sc = rtems_semaphore_obtain(diskdevs_mutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2002b2c: 03 00 80 8b sethi %hi(0x2022c00), %g1
2002b30: d0 00 62 60 ld [ %g1 + 0x260 ], %o0 ! 2022e60 <diskdevs_mutex>
2002b34: 92 10 20 00 clr %o1
2002b38: 94 10 20 00 clr %o2
2002b3c: 40 00 14 63 call 2007cc8 <rtems_semaphore_obtain>
2002b40: b0 10 20 16 mov 0x16, %i0
if (sc == RTEMS_SUCCESSFUL) {
2002b44: 80 a2 20 00 cmp %o0, 0
2002b48: 12 80 00 05 bne 2002b5c <disk_lock+0x34> <== NEVER TAKEN
2002b4c: 84 10 20 01 mov 1, %g2
diskdevs_protected = true;
2002b50: 03 00 80 8b sethi %hi(0x2022c00), %g1
2002b54: b0 10 20 00 clr %i0
2002b58: c4 28 62 64 stb %g2, [ %g1 + 0x264 ]
return RTEMS_SUCCESSFUL;
} else {
return RTEMS_NOT_CONFIGURED;
}
}
2002b5c: 81 c7 e0 08 ret
2002b60: 81 e8 00 00 restore
02002b64 <disk_unlock>:
static void
disk_unlock(void)
{
2002b64: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
diskdevs_protected = false;
sc = rtems_semaphore_release(diskdevs_mutex);
2002b68: 03 00 80 8b sethi %hi(0x2022c00), %g1
2002b6c: d0 00 62 60 ld [ %g1 + 0x260 ], %o0 ! 2022e60 <diskdevs_mutex>
static void
disk_unlock(void)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
diskdevs_protected = false;
2002b70: 03 00 80 8b sethi %hi(0x2022c00), %g1
2002b74: c0 28 62 64 clrb [ %g1 + 0x264 ] ! 2022e64 <diskdevs_protected>
sc = rtems_semaphore_release(diskdevs_mutex);
2002b78: 40 00 14 9b call 2007de4 <rtems_semaphore_release>
2002b7c: 01 00 00 00 nop
if (sc != RTEMS_SUCCESSFUL) {
2002b80: 80 a2 20 00 cmp %o0, 0
2002b84: 12 80 00 04 bne 2002b94 <disk_unlock+0x30> <== NEVER TAKEN
2002b88: 11 37 ab 6f sethi %hi(0xdeadbc00), %o0
2002b8c: 81 c7 e0 08 ret
2002b90: 81 e8 00 00 restore
/* FIXME: Error number */
rtems_fatal_error_occurred(0xdeadbeef);
2002b94: 40 00 15 d6 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
2002b98: 90 12 22 ef or %o0, 0x2ef, %o0 <== NOT EXECUTED
02004d38 <drainOutput>:
/*
* Drain output queue
*/
static void
drainOutput (struct rtems_termios_tty *tty)
{
2004d38: 9d e3 bf a0 save %sp, -96, %sp
rtems_interrupt_level level;
rtems_status_code sc;
if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
2004d3c: c2 06 20 b4 ld [ %i0 + 0xb4 ], %g1
2004d40: 80 a0 60 00 cmp %g1, 0
2004d44: 12 80 00 04 bne 2004d54 <drainOutput+0x1c> <== NEVER TAKEN
2004d48: 01 00 00 00 nop
2004d4c: 81 c7 e0 08 ret
2004d50: 81 e8 00 00 restore
rtems_interrupt_disable (level);
2004d54: 7f ff f4 d4 call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2004d58: 01 00 00 00 nop <== NOT EXECUTED
while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) {
2004d5c: c4 06 20 84 ld [ %i0 + 0x84 ], %g2 <== NOT EXECUTED
2004d60: c2 06 20 80 ld [ %i0 + 0x80 ], %g1 <== NOT EXECUTED
2004d64: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004d68: 02 80 00 14 be 2004db8 <drainOutput+0x80> <== NOT EXECUTED
2004d6c: 01 00 00 00 nop <== NOT EXECUTED
tty->rawOutBufState = rob_wait;
2004d70: a0 10 20 02 mov 2, %l0 ! 2 <PROM_START+0x2> <== NOT EXECUTED
2004d74: e0 26 20 94 st %l0, [ %i0 + 0x94 ] <== NOT EXECUTED
rtems_interrupt_enable (level);
2004d78: 7f ff f4 cf call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004d7c: 01 00 00 00 nop <== NOT EXECUTED
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
2004d80: d0 06 20 8c ld [ %i0 + 0x8c ], %o0 <== NOT EXECUTED
2004d84: 92 10 20 00 clr %o1 <== NOT EXECUTED
2004d88: 40 00 06 d3 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
2004d8c: 94 10 20 00 clr %o2 <== NOT EXECUTED
RTEMS_WAIT,
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2004d90: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2004d94: 12 80 00 0b bne 2004dc0 <drainOutput+0x88> <== NOT EXECUTED
2004d98: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
rtems_interrupt_disable (level);
2004d9c: 7f ff f4 c2 call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2004da0: 01 00 00 00 nop <== NOT EXECUTED
rtems_interrupt_level level;
rtems_status_code sc;
if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
rtems_interrupt_disable (level);
while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) {
2004da4: c4 06 20 84 ld [ %i0 + 0x84 ], %g2 <== NOT EXECUTED
2004da8: c2 06 20 80 ld [ %i0 + 0x80 ], %g1 <== NOT EXECUTED
2004dac: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004db0: 32 bf ff f2 bne,a 2004d78 <drainOutput+0x40> <== NOT EXECUTED
2004db4: e0 26 20 94 st %l0, [ %i0 + 0x94 ] <== NOT EXECUTED
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
rtems_interrupt_disable (level);
}
rtems_interrupt_enable (level);
2004db8: 7f ff f4 bf call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004dbc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_interrupt_enable (level);
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
RTEMS_WAIT,
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
2004dc0: 40 00 08 66 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
0200346c <dup2>:
int dup2(
int fildes,
int fildes2
)
{
200346c: 9d e3 bf 58 save %sp, -168, %sp
/*
* If fildes is not valid, then fildes2 should not be closed.
*/
status = fstat( fildes, &buf );
2003470: a0 07 bf b8 add %fp, -72, %l0
2003474: 90 10 00 18 mov %i0, %o0
2003478: 40 00 01 ed call 2003c2c <fstat>
200347c: 92 10 00 10 mov %l0, %o1
if ( status == -1 )
2003480: 80 a2 3f ff cmp %o0, -1
2003484: 12 80 00 04 bne 2003494 <dup2+0x28> <== ALWAYS TAKEN
2003488: 92 10 00 10 mov %l0, %o1
/*
* This fcntl handles everything else.
*/
return fcntl( fildes, F_DUPFD, fildes2 );
}
200348c: 81 c7 e0 08 ret
2003490: 91 e8 3f ff restore %g0, -1, %o0
/*
* If fildes2 is not valid, then we should not do anything either.
*/
status = fstat( fildes2, &buf );
2003494: 40 00 01 e6 call 2003c2c <fstat>
2003498: 90 10 00 19 mov %i1, %o0
if ( status == -1 )
200349c: 80 a2 3f ff cmp %o0, -1
20034a0: 02 bf ff fb be 200348c <dup2+0x20> <== ALWAYS TAKEN
20034a4: 90 10 00 18 mov %i0, %o0
/*
* This fcntl handles everything else.
*/
return fcntl( fildes, F_DUPFD, fildes2 );
20034a8: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
20034ac: 40 00 00 a2 call 2003734 <fcntl> <== NOT EXECUTED
20034b0: 92 10 20 00 clr %o1 <== NOT EXECUTED
20034b4: 81 c7 e0 08 ret <== NOT EXECUTED
20034b8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02004764 <echo>:
/*
* Echo a typed character
*/
static void
echo (unsigned char c, struct rtems_termios_tty *tty)
{
2004764: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) {
2004768: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED
200476c: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED
2004770: 02 80 00 09 be 2004794 <echo+0x30> <== NOT EXECUTED
2004774: 90 0e 20 ff and %i0, 0xff, %o0 <== NOT EXECUTED
2004778: 05 00 80 7a sethi %hi(0x201e800), %g2 <== NOT EXECUTED
200477c: c4 00 a2 2c ld [ %g2 + 0x22c ], %g2 ! 201ea2c <__ctype_ptr__><== NOT EXECUTED
2004780: 82 00 80 08 add %g2, %o0, %g1 <== NOT EXECUTED
2004784: c2 08 60 01 ldub [ %g1 + 1 ], %g1 <== NOT EXECUTED
2004788: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
200478c: 12 80 00 06 bne 20047a4 <echo+0x40> <== NOT EXECUTED
2004790: 80 a2 20 09 cmp %o0, 9 <== NOT EXECUTED
echobuf[1] = c ^ 0x40;
rtems_termios_puts (echobuf, 2, tty);
tty->column += 2;
}
else {
oproc (c, tty);
2004794: 7f ff ff 87 call 20045b0 <oproc> <== NOT EXECUTED
2004798: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200479c: 81 c7 e0 08 ret <== NOT EXECUTED
20047a0: 81 e8 00 00 restore <== 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')) {
20047a4: 02 bf ff fc be 2004794 <echo+0x30> <== NOT EXECUTED
20047a8: 80 a2 20 0a cmp %o0, 0xa <== NOT EXECUTED
20047ac: 02 bf ff fa be 2004794 <echo+0x30> <== NOT EXECUTED
20047b0: 82 10 20 5e mov 0x5e, %g1 <== NOT EXECUTED
char echobuf[2];
echobuf[0] = '^';
echobuf[1] = c ^ 0x40;
20047b4: 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] = '^';
20047b8: c2 2f bf f8 stb %g1, [ %fp + -8 ] <== NOT EXECUTED
echobuf[1] = c ^ 0x40;
20047bc: f0 2f bf f9 stb %i0, [ %fp + -7 ] <== NOT EXECUTED
rtems_termios_puts (echobuf, 2, tty);
20047c0: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
20047c4: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
20047c8: 7f ff ff 2b call 2004474 <rtems_termios_puts> <== NOT EXECUTED
20047cc: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
tty->column += 2;
20047d0: c2 06 60 28 ld [ %i1 + 0x28 ], %g1 <== NOT EXECUTED
20047d4: 82 00 60 02 add %g1, 2, %g1 <== NOT EXECUTED
20047d8: 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')) {
20047dc: 81 c7 e0 08 ret <== NOT EXECUTED
20047e0: 81 e8 00 00 restore <== NOT EXECUTED
0202cd08 <endgrent>:
group_fp = fopen("/etc/group", "r");
}
void endgrent(void)
{
if (group_fp != NULL)
202cd08: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
202cd0c: d0 00 61 5c ld [ %g1 + 0x15c ], %o0 ! 207495c <group_fp> <== NOT EXECUTED
202cd10: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202cd14: 02 80 00 05 be 202cd28 <endgrent+0x20> <== NOT EXECUTED
202cd18: 01 00 00 00 nop <== NOT EXECUTED
fclose(group_fp);
202cd1c: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202cd20: 40 00 76 30 call 204a5e0 <fclose> <== NOT EXECUTED
202cd24: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
202cd28: 81 c3 e0 08 retl <== NOT EXECUTED
0202cd30 <endpwent>:
passwd_fp = fopen("/etc/passwd", "r");
}
void endpwent(void)
{
if (passwd_fp != NULL)
202cd30: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
202cd34: d0 00 60 74 ld [ %g1 + 0x74 ], %o0 ! 2074874 <passwd_fp> <== NOT EXECUTED
202cd38: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202cd3c: 02 80 00 05 be 202cd50 <endpwent+0x20> <== NOT EXECUTED
202cd40: 01 00 00 00 nop <== NOT EXECUTED
fclose(passwd_fp);
202cd44: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202cd48: 40 00 76 26 call 204a5e0 <fclose> <== NOT EXECUTED
202cd4c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
202cd50: 81 c3 e0 08 retl <== NOT EXECUTED
020047e4 <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)
{
20047e4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (tty->ccount == 0)
20047e8: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
20047ec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20047f0: 02 80 00 36 be 20048c8 <erase+0xe4> <== NOT EXECUTED
20047f4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
return;
if (lineFlag) {
20047f8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20047fc: 12 80 00 35 bne 20048d0 <erase+0xec> <== NOT EXECUTED
2004800: c4 06 20 3c ld [ %i0 + 0x3c ], %g2 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
tty->column--;
}
}
else {
if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
2004804: 27 00 80 7a sethi %hi(0x201e800), %l3 <== NOT EXECUTED
2004808: 29 00 80 75 sethi %hi(0x201d400), %l4 <== NOT EXECUTED
200480c: 25 00 80 75 sethi %hi(0x201d400), %l2 <== NOT EXECUTED
2004810: a6 14 e2 2c or %l3, 0x22c, %l3 <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty);
2004814: a8 15 21 d0 or %l4, 0x1d0, %l4 <== NOT EXECUTED
/*
* Back up over the tab
*/
while (tty->column > col) {
rtems_termios_puts ("\b", 1, tty);
2004818: 10 80 00 0c b 2004848 <erase+0x64> <== NOT EXECUTED
200481c: a4 14 a1 c8 or %l2, 0x1c8, %l2 <== NOT EXECUTED
tty->column--;
}
}
else {
if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
2004820: 12 80 00 6a bne 20049c8 <erase+0x1e4> <== NOT EXECUTED
2004824: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
if (tty->column)
tty->column--;
}
}
}
if (!lineFlag)
2004828: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
200482c: 02 80 00 63 be 20049b8 <erase+0x1d4> <== NOT EXECUTED
2004830: 01 00 00 00 nop <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK)
echo ('\n', tty);
return;
}
}
while (tty->ccount) {
2004834: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
2004838: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200483c: 02 80 00 5f be 20049b8 <erase+0x1d4> <== NOT EXECUTED
2004840: 01 00 00 00 nop <== NOT EXECUTED
2004844: c4 04 20 3c ld [ %l0 + 0x3c ], %g2 <== NOT EXECUTED
unsigned char c = tty->cbuf[--tty->ccount];
2004848: c8 04 20 1c ld [ %l0 + 0x1c ], %g4 <== NOT EXECUTED
200484c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2004850: c2 24 20 20 st %g1, [ %l0 + 0x20 ] <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO) {
2004854: 80 88 a0 08 btst 8, %g2 <== NOT EXECUTED
2004858: 02 bf ff f4 be 2004828 <erase+0x44> <== NOT EXECUTED
200485c: e2 09 00 01 ldub [ %g4 + %g1 ], %l1 <== NOT EXECUTED
if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) {
2004860: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2004864: 12 80 00 05 bne 2004878 <erase+0x94> <== NOT EXECUTED
2004868: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
200486c: 80 88 a0 10 btst 0x10, %g2 <== NOT EXECUTED
2004870: 22 80 00 54 be,a 20049c0 <erase+0x1dc> <== NOT EXECUTED
2004874: f0 0c 20 43 ldub [ %l0 + 0x43 ], %i0 <== NOT EXECUTED
echo (tty->termios.c_cc[VERASE], tty);
}
else if (c == '\t') {
2004878: 80 a4 60 09 cmp %l1, 9 <== NOT EXECUTED
200487c: 02 80 00 24 be 200490c <erase+0x128> <== NOT EXECUTED
2004880: a2 04 60 01 inc %l1 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
tty->column--;
}
}
else {
if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
2004884: c2 04 c0 00 ld [ %l3 ], %g1 <== NOT EXECUTED
2004888: c2 08 40 11 ldub [ %g1 + %l1 ], %g1 <== NOT EXECUTED
200488c: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
2004890: 12 bf ff e4 bne 2004820 <erase+0x3c> <== NOT EXECUTED
2004894: 80 88 a2 00 btst 0x200, %g2 <== 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);
2004898: 11 00 80 75 sethi %hi(0x201d400), %o0 <== NOT EXECUTED
200489c: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
20048a0: 90 12 21 d0 or %o0, 0x1d0, %o0 <== NOT EXECUTED
20048a4: 7f ff fe f4 call 2004474 <rtems_termios_puts> <== NOT EXECUTED
20048a8: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
if (tty->column)
20048ac: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
20048b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20048b4: 02 bf ff de be 200482c <erase+0x48> <== NOT EXECUTED
20048b8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
tty->column--;
20048bc: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
}
}
}
if (!lineFlag)
20048c0: 12 bf ff dd bne 2004834 <erase+0x50> <== NOT EXECUTED
20048c4: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
20048c8: 81 c7 e0 08 ret <== NOT EXECUTED
20048cc: 81 e8 00 00 restore <== NOT EXECUTED
erase (struct rtems_termios_tty *tty, int lineFlag)
{
if (tty->ccount == 0)
return;
if (lineFlag) {
if (!(tty->termios.c_lflag & ECHO)) {
20048d0: 80 88 a0 08 btst 8, %g2 <== NOT EXECUTED
20048d4: 02 80 00 38 be 20049b4 <erase+0x1d0> <== NOT EXECUTED
20048d8: 80 88 a0 10 btst 0x10, %g2 <== NOT EXECUTED
tty->ccount = 0;
return;
}
if (!(tty->termios.c_lflag & ECHOE)) {
20048dc: 12 bf ff cb bne 2004808 <erase+0x24> <== NOT EXECUTED
20048e0: 27 00 80 7a sethi %hi(0x201e800), %l3 <== NOT EXECUTED
tty->ccount = 0;
echo (tty->termios.c_cc[VKILL], tty);
20048e4: 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;
20048e8: c0 26 20 20 clr [ %i0 + 0x20 ] <== NOT EXECUTED
echo (tty->termios.c_cc[VKILL], tty);
20048ec: 7f ff ff 9e call 2004764 <echo> <== NOT EXECUTED
20048f0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK)
20048f4: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
20048f8: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
20048fc: 02 bf ff f3 be 20048c8 <erase+0xe4> <== NOT EXECUTED
2004900: b2 10 00 18 mov %i0, %i1 <== NOT EXECUTED
echo ('\n', tty);
2004904: 7f ff ff 98 call 2004764 <echo> <== NOT EXECUTED
2004908: 91 e8 20 0a restore %g0, 0xa, %o0 <== NOT EXECUTED
int i = 0;
/*
* Find the character before the tab
*/
while (i != tty->ccount) {
200490c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004910: 02 80 00 17 be 200496c <erase+0x188> <== NOT EXECUTED
2004914: e2 04 20 2c ld [ %l0 + 0x2c ], %l1 <== NOT EXECUTED
c = tty->cbuf[i++];
if (c == '\t') {
col = (col | 7) + 1;
}
else if (iscntrl (c)) {
if (tty->termios.c_lflag & ECHOCTL)
2004918: 96 08 a2 00 and %g2, 0x200, %o3 <== NOT EXECUTED
while (i != tty->ccount) {
c = tty->cbuf[i++];
if (c == '\t') {
col = (col | 7) + 1;
}
else if (iscntrl (c)) {
200491c: d8 04 c0 00 ld [ %l3 ], %o4 <== NOT EXECUTED
2004920: 10 80 00 07 b 200493c <erase+0x158> <== NOT EXECUTED
2004924: 84 10 20 00 clr %g2 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOCTL)
2004928: 32 80 00 02 bne,a 2004930 <erase+0x14c> <== NOT EXECUTED
200492c: a2 04 60 02 add %l1, 2, %l1 <== NOT EXECUTED
int i = 0;
/*
* Find the character before the tab
*/
while (i != tty->ccount) {
2004930: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004934: 22 80 00 0f be,a 2004970 <erase+0x18c> <== NOT EXECUTED
2004938: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
c = tty->cbuf[i++];
200493c: c6 09 00 02 ldub [ %g4 + %g2 ], %g3 <== NOT EXECUTED
2004940: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (c == '\t') {
2004944: 80 a0 e0 09 cmp %g3, 9 <== NOT EXECUTED
2004948: 02 80 00 18 be 20049a8 <erase+0x1c4> <== NOT EXECUTED
200494c: 9a 03 00 03 add %o4, %g3, %o5 <== NOT EXECUTED
col = (col | 7) + 1;
}
else if (iscntrl (c)) {
2004950: c6 0b 60 01 ldub [ %o5 + 1 ], %g3 <== NOT EXECUTED
2004954: 80 88 e0 20 btst 0x20, %g3 <== NOT EXECUTED
2004958: 12 bf ff f4 bne 2004928 <erase+0x144> <== NOT EXECUTED
200495c: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
int i = 0;
/*
* Find the character before the tab
*/
while (i != tty->ccount) {
2004960: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004964: 12 bf ff f6 bne 200493c <erase+0x158> <== NOT EXECUTED
2004968: a2 04 60 01 inc %l1 <== NOT EXECUTED
}
/*
* Back up over the tab
*/
while (tty->column > col) {
200496c: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
2004970: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2004974: 16 bf ff ae bge 200482c <erase+0x48> <== NOT EXECUTED
2004978: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
200497c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2004980: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004984: 7f ff fe bc call 2004474 <rtems_termios_puts> <== NOT EXECUTED
2004988: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
tty->column--;
200498c: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
2004990: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
}
/*
* Back up over the tab
*/
while (tty->column > col) {
2004994: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2004998: 06 bf ff f9 bl 200497c <erase+0x198> <== NOT EXECUTED
200499c: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
if (tty->column)
tty->column--;
}
}
}
if (!lineFlag)
20049a0: 10 bf ff a3 b 200482c <erase+0x48> <== NOT EXECUTED
20049a4: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
* Find the character before the tab
*/
while (i != tty->ccount) {
c = tty->cbuf[i++];
if (c == '\t') {
col = (col | 7) + 1;
20049a8: a2 14 60 07 or %l1, 7, %l1 <== NOT EXECUTED
20049ac: 10 bf ff e1 b 2004930 <erase+0x14c> <== NOT EXECUTED
20049b0: a2 04 60 01 inc %l1 <== NOT EXECUTED
{
if (tty->ccount == 0)
return;
if (lineFlag) {
if (!(tty->termios.c_lflag & ECHO)) {
tty->ccount = 0;
20049b4: c0 26 20 20 clr [ %i0 + 0x20 ] <== NOT EXECUTED
return;
20049b8: 81 c7 e0 08 ret <== NOT EXECUTED
20049bc: 81 e8 00 00 restore <== NOT EXECUTED
while (tty->ccount) {
unsigned char c = tty->cbuf[--tty->ccount];
if (tty->termios.c_lflag & ECHO) {
if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) {
echo (tty->termios.c_cc[VERASE], tty);
20049c0: 7f ff ff 69 call 2004764 <echo> <== NOT EXECUTED
20049c4: 93 e8 00 10 restore %g0, %l0, %o1 <== NOT EXECUTED
tty->column--;
}
}
else {
if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
rtems_termios_puts ("\b \b", 3, tty);
20049c8: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
20049cc: 7f ff fe aa call 2004474 <rtems_termios_puts> <== NOT EXECUTED
20049d0: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
if (tty->column)
20049d4: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
20049d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20049dc: 22 80 00 05 be,a 20049f0 <erase+0x20c> <== NOT EXECUTED
20049e0: c2 04 c0 00 ld [ %l3 ], %g1 <== NOT EXECUTED
tty->column--;
20049e4: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
20049e8: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
}
if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) {
20049ec: c2 04 c0 00 ld [ %l3 ], %g1 <== NOT EXECUTED
20049f0: c2 08 40 11 ldub [ %g1 + %l1 ], %g1 <== NOT EXECUTED
20049f4: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
20049f8: 02 bf ff a9 be 200489c <erase+0xb8> <== NOT EXECUTED
20049fc: 11 00 80 75 sethi %hi(0x201d400), %o0 <== NOT EXECUTED
2004a00: c4 04 20 3c ld [ %l0 + 0x3c ], %g2 <== NOT EXECUTED
2004a04: 80 88 a2 00 btst 0x200, %g2 <== NOT EXECUTED
2004a08: 12 bf ff a6 bne 20048a0 <erase+0xbc> <== NOT EXECUTED
2004a0c: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
if (tty->column)
tty->column--;
}
}
}
if (!lineFlag)
2004a10: 10 bf ff 87 b 200482c <erase+0x48> <== NOT EXECUTED
2004a14: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
0202962c <fat_buf_access>:
#include "fat_fat_operations.h"
int
fat_buf_access(fat_fs_info_t *fs_info, uint32_t blk, int op_type,
rtems_bdbuf_buffer **buf)
{
202962c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
uint8_t i;
bool sec_of_fat;
if (fs_info->c.state == FAT_CACHE_EMPTY)
2029630: c2 0e 20 85 ldub [ %i0 + 0x85 ], %g1 <== NOT EXECUTED
2029634: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2029638: 02 80 00 5c be 20297a8 <fat_buf_access+0x17c> <== NOT EXECUTED
202963c: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
2029640: c2 06 20 80 ld [ %i0 + 0x80 ], %g1 <== NOT EXECUTED
fs_info->c.blk_num = blk;
fs_info->c.modified = 0;
fs_info->c.state = FAT_CACHE_ACTUAL;
}
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
2029644: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
2029648: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
202964c: 08 80 00 67 bleu 20297e8 <fat_buf_access+0x1bc> <== NOT EXECUTED
2029650: a0 10 20 00 clr %l0 <== NOT EXECUTED
(fs_info->c.blk_num < fs_info->vol.rdir_loc));
if (fs_info->c.blk_num != blk)
2029654: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2029658: 22 80 00 51 be,a 202979c <fat_buf_access+0x170> <== NOT EXECUTED
202965c: c2 06 20 88 ld [ %i0 + 0x88 ], %g1 <== NOT EXECUTED
{
if (fs_info->c.modified)
2029660: c2 0e 20 84 ldub [ %i0 + 0x84 ], %g1 <== NOT EXECUTED
2029664: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2029668: 02 80 00 3c be 2029758 <fat_buf_access+0x12c> <== NOT EXECUTED
202966c: a0 8c 20 ff andcc %l0, 0xff, %l0 <== NOT EXECUTED
{
if (sec_of_fat && !fs_info->vol.mirror)
2029670: 02 80 00 06 be 2029688 <fat_buf_access+0x5c> <== NOT EXECUTED
2029674: 01 00 00 00 nop <== NOT EXECUTED
2029678: c2 0e 20 48 ldub [ %i0 + 0x48 ], %g1 <== NOT EXECUTED
202967c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2029680: 22 80 00 63 be,a 202980c <fat_buf_access+0x1e0> <== NOT EXECUTED
2029684: c2 06 20 88 ld [ %i0 + 0x88 ], %g1 <== NOT EXECUTED
memcpy(fs_info->sec_buf, fs_info->c.buf->buffer,
fs_info->vol.bps);
sc = rtems_bdbuf_release_modified(fs_info->c.buf);
2029688: 7f ff 6d 92 call 2004cd0 <rtems_bdbuf_release_modified> <== NOT EXECUTED
202968c: d0 06 20 88 ld [ %i0 + 0x88 ], %o0 <== NOT EXECUTED
fs_info->c.state = FAT_CACHE_EMPTY;
2029690: c0 2e 20 85 clrb [ %i0 + 0x85 ] <== NOT EXECUTED
fs_info->c.modified = 0;
if (sc != RTEMS_SUCCESSFUL)
2029694: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029698: 12 80 00 67 bne 2029834 <fat_buf_access+0x208> <== NOT EXECUTED
202969c: c0 2e 20 84 clrb [ %i0 + 0x84 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
if (sec_of_fat && !fs_info->vol.mirror)
20296a0: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
20296a4: 02 80 00 33 be 2029770 <fat_buf_access+0x144> <== NOT EXECUTED
20296a8: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
20296ac: c2 0e 20 48 ldub [ %i0 + 0x48 ], %g1 <== NOT EXECUTED
20296b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20296b4: 12 80 00 2f bne 2029770 <fat_buf_access+0x144> <== NOT EXECUTED
20296b8: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
{
rtems_bdbuf_buffer *b;
for (i = 1; i < fs_info->vol.fats; i++)
20296bc: c2 0e 20 09 ldub [ %i0 + 9 ], %g1 <== NOT EXECUTED
20296c0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
20296c4: 08 80 00 2a bleu 202976c <fat_buf_access+0x140> <== NOT EXECUTED
20296c8: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
20296cc: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
20296d0: 10 80 00 10 b 2029710 <fat_buf_access+0xe4> <== NOT EXECUTED
20296d4: a2 07 bf fc add %fp, -4, %l1 <== NOT EXECUTED
fs_info->c.blk_num +
fs_info->vol.fat_length * i,
&b);
if ( sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(ENOMEM);
memcpy(b->buffer, fs_info->sec_buf, fs_info->vol.bps);
20296d8: d2 06 20 8c ld [ %i0 + 0x8c ], %o1 <== NOT EXECUTED
20296dc: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
20296e0: d4 16 00 00 lduh [ %i0 ], %o2 <== NOT EXECUTED
20296e4: 40 00 90 b3 call 204d9b0 <memcpy> <== NOT EXECUTED
20296e8: a0 04 20 01 inc %l0 <== NOT EXECUTED
sc = rtems_bdbuf_release_modified(b);
20296ec: 7f ff 6d 79 call 2004cd0 <rtems_bdbuf_release_modified> <== NOT EXECUTED
20296f0: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
if ( sc != RTEMS_SUCCESSFUL)
20296f4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20296f8: 12 80 00 12 bne 2029740 <fat_buf_access+0x114> <== NOT EXECUTED
20296fc: 90 0c 20 ff and %l0, 0xff, %o0 <== NOT EXECUTED
if (sec_of_fat && !fs_info->vol.mirror)
{
rtems_bdbuf_buffer *b;
for (i = 1; i < fs_info->vol.fats; i++)
2029700: c2 0e 20 09 ldub [ %i0 + 9 ], %g1 <== NOT EXECUTED
2029704: 80 a0 40 08 cmp %g1, %o0 <== NOT EXECUTED
2029708: 08 80 00 1a bleu 2029770 <fat_buf_access+0x144> <== NOT EXECUTED
202970c: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
{
sc = rtems_bdbuf_get(fs_info->vol.dev,
2029710: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 <== NOT EXECUTED
2029714: 7f ff 65 1e call 2002b8c <.umul> <== NOT EXECUTED
2029718: e4 1e 20 58 ldd [ %i0 + 0x58 ], %l2 <== NOT EXECUTED
202971c: d4 06 20 80 ld [ %i0 + 0x80 ], %o2 <== NOT EXECUTED
2029720: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
2029724: 94 02 00 0a add %o0, %o2, %o2 <== NOT EXECUTED
2029728: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
202972c: 7f ff 72 32 call 2005ff4 <rtems_bdbuf_get> <== NOT EXECUTED
2029730: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
fs_info->c.blk_num +
fs_info->vol.fat_length * i,
&b);
if ( sc != RTEMS_SUCCESSFUL)
2029734: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029738: 02 bf ff e8 be 20296d8 <fat_buf_access+0xac> <== NOT EXECUTED
202973c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
memcpy(b->buffer, fs_info->sec_buf, fs_info->vol.bps);
sc = rtems_bdbuf_release_modified(b);
if ( sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(ENOMEM);
2029740: 40 00 83 50 call 204a480 <__errno> <== NOT EXECUTED
2029744: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2029748: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
202974c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029750: 81 c7 e0 08 ret <== NOT EXECUTED
2029754: 81 e8 00 00 restore <== NOT EXECUTED
}
}
}
else
{
sc = rtems_bdbuf_release(fs_info->c.buf);
2029758: 7f ff 6d 81 call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
202975c: d0 06 20 88 ld [ %i0 + 0x88 ], %o0 <== NOT EXECUTED
fs_info->c.state = FAT_CACHE_EMPTY;
if (sc != RTEMS_SUCCESSFUL)
2029760: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029764: 12 80 00 34 bne 2029834 <fat_buf_access+0x208> <== NOT EXECUTED
2029768: c0 2e 20 85 clrb [ %i0 + 0x85 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
}
if (op_type == FAT_OP_TYPE_READ)
202976c: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
2029770: 02 80 00 2c be 2029820 <fat_buf_access+0x1f4> <== NOT EXECUTED
2029774: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
sc = rtems_bdbuf_read(fs_info->vol.dev, blk, &fs_info->c.buf);
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
2029778: d0 1e 20 58 ldd [ %i0 + 0x58 ], %o0 <== NOT EXECUTED
202977c: 7f ff 72 1e call 2005ff4 <rtems_bdbuf_get> <== NOT EXECUTED
2029780: 96 06 20 88 add %i0, 0x88, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2029784: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029788: 12 80 00 2b bne 2029834 <fat_buf_access+0x208> <== NOT EXECUTED
202978c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
fs_info->c.blk_num = blk;
2029790: f2 26 20 80 st %i1, [ %i0 + 0x80 ] <== NOT EXECUTED
fs_info->c.state = FAT_CACHE_ACTUAL;
2029794: c2 2e 20 85 stb %g1, [ %i0 + 0x85 ] <== NOT EXECUTED
}
*buf = fs_info->c.buf;
2029798: c2 06 20 88 ld [ %i0 + 0x88 ], %g1 <== NOT EXECUTED
202979c: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
return RC_OK;
}
20297a0: 81 c7 e0 08 ret <== NOT EXECUTED
20297a4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
bool sec_of_fat;
if (fs_info->c.state == FAT_CACHE_EMPTY)
{
if (op_type == FAT_OP_TYPE_READ)
20297a8: 02 80 00 14 be 20297f8 <fat_buf_access+0x1cc> <== NOT EXECUTED
20297ac: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
sc = rtems_bdbuf_read(fs_info->vol.dev, blk, &fs_info->c.buf);
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
20297b0: d0 1e 20 58 ldd [ %i0 + 0x58 ], %o0 <== NOT EXECUTED
20297b4: 7f ff 72 10 call 2005ff4 <rtems_bdbuf_get> <== NOT EXECUTED
20297b8: 96 06 20 88 add %i0, 0x88, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
20297bc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20297c0: 12 80 00 1d bne 2029834 <fat_buf_access+0x208> <== NOT EXECUTED
20297c4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
fs_info->c.blk_num = blk;
fs_info->c.modified = 0;
fs_info->c.state = FAT_CACHE_ACTUAL;
}
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
20297c8: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
sc = rtems_bdbuf_read(fs_info->vol.dev, blk, &fs_info->c.buf);
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
fs_info->c.blk_num = blk;
20297cc: f2 26 20 80 st %i1, [ %i0 + 0x80 ] <== NOT EXECUTED
fs_info->c.modified = 0;
fs_info->c.state = FAT_CACHE_ACTUAL;
20297d0: c2 2e 20 85 stb %g1, [ %i0 + 0x85 ] <== NOT EXECUTED
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
fs_info->c.blk_num = blk;
fs_info->c.modified = 0;
20297d4: c0 2e 20 84 clrb [ %i0 + 0x84 ] <== NOT EXECUTED
fs_info->c.state = FAT_CACHE_ACTUAL;
20297d8: 82 10 00 19 mov %i1, %g1 <== NOT EXECUTED
}
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
20297dc: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
20297e0: 18 bf ff 9d bgu 2029654 <fat_buf_access+0x28> <== NOT EXECUTED
20297e4: a0 10 20 00 clr %l0 <== NOT EXECUTED
20297e8: c4 06 20 1c ld [ %i0 + 0x1c ], %g2 <== NOT EXECUTED
20297ec: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20297f0: 10 bf ff 99 b 2029654 <fat_buf_access+0x28> <== NOT EXECUTED
20297f4: a0 40 20 00 addx %g0, 0, %l0 <== NOT EXECUTED
if (fs_info->c.state == FAT_CACHE_EMPTY)
{
if (op_type == FAT_OP_TYPE_READ)
sc = rtems_bdbuf_read(fs_info->vol.dev, blk, &fs_info->c.buf);
20297f8: d0 1e 20 58 ldd [ %i0 + 0x58 ], %o0 <== NOT EXECUTED
20297fc: 7f ff 72 33 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
2029800: 96 06 20 88 add %i0, 0x88, %o3 <== NOT EXECUTED
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
if (sc != RTEMS_SUCCESSFUL)
2029804: 10 bf ff ef b 20297c0 <fat_buf_access+0x194> <== NOT EXECUTED
2029808: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
if (fs_info->c.blk_num != blk)
{
if (fs_info->c.modified)
{
if (sec_of_fat && !fs_info->vol.mirror)
memcpy(fs_info->sec_buf, fs_info->c.buf->buffer,
202980c: d0 06 20 8c ld [ %i0 + 0x8c ], %o0 <== NOT EXECUTED
2029810: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2029814: 40 00 90 67 call 204d9b0 <memcpy> <== NOT EXECUTED
2029818: d4 16 00 00 lduh [ %i0 ], %o2 <== NOT EXECUTED
202981c: 30 bf ff 9b b,a 2029688 <fat_buf_access+0x5c> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
}
if (op_type == FAT_OP_TYPE_READ)
sc = rtems_bdbuf_read(fs_info->vol.dev, blk, &fs_info->c.buf);
2029820: d0 1e 20 58 ldd [ %i0 + 0x58 ], %o0 <== NOT EXECUTED
2029824: 7f ff 72 29 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
2029828: 96 06 20 88 add %i0, 0x88, %o3 <== NOT EXECUTED
else
sc = rtems_bdbuf_get(fs_info->vol.dev, blk, &fs_info->c.buf);
if (sc != RTEMS_SUCCESSFUL)
202982c: 10 bf ff d7 b 2029788 <fat_buf_access+0x15c> <== NOT EXECUTED
2029830: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
2029834: 40 00 83 13 call 204a480 <__errno> <== NOT EXECUTED
2029838: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202983c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2029840: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029844: 81 c7 e0 08 ret <== NOT EXECUTED
2029848: 81 e8 00 00 restore <== NOT EXECUTED
02029490 <fat_buf_release>:
return RC_OK;
}
int
fat_buf_release(fat_fs_info_t *fs_info)
{
2029490: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
uint8_t i;
bool sec_of_fat;
if (fs_info->c.state == FAT_CACHE_EMPTY)
2029494: c2 0e 20 85 ldub [ %i0 + 0x85 ], %g1 <== NOT EXECUTED
return RC_OK;
}
int
fat_buf_release(fat_fs_info_t *fs_info)
{
2029498: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
uint8_t i;
bool sec_of_fat;
if (fs_info->c.state == FAT_CACHE_EMPTY)
202949c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20294a0: 02 80 00 41 be 20295a4 <fat_buf_release+0x114> <== NOT EXECUTED
20294a4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
20294a8: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 <== NOT EXECUTED
20294ac: c4 14 20 14 lduh [ %l0 + 0x14 ], %g2 <== NOT EXECUTED
20294b0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20294b4: 1a 80 00 46 bcc 20295cc <fat_buf_release+0x13c> <== NOT EXECUTED
20294b8: a2 10 20 00 clr %l1 <== NOT EXECUTED
(fs_info->c.blk_num < fs_info->vol.rdir_loc));
if (fs_info->c.modified)
20294bc: c2 0c 20 84 ldub [ %l0 + 0x84 ], %g1 <== NOT EXECUTED
20294c0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20294c4: 02 80 00 3a be 20295ac <fat_buf_release+0x11c> <== NOT EXECUTED
20294c8: a2 8c 60 ff andcc %l1, 0xff, %l1 <== NOT EXECUTED
{
if (sec_of_fat && !fs_info->vol.mirror)
20294cc: 02 80 00 06 be 20294e4 <fat_buf_release+0x54> <== NOT EXECUTED
20294d0: 01 00 00 00 nop <== NOT EXECUTED
20294d4: c2 0c 20 48 ldub [ %l0 + 0x48 ], %g1 <== NOT EXECUTED
20294d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20294dc: 22 80 00 44 be,a 20295ec <fat_buf_release+0x15c> <== NOT EXECUTED
20294e0: c2 04 20 88 ld [ %l0 + 0x88 ], %g1 <== NOT EXECUTED
memcpy(fs_info->sec_buf, fs_info->c.buf->buffer, fs_info->vol.bps);
sc = rtems_bdbuf_release_modified(fs_info->c.buf);
20294e4: 7f ff 6d fb call 2004cd0 <rtems_bdbuf_release_modified> <== NOT EXECUTED
20294e8: d0 04 20 88 ld [ %l0 + 0x88 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
20294ec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20294f0: 12 80 00 44 bne 2029600 <fat_buf_release+0x170> <== NOT EXECUTED
20294f4: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
fs_info->c.modified = 0;
if (sec_of_fat && !fs_info->vol.mirror)
20294f8: 02 80 00 32 be 20295c0 <fat_buf_release+0x130> <== NOT EXECUTED
20294fc: c0 2c 20 84 clrb [ %l0 + 0x84 ] <== NOT EXECUTED
2029500: c2 0c 20 48 ldub [ %l0 + 0x48 ], %g1 <== NOT EXECUTED
2029504: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2029508: 32 80 00 2f bne,a 20295c4 <fat_buf_release+0x134> <== NOT EXECUTED
202950c: c0 2c 20 85 clrb [ %l0 + 0x85 ] <== NOT EXECUTED
{
rtems_bdbuf_buffer *b;
for (i = 1; i < fs_info->vol.fats; i++)
2029510: c2 0c 20 09 ldub [ %l0 + 9 ], %g1 <== NOT EXECUTED
2029514: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2029518: 08 80 00 2a bleu 20295c0 <fat_buf_release+0x130> <== NOT EXECUTED
202951c: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
2029520: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
2029524: 10 80 00 10 b 2029564 <fat_buf_release+0xd4> <== NOT EXECUTED
2029528: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
fs_info->c.blk_num +
fs_info->vol.fat_length * i,
&b);
if ( sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(ENOMEM);
memcpy(b->buffer, fs_info->sec_buf, fs_info->vol.bps);
202952c: d2 04 20 8c ld [ %l0 + 0x8c ], %o1 <== NOT EXECUTED
2029530: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
2029534: d4 14 00 00 lduh [ %l0 ], %o2 <== NOT EXECUTED
2029538: 40 00 91 1e call 204d9b0 <memcpy> <== NOT EXECUTED
202953c: a2 04 60 01 inc %l1 <== NOT EXECUTED
sc = rtems_bdbuf_release_modified(b);
2029540: 7f ff 6d e4 call 2004cd0 <rtems_bdbuf_release_modified> <== NOT EXECUTED
2029544: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
if ( sc != RTEMS_SUCCESSFUL)
2029548: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202954c: 12 80 00 12 bne 2029594 <fat_buf_release+0x104> <== NOT EXECUTED
2029550: 90 0c 60 ff and %l1, 0xff, %o0 <== NOT EXECUTED
if (sec_of_fat && !fs_info->vol.mirror)
{
rtems_bdbuf_buffer *b;
for (i = 1; i < fs_info->vol.fats; i++)
2029554: c2 0c 20 09 ldub [ %l0 + 9 ], %g1 <== NOT EXECUTED
2029558: 80 a0 40 08 cmp %g1, %o0 <== NOT EXECUTED
202955c: 28 80 00 1a bleu,a 20295c4 <fat_buf_release+0x134> <== NOT EXECUTED
2029560: c0 2c 20 85 clrb [ %l0 + 0x85 ] <== NOT EXECUTED
{
sc = rtems_bdbuf_get(fs_info->vol.dev,
2029564: d2 04 20 18 ld [ %l0 + 0x18 ], %o1 <== NOT EXECUTED
2029568: 7f ff 65 89 call 2002b8c <.umul> <== NOT EXECUTED
202956c: e8 1c 20 58 ldd [ %l0 + 0x58 ], %l4 <== NOT EXECUTED
2029570: d4 04 20 80 ld [ %l0 + 0x80 ], %o2 <== NOT EXECUTED
2029574: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
2029578: 94 02 00 0a add %o0, %o2, %o2 <== NOT EXECUTED
202957c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2029580: 7f ff 72 9d call 2005ff4 <rtems_bdbuf_get> <== NOT EXECUTED
2029584: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
fs_info->c.blk_num +
fs_info->vol.fat_length * i,
&b);
if ( sc != RTEMS_SUCCESSFUL)
2029588: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202958c: 02 bf ff e8 be 202952c <fat_buf_release+0x9c> <== NOT EXECUTED
2029590: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
memcpy(b->buffer, fs_info->sec_buf, fs_info->vol.bps);
sc = rtems_bdbuf_release_modified(b);
if ( sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(ENOMEM);
2029594: 40 00 83 bb call 204a480 <__errno> <== NOT EXECUTED
2029598: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202959c: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
20295a0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20295a4: 81 c7 e0 08 ret <== NOT EXECUTED
20295a8: 81 e8 00 00 restore <== NOT EXECUTED
}
}
}
else
{
sc = rtems_bdbuf_release(fs_info->c.buf);
20295ac: 7f ff 6d ec call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
20295b0: d0 04 20 88 ld [ %l0 + 0x88 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
20295b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20295b8: 12 80 00 12 bne 2029600 <fat_buf_release+0x170> <== NOT EXECUTED
20295bc: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
}
fs_info->c.state = FAT_CACHE_EMPTY;
20295c0: c0 2c 20 85 clrb [ %l0 + 0x85 ] <== NOT EXECUTED
return RC_OK;
}
20295c4: 81 c7 e0 08 ret <== NOT EXECUTED
20295c8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*buf = fs_info->c.buf;
return RC_OK;
}
int
fat_buf_release(fat_fs_info_t *fs_info)
20295cc: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED
20295d0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
return RC_OK;
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
(fs_info->c.blk_num < fs_info->vol.rdir_loc));
if (fs_info->c.modified)
20295d4: c2 0c 20 84 ldub [ %l0 + 0x84 ], %g1 <== NOT EXECUTED
*buf = fs_info->c.buf;
return RC_OK;
}
int
fat_buf_release(fat_fs_info_t *fs_info)
20295d8: a2 40 20 00 addx %g0, 0, %l1 <== NOT EXECUTED
return RC_OK;
sec_of_fat = ((fs_info->c.blk_num >= fs_info->vol.fat_loc) &&
(fs_info->c.blk_num < fs_info->vol.rdir_loc));
if (fs_info->c.modified)
20295dc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20295e0: 32 bf ff bb bne,a 20294cc <fat_buf_release+0x3c> <== NOT EXECUTED
20295e4: a2 8c 60 ff andcc %l1, 0xff, %l1 <== NOT EXECUTED
20295e8: 30 bf ff f1 b,a 20295ac <fat_buf_release+0x11c> <== NOT EXECUTED
{
if (sec_of_fat && !fs_info->vol.mirror)
memcpy(fs_info->sec_buf, fs_info->c.buf->buffer, fs_info->vol.bps);
20295ec: d0 04 20 8c ld [ %l0 + 0x8c ], %o0 <== NOT EXECUTED
20295f0: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
20295f4: 40 00 90 ef call 204d9b0 <memcpy> <== NOT EXECUTED
20295f8: d4 14 00 00 lduh [ %l0 ], %o2 <== NOT EXECUTED
20295fc: 30 bf ff ba b,a 20294e4 <fat_buf_release+0x54> <== NOT EXECUTED
}
else
{
sc = rtems_bdbuf_release(fs_info->c.buf);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2029600: 40 00 83 a0 call 204a480 <__errno> <== NOT EXECUTED
2029604: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2029608: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
202960c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029610: 81 c7 e0 08 ret <== NOT EXECUTED
2029614: 81 e8 00 00 restore <== NOT EXECUTED
0202a464 <fat_cluster_read>:
fat_cluster_read(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
void *buff
)
{
202a464: 98 10 00 0a mov %o2, %o4 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
202a468: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
202a46c: 12 80 00 06 bne 202a484 <fat_cluster_read+0x20> <== NOT EXECUTED
202a470: c4 02 20 34 ld [ %o0 + 0x34 ], %g2 <== NOT EXECUTED
202a474: c2 08 a0 0a ldub [ %g2 + 0xa ], %g1 <== NOT EXECUTED
202a478: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
202a47c: 32 80 00 0e bne,a 202a4b4 <fat_cluster_read+0x50> <== NOT EXECUTED
202a480: c2 08 a0 02 ldub [ %g2 + 2 ], %g1 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
202a484: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1 <== NOT EXECUTED
202a488: c6 08 a0 05 ldub [ %g2 + 5 ], %g3 <== NOT EXECUTED
202a48c: 92 02 7f fe add %o1, -2, %o1 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t fsec = 0;
fsec = fat_cluster_num_to_sector_num(mt_entry, cln);
return _fat_block_read(mt_entry, fsec, 0,
202a490: d6 08 a0 04 ldub [ %g2 + 4 ], %o3 <== NOT EXECUTED
202a494: 93 2a 40 03 sll %o1, %g3, %o1 <== NOT EXECUTED
202a498: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED
202a49c: c2 08 a0 02 ldub [ %g2 + 2 ], %g1 <== NOT EXECUTED
202a4a0: 94 10 20 00 clr %o2 <== NOT EXECUTED
202a4a4: 97 2a c0 01 sll %o3, %g1, %o3 <== NOT EXECUTED
202a4a8: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202a4ac: 7f ff fd db call 2029c18 <_fat_block_read> <== NOT EXECUTED
202a4b0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
202a4b4: d6 08 a0 04 ldub [ %g2 + 4 ], %o3 <== NOT EXECUTED
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
return fs_info->vol.rdir_loc;
202a4b8: d2 00 a0 1c ld [ %g2 + 0x1c ], %o1 <== NOT EXECUTED
202a4bc: 97 2a c0 01 sll %o3, %g1, %o3 <== NOT EXECUTED
202a4c0: 94 10 20 00 clr %o2 <== NOT EXECUTED
202a4c4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202a4c8: 7f ff fd d4 call 2029c18 <_fat_block_read> <== NOT EXECUTED
202a4cc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02029ae8 <fat_cluster_write>:
fat_cluster_write(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
const void *buff
)
{
2029ae8: 98 10 00 0a mov %o2, %o4 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2029aec: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
2029af0: 12 80 00 06 bne 2029b08 <fat_cluster_write+0x20> <== NOT EXECUTED
2029af4: c4 02 20 34 ld [ %o0 + 0x34 ], %g2 <== NOT EXECUTED
2029af8: c2 08 a0 0a ldub [ %g2 + 0xa ], %g1 <== NOT EXECUTED
2029afc: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
2029b00: 32 80 00 0e bne,a 2029b38 <fat_cluster_write+0x50> <== NOT EXECUTED
2029b04: c2 08 a0 02 ldub [ %g2 + 2 ], %g1 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2029b08: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1 <== NOT EXECUTED
2029b0c: c6 08 a0 05 ldub [ %g2 + 5 ], %g3 <== NOT EXECUTED
2029b10: 92 02 7f fe add %o1, -2, %o1 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t fsec = 0;
fsec = fat_cluster_num_to_sector_num(mt_entry, cln);
return _fat_block_write(mt_entry, fsec, 0,
2029b14: d6 08 a0 04 ldub [ %g2 + 4 ], %o3 <== NOT EXECUTED
2029b18: 93 2a 40 03 sll %o1, %g3, %o1 <== NOT EXECUTED
2029b1c: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED
2029b20: c2 08 a0 02 ldub [ %g2 + 2 ], %g1 <== NOT EXECUTED
2029b24: 94 10 20 00 clr %o2 <== NOT EXECUTED
2029b28: 97 2a c0 01 sll %o3, %g1, %o3 <== NOT EXECUTED
2029b2c: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2029b30: 7f ff ff 47 call 202984c <_fat_block_write> <== NOT EXECUTED
2029b34: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
2029b38: d6 08 a0 04 ldub [ %g2 + 4 ], %o3 <== NOT EXECUTED
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
return fs_info->vol.rdir_loc;
2029b3c: d2 00 a0 1c ld [ %g2 + 0x1c ], %o1 <== NOT EXECUTED
2029b40: 97 2a c0 01 sll %o3, %g1, %o3 <== NOT EXECUTED
2029b44: 94 10 20 00 clr %o2 <== NOT EXECUTED
2029b48: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2029b4c: 7f ff ff 40 call 202984c <_fat_block_write> <== NOT EXECUTED
2029b50: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02029908 <fat_fat32_update_fsinfo_sector>:
fat_fat32_update_fsinfo_sector(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t free_count,
uint32_t next_free
)
{
2029908: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
ssize_t ret1 = 0, ret2 = 0;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
202990c: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t le_free_count = 0;
uint32_t le_next_free = 0;
le_free_count = CT_LE_L(free_count);
2029910: 89 2e 60 18 sll %i1, 0x18, %g4 <== NOT EXECUTED
le_next_free = CT_LE_L(next_free);
ret1 = _fat_block_write(mt_entry,
2029914: d2 14 20 3c lduh [ %l0 + 0x3c ], %o1 <== NOT EXECUTED
ssize_t ret1 = 0, ret2 = 0;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t le_free_count = 0;
uint32_t le_next_free = 0;
le_free_count = CT_LE_L(free_count);
2029918: 87 36 60 10 srl %i1, 0x10, %g3 <== NOT EXECUTED
202991c: 83 36 60 18 srl %i1, 0x18, %g1 <== NOT EXECUTED
2029920: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
2029924: 82 11 00 01 or %g4, %g1, %g1 <== NOT EXECUTED
2029928: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
202992c: b3 36 60 08 srl %i1, 8, %i1 <== NOT EXECUTED
2029930: b2 0e 60 ff and %i1, 0xff, %i1 <== NOT EXECUTED
2029934: b3 2e 60 10 sll %i1, 0x10, %i1 <== NOT EXECUTED
2029938: 82 10 40 19 or %g1, %i1, %g1 <== NOT EXECUTED
202993c: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
le_next_free = CT_LE_L(next_free);
2029940: 85 36 a0 10 srl %i2, 0x10, %g2 <== NOT EXECUTED
2029944: 87 2e a0 18 sll %i2, 0x18, %g3 <== NOT EXECUTED
ssize_t ret1 = 0, ret2 = 0;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t le_free_count = 0;
uint32_t le_next_free = 0;
le_free_count = CT_LE_L(free_count);
2029948: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
le_next_free = CT_LE_L(next_free);
202994c: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
2029950: 83 36 a0 18 srl %i2, 0x18, %g1 <== NOT EXECUTED
2029954: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2029958: 82 10 c0 01 or %g3, %g1, %g1 <== NOT EXECUTED
202995c: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
2029960: b4 0e a0 ff and %i2, 0xff, %i2 <== NOT EXECUTED
2029964: b5 2e a0 10 sll %i2, 0x10, %i2 <== NOT EXECUTED
2029968: 82 10 40 1a or %g1, %i2, %g1 <== NOT EXECUTED
202996c: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
ret1 = _fat_block_write(mt_entry,
2029970: 94 10 21 e8 mov 0x1e8, %o2 <== NOT EXECUTED
register fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t le_free_count = 0;
uint32_t le_next_free = 0;
le_free_count = CT_LE_L(free_count);
le_next_free = CT_LE_L(next_free);
2029974: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
ret1 = _fat_block_write(mt_entry,
2029978: 96 10 20 04 mov 4, %o3 <== NOT EXECUTED
202997c: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
2029980: 7f ff ff b3 call 202984c <_fat_block_write> <== NOT EXECUTED
2029984: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
fs_info->vol.info_sec,
FAT_FSINFO_FREE_CLUSTER_COUNT_OFFSET,
4,
(char *)(&le_free_count));
ret2 = _fat_block_write(mt_entry,
2029988: d2 14 20 3c lduh [ %l0 + 0x3c ], %o1 <== NOT EXECUTED
uint32_t le_next_free = 0;
le_free_count = CT_LE_L(free_count);
le_next_free = CT_LE_L(next_free);
ret1 = _fat_block_write(mt_entry,
202998c: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
fs_info->vol.info_sec,
FAT_FSINFO_FREE_CLUSTER_COUNT_OFFSET,
4,
(char *)(&le_free_count));
ret2 = _fat_block_write(mt_entry,
2029990: 94 10 21 ec mov 0x1ec, %o2 <== NOT EXECUTED
2029994: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2029998: 96 10 20 04 mov 4, %o3 <== NOT EXECUTED
202999c: 7f ff ff ac call 202984c <_fat_block_write> <== NOT EXECUTED
20299a0: 98 07 bf f8 add %fp, -8, %o4 <== NOT EXECUTED
fs_info->vol.info_sec,
FAT_FSINFO_NEXT_FREE_CLUSTER_OFFSET,
4,
(char *)(&le_next_free));
if ( (ret1 < 0) || (ret2 < 0) )
20299a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20299a8: 06 80 00 06 bl 20299c0 <fat_fat32_update_fsinfo_sector+0xb8><== NOT EXECUTED
20299ac: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
20299b0: 06 80 00 04 bl 20299c0 <fat_fat32_update_fsinfo_sector+0xb8><== NOT EXECUTED
20299b4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return -1;
return RC_OK;
}
20299b8: 81 c7 e0 08 ret <== NOT EXECUTED
20299bc: 81 e8 00 00 restore <== NOT EXECUTED
20299c0: 81 c7 e0 08 ret <== NOT EXECUTED
20299c4: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
02028fd4 <fat_file_close>:
int
fat_file_close(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
2028fd4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* if links_num field of fat-file descriptor is greater than 1
* decrement the count of links and return
*/
if (fat_fd->links_num > 1)
2028fd8: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
2028fdc: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2028fe0: 08 80 00 07 bleu 2028ffc <fat_file_close+0x28> <== NOT EXECUTED
2028fe4: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
{
fat_fd->links_num--;
2028fe8: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2028fec: 90 10 20 00 clr %o0 <== NOT EXECUTED
2028ff0: c2 26 60 08 st %g1, [ %i1 + 8 ] <== NOT EXECUTED
* flush any modified "cached" buffer back to disk
*/
rc = fat_buf_release(fs_info);
return rc;
}
2028ff4: 81 c7 e0 08 ret <== NOT EXECUTED
2028ff8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return rc;
}
key = fat_construct_key(mt_entry, &fat_fd->dir_pos.sname);
if (fat_fd->flags & FAT_FILE_REMOVED)
2028ffc: c2 0e 60 30 ldub [ %i1 + 0x30 ], %g1 <== NOT EXECUTED
2029000: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2029004: 22 80 00 16 be,a 202905c <fat_file_close+0x88> <== NOT EXECUTED
2029008: d2 06 60 0c ld [ %i1 + 0xc ], %o1 <== NOT EXECUTED
{
rc = fat_file_truncate(mt_entry, fat_fd, 0);
202900c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2029010: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2029014: 7f ff fe 0b call 2028840 <fat_file_truncate> <== NOT EXECUTED
2029018: 94 10 20 00 clr %o2 <== NOT EXECUTED
if ( rc != RC_OK )
202901c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029020: 12 bf ff f5 bne 2028ff4 <fat_file_close+0x20> <== NOT EXECUTED
2029024: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
2029028: 7f ff 94 e5 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
202902c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
return rc;
_hash_delete(fs_info->rhash, key, fat_fd->ino, fat_fd);
if ( fat_ino_is_unique(mt_entry, fat_fd->ino) )
2029030: d2 06 60 0c ld [ %i1 + 0xc ], %o1 <== NOT EXECUTED
2029034: 40 00 00 d4 call 2029384 <fat_ino_is_unique> <== NOT EXECUTED
2029038: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202903c: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
2029040: 32 80 00 13 bne,a 202908c <fat_file_close+0xb8> <== NOT EXECUTED
2029044: d2 06 60 0c ld [ %i1 + 0xc ], %o1 <== NOT EXECUTED
fat_fd->links_num = 0;
}
else
{
_hash_delete(fs_info->vhash, key, fat_fd->ino, fat_fd);
free(fat_fd);
2029048: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
202904c: 7f ff 7e 24 call 20088dc <free> <== NOT EXECUTED
2029050: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
}
}
/*
* flush any modified "cached" buffer back to disk
*/
rc = fat_buf_release(fs_info);
2029054: 40 00 01 0f call 2029490 <fat_buf_release> <== NOT EXECUTED
2029058: 81 e8 00 00 restore <== NOT EXECUTED
free(fat_fd);
}
else
{
if (fat_ino_is_unique(mt_entry, fat_fd->ino))
202905c: 40 00 00 ca call 2029384 <fat_ino_is_unique> <== NOT EXECUTED
2029060: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2029064: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
2029068: 02 80 00 05 be 202907c <fat_file_close+0xa8> <== NOT EXECUTED
202906c: 01 00 00 00 nop <== NOT EXECUTED
{
fat_fd->links_num = 0;
2029070: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
}
}
/*
* flush any modified "cached" buffer back to disk
*/
rc = fat_buf_release(fs_info);
2029074: 40 00 01 07 call 2029490 <fat_buf_release> <== NOT EXECUTED
2029078: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
202907c: 7f ff 94 d0 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
2029080: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
fat_fd->links_num = 0;
}
else
{
_hash_delete(fs_info->vhash, key, fat_fd->ino, fat_fd);
free(fat_fd);
2029084: 10 bf ff f2 b 202904c <fat_file_close+0x78> <== NOT EXECUTED
2029088: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
return rc;
_hash_delete(fs_info->rhash, key, fat_fd->ino, fat_fd);
if ( fat_ino_is_unique(mt_entry, fat_fd->ino) )
fat_free_unique_ino(mt_entry, fat_fd->ino);
202908c: 40 00 00 b0 call 202934c <fat_free_unique_ino> <== NOT EXECUTED
2029090: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
fat_fd->links_num = 0;
}
else
{
_hash_delete(fs_info->vhash, key, fat_fd->ino, fat_fd);
free(fat_fd);
2029094: 10 bf ff ee b 202904c <fat_file_close+0x78> <== NOT EXECUTED
2029098: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
020285ec <fat_file_datasync>:
int
fat_file_datasync(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
20285ec: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uint32_t cur_cln = fat_fd->cln;
rtems_bdbuf_buffer *block = NULL;
uint32_t sec = 0;
uint32_t i = 0;
if (fat_fd->fat_file_size == 0)
20285f0: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
int
fat_file_datasync(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
20285f4: a8 10 00 18 mov %i0, %l4 <== NOT EXECUTED
uint32_t cur_cln = fat_fd->cln;
rtems_bdbuf_buffer *block = NULL;
uint32_t sec = 0;
uint32_t i = 0;
if (fat_fd->fat_file_size == 0)
20285f8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
fat_file_fd_t *fat_fd
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_fs_info_t *fs_info = mt_entry->fs_info;
20285fc: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
uint32_t cur_cln = fat_fd->cln;
2028600: c2 06 60 1c ld [ %i1 + 0x1c ], %g1 <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
uint32_t sec = 0;
uint32_t i = 0;
if (fat_fd->fat_file_size == 0)
2028604: 02 80 00 33 be 20286d0 <fat_file_datasync+0xe4> <== NOT EXECUTED
2028608: b0 10 20 00 clr %i0 <== NOT EXECUTED
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = fat_fd->cln;
202860c: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
2028610: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
/*
* we can use only one bdbuf :( and we also know that cache is useless
* for sync operation, so don't use it
*/
rc = fat_buf_release(fs_info);
2028614: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2028618: 40 00 03 9e call 2029490 <fat_buf_release> <== NOT EXECUTED
202861c: a4 07 bf f8 add %fp, -8, %l2 <== NOT EXECUTED
if (rc != RC_OK)
2028620: aa 92 20 00 orcc %o0, 0, %l5 <== NOT EXECUTED
2028624: 12 80 00 33 bne 20286f0 <fat_file_datasync+0x104> <== NOT EXECUTED
2028628: ac 07 bf fc add %fp, -4, %l6 <== NOT EXECUTED
return rc;
/* for each cluster of the file ... */
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
202862c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2028630: c4 04 60 0c ld [ %l1 + 0xc ], %g2 <== NOT EXECUTED
2028634: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED
2028638: 84 0a 40 02 and %o1, %g2, %g2 <== NOT EXECUTED
202863c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2028640: 1a 80 00 2c bcc 20286f0 <fat_file_datasync+0x104> <== NOT EXECUTED
2028644: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028648: 02 80 00 24 be 20286d8 <fat_file_datasync+0xec> <== NOT EXECUTED
202864c: c2 05 20 34 ld [ %l4 + 0x34 ], %g1 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028650: c4 00 60 30 ld [ %g1 + 0x30 ], %g2 <== NOT EXECUTED
2028654: c2 08 60 05 ldub [ %g1 + 5 ], %g1 <== NOT EXECUTED
2028658: a6 02 7f fe add %o1, -2, %l3 <== NOT EXECUTED
202865c: a7 2c c0 01 sll %l3, %g1, %l3 <== NOT EXECUTED
2028660: a6 04 c0 02 add %l3, %g2, %l3 <== NOT EXECUTED
{
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
/* for each sector in cluster ... */
for ( i = 0; i < fs_info->vol.spc; i++ )
2028664: c2 0c 60 04 ldub [ %l1 + 4 ], %g1 <== NOT EXECUTED
2028668: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202866c: 02 80 00 23 be 20286f8 <fat_file_datasync+0x10c> <== NOT EXECUTED
2028670: a0 10 20 00 clr %l0 <== NOT EXECUTED
{
/* ... sync it */
sc = rtems_bdbuf_read(fs_info->vol.dev, (sec + i), &block);
2028674: 10 80 00 0c b 20286a4 <fat_file_datasync+0xb8> <== NOT EXECUTED
2028678: d0 1c 60 58 ldd [ %l1 + 0x58 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one( EIO );
sc = rtems_bdbuf_sync(block);
202867c: 7f ff 74 5c call 20057ec <rtems_bdbuf_sync> <== NOT EXECUTED
2028680: d0 07 bf f8 ld [ %fp + -8 ], %o0 <== NOT EXECUTED
if ( sc != RTEMS_SUCCESSFUL )
2028684: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028688: 12 80 00 0e bne 20286c0 <fat_file_datasync+0xd4> <== NOT EXECUTED
202868c: 01 00 00 00 nop <== NOT EXECUTED
/* for each cluster of the file ... */
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
{
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
/* for each sector in cluster ... */
for ( i = 0; i < fs_info->vol.spc; i++ )
2028690: c2 0c 60 04 ldub [ %l1 + 4 ], %g1 <== NOT EXECUTED
2028694: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2028698: 08 80 00 18 bleu 20286f8 <fat_file_datasync+0x10c> <== NOT EXECUTED
202869c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
/* ... sync it */
sc = rtems_bdbuf_read(fs_info->vol.dev, (sec + i), &block);
20286a0: d0 1c 60 58 ldd [ %l1 + 0x58 ], %o0 <== NOT EXECUTED
20286a4: 94 04 00 13 add %l0, %l3, %o2 <== NOT EXECUTED
20286a8: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
20286ac: 7f ff 76 87 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
20286b0: a0 04 20 01 inc %l0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
20286b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20286b8: 02 bf ff f1 be 202867c <fat_file_datasync+0x90> <== NOT EXECUTED
20286bc: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
sc = rtems_bdbuf_sync(block);
if ( sc != RTEMS_SUCCESSFUL )
rtems_set_errno_and_return_minus_one( EIO );
20286c0: 40 00 87 70 call 204a480 <__errno> <== NOT EXECUTED
20286c4: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
20286c8: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20286cc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20286d0: 81 c7 e0 08 ret <== NOT EXECUTED
20286d4: 81 e8 00 00 restore <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
20286d8: c4 08 60 0a ldub [ %g1 + 0xa ], %g2 <== NOT EXECUTED
20286dc: 80 88 a0 03 btst 3, %g2 <== NOT EXECUTED
20286e0: 22 bf ff dd be,a 2028654 <fat_file_datasync+0x68> <== NOT EXECUTED
20286e4: c4 00 60 30 ld [ %g1 + 0x30 ], %g2 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
20286e8: 10 bf ff df b 2028664 <fat_file_datasync+0x78> <== NOT EXECUTED
20286ec: e6 00 60 1c ld [ %g1 + 0x1c ], %l3 <== NOT EXECUTED
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
if ( rc != RC_OK )
return rc;
}
return rc;
}
20286f0: 81 c7 e0 08 ret <== NOT EXECUTED
20286f4: 91 e8 00 15 restore %g0, %l5, %o0 <== NOT EXECUTED
sc = rtems_bdbuf_sync(block);
if ( sc != RTEMS_SUCCESSFUL )
rtems_set_errno_and_return_minus_one( EIO );
}
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
20286f8: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
20286fc: 40 00 72 c2 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2028700: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
2028704: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2028708: 02 bf ff ca be 2028630 <fat_file_datasync+0x44> <== NOT EXECUTED
202870c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
return rc;
}
return rc;
}
2028710: 81 c7 e0 08 ret <== NOT EXECUTED
2028714: 81 e8 00 00 restore <== NOT EXECUTED
02028948 <fat_file_extend>:
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
uint32_t new_length,
uint32_t *a_length
)
{
2028948: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
uint32_t old_last_cl;
uint32_t last_cl = 0;
uint32_t bytes_remain = 0;
uint32_t cls_added;
*a_length = new_length;
202894c: f4 26 c0 00 st %i2, [ %i3 ] <== NOT EXECUTED
if (new_length <= fat_fd->fat_file_size)
2028950: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
uint32_t *a_length
)
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t chain = 0;
2028954: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t bytes2add = 0;
uint32_t cls2add = 0;
uint32_t old_last_cl;
uint32_t last_cl = 0;
2028958: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
uint32_t new_length,
uint32_t *a_length
)
{
202895c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
uint32_t bytes_remain = 0;
uint32_t cls_added;
*a_length = new_length;
if (new_length <= fat_fd->fat_file_size)
2028960: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED
2028964: 08 80 00 3f bleu 2028a60 <fat_file_extend+0x118> <== NOT EXECUTED
2028968: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
return RC_OK;
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
202896c: c4 06 60 20 ld [ %i1 + 0x20 ], %g2 <== NOT EXECUTED
2028970: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
2028974: 22 80 00 3d be,a 2028a68 <fat_file_extend+0x120> <== NOT EXECUTED
2028978: c4 06 60 24 ld [ %i1 + 0x24 ], %g2 <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
rtems_set_errno_and_return_minus_one( ENOSPC );
bytes_remain = (fs_info->vol.bpc -
(fat_fd->fat_file_size & (fs_info->vol.bpc - 1))) &
202897c: c6 14 60 06 lduh [ %l1 + 6 ], %g3 <== NOT EXECUTED
(fs_info->vol.bpc - 1);
bytes2add = new_length - fat_fd->fat_file_size;
2028980: a8 26 80 01 sub %i2, %g1, %l4 <== NOT EXECUTED
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
rtems_set_errno_and_return_minus_one( ENOSPC );
bytes_remain = (fs_info->vol.bpc -
(fat_fd->fat_file_size & (fs_info->vol.bpc - 1))) &
2028984: 84 00 ff ff add %g3, -1, %g2 <== NOT EXECUTED
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
rtems_set_errno_and_return_minus_one( ENOSPC );
bytes_remain = (fs_info->vol.bpc -
2028988: a4 08 80 01 and %g2, %g1, %l2 <== NOT EXECUTED
202898c: a4 20 c0 12 sub %g3, %l2, %l2 <== NOT EXECUTED
2028990: a4 0c 80 02 and %l2, %g2, %l2 <== NOT EXECUTED
(fat_fd->fat_file_size & (fs_info->vol.bpc - 1))) &
(fs_info->vol.bpc - 1);
bytes2add = new_length - fat_fd->fat_file_size;
if (bytes2add > bytes_remain)
2028994: 80 a4 80 14 cmp %l2, %l4 <== NOT EXECUTED
2028998: 1a 80 00 3f bcc 2028a94 <fat_file_extend+0x14c> <== NOT EXECUTED
202899c: b0 10 20 00 clr %i0 <== NOT EXECUTED
/*
* if in last cluster allocated for the file there is enough room to
* handle extention (hence we don't need to add even one cluster to the
* file ) - return
*/
if (bytes2add == 0)
20289a0: a8 a5 00 12 subcc %l4, %l2, %l4 <== NOT EXECUTED
20289a4: 02 80 00 3c be 2028a94 <fat_file_extend+0x14c> <== NOT EXECUTED
20289a8: a6 05 3f ff add %l4, -1, %l3 <== NOT EXECUTED
return RC_OK;
cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;
20289ac: c2 0c 60 08 ldub [ %l1 + 8 ], %g1 <== NOT EXECUTED
rc = fat_scan_fat_for_free_clusters(mt_entry, &chain, cls2add,
20289b0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* file ) - return
*/
if (bytes2add == 0)
return RC_OK;
cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;
20289b4: a7 34 c0 01 srl %l3, %g1, %l3 <== NOT EXECUTED
rc = fat_scan_fat_for_free_clusters(mt_entry, &chain, cls2add,
20289b8: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
* file ) - return
*/
if (bytes2add == 0)
return RC_OK;
cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;
20289bc: a6 04 e0 01 inc %l3 <== NOT EXECUTED
rc = fat_scan_fat_for_free_clusters(mt_entry, &chain, cls2add,
20289c0: 96 07 bf f0 add %fp, -16, %o3 <== NOT EXECUTED
20289c4: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
20289c8: 40 00 72 cb call 20454f4 <fat_scan_fat_for_free_clusters> <== NOT EXECUTED
20289cc: 98 07 bf f4 add %fp, -12, %o4 <== NOT EXECUTED
&cls_added, &last_cl);
/* this means that low level I/O error occured */
if (rc != RC_OK)
20289d0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20289d4: 12 80 00 30 bne 2028a94 <fat_file_extend+0x14c> <== NOT EXECUTED
20289d8: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
return rc;
/* this means that no space left on device */
if ((cls_added == 0) && (bytes_remain == 0))
20289dc: 02 80 00 53 be 2028b28 <fat_file_extend+0x1e0> <== NOT EXECUTED
20289e0: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOSPC);
/* check wether we satisfied request for 'cls2add' clusters */
if (cls2add != cls_added)
20289e4: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
20289e8: 02 80 00 0b be 2028a14 <fat_file_extend+0xcc> <== NOT EXECUTED
20289ec: 88 38 00 01 xnor %g0, %g1, %g4 <== NOT EXECUTED
*a_length = new_length -
20289f0: c6 0c 60 08 ldub [ %l1 + 8 ], %g3 <== NOT EXECUTED
20289f4: c4 14 60 06 lduh [ %l1 + 6 ], %g2 <== NOT EXECUTED
20289f8: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
20289fc: a6 01 00 13 add %g4, %l3, %l3 <== NOT EXECUTED
2028a00: a8 0d 00 02 and %l4, %g2, %l4 <== NOT EXECUTED
2028a04: a7 2c c0 03 sll %l3, %g3, %l3 <== NOT EXECUTED
2028a08: a6 26 80 13 sub %i2, %l3, %l3 <== NOT EXECUTED
2028a0c: a8 24 c0 14 sub %l3, %l4, %l4 <== NOT EXECUTED
2028a10: e8 26 c0 00 st %l4, [ %i3 ] <== NOT EXECUTED
((cls2add - cls_added - 1) << fs_info->vol.bpc_log2) -
(bytes2add & (fs_info->vol.bpc - 1));
/* add new chain to the end of existed */
if ( fat_fd->fat_file_size == 0 )
2028a14: d6 06 60 18 ld [ %i1 + 0x18 ], %o3 <== NOT EXECUTED
2028a18: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
2028a1c: 32 80 00 20 bne,a 2028a9c <fat_file_extend+0x154> <== NOT EXECUTED
2028a20: d2 06 60 3c ld [ %i1 + 0x3c ], %o1 <== NOT EXECUTED
{
fat_fd->map.disk_cln = fat_fd->cln = chain;
2028a24: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
fat_fd->map.file_cln = 0;
2028a28: c0 26 60 34 clr [ %i1 + 0x34 ] <== NOT EXECUTED
(bytes2add & (fs_info->vol.bpc - 1));
/* add new chain to the end of existed */
if ( fat_fd->fat_file_size == 0 )
{
fat_fd->map.disk_cln = fat_fd->cln = chain;
2028a2c: c4 26 60 38 st %g2, [ %i1 + 0x38 ] <== NOT EXECUTED
2028a30: c4 26 60 1c st %g2, [ %i1 + 0x1c ] <== NOT EXECUTED
}
fat_buf_release(fs_info);
}
/* update number of the last cluster of the file if it changed */
if (cls_added != 0)
2028a34: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028a38: 22 80 00 08 be,a 2028a58 <fat_file_extend+0x110> <== NOT EXECUTED
2028a3c: f4 26 60 18 st %i2, [ %i1 + 0x18 ] <== NOT EXECUTED
{
fat_fd->map.last_cln = last_cl;
2028a40: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
if (fat_fd->fat_file_type == FAT_DIRECTORY)
2028a44: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
2028a48: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2028a4c: 02 80 00 22 be 2028ad4 <fat_file_extend+0x18c> <== NOT EXECUTED
2028a50: c4 26 60 3c st %g2, [ %i1 + 0x3c ] <== NOT EXECUTED
return rc;
}
}
}
fat_fd->fat_file_size = new_length;
2028a54: f4 26 60 18 st %i2, [ %i1 + 0x18 ] <== NOT EXECUTED
return RC_OK;
2028a58: 81 c7 e0 08 ret <== NOT EXECUTED
2028a5c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
2028a60: 81 c7 e0 08 ret <== NOT EXECUTED
2028a64: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*a_length = new_length;
if (new_length <= fat_fd->fat_file_size)
return RC_OK;
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028a68: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2028a6c: 32 bf ff c5 bne,a 2028980 <fat_file_extend+0x38> <== NOT EXECUTED
2028a70: c6 14 60 06 lduh [ %l1 + 6 ], %g3 <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
2028a74: c4 0c 60 0a ldub [ %l1 + 0xa ], %g2 <== NOT EXECUTED
2028a78: 80 88 a0 03 btst 3, %g2 <== NOT EXECUTED
2028a7c: 22 bf ff c1 be,a 2028980 <fat_file_extend+0x38> <== NOT EXECUTED
2028a80: c6 14 60 06 lduh [ %l1 + 6 ], %g3 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
/* this means that no space left on device */
if ((cls_added == 0) && (bytes_remain == 0))
rtems_set_errno_and_return_minus_one(ENOSPC);
2028a84: 40 00 86 7f call 204a480 <__errno> <== NOT EXECUTED
2028a88: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2028a8c: 82 10 20 1c mov 0x1c, %g1 <== NOT EXECUTED
2028a90: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2028a94: 81 c7 e0 08 ret <== NOT EXECUTED
2028a98: 81 e8 00 00 restore <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln = chain;
fat_fd->map.file_cln = 0;
}
else
{
if (fat_fd->map.last_cln != FAT_UNDEFINED_VALUE)
2028a9c: 80 a2 7f ff cmp %o1, -1 <== NOT EXECUTED
2028aa0: 02 80 00 18 be 2028b00 <fat_file_extend+0x1b8> <== NOT EXECUTED
2028aa4: 96 02 ff ff add %o3, -1, %o3 <== NOT EXECUTED
{
old_last_cl = fat_fd->map.last_cln;
2028aa8: d2 27 bf f8 st %o1, [ %fp + -8 ] <== NOT EXECUTED
fat_free_fat_clusters_chain(mt_entry, chain);
return rc;
}
}
rc = fat_set_fat_cluster(mt_entry, old_last_cl, chain);
2028aac: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
2028ab0: 40 00 71 10 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
2028ab4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( rc != RC_OK )
2028ab8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2028abc: 12 80 00 0d bne 2028af0 <fat_file_extend+0x1a8> <== NOT EXECUTED
2028ac0: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
fat_free_fat_clusters_chain(mt_entry, chain);
return rc;
}
fat_buf_release(fs_info);
2028ac4: 40 00 02 73 call 2029490 <fat_buf_release> <== NOT EXECUTED
2028ac8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2028acc: 10 bf ff da b 2028a34 <fat_file_extend+0xec> <== NOT EXECUTED
2028ad0: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
if (cls_added != 0)
{
fat_fd->map.last_cln = last_cl;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
{
rc = fat_init_clusters_chain(mt_entry, chain);
2028ad4: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2028ad8: 40 00 04 20 call 2029b58 <fat_init_clusters_chain> <== NOT EXECUTED
2028adc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( rc != RC_OK )
2028ae0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2028ae4: 22 bf ff dd be,a 2028a58 <fat_file_extend+0x110> <== NOT EXECUTED
2028ae8: f4 26 60 18 st %i2, [ %i1 + 0x18 ] <== NOT EXECUTED
{
fat_free_fat_clusters_chain(mt_entry, chain);
2028aec: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2028af0: 40 00 72 49 call 2045414 <fat_free_fat_clusters_chain> <== NOT EXECUTED
2028af4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
2028af8: 81 c7 e0 08 ret <== NOT EXECUTED
2028afc: 81 e8 00 00 restore <== NOT EXECUTED
{
old_last_cl = fat_fd->map.last_cln;
}
else
{
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
2028b00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028b04: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028b08: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2028b0c: 7f ff ff 18 call 202876c <fat_file_ioctl> <== NOT EXECUTED
2028b10: 98 07 bf f8 add %fp, -8, %o4 <== NOT EXECUTED
(fat_fd->fat_file_size - 1), &old_last_cl);
if ( rc != RC_OK )
2028b14: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2028b18: 12 bf ff f5 bne 2028aec <fat_file_extend+0x1a4> <== NOT EXECUTED
2028b1c: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
fat_free_fat_clusters_chain(mt_entry, chain);
return rc;
}
}
rc = fat_set_fat_cluster(mt_entry, old_last_cl, chain);
2028b20: 10 bf ff e4 b 2028ab0 <fat_file_extend+0x168> <== NOT EXECUTED
2028b24: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
/* this means that low level I/O error occured */
if (rc != RC_OK)
return rc;
/* this means that no space left on device */
if ((cls_added == 0) && (bytes_remain == 0))
2028b28: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028b2c: 12 bf ff af bne 20289e8 <fat_file_extend+0xa0> <== NOT EXECUTED
2028b30: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
2028b34: 30 bf ff d4 b,a 2028a84 <fat_file_extend+0x13c> <== NOT EXECUTED
0202876c <fat_file_ioctl>:
fat_file_ioctl(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
int cmd,
...)
{
202876c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uint32_t cl_start = 0;
uint32_t pos = 0;
uint32_t *ret;
va_list ap;
va_start(ap, cmd);
2028770: 82 07 a0 50 add %fp, 0x50, %g1 <== NOT EXECUTED
2028774: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
2028778: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
202877c: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
2028780: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
int cmd,
...)
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = 0;
2028784: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t *ret;
va_list ap;
va_start(ap, cmd);
switch (cmd)
2028788: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
202878c: 02 80 00 08 be 20287ac <fat_file_ioctl+0x40> <== NOT EXECUTED
2028790: c2 06 20 34 ld [ %i0 + 0x34 ], %g1 <== NOT EXECUTED
*ret = cur_cln;
break;
default:
errno = EINVAL;
2028794: 40 00 87 3b call 204a480 <__errno> <== NOT EXECUTED
2028798: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202879c: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20287a0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
rc = -1;
break;
}
return rc;
}
20287a4: 81 c7 e0 08 ret <== NOT EXECUTED
20287a8: 81 e8 00 00 restore <== NOT EXECUTED
case F_CLU_NUM:
pos = va_arg(ap, uint32_t );
ret = va_arg(ap, uint32_t *);
/* sanity check */
if ( pos >= fat_fd->fat_file_size )
20287ac: c4 06 60 18 ld [ %i1 + 0x18 ], %g2 <== NOT EXECUTED
switch (cmd)
{
case F_CLU_NUM:
pos = va_arg(ap, uint32_t );
ret = va_arg(ap, uint32_t *);
20287b0: 86 07 a0 58 add %fp, 0x58, %g3 <== NOT EXECUTED
/* sanity check */
if ( pos >= fat_fd->fat_file_size )
20287b4: 80 a6 c0 02 cmp %i3, %g2 <== NOT EXECUTED
20287b8: 1a 80 00 1c bcc 2028828 <fat_file_ioctl+0xbc> <== NOT EXECUTED
20287bc: c6 27 bf f8 st %g3, [ %fp + -8 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
20287c0: c4 06 60 20 ld [ %i1 + 0x20 ], %g2 <== NOT EXECUTED
20287c4: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
20287c8: 22 80 00 0e be,a 2028800 <fat_file_ioctl+0x94> <== NOT EXECUTED
20287cc: c4 06 60 24 ld [ %i1 + 0x24 ], %g2 <== NOT EXECUTED
return RC_OK;
}
cl_start = pos >> fs_info->vol.bpc_log2;
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
20287d0: d4 08 60 08 ldub [ %g1 + 8 ], %o2 <== NOT EXECUTED
20287d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20287d8: 95 36 c0 0a srl %i3, %o2, %o2 <== NOT EXECUTED
20287dc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20287e0: 7f ff ff 55 call 2028534 <fat_file_lseek> <== NOT EXECUTED
20287e4: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if ( rc != RC_OK )
20287e8: b0 92 60 00 orcc %o1, 0, %i0 <== NOT EXECUTED
20287ec: 12 bf ff ee bne 20287a4 <fat_file_ioctl+0x38> <== NOT EXECUTED
20287f0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
*ret = cur_cln;
20287f4: c2 27 00 00 st %g1, [ %i4 ] <== NOT EXECUTED
break;
20287f8: 81 c7 e0 08 ret <== NOT EXECUTED
20287fc: 81 e8 00 00 restore <== NOT EXECUTED
/* sanity check */
if ( pos >= fat_fd->fat_file_size )
rtems_set_errno_and_return_minus_one( EIO );
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028800: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2028804: 32 bf ff f4 bne,a 20287d4 <fat_file_ioctl+0x68> <== NOT EXECUTED
2028808: d4 08 60 08 ldub [ %g1 + 8 ], %o2 <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
202880c: c4 08 60 0a ldub [ %g1 + 0xa ], %g2 <== NOT EXECUTED
2028810: 80 88 a0 03 btst 3, %g2 <== NOT EXECUTED
2028814: 22 bf ff f0 be,a 20287d4 <fat_file_ioctl+0x68> <== NOT EXECUTED
2028818: d4 08 60 08 ldub [ %g1 + 8 ], %o2 <== NOT EXECUTED
{
/* cluster 0 (zero) reserved for root dir */
*ret = 0;
202881c: c0 27 00 00 clr [ %i4 ] <== NOT EXECUTED
return RC_OK;
2028820: 81 c7 e0 08 ret <== NOT EXECUTED
2028824: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
pos = va_arg(ap, uint32_t );
ret = va_arg(ap, uint32_t *);
/* sanity check */
if ( pos >= fat_fd->fat_file_size )
rtems_set_errno_and_return_minus_one( EIO );
2028828: 40 00 87 16 call 204a480 <__errno> <== NOT EXECUTED
202882c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2028830: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2028834: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2028838: 81 c7 e0 08 ret <== NOT EXECUTED
202883c: 81 e8 00 00 restore <== NOT EXECUTED
02028534 <fat_file_lseek>:
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
uint32_t file_cln,
uint32_t *disk_cln
)
{
2028534: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
if (file_cln == fat_fd->map.file_cln)
2028538: e2 06 60 34 ld [ %i1 + 0x34 ], %l1 <== NOT EXECUTED
202853c: 80 a4 40 1a cmp %l1, %i2 <== NOT EXECUTED
2028540: 22 80 00 25 be,a 20285d4 <fat_file_lseek+0xa0> <== NOT EXECUTED
2028544: c2 06 60 38 ld [ %i1 + 0x38 ], %g1 <== NOT EXECUTED
{
uint32_t cur_cln;
uint32_t count;
uint32_t i;
if (file_cln > fat_fd->map.file_cln)
2028548: 2a 80 00 18 bcs,a 20285a8 <fat_file_lseek+0x74> <== NOT EXECUTED
202854c: d2 06 60 38 ld [ %i1 + 0x38 ], %o1 <== NOT EXECUTED
cur_cln = fat_fd->map.disk_cln;
count = file_cln - fat_fd->map.file_cln;
}
else
{
cur_cln = fat_fd->cln;
2028550: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
2028554: a2 10 00 1a mov %i2, %l1 <== NOT EXECUTED
2028558: d2 27 bf fc st %o1, [ %fp + -4 ] <== NOT EXECUTED
count = file_cln;
}
/* skip over the clusters */
for (i = 0; i < count; i++)
202855c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2028560: 02 80 00 15 be 20285b4 <fat_file_lseek+0x80> <== NOT EXECUTED
2028564: a0 10 20 00 clr %l0 <== NOT EXECUTED
2028568: 10 80 00 05 b 202857c <fat_file_lseek+0x48> <== NOT EXECUTED
202856c: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
2028570: 80 a4 40 10 cmp %l1, %l0 <== NOT EXECUTED
2028574: 08 80 00 10 bleu 20285b4 <fat_file_lseek+0x80> <== NOT EXECUTED
2028578: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
202857c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2028580: 40 00 73 21 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2028584: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
2028588: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202858c: 22 bf ff f9 be,a 2028570 <fat_file_lseek+0x3c> <== NOT EXECUTED
2028590: a0 04 20 01 inc %l0 <== NOT EXECUTED
return rc;
2028594: 86 10 00 08 mov %o0, %g3 <== NOT EXECUTED
2028598: 85 3a 20 1f sra %o0, 0x1f, %g2 <== NOT EXECUTED
fat_fd->map.disk_cln = cur_cln;
*disk_cln = cur_cln;
}
return RC_OK;
}
202859c: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
20285a0: 81 c7 e0 08 ret <== NOT EXECUTED
20285a4: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
uint32_t i;
if (file_cln > fat_fd->map.file_cln)
{
cur_cln = fat_fd->map.disk_cln;
count = file_cln - fat_fd->map.file_cln;
20285a8: a2 26 80 11 sub %i2, %l1, %l1 <== NOT EXECUTED
uint32_t count;
uint32_t i;
if (file_cln > fat_fd->map.file_cln)
{
cur_cln = fat_fd->map.disk_cln;
20285ac: 10 bf ff ec b 202855c <fat_file_lseek+0x28> <== NOT EXECUTED
20285b0: d2 27 bf fc st %o1, [ %fp + -4 ] <== NOT EXECUTED
if ( rc != RC_OK )
return rc;
}
/* update cache */
fat_fd->map.file_cln = file_cln;
20285b4: f4 26 60 34 st %i2, [ %i1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = cur_cln;
20285b8: d2 26 60 38 st %o1, [ %i1 + 0x38 ] <== NOT EXECUTED
*disk_cln = cur_cln;
20285bc: 84 10 20 00 clr %g2 <== NOT EXECUTED
20285c0: 86 10 20 00 clr %g3 <== NOT EXECUTED
20285c4: d2 26 c0 00 st %o1, [ %i3 ] <== NOT EXECUTED
}
return RC_OK;
}
20285c8: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
20285cc: 81 c7 e0 08 ret <== NOT EXECUTED
20285d0: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
)
{
int rc = RC_OK;
if (file_cln == fat_fd->map.file_cln)
*disk_cln = fat_fd->map.disk_cln;
20285d4: 84 10 20 00 clr %g2 <== NOT EXECUTED
20285d8: 86 10 20 00 clr %g3 <== NOT EXECUTED
20285dc: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
fat_fd->map.disk_cln = cur_cln;
*disk_cln = cur_cln;
}
return RC_OK;
}
20285e0: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
20285e4: 81 c7 e0 08 ret <== NOT EXECUTED
20285e8: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
02028718 <fat_file_mark_removed>:
void
fat_file_mark_removed(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
2028718: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
static inline uint32_t
fat_construct_key(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_pos_t *pos)
{
return ( ((fat_cluster_num_to_sector512_num(mt_entry, pos->cln) +
202871c: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
2028720: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t cln
)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
2028724: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
(pos->ofs >> FAT_SECTOR512_BITS)) << 4) +
2028728: e2 06 60 24 ld [ %i1 + 0x24 ], %l1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
202872c: 7f ff 97 24 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
2028730: 90 10 00 19 mov %i1, %o0 <== 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 );
2028734: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED
2028738: a3 34 60 05 srl %l1, 5, %l1 <== NOT EXECUTED
202873c: a2 0c 60 01 and %l1, 1, %l1 <== NOT EXECUTED
2028740: 83 2c 60 04 sll %l1, 4, %g1 <== NOT EXECUTED
2028744: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028748: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
202874c: a2 20 40 11 sub %g1, %l1, %l1 <== NOT EXECUTED
2028750: 7f ff 97 0f call 200e38c <_Chain_Append> <== NOT EXECUTED
2028754: 90 02 00 11 add %o0, %l1, %o0 <== NOT EXECUTED
_hash_delete(fs_info->vhash, key, fat_fd->ino, fat_fd);
_hash_insert(fs_info->rhash, key, fat_fd->ino, fat_fd);
fat_fd->flags |= FAT_FILE_REMOVED;
2028758: c2 0e 60 30 ldub [ %i1 + 0x30 ], %g1 <== NOT EXECUTED
202875c: 82 10 60 01 or %g1, 1, %g1 <== NOT EXECUTED
2028760: c2 2e 60 30 stb %g1, [ %i1 + 0x30 ] <== NOT EXECUTED
}
2028764: 81 c7 e0 08 ret <== NOT EXECUTED
2028768: 81 e8 00 00 restore <== NOT EXECUTED
0202909c <fat_file_open>:
fat_file_open(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_dir_pos_t *dir_pos,
fat_file_fd_t **fat_fd
)
{
202909c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
static inline uint32_t
fat_construct_key(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_pos_t *pos)
{
return ( ((fat_cluster_num_to_sector512_num(mt_entry, pos->cln) +
20290a0: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
20290a4: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t cln
)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
20290a8: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
20290ac: 02 80 00 0c be 20290dc <fat_file_open+0x40> <== NOT EXECUTED
20290b0: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
20290b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20290b8: 32 80 00 7d bne,a 20292ac <fat_file_open+0x210> <== NOT EXECUTED
20290bc: c4 0c 20 05 ldub [ %l0 + 5 ], %g2 <== NOT EXECUTED
20290c0: c4 0c 20 0a ldub [ %l0 + 0xa ], %g2 <== NOT EXECUTED
20290c4: 80 88 a0 03 btst 3, %g2 <== NOT EXECUTED
20290c8: 22 80 00 79 be,a 20292ac <fat_file_open+0x210> <== NOT EXECUTED
20290cc: c4 0c 20 05 ldub [ %l0 + 5 ], %g2 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
20290d0: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
return 1;
return (fat_cluster_num_to_sector_num(mt_entry, cln) <<
20290d4: c2 0c 20 03 ldub [ %l0 + 3 ], %g1 <== NOT EXECUTED
20290d8: 85 28 80 01 sll %g2, %g1, %g2 <== NOT EXECUTED
(pos->ofs >> FAT_SECTOR512_BITS)) << 4) +
20290dc: c2 06 60 04 ld [ %i1 + 4 ], %g1 <== NOT EXECUTED
uint32_t key2,
fat_file_fd_t **ret
)
{
uint32_t mod = (key1) % FAT_HASH_MODULE;
rtems_chain_node *the_node = ((rtems_chain_control *)((hash) + mod))->first;
20290e0: da 04 20 68 ld [ %l0 + 0x68 ], %o5 <== NOT EXECUTED
static inline uint32_t
fat_construct_key(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_pos_t *pos)
{
return ( ((fat_cluster_num_to_sector512_num(mt_entry, pos->cln) +
20290e4: 87 30 60 05 srl %g1, 5, %g3 <== NOT EXECUTED
20290e8: a3 30 60 09 srl %g1, 9, %l1 <== NOT EXECUTED
20290ec: 86 08 e0 0f and %g3, 0xf, %g3 <== NOT EXECUTED
20290f0: a2 00 80 11 add %g2, %l1, %l1 <== NOT EXECUTED
20290f4: a3 2c 60 04 sll %l1, 4, %l1 <== NOT EXECUTED
20290f8: a2 04 40 03 add %l1, %g3, %l1 <== NOT EXECUTED
20290fc: 82 0c 60 01 and %l1, 1, %g1 <== NOT EXECUTED
2029100: a7 28 60 04 sll %g1, 4, %l3 <== NOT EXECUTED
2029104: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
2029108: a6 24 c0 01 sub %l3, %g1, %l3 <== NOT EXECUTED
202910c: c2 03 40 13 ld [ %o5 + %l3 ], %g1 <== NOT EXECUTED
2029110: 9a 03 40 13 add %o5, %l3, %o5 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2029114: 9a 03 60 04 add %o5, 4, %o5 <== NOT EXECUTED
for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )
2029118: 80 a3 40 01 cmp %o5, %g1 <== NOT EXECUTED
202911c: 22 80 00 1f be,a 2029198 <fat_file_open+0xfc> <== NOT EXECUTED
2029120: da 04 20 6c ld [ %l0 + 0x6c ], %o5 <== NOT EXECUTED
2029124: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
2029128: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
202912c: 02 80 00 0c be 202915c <fat_file_open+0xc0> <== NOT EXECUTED
2029130: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2029134: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2029138: 32 80 00 67 bne,a 20292d4 <fat_file_open+0x238> <== NOT EXECUTED
202913c: c8 0c 20 05 ldub [ %l0 + 5 ], %g4 <== NOT EXECUTED
2029140: c6 0c 20 0a ldub [ %l0 + 0xa ], %g3 <== NOT EXECUTED
2029144: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
2029148: 22 80 00 63 be,a 20292d4 <fat_file_open+0x238> <== NOT EXECUTED
202914c: c8 0c 20 05 ldub [ %l0 + 5 ], %g4 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
2029150: c8 04 20 1c ld [ %l0 + 0x1c ], %g4 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
return 1;
return (fat_cluster_num_to_sector_num(mt_entry, cln) <<
2029154: c6 0c 20 03 ldub [ %l0 + 3 ], %g3 <== NOT EXECUTED
2029158: 89 29 00 03 sll %g4, %g3, %g4 <== NOT EXECUTED
(pos->ofs >> FAT_SECTOR512_BITS)) << 4) +
202915c: c6 00 60 24 ld [ %g1 + 0x24 ], %g3 <== NOT EXECUTED
{
fat_file_fd_t *ffd = (fat_file_fd_t *)the_node;
uint32_t ck = fat_construct_key(mt_entry, &ffd->dir_pos.sname);
if ( (key1) == ck)
2029160: 85 30 e0 05 srl %g3, 5, %g2 <== NOT EXECUTED
2029164: 87 30 e0 09 srl %g3, 9, %g3 <== NOT EXECUTED
2029168: 84 08 a0 0f and %g2, 0xf, %g2 <== NOT EXECUTED
202916c: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
2029170: 89 29 20 04 sll %g4, 4, %g4 <== NOT EXECUTED
2029174: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
2029178: 80 a4 40 04 cmp %l1, %g4 <== NOT EXECUTED
202917c: 22 80 00 62 be,a 2029304 <fat_file_open+0x268> <== NOT EXECUTED
2029180: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
{
*ret = (void *)the_node;
return 0;
}
}
the_node = the_node->next;
2029184: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
)
{
uint32_t mod = (key1) % FAT_HASH_MODULE;
rtems_chain_node *the_node = ((rtems_chain_control *)((hash) + mod))->first;
for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )
2029188: 80 a3 40 01 cmp %o5, %g1 <== NOT EXECUTED
202918c: 32 bf ff e7 bne,a 2029128 <fat_file_open+0x8c> <== NOT EXECUTED
2029190: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 <== NOT EXECUTED
uint32_t key2,
fat_file_fd_t **ret
)
{
uint32_t mod = (key1) % FAT_HASH_MODULE;
rtems_chain_node *the_node = ((rtems_chain_control *)((hash) + mod))->first;
2029194: da 04 20 6c ld [ %l0 + 0x6c ], %o5 <== NOT EXECUTED
2029198: c2 03 40 13 ld [ %o5 + %l3 ], %g1 <== NOT EXECUTED
202919c: 9a 03 40 13 add %o5, %l3, %o5 <== NOT EXECUTED
20291a0: 9a 03 60 04 add %o5, 4, %o5 <== NOT EXECUTED
for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )
20291a4: 80 a0 40 0d cmp %g1, %o5 <== NOT EXECUTED
20291a8: 02 80 00 1f be 2029224 <fat_file_open+0x188> <== NOT EXECUTED
20291ac: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
static inline uint32_t
fat_construct_key(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_pos_t *pos)
{
return ( ((fat_cluster_num_to_sector512_num(mt_entry, pos->cln) +
20291b0: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
20291b4: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
20291b8: 02 80 00 0c be 20291e8 <fat_file_open+0x14c> <== NOT EXECUTED
20291bc: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
20291c0: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20291c4: 32 80 00 3f bne,a 20292c0 <fat_file_open+0x224> <== NOT EXECUTED
20291c8: c8 0c 20 05 ldub [ %l0 + 5 ], %g4 <== NOT EXECUTED
20291cc: c6 0c 20 0a ldub [ %l0 + 0xa ], %g3 <== NOT EXECUTED
20291d0: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
20291d4: 22 80 00 3b be,a 20292c0 <fat_file_open+0x224> <== NOT EXECUTED
20291d8: c8 0c 20 05 ldub [ %l0 + 5 ], %g4 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
20291dc: c8 04 20 1c ld [ %l0 + 0x1c ], %g4 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
if (cln == 1)
return 1;
return (fat_cluster_num_to_sector_num(mt_entry, cln) <<
20291e0: c6 0c 20 03 ldub [ %l0 + 3 ], %g3 <== NOT EXECUTED
20291e4: 89 29 00 03 sll %g4, %g3, %g4 <== NOT EXECUTED
(pos->ofs >> FAT_SECTOR512_BITS)) << 4) +
20291e8: c6 00 60 24 ld [ %g1 + 0x24 ], %g3 <== NOT EXECUTED
{
fat_file_fd_t *ffd = (fat_file_fd_t *)the_node;
uint32_t ck = fat_construct_key(mt_entry, &ffd->dir_pos.sname);
if ( (key1) == ck)
20291ec: 85 30 e0 05 srl %g3, 5, %g2 <== NOT EXECUTED
20291f0: 87 30 e0 09 srl %g3, 9, %g3 <== NOT EXECUTED
20291f4: 84 08 a0 0f and %g2, 0xf, %g2 <== NOT EXECUTED
20291f8: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20291fc: 89 29 20 04 sll %g4, 4, %g4 <== NOT EXECUTED
2029200: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
2029204: 80 a4 40 04 cmp %l1, %g4 <== NOT EXECUTED
2029208: 02 80 00 38 be 20292e8 <fat_file_open+0x24c> <== NOT EXECUTED
202920c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
{
*ret = (void *)the_node;
return 0;
}
}
the_node = the_node->next;
2029210: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
)
{
uint32_t mod = (key1) % FAT_HASH_MODULE;
rtems_chain_node *the_node = ((rtems_chain_control *)((hash) + mod))->first;
for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )
2029214: 80 a3 40 01 cmp %o5, %g1 <== NOT EXECUTED
2029218: 32 bf ff e7 bne,a 20291b4 <fat_file_open+0x118> <== NOT EXECUTED
202921c: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 <== NOT EXECUTED
2029220: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
}
/* access "removed-but-still-open" hash table */
rc = _hash_search(mt_entry, fs_info->rhash, key, key, &lfat_fd);
lfat_fd = (*fat_fd) = (fat_file_fd_t*)malloc(sizeof(fat_file_fd_t));
2029224: 7f ff 7f 8f call 2009060 <malloc> <== NOT EXECUTED
2029228: 90 10 20 44 mov 0x44, %o0 <== NOT EXECUTED
202922c: d0 26 80 00 st %o0, [ %i2 ] <== NOT EXECUTED
if ( lfat_fd == NULL )
2029230: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029234: 02 80 00 40 be 2029334 <fat_file_open+0x298> <== NOT EXECUTED
2029238: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
202923c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2029240: 40 00 92 6f call 204dbfc <memset> <== NOT EXECUTED
2029244: 94 10 20 44 mov 0x44, %o2 <== NOT EXECUTED
lfat_fd->links_num = 1;
lfat_fd->flags &= ~FAT_FILE_REMOVED;
2029248: c2 0c a0 30 ldub [ %l2 + 0x30 ], %g1 <== NOT EXECUTED
lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
lfat_fd->dir_pos = *dir_pos;
202924c: c4 06 60 0c ld [ %i1 + 0xc ], %g2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
lfat_fd->links_num = 1;
lfat_fd->flags &= ~FAT_FILE_REMOVED;
2029250: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED
lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
lfat_fd->dir_pos = *dir_pos;
2029254: da 06 40 00 ld [ %i1 ], %o5 <== NOT EXECUTED
2029258: c8 06 60 04 ld [ %i1 + 4 ], %g4 <== NOT EXECUTED
202925c: c6 06 60 08 ld [ %i1 + 8 ], %g3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
lfat_fd->links_num = 1;
lfat_fd->flags &= ~FAT_FILE_REMOVED;
2029260: c2 2c a0 30 stb %g1, [ %l2 + 0x30 ] <== NOT EXECUTED
if ( lfat_fd == NULL )
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
lfat_fd->links_num = 1;
2029264: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
lfat_fd->flags &= ~FAT_FILE_REMOVED;
lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
lfat_fd->dir_pos = *dir_pos;
2029268: da 24 a0 20 st %o5, [ %l2 + 0x20 ] <== NOT EXECUTED
if ( lfat_fd == NULL )
rtems_set_errno_and_return_minus_one( ENOMEM );
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
lfat_fd->links_num = 1;
202926c: c2 24 a0 08 st %g1, [ %l2 + 8 ] <== NOT EXECUTED
lfat_fd->flags &= ~FAT_FILE_REMOVED;
lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
lfat_fd->dir_pos = *dir_pos;
2029270: c8 24 a0 24 st %g4, [ %l2 + 0x24 ] <== NOT EXECUTED
memset(lfat_fd, 0, sizeof(fat_file_fd_t));
lfat_fd->links_num = 1;
lfat_fd->flags &= ~FAT_FILE_REMOVED;
lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
2029274: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
lfat_fd->dir_pos = *dir_pos;
2029278: c6 24 a0 28 st %g3, [ %l2 + 0x28 ] <== NOT EXECUTED
202927c: c4 24 a0 2c st %g2, [ %l2 + 0x2c ] <== NOT EXECUTED
if ( rc != RC_OK )
2029280: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
2029284: 02 80 00 25 be 2029318 <fat_file_open+0x27c> <== NOT EXECUTED
2029288: c2 24 a0 3c st %g1, [ %l2 + 0x3c ] <== NOT EXECUTED
lfat_fd->ino = key;
202928c: e2 24 a0 0c st %l1, [ %l2 + 0xc ] <== 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 );
2029290: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
2029294: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2029298: 90 02 00 13 add %o0, %l3, %o0 <== NOT EXECUTED
202929c: 7f ff 94 3c call 200e38c <_Chain_Append> <== NOT EXECUTED
20292a0: b0 10 20 00 clr %i0 <== NOT EXECUTED
* other fields of fat-file descriptor will be initialized on upper
* level
*/
return RC_OK;
}
20292a4: 81 c7 e0 08 ret <== NOT EXECUTED
20292a8: 81 e8 00 00 restore <== NOT EXECUTED
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
20292ac: c6 04 20 30 ld [ %l0 + 0x30 ], %g3 <== NOT EXECUTED
20292b0: 82 00 7f fe add %g1, -2, %g1 <== NOT EXECUTED
20292b4: 85 28 40 02 sll %g1, %g2, %g2 <== NOT EXECUTED
20292b8: 10 bf ff 87 b 20290d4 <fat_file_open+0x38> <== NOT EXECUTED
20292bc: 84 00 80 03 add %g2, %g3, %g2 <== NOT EXECUTED
20292c0: c6 04 20 30 ld [ %l0 + 0x30 ], %g3 <== NOT EXECUTED
20292c4: 84 00 bf fe add %g2, -2, %g2 <== NOT EXECUTED
20292c8: 89 28 80 04 sll %g2, %g4, %g4 <== NOT EXECUTED
20292cc: 10 bf ff c5 b 20291e0 <fat_file_open+0x144> <== NOT EXECUTED
20292d0: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20292d4: c6 04 20 30 ld [ %l0 + 0x30 ], %g3 <== NOT EXECUTED
20292d8: 84 00 bf fe add %g2, -2, %g2 <== NOT EXECUTED
20292dc: 89 28 80 04 sll %g2, %g4, %g4 <== NOT EXECUTED
20292e0: 10 bf ff 9d b 2029154 <fat_file_open+0xb8> <== NOT EXECUTED
20292e4: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
fat_file_fd_t *ffd = (fat_file_fd_t *)the_node;
uint32_t ck = fat_construct_key(mt_entry, &ffd->dir_pos.sname);
if ( (key1) == ck)
{
if ( ((key2) == 0) || ((key2) == ffd->ino) )
20292e8: 02 bf ff cf be 2029224 <fat_file_open+0x188> <== NOT EXECUTED
20292ec: a8 10 20 00 clr %l4 <== NOT EXECUTED
20292f0: c4 00 60 0c ld [ %g1 + 0xc ], %g2 <== NOT EXECUTED
20292f4: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED
20292f8: 32 bf ff c7 bne,a 2029214 <fat_file_open+0x178> <== NOT EXECUTED
20292fc: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
2029300: 30 bf ff c9 b,a 2029224 <fat_file_open+0x188> <== NOT EXECUTED
/* access "valid" hash table */
rc = _hash_search(mt_entry, fs_info->vhash, key, 0, &lfat_fd);
if ( rc == RC_OK )
{
/* return pointer to fat_file_descriptor allocated before */
(*fat_fd) = lfat_fd;
2029304: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
lfat_fd->links_num++;
2029308: 84 00 a0 01 inc %g2 <== NOT EXECUTED
202930c: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
return rc;
2029310: 81 c7 e0 08 ret <== NOT EXECUTED
2029314: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if ( rc != RC_OK )
lfat_fd->ino = key;
else
{
lfat_fd->ino = fat_get_unique_ino(mt_entry);
2029318: 40 00 00 20 call 2029398 <fat_get_unique_ino> <== NOT EXECUTED
202931c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ( lfat_fd->ino == 0 )
2029320: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029324: 12 bf ff db bne 2029290 <fat_file_open+0x1f4> <== NOT EXECUTED
2029328: d0 24 a0 0c st %o0, [ %l2 + 0xc ] <== NOT EXECUTED
{
free((*fat_fd));
202932c: 7f ff 7d 6c call 20088dc <free> <== NOT EXECUTED
2029330: d0 06 80 00 ld [ %i2 ], %o0 <== NOT EXECUTED
/*
* XXX: kernel resource is unsufficient, but not the memory,
* but there is no suitable errno :(
*/
rtems_set_errno_and_return_minus_one( ENOMEM );
2029334: 40 00 84 53 call 204a480 <__errno> <== NOT EXECUTED
2029338: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202933c: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
2029340: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029344: 81 c7 e0 08 ret <== NOT EXECUTED
2029348: 81 e8 00 00 restore <== NOT EXECUTED
02028da8 <fat_file_read>:
fat_file_fd_t *fat_fd,
uint32_t start,
uint32_t count,
uint8_t *buf
)
{
2028da8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
2028dac: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
uint32_t sec = 0;
uint32_t byte = 0;
uint32_t c = 0;
/* it couldn't be removed - otherwise cache update will be broken */
if (count == 0)
2028db0: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2028db4: 02 80 00 50 be 2028ef4 <fat_file_read+0x14c> <== NOT EXECUTED
2028db8: e4 06 20 34 ld [ %i0 + 0x34 ], %l2 <== NOT EXECUTED
/*
* >= because start is offset and computed from 0 and file_size
* computed from 1
*/
if ( start >= fat_fd->fat_file_size )
2028dbc: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
2028dc0: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
2028dc4: 08 80 00 4c bleu 2028ef4 <fat_file_read+0x14c> <== NOT EXECUTED
2028dc8: 80 a6 c0 01 cmp %i3, %g1 <== NOT EXECUTED
return FAT_EOF;
if ((count > fat_fd->fat_file_size) ||
2028dcc: 08 80 00 68 bleu 2028f6c <fat_file_read+0x1c4> <== NOT EXECUTED
2028dd0: 84 20 40 1b sub %g1, %i3, %g2 <== NOT EXECUTED
(start > fat_fd->fat_file_size - count))
count = fat_fd->fat_file_size - start;
2028dd4: b6 20 40 1a sub %g1, %i2, %i3 <== NOT EXECUTED
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028dd8: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
2028ddc: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2028de0: 02 80 00 47 be 2028efc <fat_file_read+0x154> <== NOT EXECUTED
2028de4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
return -1;
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
2028de8: ea 0c a0 08 ldub [ %l2 + 8 ], %l5 <== NOT EXECUTED
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
2028dec: e2 14 a0 06 lduh [ %l2 + 6 ], %l1 <== NOT EXECUTED
return -1;
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
2028df0: ab 36 80 15 srl %i2, %l5, %l5 <== NOT EXECUTED
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
2028df4: a8 07 bf fc add %fp, -4, %l4 <== NOT EXECUTED
2028df8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028dfc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028e00: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
2028e04: 7f ff fd cc call 2028534 <fat_file_lseek> <== NOT EXECUTED
2028e08: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
if (rc != RC_OK)
2028e0c: b0 92 60 00 orcc %o1, 0, %i0 <== NOT EXECUTED
2028e10: 12 80 00 66 bne 2028fa8 <fat_file_read+0x200> <== NOT EXECUTED
2028e14: a3 2c 60 10 sll %l1, 0x10, %l1 <== NOT EXECUTED
return rc;
while (count > 0)
2028e18: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
2028e1c: a3 34 60 10 srl %l1, 0x10, %l1 <== NOT EXECUTED
2028e20: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028e24: 02 80 00 63 be 2028fb0 <fat_file_read+0x208> <== NOT EXECUTED
2028e28: b4 0e 80 11 and %i2, %l1, %i2 <== NOT EXECUTED
cl_start = start >> fs_info->vol.bpc_log2;
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
2028e2c: c6 0c a0 02 ldub [ %l2 + 2 ], %g3 <== NOT EXECUTED
2028e30: d4 14 80 00 lduh [ %l2 ], %o2 <== NOT EXECUTED
2028e34: 82 10 00 1a mov %i2, %g1 <== NOT EXECUTED
2028e38: 10 80 00 20 b 2028eb8 <fat_file_read+0x110> <== NOT EXECUTED
2028e3c: a6 10 20 00 clr %l3 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028e40: da 08 a0 0a ldub [ %g2 + 0xa ], %o5 <== NOT EXECUTED
2028e44: 80 8b 60 03 btst 3, %o5 <== NOT EXECUTED
2028e48: 22 80 00 27 be,a 2028ee4 <fat_file_read+0x13c> <== NOT EXECUTED
2028e4c: da 00 a0 30 ld [ %g2 + 0x30 ], %o5 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
2028e50: d2 00 a0 1c ld [ %g2 + 0x1c ], %o1 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_read(mt_entry, sec, byte, c, buf + cmpltd);
2028e54: 87 30 40 03 srl %g1, %g3, %g3 <== NOT EXECUTED
2028e58: 98 07 00 13 add %i4, %l3, %o4 <== NOT EXECUTED
2028e5c: 92 02 40 03 add %o1, %g3, %o1 <== NOT EXECUTED
2028e60: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
2028e64: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
2028e68: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
2028e6c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028e70: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
2028e74: 40 00 03 69 call 2029c18 <_fat_block_read> <== NOT EXECUTED
2028e78: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
if ( ret < 0 )
return -1;
count -= c;
cmpltd += c;
2028e7c: a6 04 c0 11 add %l3, %l1, %l3 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_read(mt_entry, sec, byte, c, buf + cmpltd);
if ( ret < 0 )
2028e80: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
return -1;
count -= c;
cmpltd += c;
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2028e84: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_read(mt_entry, sec, byte, c, buf + cmpltd);
if ( ret < 0 )
2028e88: 06 80 00 37 bl 2028f64 <fat_file_read+0x1bc> <== NOT EXECUTED
2028e8c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
count -= c;
cmpltd += c;
save_cln = cur_cln;
2028e90: ec 07 bf fc ld [ %fp + -4 ], %l6 <== NOT EXECUTED
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2028e94: 40 00 70 dc call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2028e98: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
if ( rc != RC_OK )
2028e9c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028ea0: 12 80 00 38 bne 2028f80 <fat_file_read+0x1d8> <== NOT EXECUTED
2028ea4: b6 a6 c0 11 subcc %i3, %l1, %i3 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028ea8: 02 80 00 38 be 2028f88 <fat_file_read+0x1e0> <== NOT EXECUTED
2028eac: 82 10 20 00 clr %g1 <== NOT EXECUTED
2028eb0: c6 0c a0 02 ldub [ %l2 + 2 ], %g3 <== NOT EXECUTED
2028eb4: d4 14 80 00 lduh [ %l2 ], %o2 <== NOT EXECUTED
{
c = MIN(count, (fs_info->vol.bpc - ofs));
2028eb8: e2 14 a0 06 lduh [ %l2 + 6 ], %l1 <== NOT EXECUTED
2028ebc: a2 24 40 01 sub %l1, %g1, %l1 <== NOT EXECUTED
2028ec0: 80 a4 40 1b cmp %l1, %i3 <== NOT EXECUTED
2028ec4: 08 80 00 03 bleu 2028ed0 <fat_file_read+0x128> <== NOT EXECUTED
2028ec8: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
2028ecc: a2 10 00 1b mov %i3, %l1 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028ed0: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028ed4: 88 00 bf fe add %g2, -2, %g4 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028ed8: 02 bf ff da be 2028e40 <fat_file_read+0x98> <== NOT EXECUTED
2028edc: c4 04 20 34 ld [ %l0 + 0x34 ], %g2 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028ee0: da 00 a0 30 ld [ %g2 + 0x30 ], %o5 <== NOT EXECUTED
2028ee4: d2 08 a0 05 ldub [ %g2 + 5 ], %o1 <== NOT EXECUTED
2028ee8: 93 29 00 09 sll %g4, %o1, %o1 <== NOT EXECUTED
2028eec: 10 bf ff da b 2028e54 <fat_file_read+0xac> <== NOT EXECUTED
2028ef0: 92 02 40 0d add %o1, %o5, %o1 <== NOT EXECUTED
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
return cmpltd;
2028ef4: 81 c7 e0 08 ret <== NOT EXECUTED
2028ef8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if ((count > fat_fd->fat_file_size) ||
(start > fat_fd->fat_file_size - count))
count = fat_fd->fat_file_size - start;
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028efc: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
2028f00: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028f04: 32 bf ff ba bne,a 2028dec <fat_file_read+0x44> <== NOT EXECUTED
2028f08: ea 0c a0 08 ldub [ %l2 + 8 ], %l5 <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
2028f0c: c2 0c a0 0a ldub [ %l2 + 0xa ], %g1 <== NOT EXECUTED
2028f10: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
2028f14: 22 bf ff b6 be,a 2028dec <fat_file_read+0x44> <== NOT EXECUTED
2028f18: ea 0c a0 08 ldub [ %l2 + 8 ], %l5 <== NOT EXECUTED
{
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->cln);
2028f1c: c2 06 60 1c ld [ %i1 + 0x1c ], %g1 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028f20: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028f24: 32 80 00 27 bne,a 2028fc0 <fat_file_read+0x218> <== NOT EXECUTED
2028f28: c6 0c a0 05 ldub [ %l2 + 5 ], %g3 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
2028f2c: d2 04 a0 1c ld [ %l2 + 0x1c ], %o1 <== NOT EXECUTED
sec += (start >> fs_info->vol.sec_log2);
byte = start & (fs_info->vol.bps - 1);
ret = _fat_block_read(mt_entry, sec, byte, count, buf);
2028f30: d4 14 80 00 lduh [ %l2 ], %o2 <== NOT EXECUTED
2028f34: c2 0c a0 02 ldub [ %l2 + 2 ], %g1 <== NOT EXECUTED
2028f38: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
2028f3c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028f40: 94 0e 80 0a and %i2, %o2, %o2 <== NOT EXECUTED
2028f44: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2028f48: b5 36 80 01 srl %i2, %g1, %i2 <== NOT EXECUTED
2028f4c: 98 10 00 1c mov %i4, %o4 <== NOT EXECUTED
2028f50: 40 00 03 32 call 2029c18 <_fat_block_read> <== NOT EXECUTED
2028f54: 92 02 40 1a add %o1, %i2, %o1 <== NOT EXECUTED
if ( ret < 0 )
2028f58: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2028f5c: 16 80 00 13 bge 2028fa8 <fat_file_read+0x200> <== NOT EXECUTED
2028f60: 01 00 00 00 nop <== NOT EXECUTED
fat_fd->map.file_cln = cl_start +
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
return cmpltd;
}
2028f64: 81 c7 e0 08 ret <== NOT EXECUTED
2028f68: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
* computed from 1
*/
if ( start >= fat_fd->fat_file_size )
return FAT_EOF;
if ((count > fat_fd->fat_file_size) ||
2028f6c: 80 a6 80 02 cmp %i2, %g2 <== NOT EXECUTED
2028f70: 28 bf ff 9b bleu,a 2028ddc <fat_file_read+0x34> <== NOT EXECUTED
2028f74: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
(start > fat_fd->fat_file_size - count))
count = fat_fd->fat_file_size - start;
2028f78: 10 bf ff 98 b 2028dd8 <fat_file_read+0x30> <== NOT EXECUTED
2028f7c: b6 20 40 1a sub %g1, %i2, %i3 <== NOT EXECUTED
count -= c;
cmpltd += c;
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
if ( rc != RC_OK )
2028f80: 81 c7 e0 08 ret <== NOT EXECUTED
2028f84: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028f88: b0 10 00 13 mov %l3, %i0 <== NOT EXECUTED
ofs = 0;
}
/* update cache */
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
2028f8c: c2 0c a0 08 ldub [ %l2 + 8 ], %g1 <== NOT EXECUTED
2028f90: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
2028f94: ec 26 60 38 st %l6, [ %i1 + 0x38 ] <== NOT EXECUTED
ofs = 0;
}
/* update cache */
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
2028f98: a6 06 80 13 add %i2, %l3, %l3 <== NOT EXECUTED
2028f9c: a7 34 c0 01 srl %l3, %g1, %l3 <== NOT EXECUTED
2028fa0: aa 04 c0 15 add %l3, %l5, %l5 <== NOT EXECUTED
2028fa4: ea 26 60 34 st %l5, [ %i1 + 0x34 ] <== NOT EXECUTED
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
return cmpltd;
2028fa8: 81 c7 e0 08 ret <== NOT EXECUTED
2028fac: 81 e8 00 00 restore <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028fb0: b0 10 20 00 clr %i0 <== NOT EXECUTED
2028fb4: ac 10 20 00 clr %l6 <== NOT EXECUTED
2028fb8: 10 bf ff f5 b 2028f8c <fat_file_read+0x1e4> <== NOT EXECUTED
2028fbc: a6 10 20 00 clr %l3 <== NOT EXECUTED
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028fc0: c4 04 a0 30 ld [ %l2 + 0x30 ], %g2 <== NOT EXECUTED
2028fc4: 82 00 7f fe add %g1, -2, %g1 <== NOT EXECUTED
2028fc8: 93 28 40 03 sll %g1, %g3, %o1 <== NOT EXECUTED
2028fcc: 10 bf ff d9 b 2028f30 <fat_file_read+0x188> <== NOT EXECUTED
2028fd0: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
02028448 <fat_file_reopen>:
* RC_OK
*/
int
fat_file_reopen(fat_file_fd_t *fat_fd)
{
fat_fd->links_num++;
2028448: c4 02 20 08 ld [ %o0 + 8 ], %g2 <== NOT EXECUTED
* RETURNS:
* RC_OK
*/
int
fat_file_reopen(fat_file_fd_t *fat_fd)
{
202844c: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
fat_fd->links_num++;
2028450: 84 00 a0 01 inc %g2 <== NOT EXECUTED
return RC_OK;
}
2028454: 90 10 20 00 clr %o0 <== NOT EXECUTED
2028458: 81 c3 e0 08 retl <== NOT EXECUTED
202845c: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
02028460 <fat_file_size>:
int
fat_file_size(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
2028460: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = fat_fd->cln;
uint32_t save_cln = 0;
/* Have we requested root dir size for FAT12/16? */
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028464: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
int
fat_file_size(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
2028468: a4 10 00 18 mov %i0, %l2 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = fat_fd->cln;
uint32_t save_cln = 0;
/* Have we requested root dir size for FAT12/16? */
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
202846c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
2028470: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t cur_cln = fat_fd->cln;
uint32_t save_cln = 0;
/* Have we requested root dir size for FAT12/16? */
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028474: 02 80 00 24 be 2028504 <fat_file_size+0xa4> <== NOT EXECUTED
2028478: e2 06 60 1c ld [ %i1 + 0x1c ], %l1 <== NOT EXECUTED
{
fat_fd->fat_file_size = fs_info->vol.rdir_size;
return rc;
}
fat_fd->fat_file_size = 0;
202847c: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
2028480: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2028484: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2028488: 84 0c 40 02 and %l1, %g2, %g2 <== NOT EXECUTED
202848c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2028490: 1a 80 00 18 bcc 20284f0 <fat_file_size+0x90> <== NOT EXECUTED
2028494: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
fat_file_fd_t *fat_fd
)
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = fat_fd->cln;
2028498: 10 80 00 0d b 20284cc <fat_file_size+0x6c> <== NOT EXECUTED
202849c: e2 27 bf fc st %l1, [ %fp + -4 ] <== NOT EXECUTED
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
if ( rc != RC_OK )
return rc;
fat_fd->fat_file_size += fs_info->vol.bpc;
20284a0: c4 14 20 06 lduh [ %l0 + 6 ], %g2 <== NOT EXECUTED
return rc;
}
fat_fd->fat_file_size = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
20284a4: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
if ( rc != RC_OK )
return rc;
fat_fd->fat_file_size += fs_info->vol.bpc;
20284a8: 84 00 c0 02 add %g3, %g2, %g2 <== NOT EXECUTED
20284ac: c4 26 60 18 st %g2, [ %i1 + 0x18 ] <== NOT EXECUTED
return rc;
}
fat_fd->fat_file_size = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
20284b0: c6 04 20 0c ld [ %l0 + 0xc ], %g3 <== NOT EXECUTED
20284b4: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
20284b8: 86 08 40 03 and %g1, %g3, %g3 <== NOT EXECUTED
20284bc: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
20284c0: 1a 80 00 0e bcc 20284f8 <fat_file_size+0x98> <== NOT EXECUTED
20284c4: 90 10 20 00 clr %o0 <== NOT EXECUTED
20284c8: a2 10 00 01 mov %g1, %l1 <== NOT EXECUTED
{
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
20284cc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20284d0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20284d4: 40 00 73 4c call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
20284d8: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
20284dc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20284e0: 22 bf ff f0 be,a 20284a0 <fat_file_size+0x40> <== NOT EXECUTED
20284e4: c6 06 60 18 ld [ %i1 + 0x18 ], %g3 <== NOT EXECUTED
fat_fd->fat_file_size += fs_info->vol.bpc;
}
fat_fd->map.last_cln = save_cln;
return rc;
}
20284e8: 81 c7 e0 08 ret <== NOT EXECUTED
20284ec: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return rc;
}
fat_fd->fat_file_size = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
20284f0: a2 10 20 00 clr %l1 <== NOT EXECUTED
if ( rc != RC_OK )
return rc;
fat_fd->fat_file_size += fs_info->vol.bpc;
}
fat_fd->map.last_cln = save_cln;
20284f4: 90 10 20 00 clr %o0 <== NOT EXECUTED
20284f8: e2 26 60 3c st %l1, [ %i1 + 0x3c ] <== NOT EXECUTED
return rc;
}
20284fc: 81 c7 e0 08 ret <== NOT EXECUTED
2028500: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = fat_fd->cln;
uint32_t save_cln = 0;
/* Have we requested root dir size for FAT12/16? */
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028504: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
2028508: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202850c: 32 bf ff dd bne,a 2028480 <fat_file_size+0x20> <== NOT EXECUTED
2028510: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
2028514: c2 0c 20 0a ldub [ %l0 + 0xa ], %g1 <== NOT EXECUTED
2028518: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
202851c: 22 bf ff d9 be,a 2028480 <fat_file_size+0x20> <== NOT EXECUTED
2028520: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
{
fat_fd->fat_file_size = fs_info->vol.rdir_size;
2028524: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
2028528: 90 10 20 00 clr %o0 <== NOT EXECUTED
return rc;
202852c: 10 bf ff ef b 20284e8 <fat_file_size+0x88> <== NOT EXECUTED
2028530: c2 26 60 18 st %g1, [ %i1 + 0x18 ] <== NOT EXECUTED
02028840 <fat_file_truncate>:
fat_file_truncate(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
uint32_t new_length
)
{
2028840: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uint32_t cur_cln = 0;
uint32_t cl_start = 0;
uint32_t new_last_cln = FAT_UNDEFINED_VALUE;
if ( new_length >= fat_fd->fat_file_size )
2028844: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
2028848: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
202884c: 08 80 00 33 bleu 2028918 <fat_file_truncate+0xd8> <== NOT EXECUTED
2028850: c4 06 20 34 ld [ %i0 + 0x34 ], %g2 <== NOT EXECUTED
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = 0;
uint32_t cl_start = 0;
uint32_t new_last_cln = FAT_UNDEFINED_VALUE;
2028854: 86 10 3f ff mov -1, %g3 <== NOT EXECUTED
uint32_t new_length
)
{
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = 0;
2028858: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
if ( new_length >= fat_fd->fat_file_size )
return rc;
assert(fat_fd->fat_file_size);
202885c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028860: 02 80 00 31 be 2028924 <fat_file_truncate+0xe4> <== NOT EXECUTED
2028864: c6 27 bf f8 st %g3, [ %fp + -8 ] <== NOT EXECUTED
cl_start = (new_length + fs_info->vol.bpc - 1) >> fs_info->vol.bpc_log2;
2028868: c6 10 a0 06 lduh [ %g2 + 6 ], %g3 <== NOT EXECUTED
202886c: c4 08 a0 08 ldub [ %g2 + 8 ], %g2 <== NOT EXECUTED
2028870: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
2028874: b4 00 c0 1a add %g3, %i2, %i2 <== NOT EXECUTED
2028878: b5 36 80 02 srl %i2, %g2, %i2 <== NOT EXECUTED
if ((cl_start << fs_info->vol.bpc_log2) >= fat_fd->fat_file_size)
202887c: 85 2e 80 02 sll %i2, %g2, %g2 <== NOT EXECUTED
2028880: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2028884: 08 80 00 25 bleu 2028918 <fat_file_truncate+0xd8> <== NOT EXECUTED
2028888: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
return RC_OK;
if (cl_start != 0)
202888c: 02 80 00 09 be 20288b0 <fat_file_truncate+0x70> <== NOT EXECUTED
2028890: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
{
rc = fat_file_lseek(mt_entry, fat_fd, cl_start - 1, &new_last_cln);
2028894: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028898: 94 06 bf ff add %i2, -1, %o2 <== NOT EXECUTED
202889c: 7f ff ff 26 call 2028534 <fat_file_lseek> <== NOT EXECUTED
20288a0: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
if (rc != RC_OK)
20288a4: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
20288a8: 12 80 00 1d bne 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
20288ac: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
return rc;
}
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
20288b0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20288b4: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
20288b8: 7f ff ff 1f call 2028534 <fat_file_lseek> <== NOT EXECUTED
20288bc: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if (rc != RC_OK)
20288c0: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
20288c4: 12 80 00 16 bne 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
20288c8: 01 00 00 00 nop <== NOT EXECUTED
return rc;
rc = fat_free_fat_clusters_chain(mt_entry, cur_cln);
20288cc: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
20288d0: 40 00 72 d1 call 2045414 <fat_free_fat_clusters_chain> <== NOT EXECUTED
20288d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc != RC_OK)
20288d8: 92 92 20 00 orcc %o0, 0, %o1 <== NOT EXECUTED
20288dc: 12 80 00 10 bne 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
20288e0: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
return rc;
if (cl_start != 0)
20288e4: 02 80 00 0e be 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
20288e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
{
rc = fat_set_fat_cluster(mt_entry, new_last_cln, FAT_GENFAT_EOC);
20288ec: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
20288f0: 40 00 71 80 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
20288f4: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
20288f8: 92 92 20 00 orcc %o0, 0, %o1 <== NOT EXECUTED
20288fc: 12 80 00 08 bne 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
2028900: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
return rc;
fat_fd->map.file_cln = cl_start - 1;
2028904: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
fat_fd->map.disk_cln = new_last_cln;
fat_fd->map.last_cln = new_last_cln;
2028908: c2 26 60 3c st %g1, [ %i1 + 0x3c ] <== NOT EXECUTED
if (cl_start != 0)
{
rc = fat_set_fat_cluster(mt_entry, new_last_cln, FAT_GENFAT_EOC);
if ( rc != RC_OK )
return rc;
fat_fd->map.file_cln = cl_start - 1;
202890c: f4 26 60 34 st %i2, [ %i1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = new_last_cln;
2028910: 10 80 00 03 b 202891c <fat_file_truncate+0xdc> <== NOT EXECUTED
2028914: c2 26 60 38 st %g1, [ %i1 + 0x38 ] <== NOT EXECUTED
fat_fd->map.last_cln = new_last_cln;
2028918: 92 10 20 00 clr %o1 <== NOT EXECUTED
}
return RC_OK;
}
202891c: 81 c7 e0 08 ret <== NOT EXECUTED
2028920: 91 e8 00 09 restore %g0, %o1, %o0 <== NOT EXECUTED
if ( new_length >= fat_fd->fat_file_size )
return rc;
assert(fat_fd->fat_file_size);
2028924: 11 00 81 aa sethi %hi(0x206a800), %o0 <== NOT EXECUTED
2028928: 15 00 81 aa sethi %hi(0x206a800), %o2 <== NOT EXECUTED
202892c: 17 00 81 aa sethi %hi(0x206a800), %o3 <== NOT EXECUTED
2028930: 90 12 22 48 or %o0, 0x248, %o0 <== NOT EXECUTED
2028934: 94 12 a2 b0 or %o2, 0x2b0, %o2 <== NOT EXECUTED
2028938: 96 12 e2 98 or %o3, 0x298, %o3 <== NOT EXECUTED
202893c: 40 00 0e 85 call 202c350 <__assert_func> <== NOT EXECUTED
2028940: 92 10 22 6d mov 0x26d, %o1 <== NOT EXECUTED
02028b38 <fat_file_write>:
fat_file_fd_t *fat_fd,
uint32_t start,
uint32_t count,
const uint8_t *buf
)
{
2028b38: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uint32_t save_ofs;
uint32_t sec = 0;
uint32_t byte = 0;
uint32_t c = 0;
if ( count == 0 )
2028b3c: 90 10 20 00 clr %o0 <== NOT EXECUTED
fat_file_fd_t *fat_fd,
uint32_t start,
uint32_t count,
const uint8_t *buf
)
{
2028b40: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
uint32_t save_ofs;
uint32_t sec = 0;
uint32_t byte = 0;
uint32_t c = 0;
if ( count == 0 )
2028b44: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2028b48: 02 80 00 81 be 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028b4c: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
return cmpltd;
if ( start > fat_fd->fat_file_size )
2028b50: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
{
int rc = 0;
ssize_t ret = 0;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cmpltd = 0;
uint32_t cur_cln = 0;
2028b54: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t c = 0;
if ( count == 0 )
return cmpltd;
if ( start > fat_fd->fat_file_size )
2028b58: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
2028b5c: 0a 80 00 7e bcs 2028d54 <fat_file_write+0x21c> <== NOT EXECUTED
2028b60: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
if ((count > fat_fd->size_limit) ||
2028b64: c2 06 60 14 ld [ %i1 + 0x14 ], %g1 <== NOT EXECUTED
2028b68: 80 a6 c0 01 cmp %i3, %g1 <== NOT EXECUTED
2028b6c: 18 80 00 7a bgu 2028d54 <fat_file_write+0x21c> <== NOT EXECUTED
2028b70: 82 20 40 1b sub %g1, %i3, %g1 <== NOT EXECUTED
2028b74: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED
2028b78: 18 80 00 77 bgu 2028d54 <fat_file_write+0x21c> <== NOT EXECUTED
2028b7c: a4 06 c0 1a add %i3, %i2, %l2 <== NOT EXECUTED
(start > fat_fd->size_limit - count))
rtems_set_errno_and_return_minus_one( EIO );
rc = fat_file_extend(mt_entry, fat_fd, start + count, &c);
2028b80: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2028b84: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028b88: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2028b8c: 7f ff ff 6f call 2028948 <fat_file_extend> <== NOT EXECUTED
2028b90: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
if (rc != RC_OK)
2028b94: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028b98: 12 80 00 6d bne 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028b9c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
/*
* check whether there was enough room on device to locate
* file of 'start + count' bytes
*/
if (c != (start + count))
2028ba0: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED
2028ba4: 32 80 00 02 bne,a 2028bac <fat_file_write+0x74> <== NOT EXECUTED
2028ba8: b6 20 40 1a sub %g1, %i2, %i3 <== NOT EXECUTED
count = c - start;
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028bac: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
2028bb0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2028bb4: 22 80 00 48 be,a 2028cd4 <fat_file_write+0x19c> <== NOT EXECUTED
2028bb8: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
return -1;
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
2028bbc: e8 0c 60 08 ldub [ %l1 + 8 ], %l4 <== NOT EXECUTED
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
2028bc0: e4 14 60 06 lduh [ %l1 + 6 ], %l2 <== NOT EXECUTED
return -1;
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
2028bc4: a9 36 80 14 srl %i2, %l4, %l4 <== NOT EXECUTED
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
2028bc8: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
2028bcc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028bd0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2028bd4: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
2028bd8: 7f ff fe 57 call 2028534 <fat_file_lseek> <== NOT EXECUTED
2028bdc: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
if (rc != RC_OK)
2028be0: 90 92 60 00 orcc %o1, 0, %o0 <== NOT EXECUTED
2028be4: 12 80 00 5a bne 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028be8: a5 2c a0 10 sll %l2, 0x10, %l2 <== NOT EXECUTED
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
2028bec: a5 34 a0 10 srl %l2, 0x10, %l2 <== NOT EXECUTED
2028bf0: a4 04 bf ff add %l2, -1, %l2 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028bf4: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
return ret;
}
cl_start = start >> fs_info->vol.bpc_log2;
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
2028bf8: b4 0e 80 12 and %i2, %l2, %i2 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028bfc: ac 10 20 00 clr %l6 <== NOT EXECUTED
2028c00: 02 80 00 5c be 2028d70 <fat_file_write+0x238> <== NOT EXECUTED
2028c04: a4 10 20 00 clr %l2 <== NOT EXECUTED
cl_start = start >> fs_info->vol.bpc_log2;
save_ofs = ofs = start & (fs_info->vol.bpc - 1);
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
2028c08: c8 0c 60 02 ldub [ %l1 + 2 ], %g4 <== NOT EXECUTED
2028c0c: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
2028c10: 10 80 00 22 b 2028c98 <fat_file_write+0x160> <== NOT EXECUTED
2028c14: 84 10 00 1a mov %i2, %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028c18: d8 08 e0 0a ldub [ %g3 + 0xa ], %o4 <== NOT EXECUTED
2028c1c: 80 8b 20 03 btst 3, %o4 <== NOT EXECUTED
2028c20: 22 80 00 29 be,a 2028cc4 <fat_file_write+0x18c> <== NOT EXECUTED
2028c24: d8 00 e0 30 ld [ %g3 + 0x30 ], %o4 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
2028c28: d2 00 e0 1c ld [ %g3 + 0x1c ], %o1 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_write(mt_entry, sec, byte, c, buf + cmpltd);
2028c2c: 89 30 80 04 srl %g2, %g4, %g4 <== NOT EXECUTED
2028c30: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
2028c34: 92 02 40 04 add %o1, %g4, %o1 <== NOT EXECUTED
2028c38: 96 10 00 01 mov %g1, %o3 <== NOT EXECUTED
2028c3c: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
while (count > 0)
{
c = MIN(count, (fs_info->vol.bpc - ofs));
2028c40: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_write(mt_entry, sec, byte, c, buf + cmpltd);
2028c44: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
2028c48: 98 07 00 12 add %i4, %l2, %o4 <== NOT EXECUTED
2028c4c: 94 0a 80 02 and %o2, %g2, %o2 <== NOT EXECUTED
2028c50: 40 00 02 ff call 202984c <_fat_block_write> <== NOT EXECUTED
2028c54: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
count -= c;
cmpltd += c;
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2028c58: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, cur_cln);
sec += (ofs >> fs_info->vol.sec_log2);
byte = ofs & (fs_info->vol.bps - 1);
ret = _fat_block_write(mt_entry, sec, byte, c, buf + cmpltd);
if ( ret < 0 )
2028c5c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028c60: 06 80 00 3a bl 2028d48 <fat_file_write+0x210> <== NOT EXECUTED
2028c64: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
count -= c;
cmpltd += c;
save_cln = cur_cln;
2028c68: ec 07 bf fc ld [ %fp + -4 ], %l6 <== NOT EXECUTED
ret = _fat_block_write(mt_entry, sec, byte, c, buf + cmpltd);
if ( ret < 0 )
return -1;
count -= c;
2028c6c: ea 07 bf f8 ld [ %fp + -8 ], %l5 <== NOT EXECUTED
cmpltd += c;
save_cln = cur_cln;
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2028c70: 40 00 71 65 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2028c74: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
if ( rc != RC_OK )
2028c78: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028c7c: 12 80 00 34 bne 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028c80: b6 a6 c0 15 subcc %i3, %l5, %i3 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028c84: 02 80 00 3a be 2028d6c <fat_file_write+0x234> <== NOT EXECUTED
2028c88: a4 04 80 15 add %l2, %l5, %l2 <== NOT EXECUTED
2028c8c: c8 0c 60 02 ldub [ %l1 + 2 ], %g4 <== NOT EXECUTED
2028c90: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
2028c94: 84 10 20 00 clr %g2 <== NOT EXECUTED
{
c = MIN(count, (fs_info->vol.bpc - ofs));
2028c98: c2 14 60 06 lduh [ %l1 + 6 ], %g1 <== NOT EXECUTED
2028c9c: 82 20 40 02 sub %g1, %g2, %g1 <== NOT EXECUTED
2028ca0: 80 a0 40 1b cmp %g1, %i3 <== NOT EXECUTED
2028ca4: 08 80 00 03 bleu 2028cb0 <fat_file_write+0x178> <== NOT EXECUTED
2028ca8: c6 07 bf fc ld [ %fp + -4 ], %g3 <== NOT EXECUTED
2028cac: 82 10 00 1b mov %i3, %g1 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028cb0: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028cb4: 9a 00 ff fe add %g3, -2, %o5 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028cb8: 02 bf ff d8 be 2028c18 <fat_file_write+0xe0> <== NOT EXECUTED
2028cbc: c6 04 20 34 ld [ %l0 + 0x34 ], %g3 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028cc0: d8 00 e0 30 ld [ %g3 + 0x30 ], %o4 <== NOT EXECUTED
2028cc4: d2 08 e0 05 ldub [ %g3 + 5 ], %o1 <== NOT EXECUTED
2028cc8: 93 2b 40 09 sll %o5, %o1, %o1 <== NOT EXECUTED
2028ccc: 10 bf ff d8 b 2028c2c <fat_file_write+0xf4> <== NOT EXECUTED
2028cd0: 92 02 40 0c add %o1, %o4, %o1 <== NOT EXECUTED
* file of 'start + count' bytes
*/
if (c != (start + count))
count = c - start;
if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&
2028cd4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2028cd8: 32 bf ff ba bne,a 2028bc0 <fat_file_write+0x88> <== NOT EXECUTED
2028cdc: e8 0c 60 08 ldub [ %l1 + 8 ], %l4 <== NOT EXECUTED
(fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))
2028ce0: c2 0c 60 0a ldub [ %l1 + 0xa ], %g1 <== NOT EXECUTED
2028ce4: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
2028ce8: 22 bf ff b6 be,a 2028bc0 <fat_file_write+0x88> <== NOT EXECUTED
2028cec: e8 0c 60 08 ldub [ %l1 + 8 ], %l4 <== NOT EXECUTED
{
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->cln);
2028cf0: c4 06 60 1c ld [ %i1 + 0x1c ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
2028cf4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2028cf8: 12 80 00 26 bne 2028d90 <fat_file_write+0x258> <== NOT EXECUTED
2028cfc: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
2028d00: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
2028d04: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
2028d08: 22 80 00 23 be,a 2028d94 <fat_file_write+0x25c> <== NOT EXECUTED
2028d0c: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
2028d10: d2 00 60 1c ld [ %g1 + 0x1c ], %o1 <== NOT EXECUTED
sec += (start >> fs_info->vol.sec_log2);
byte = start & (fs_info->vol.bps - 1);
ret = _fat_block_write(mt_entry, sec, byte, count, buf);
2028d14: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
2028d18: c2 0c 60 02 ldub [ %l1 + 2 ], %g1 <== NOT EXECUTED
2028d1c: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
2028d20: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2028d24: 94 0e 80 0a and %i2, %o2, %o2 <== NOT EXECUTED
2028d28: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2028d2c: b5 36 80 01 srl %i2, %g1, %i2 <== NOT EXECUTED
2028d30: 98 10 00 1c mov %i4, %o4 <== NOT EXECUTED
2028d34: 40 00 02 c6 call 202984c <_fat_block_write> <== NOT EXECUTED
2028d38: 92 02 40 1a add %o1, %i2, %o1 <== NOT EXECUTED
if ( ret < 0 )
2028d3c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2028d40: 16 80 00 03 bge 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028d44: 01 00 00 00 nop <== NOT EXECUTED
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
return cmpltd;
2028d48: 90 10 3f ff mov -1, %o0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
}
2028d4c: 81 c7 e0 08 ret <== NOT EXECUTED
2028d50: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
if ( start > fat_fd->fat_file_size )
rtems_set_errno_and_return_minus_one( EIO );
if ((count > fat_fd->size_limit) ||
(start > fat_fd->size_limit - count))
rtems_set_errno_and_return_minus_one( EIO );
2028d54: 40 00 85 cb call 204a480 <__errno> <== NOT EXECUTED
2028d58: 01 00 00 00 nop <== NOT EXECUTED
2028d5c: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
2028d60: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2028d64: 10 bf ff fa b 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028d68: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
rc = fat_file_lseek(mt_entry, fat_fd, cl_start, &cur_cln);
if (rc != RC_OK)
return rc;
while (count > 0)
2028d6c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
ofs = 0;
}
/* update cache */
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
2028d70: c2 0c 60 08 ldub [ %l1 + 8 ], %g1 <== NOT EXECUTED
2028d74: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
2028d78: ec 26 60 38 st %l6, [ %i1 + 0x38 ] <== NOT EXECUTED
ofs = 0;
}
/* update cache */
/* XXX: check this - I'm not sure :( */
fat_fd->map.file_cln = cl_start +
2028d7c: a4 06 80 12 add %i2, %l2, %l2 <== NOT EXECUTED
2028d80: a5 34 80 01 srl %l2, %g1, %l2 <== NOT EXECUTED
2028d84: a8 04 80 14 add %l2, %l4, %l4 <== NOT EXECUTED
((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
fat_fd->map.disk_cln = save_cln;
return cmpltd;
2028d88: 10 bf ff f1 b 2028d4c <fat_file_write+0x214> <== NOT EXECUTED
2028d8c: e8 26 60 34 st %l4, [ %i1 + 0x34 ] <== NOT EXECUTED
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
2028d90: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 <== NOT EXECUTED
2028d94: c2 08 60 05 ldub [ %g1 + 5 ], %g1 <== NOT EXECUTED
2028d98: 84 00 bf fe add %g2, -2, %g2 <== NOT EXECUTED
2028d9c: 93 28 80 01 sll %g2, %g1, %o1 <== NOT EXECUTED
2028da0: 10 bf ff dd b 2028d14 <fat_file_write+0x1dc> <== NOT EXECUTED
2028da4: 92 02 40 03 add %o1, %g3, %o1 <== NOT EXECUTED
02045414 <fat_free_fat_clusters_chain>:
int
fat_free_fat_clusters_chain(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t chain
)
{
2045414: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK, rc1 = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
2045418: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t cur_cln = chain;
uint32_t next_cln = 0;
204541c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t freed_cls_cnt = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
2045420: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2045424: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2045428: 84 0e 40 02 and %i1, %g2, %g2 <== NOT EXECUTED
int
fat_free_fat_clusters_chain(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t chain
)
{
204542c: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = chain;
uint32_t next_cln = 0;
uint32_t freed_cls_cnt = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
2045430: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2045434: a6 10 20 00 clr %l3 <== NOT EXECUTED
2045438: 08 80 00 24 bleu 20454c8 <fat_free_fat_clusters_chain+0xb4><== NOT EXECUTED
204543c: aa 10 20 00 clr %l5 <== NOT EXECUTED
2045440: a4 10 00 19 mov %i1, %l2 <== NOT EXECUTED
2045444: 10 80 00 0e b 204547c <fat_free_fat_clusters_chain+0x68> <== NOT EXECUTED
2045448: a8 07 bf fc add %fp, -4, %l4 <== NOT EXECUTED
fat_buf_release(fs_info);
return rc;
}
rc = fat_set_fat_cluster(mt_entry, cur_cln, FAT_GENFAT_FREE);
204544c: 7f ff fe a9 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
2045450: 01 00 00 00 nop <== NOT EXECUTED
if ( rc != RC_OK )
2045454: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2045458: 02 80 00 03 be 2045464 <fat_free_fat_clusters_chain+0x50> <== NOT EXECUTED
204545c: e4 07 bf fc ld [ %fp + -4 ], %l2 <== NOT EXECUTED
2045460: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cur_cln = chain;
uint32_t next_cln = 0;
uint32_t freed_cls_cnt = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
2045464: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2045468: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
204546c: 84 0c 80 02 and %l2, %g2, %g2 <== NOT EXECUTED
2045470: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2045474: 1a 80 00 15 bcc 20454c8 <fat_free_fat_clusters_chain+0xb4><== NOT EXECUTED
2045478: a6 04 e0 01 inc %l3 <== NOT EXECUTED
{
rc = fat_get_fat_cluster(mt_entry, cur_cln, &next_cln);
204547c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2045480: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
2045484: 7f ff ff 60 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2045488: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
fat_buf_release(fs_info);
return rc;
}
rc = fat_set_fat_cluster(mt_entry, cur_cln, FAT_GENFAT_FREE);
204548c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
uint32_t next_cln = 0;
uint32_t freed_cls_cnt = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
{
rc = fat_get_fat_cluster(mt_entry, cur_cln, &next_cln);
2045490: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
fat_buf_release(fs_info);
return rc;
}
rc = fat_set_fat_cluster(mt_entry, cur_cln, FAT_GENFAT_FREE);
2045494: 94 10 20 00 clr %o2 <== NOT EXECUTED
uint32_t freed_cls_cnt = 0;
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
{
rc = fat_get_fat_cluster(mt_entry, cur_cln, &next_cln);
if ( rc != RC_OK )
2045498: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
204549c: 02 bf ff ec be 204544c <fat_free_fat_clusters_chain+0x38> <== NOT EXECUTED
20454a0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
{
if(fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)
20454a4: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED
20454a8: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
20454ac: 02 80 00 03 be 20454b8 <fat_free_fat_clusters_chain+0xa4> <== NOT EXECUTED
20454b0: 82 04 c0 01 add %l3, %g1, %g1 <== NOT EXECUTED
fs_info->vol.free_cls += freed_cls_cnt;
20454b4: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
fat_buf_release(fs_info);
20454b8: 7f ff 8f f6 call 2029490 <fat_buf_release> <== NOT EXECUTED
20454bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
20454c0: 81 c7 e0 08 ret <== NOT EXECUTED
20454c4: 81 e8 00 00 restore <== NOT EXECUTED
freed_cls_cnt++;
cur_cln = next_cln;
}
fs_info->vol.next_cl = chain;
if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)
20454c8: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED
20454cc: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
20454d0: 02 80 00 04 be 20454e0 <fat_free_fat_clusters_chain+0xcc> <== NOT EXECUTED
20454d4: f2 24 20 44 st %i1, [ %l0 + 0x44 ] <== NOT EXECUTED
fs_info->vol.free_cls += freed_cls_cnt;
20454d8: 82 04 c0 01 add %l3, %g1, %g1 <== NOT EXECUTED
20454dc: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
fat_buf_release(fs_info);
20454e0: b0 10 00 15 mov %l5, %i0 <== NOT EXECUTED
20454e4: 7f ff 8f eb call 2029490 <fat_buf_release> <== NOT EXECUTED
20454e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc1 != RC_OK)
return rc1;
return RC_OK;
}
20454ec: 81 c7 e0 08 ret <== NOT EXECUTED
20454f0: 81 e8 00 00 restore <== NOT EXECUTED
0202934c <fat_free_unique_ino>:
void
fat_free_unique_ino(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t ino
)
{
202934c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
2029350: c4 06 20 34 ld [ %i0 + 0x34 ], %g2 <== NOT EXECUTED
FAT_SET_UNIQ_INO_FREE((ino - fs_info->uino_base), fs_info->uino);
2029354: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
2029358: c2 00 a0 70 ld [ %g2 + 0x70 ], %g1 <== NOT EXECUTED
202935c: c4 00 a0 7c ld [ %g2 + 0x7c ], %g2 <== NOT EXECUTED
2029360: 84 26 40 02 sub %i1, %g2, %g2 <== NOT EXECUTED
2029364: 87 30 a0 03 srl %g2, 3, %g3 <== NOT EXECUTED
2029368: c8 08 40 03 ldub [ %g1 + %g3 ], %g4 <== NOT EXECUTED
202936c: 84 08 a0 07 and %g2, 7, %g2 <== NOT EXECUTED
2029370: 85 2b 40 02 sll %o5, %g2, %g2 <== NOT EXECUTED
2029374: 84 29 00 02 andn %g4, %g2, %g2 <== NOT EXECUTED
2029378: c4 28 40 03 stb %g2, [ %g1 + %g3 ] <== NOT EXECUTED
}
202937c: 81 c7 e0 08 ret <== NOT EXECUTED
2029380: 81 e8 00 00 restore <== NOT EXECUTED
02045204 <fat_get_fat_cluster>:
fat_get_fat_cluster(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
uint32_t *ret_val
)
{
2045204: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
rtems_bdbuf_buffer *block0 = NULL;
2045208: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t sec = 0;
uint32_t ofs = 0;
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
204520c: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
2045210: 08 80 00 6c bleu 20453c0 <fat_get_fat_cluster+0x1bc> <== NOT EXECUTED
2045214: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
2045218: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
204521c: 82 00 60 01 inc %g1 <== NOT EXECUTED
2045220: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2045224: 18 80 00 67 bgu 20453c0 <fat_get_fat_cluster+0x1bc> <== NOT EXECUTED
2045228: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
204522c: c2 0c 20 0a ldub [ %l0 + 0xa ], %g1 <== NOT EXECUTED
2045230: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2045234: 12 80 00 24 bne 20452c4 <fat_get_fat_cluster+0xc0> <== NOT EXECUTED
2045238: e6 0c 20 02 ldub [ %l0 + 2 ], %l3 <== NOT EXECUTED
204523c: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2045240: 02 80 00 27 be 20452dc <fat_get_fat_cluster+0xd8> <== NOT EXECUTED
2045244: 01 00 00 00 nop <== NOT EXECUTED
2045248: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
204524c: a3 2e 60 01 sll %i1, 1, %l1 <== NOT EXECUTED
2045250: a7 34 40 13 srl %l1, %l3, %l3 <== NOT EXECUTED
2045254: a6 04 c0 01 add %l3, %g1, %l3 <== NOT EXECUTED
fs_info->vol.afat_loc;
ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
2045258: e8 14 00 00 lduh [ %l0 ], %l4 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &block0);
204525c: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
2045260: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2045264: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2045268: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
204526c: 7f ff 90 f0 call 202962c <fat_buf_access> <== NOT EXECUTED
2045270: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
if (rc != RC_OK)
2045274: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2045278: 12 80 00 11 bne 20452bc <fat_get_fat_cluster+0xb8> <== NOT EXECUTED
204527c: a9 2d 20 10 sll %l4, 0x10, %l4 <== NOT EXECUTED
return rc;
switch ( fs_info->vol.type )
2045280: c2 0c 20 0a ldub [ %l0 + 0xa ], %g1 <== NOT EXECUTED
2045284: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
fs_info->vol.afat_loc;
ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
2045288: a9 35 20 10 srl %l4, 0x10, %l4 <== NOT EXECUTED
204528c: a8 05 3f ff add %l4, -1, %l4 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &block0);
if (rc != RC_OK)
return rc;
switch ( fs_info->vol.type )
2045290: 02 80 00 18 be 20452f0 <fat_get_fat_cluster+0xec> <== NOT EXECUTED
2045294: a2 0c 40 14 and %l1, %l4, %l1 <== NOT EXECUTED
2045298: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED
204529c: 02 80 00 35 be 2045370 <fat_get_fat_cluster+0x16c> <== NOT EXECUTED
20452a0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
20452a4: 02 80 00 20 be 2045324 <fat_get_fat_cluster+0x120> <== NOT EXECUTED
20452a8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
*ret_val = *((uint32_t *)(block0->buffer + ofs));
*ret_val = CF_LE_L(*ret_val);
break;
default:
rtems_set_errno_and_return_minus_one(EIO);
20452ac: 40 00 14 75 call 204a480 <__errno> <== NOT EXECUTED
20452b0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20452b4: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20452b8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
break;
}
return RC_OK;
}
20452bc: 81 c7 e0 08 ret <== NOT EXECUTED
20452c0: 81 e8 00 00 restore <== NOT EXECUTED
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
20452c4: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
20452c8: a3 36 60 01 srl %i1, 1, %l1 <== NOT EXECUTED
20452cc: a2 04 40 19 add %l1, %i1, %l1 <== NOT EXECUTED
20452d0: a7 34 40 13 srl %l1, %l3, %l3 <== NOT EXECUTED
20452d4: 10 bf ff e1 b 2045258 <fat_get_fat_cluster+0x54> <== NOT EXECUTED
20452d8: a6 04 c0 01 add %l3, %g1, %l3 <== NOT EXECUTED
20452dc: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
20452e0: a3 2e 60 02 sll %i1, 2, %l1 <== NOT EXECUTED
20452e4: a7 34 40 13 srl %l1, %l3, %l3 <== NOT EXECUTED
20452e8: 10 bf ff dc b 2045258 <fat_get_fat_cluster+0x54> <== NOT EXECUTED
20452ec: a6 04 c0 01 add %l3, %g1, %l3 <== NOT EXECUTED
else
*ret_val = (*ret_val) & FAT_FAT12_MASK;
break;
case FAT_FAT16:
*ret_val = *((uint16_t *)(block0->buffer + ofs));
20452f0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
*ret_val = CF_LE_W(*ret_val);
20452f4: 07 00 00 3f sethi %hi(0xfc00), %g3 <== NOT EXECUTED
else
*ret_val = (*ret_val) & FAT_FAT12_MASK;
break;
case FAT_FAT16:
*ret_val = *((uint16_t *)(block0->buffer + ofs));
20452f8: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
*ret_val = CF_LE_W(*ret_val);
20452fc: 86 10 e3 ff or %g3, 0x3ff, %g3 <== NOT EXECUTED
else
*ret_val = (*ret_val) & FAT_FAT12_MASK;
break;
case FAT_FAT16:
*ret_val = *((uint16_t *)(block0->buffer + ofs));
2045300: c2 10 40 11 lduh [ %g1 + %l1 ], %g1 <== NOT EXECUTED
*ret_val = CF_LE_W(*ret_val);
2045304: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
2045308: 85 30 60 18 srl %g1, 0x18, %g2 <== NOT EXECUTED
204530c: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
2045310: 82 08 40 03 and %g1, %g3, %g1 <== NOT EXECUTED
2045314: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2045318: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
break;
204531c: 81 c7 e0 08 ret <== NOT EXECUTED
2045320: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
/*
* we are enforced in complex computations for FAT12 to escape CPU
* align problems for some architectures
*/
*ret_val = (*((uint8_t *)(block0->buffer + ofs)));
if ( ofs == (fs_info->vol.bps - 1) )
2045324: c6 14 00 00 lduh [ %l0 ], %g3 <== NOT EXECUTED
case FAT_FAT12:
/*
* we are enforced in complex computations for FAT12 to escape CPU
* align problems for some architectures
*/
*ret_val = (*((uint8_t *)(block0->buffer + ofs)));
2045328: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
if ( ofs == (fs_info->vol.bps - 1) )
204532c: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
case FAT_FAT12:
/*
* we are enforced in complex computations for FAT12 to escape CPU
* align problems for some architectures
*/
*ret_val = (*((uint8_t *)(block0->buffer + ofs)));
2045330: c2 08 80 11 ldub [ %g2 + %l1 ], %g1 <== NOT EXECUTED
if ( ofs == (fs_info->vol.bps - 1) )
2045334: 80 a0 c0 11 cmp %g3, %l1 <== NOT EXECUTED
2045338: 02 80 00 28 be 20453d8 <fat_get_fat_cluster+0x1d4> <== NOT EXECUTED
204533c: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
*ret_val |= (*((uint8_t *)(block0->buffer)))<<8;
}
else
{
*ret_val |= (*((uint8_t *)(block0->buffer + ofs + 1)))<<8;
2045340: a2 00 80 11 add %g2, %l1, %l1 <== NOT EXECUTED
2045344: c4 0c 60 01 ldub [ %l1 + 1 ], %g2 <== NOT EXECUTED
2045348: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
204534c: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2045350: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
}
if ( FAT_CLUSTER_IS_ODD(cln) )
2045354: 80 8e 60 01 btst 1, %i1 <== NOT EXECUTED
2045358: 22 80 00 17 be,a 20453b4 <fat_get_fat_cluster+0x1b0> <== NOT EXECUTED
204535c: 82 08 6f ff and %g1, 0xfff, %g1 <== NOT EXECUTED
*ret_val = (*ret_val) >> FAT12_SHIFT;
2045360: 83 30 60 04 srl %g1, 4, %g1 <== NOT EXECUTED
2045364: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
2045368: 81 c7 e0 08 ret <== NOT EXECUTED
204536c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*ret_val = *((uint16_t *)(block0->buffer + ofs));
*ret_val = CF_LE_W(*ret_val);
break;
case FAT_FAT32:
*ret_val = *((uint32_t *)(block0->buffer + ofs));
2045370: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045374: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
2045378: c2 00 40 11 ld [ %g1 + %l1 ], %g1 <== NOT EXECUTED
*ret_val = CF_LE_L(*ret_val);
204537c: 85 30 60 10 srl %g1, 0x10, %g2 <== NOT EXECUTED
2045380: 89 28 60 18 sll %g1, 0x18, %g4 <== NOT EXECUTED
2045384: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
2045388: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
204538c: 86 11 00 03 or %g4, %g3, %g3 <== NOT EXECUTED
2045390: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2045394: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
2045398: 82 08 60 ff and %g1, 0xff, %g1 <== NOT EXECUTED
204539c: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
20453a0: 82 10 c0 01 or %g3, %g1, %g1 <== NOT EXECUTED
20453a4: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
20453a8: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
break;
20453ac: 81 c7 e0 08 ret <== NOT EXECUTED
20453b0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
if ( FAT_CLUSTER_IS_ODD(cln) )
*ret_val = (*ret_val) >> FAT12_SHIFT;
else
*ret_val = (*ret_val) & FAT_FAT12_MASK;
20453b4: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
20453b8: 81 c7 e0 08 ret <== NOT EXECUTED
20453bc: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
uint32_t sec = 0;
uint32_t ofs = 0;
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
20453c0: 40 00 14 30 call 204a480 <__errno> <== NOT EXECUTED
20453c4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20453c8: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20453cc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20453d0: 81 c7 e0 08 ret <== NOT EXECUTED
20453d4: 81 e8 00 00 restore <== NOT EXECUTED
* align problems for some architectures
*/
*ret_val = (*((uint8_t *)(block0->buffer + ofs)));
if ( ofs == (fs_info->vol.bps - 1) )
{
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
20453d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20453dc: 92 04 e0 01 add %l3, 1, %o1 <== NOT EXECUTED
20453e0: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
20453e4: 7f ff 90 92 call 202962c <fat_buf_access> <== NOT EXECUTED
20453e8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
&block0);
if (rc != RC_OK)
20453ec: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20453f0: 12 bf ff b3 bne 20452bc <fat_get_fat_cluster+0xb8> <== NOT EXECUTED
20453f4: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
return rc;
*ret_val |= (*((uint8_t *)(block0->buffer)))<<8;
20453f8: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
20453fc: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
2045400: c4 08 80 00 ldub [ %g2 ], %g2 <== NOT EXECUTED
2045404: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2045408: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
204540c: 10 bf ff d2 b 2045354 <fat_get_fat_cluster+0x150> <== NOT EXECUTED
2045410: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
02029398 <fat_get_unique_ino>:
* 0 means FAILED !!!
*
*/
uint32_t
fat_get_unique_ino(rtems_filesystem_mount_table_entry_t *mt_entry)
{
2029398: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
register fat_fs_info_t *fs_info = mt_entry->fs_info;
202939c: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
fs_info->index++;
if (fs_info->index >= fs_info->uino_pool_size)
fs_info->index = 0;
}
if ((fs_info->uino_pool_size << 1) < (0x0FFFFFFF - fs_info->uino_base))
20293a0: 23 03 ff ff sethi %hi(0xffffc00), %l1 <== NOT EXECUTED
20293a4: da 04 20 78 ld [ %l0 + 0x78 ], %o5 <== NOT EXECUTED
20293a8: a2 14 63 ff or %l1, 0x3ff, %l1 <== NOT EXECUTED
uint32_t j = 0;
bool resrc_unsuff = false;
while (!resrc_unsuff)
{
for (j = 0; j < fs_info->uino_pool_size; j++)
20293ac: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
20293b0: 02 80 00 20 be 2029430 <fat_get_unique_ino+0x98> <== NOT EXECUTED
20293b4: 92 10 00 0d mov %o5, %o1 <== NOT EXECUTED
{
if (!FAT_UNIQ_INO_IS_BUSY(fs_info->index, fs_info->uino))
20293b8: c6 04 20 70 ld [ %l0 + 0x70 ], %g3 <== NOT EXECUTED
20293bc: c2 04 20 74 ld [ %l0 + 0x74 ], %g1 <== NOT EXECUTED
20293c0: 85 30 60 03 srl %g1, 3, %g2 <== NOT EXECUTED
20293c4: c8 48 c0 02 ldsb [ %g3 + %g2 ], %g4 <== NOT EXECUTED
20293c8: 98 08 60 07 and %g1, 7, %o4 <== NOT EXECUTED
20293cc: 96 00 c0 02 add %g3, %g2, %o3 <== NOT EXECUTED
20293d0: 89 39 00 0c sra %g4, %o4, %g4 <== NOT EXECUTED
20293d4: 80 89 20 01 btst 1, %g4 <== NOT EXECUTED
20293d8: 02 80 00 1e be 2029450 <fat_get_unique_ino+0xb8> <== NOT EXECUTED
20293dc: c4 08 c0 02 ldub [ %g3 + %g2 ], %g2 <== NOT EXECUTED
{
FAT_SET_UNIQ_INO_BUSY(fs_info->index, fs_info->uino);
return (fs_info->uino_base + fs_info->index);
20293e0: 10 80 00 0a b 2029408 <fat_get_unique_ino+0x70> <== NOT EXECUTED
20293e4: 88 10 20 00 clr %g4 <== NOT EXECUTED
while (!resrc_unsuff)
{
for (j = 0; j < fs_info->uino_pool_size; j++)
{
if (!FAT_UNIQ_INO_IS_BUSY(fs_info->index, fs_info->uino))
20293e8: 85 30 60 03 srl %g1, 3, %g2 <== NOT EXECUTED
20293ec: d6 48 c0 02 ldsb [ %g3 + %g2 ], %o3 <== NOT EXECUTED
20293f0: 98 08 60 07 and %g1, 7, %o4 <== NOT EXECUTED
20293f4: 97 3a c0 0c sra %o3, %o4, %o3 <== NOT EXECUTED
20293f8: 80 8a e0 01 btst 1, %o3 <== NOT EXECUTED
20293fc: 96 00 c0 02 add %g3, %g2, %o3 <== NOT EXECUTED
2029400: 02 80 00 14 be 2029450 <fat_get_unique_ino+0xb8> <== NOT EXECUTED
2029404: c4 08 c0 02 ldub [ %g3 + %g2 ], %g2 <== NOT EXECUTED
{
FAT_SET_UNIQ_INO_BUSY(fs_info->index, fs_info->uino);
return (fs_info->uino_base + fs_info->index);
}
fs_info->index++;
2029408: 82 00 60 01 inc %g1 <== NOT EXECUTED
if (fs_info->index >= fs_info->uino_pool_size)
202940c: 80 a3 40 01 cmp %o5, %g1 <== NOT EXECUTED
2029410: 18 80 00 03 bgu 202941c <fat_get_unique_ino+0x84> <== NOT EXECUTED
2029414: c2 24 20 74 st %g1, [ %l0 + 0x74 ] <== NOT EXECUTED
fs_info->index = 0;
2029418: c0 24 20 74 clr [ %l0 + 0x74 ] <== NOT EXECUTED
uint32_t j = 0;
bool resrc_unsuff = false;
while (!resrc_unsuff)
{
for (j = 0; j < fs_info->uino_pool_size; j++)
202941c: 88 01 20 01 inc %g4 <== NOT EXECUTED
2029420: 80 a1 00 0d cmp %g4, %o5 <== NOT EXECUTED
2029424: 2a bf ff f1 bcs,a 20293e8 <fat_get_unique_ino+0x50> <== NOT EXECUTED
2029428: c2 04 20 74 ld [ %l0 + 0x74 ], %g1 <== NOT EXECUTED
202942c: 92 10 00 0d mov %o5, %o1 <== NOT EXECUTED
fs_info->index++;
if (fs_info->index >= fs_info->uino_pool_size)
fs_info->index = 0;
}
if ((fs_info->uino_pool_size << 1) < (0x0FFFFFFF - fs_info->uino_base))
2029430: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2029434: 93 2a 60 01 sll %o1, 1, %o1 <== NOT EXECUTED
2029438: 82 24 40 01 sub %l1, %g1, %g1 <== NOT EXECUTED
202943c: 80 a2 40 01 cmp %o1, %g1 <== NOT EXECUTED
2029440: 2a 80 00 0c bcs,a 2029470 <fat_get_unique_ino+0xd8> <== NOT EXECUTED
2029444: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 <== NOT EXECUTED
}
else
resrc_unsuff = true;
}
return 0;
}
2029448: 81 c7 e0 08 ret <== NOT EXECUTED
202944c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
{
for (j = 0; j < fs_info->uino_pool_size; j++)
{
if (!FAT_UNIQ_INO_IS_BUSY(fs_info->index, fs_info->uino))
{
FAT_SET_UNIQ_INO_BUSY(fs_info->index, fs_info->uino);
2029450: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2029454: 99 28 40 0c sll %g1, %o4, %o4 <== NOT EXECUTED
2029458: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
202945c: c4 2a c0 00 stb %g2, [ %o3 ] <== NOT EXECUTED
return (fs_info->uino_base + fs_info->index);
2029460: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2029464: f0 04 20 74 ld [ %l0 + 0x74 ], %i0 <== NOT EXECUTED
2029468: 81 c7 e0 08 ret <== NOT EXECUTED
202946c: 91 ee 00 01 restore %i0, %g1, %o0 <== NOT EXECUTED
}
if ((fs_info->uino_pool_size << 1) < (0x0FFFFFFF - fs_info->uino_base))
{
fs_info->uino_pool_size <<= 1;
fs_info->uino = realloc(fs_info->uino, fs_info->uino_pool_size);
2029470: 7f ff 82 da call 2009fd8 <realloc> <== NOT EXECUTED
2029474: d2 24 20 78 st %o1, [ %l0 + 0x78 ] <== NOT EXECUTED
if (fs_info->uino != NULL)
2029478: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202947c: 02 bf ff f3 be 2029448 <fat_get_unique_ino+0xb0> <== NOT EXECUTED
2029480: d0 24 20 70 st %o0, [ %l0 + 0x70 ] <== NOT EXECUTED
fs_info->index = fs_info->uino_pool_size;
2029484: da 04 20 78 ld [ %l0 + 0x78 ], %o5 <== NOT EXECUTED
2029488: 10 bf ff c9 b 20293ac <fat_get_unique_ino+0x14> <== NOT EXECUTED
202948c: da 24 20 74 st %o5, [ %l0 + 0x74 ] <== NOT EXECUTED
02029b58 <fat_init_clusters_chain>:
int
fat_init_clusters_chain(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t start_cln
)
{
2029b58: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
ssize_t ret = 0;
register fat_fs_info_t *fs_info = mt_entry->fs_info;
2029b5c: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
uint32_t cur_cln = start_cln;
2029b60: f2 27 bf fc st %i1, [ %fp + -4 ] <== NOT EXECUTED
char *buf;
buf = calloc(fs_info->vol.bpc, sizeof(char));
2029b64: d0 14 20 06 lduh [ %l0 + 6 ], %o0 <== NOT EXECUTED
2029b68: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2029b6c: 7f ff 79 ba call 2008254 <calloc> <== NOT EXECUTED
2029b70: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
if ( buf == NULL )
2029b74: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2029b78: 02 80 00 22 be 2029c00 <fat_init_clusters_chain+0xa8> <== NOT EXECUTED
2029b7c: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
2029b80: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2029b84: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2029b88: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2029b8c: 84 0a 40 02 and %o1, %g2, %g2 <== NOT EXECUTED
2029b90: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2029b94: 1a 80 00 11 bcc 2029bd8 <fat_init_clusters_chain+0x80> <== NOT EXECUTED
2029b98: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
{
ret = fat_cluster_write(mt_entry, cur_cln, buf);
2029b9c: 7f ff ff d3 call 2029ae8 <fat_cluster_write> <== NOT EXECUTED
2029ba0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
{
free(buf);
return -1;
}
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2029ba4: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
{
ret = fat_cluster_write(mt_entry, cur_cln, buf);
if ( ret == -1 )
2029ba8: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
2029bac: 02 80 00 10 be 2029bec <fat_init_clusters_chain+0x94> <== NOT EXECUTED
2029bb0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
{
free(buf);
return -1;
}
rc = fat_get_fat_cluster(mt_entry, cur_cln, &cur_cln);
2029bb4: 40 00 6d 94 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
2029bb8: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
if ( rc != RC_OK )
2029bbc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2029bc0: 02 bf ff f1 be 2029b84 <fat_init_clusters_chain+0x2c> <== NOT EXECUTED
2029bc4: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
free(buf);
2029bc8: 7f ff 7b 45 call 20088dc <free> <== NOT EXECUTED
2029bcc: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
return rc;
2029bd0: 81 c7 e0 08 ret <== NOT EXECUTED
2029bd4: 81 e8 00 00 restore <== NOT EXECUTED
}
}
free(buf);
2029bd8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2029bdc: 7f ff 7b 40 call 20088dc <free> <== NOT EXECUTED
2029be0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return rc;
}
2029be4: 81 c7 e0 08 ret <== NOT EXECUTED
2029be8: 81 e8 00 00 restore <== NOT EXECUTED
while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)
{
ret = fat_cluster_write(mt_entry, cur_cln, buf);
if ( ret == -1 )
{
free(buf);
2029bec: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2029bf0: 7f ff 7b 3b call 20088dc <free> <== NOT EXECUTED
2029bf4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return -1;
2029bf8: 81 c7 e0 08 ret <== NOT EXECUTED
2029bfc: 81 e8 00 00 restore <== NOT EXECUTED
uint32_t cur_cln = start_cln;
char *buf;
buf = calloc(fs_info->vol.bpc, sizeof(char));
if ( buf == NULL )
rtems_set_errno_and_return_minus_one( EIO );
2029c00: 40 00 82 20 call 204a480 <__errno> <== NOT EXECUTED
2029c04: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2029c08: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2029c0c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029c10: 81 c7 e0 08 ret <== NOT EXECUTED
2029c14: 81 e8 00 00 restore <== NOT EXECUTED
02029ca0 <fat_init_volume_info>:
* RC_OK on success, or -1 if error occured
* and errno set appropriately
*/
int
fat_init_volume_info(rtems_filesystem_mount_table_entry_t *mt_entry)
{
2029ca0: 9d e3 be e8 save %sp, -280, %sp <== NOT EXECUTED
ssize_t ret = 0;
struct stat stat_buf;
int i = 0;
rtems_bdbuf_buffer *block = NULL;
rc = stat(mt_entry->dev, &stat_buf);
2029ca4: d0 06 20 70 ld [ %i0 + 0x70 ], %o0 <== NOT EXECUTED
int
fat_init_volume_info(rtems_filesystem_mount_table_entry_t *mt_entry)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
2029ca8: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
* RC_OK on success, or -1 if error occured
* and errno set appropriately
*/
int
fat_init_volume_info(rtems_filesystem_mount_table_entry_t *mt_entry)
{
2029cac: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
char boot_rec[FAT_MAX_BPB_SIZE];
char fs_info_sector[FAT_USEFUL_INFO_SIZE];
ssize_t ret = 0;
struct stat stat_buf;
int i = 0;
rtems_bdbuf_buffer *block = NULL;
2029cb0: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rc = stat(mt_entry->dev, &stat_buf);
2029cb4: 7f ff 81 bb call 200a3a0 <stat> <== NOT EXECUTED
2029cb8: 92 07 bf a8 add %fp, -88, %o1 <== NOT EXECUTED
if (rc == -1)
2029cbc: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
2029cc0: 02 80 00 ed be 202a074 <fat_init_volume_info+0x3d4> <== NOT EXECUTED
2029cc4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
return rc;
/* Must be a block device. */
if (!S_ISBLK(stat_buf.st_mode))
2029cc8: c4 07 bf b4 ld [ %fp + -76 ], %g2 <== NOT EXECUTED
2029ccc: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2029cd0: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
2029cd4: 03 00 00 18 sethi %hi(0x6000), %g1 <== NOT EXECUTED
2029cd8: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2029cdc: 12 80 01 7d bne 202a2d0 <fat_init_volume_info+0x630> <== NOT EXECUTED
2029ce0: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOTTY);
/* check that device is registred as block device and lock it */
vol->dd = rtems_disk_obtain(stat_buf.st_rdev);
2029ce4: 7f ff 75 eb call 2007490 <rtems_disk_obtain> <== NOT EXECUTED
2029ce8: d0 1f bf c0 ldd [ %fp + -64 ], %o0 <== NOT EXECUTED
if (vol->dd == NULL)
2029cec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029cf0: 02 80 01 aa be 202a398 <fat_init_volume_info+0x6f8> <== NOT EXECUTED
2029cf4: d0 24 20 60 st %o0, [ %l0 + 0x60 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
vol->dev = stat_buf.st_rdev;
2029cf8: d0 1f bf c0 ldd [ %fp + -64 ], %o0 <== NOT EXECUTED
/* Read boot record */
/* FIXME: Asserts FAT_MAX_BPB_SIZE < bdbuf block size */
sc = rtems_bdbuf_read( vol->dev, 0, &block);
2029cfc: 94 10 20 00 clr %o2 <== NOT EXECUTED
/* check that device is registred as block device and lock it */
vol->dd = rtems_disk_obtain(stat_buf.st_rdev);
if (vol->dd == NULL)
rtems_set_errno_and_return_minus_one(EIO);
vol->dev = stat_buf.st_rdev;
2029d00: d0 3c 20 58 std %o0, [ %l0 + 0x58 ] <== NOT EXECUTED
/* Read boot record */
/* FIXME: Asserts FAT_MAX_BPB_SIZE < bdbuf block size */
sc = rtems_bdbuf_read( vol->dev, 0, &block);
2029d04: 7f ff 70 f1 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
2029d08: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2029d0c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029d10: 12 80 01 8e bne 202a348 <fat_init_volume_info+0x6a8> <== NOT EXECUTED
2029d14: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EIO);
}
memcpy( boot_rec, block->buffer, FAT_MAX_BPB_SIZE);
2029d18: 94 10 20 5a mov 0x5a, %o2 <== NOT EXECUTED
2029d1c: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2029d20: 40 00 8f 24 call 204d9b0 <memcpy> <== NOT EXECUTED
2029d24: 90 07 bf 48 add %fp, -184, %o0 <== NOT EXECUTED
sc = rtems_bdbuf_release( block);
2029d28: 7f ff 6c 0d call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
2029d2c: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2029d30: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029d34: 12 80 01 85 bne 202a348 <fat_init_volume_info+0x6a8> <== NOT EXECUTED
2029d38: c4 0f bf 53 ldub [ %fp + -173 ], %g2 <== NOT EXECUTED
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EIO );
}
/* Evaluate boot record */
vol->bps = FAT_GET_BR_BYTES_PER_SECTOR(boot_rec);
2029d3c: c2 0f bf 54 ldub [ %fp + -172 ], %g1 <== NOT EXECUTED
2029d40: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2029d44: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2029d48: c2 34 00 00 sth %g1, [ %l0 ] <== NOT EXECUTED
if ( (vol->bps != 512) &&
2029d4c: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
2029d50: 85 30 60 10 srl %g1, 0x10, %g2 <== NOT EXECUTED
2029d54: 80 a0 a4 00 cmp %g2, 0x400 <== NOT EXECUTED
2029d58: 12 80 00 c9 bne 202a07c <fat_init_volume_info+0x3dc> <== NOT EXECUTED
2029d5c: 80 a0 a2 00 cmp %g2, 0x200 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EINVAL );
}
for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
2029d60: 83 30 60 19 srl %g1, 0x19, %g1 <== NOT EXECUTED
2029d64: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2029d68: 12 80 00 09 bne 2029d8c <fat_init_volume_info+0xec> <== NOT EXECUTED
2029d6c: c0 2c 20 03 clrb [ %l0 + 3 ] <== NOT EXECUTED
2029d70: c4 0c 20 03 ldub [ %l0 + 3 ], %g2 <== NOT EXECUTED
i >>= 1, vol->sec_mul++);
2029d74: 83 38 60 01 sra %g1, 1, %g1 <== NOT EXECUTED
2029d78: 86 00 a0 01 add %g2, 1, %g3 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EINVAL );
}
for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
2029d7c: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2029d80: 02 bf ff fd be 2029d74 <fat_init_volume_info+0xd4> <== NOT EXECUTED
2029d84: 84 10 00 03 mov %g3, %g2 <== NOT EXECUTED
2029d88: c6 2c 20 03 stb %g3, [ %l0 + 3 ] <== NOT EXECUTED
i >>= 1, vol->sec_mul++);
for (vol->sec_log2 = 0, i = vol->bps; (i & 1) == 0;
2029d8c: c4 14 00 00 lduh [ %l0 ], %g2 <== NOT EXECUTED
2029d90: c0 2c 20 02 clrb [ %l0 + 2 ] <== NOT EXECUTED
2029d94: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
2029d98: 12 80 00 0a bne 2029dc0 <fat_init_volume_info+0x120> <== NOT EXECUTED
2029d9c: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
2029da0: 10 80 00 03 b 2029dac <fat_init_volume_info+0x10c> <== NOT EXECUTED
2029da4: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2029da8: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
i >>= 1, vol->sec_log2++);
2029dac: 85 38 a0 01 sra %g2, 1, %g2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
}
for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
i >>= 1, vol->sec_mul++);
for (vol->sec_log2 = 0, i = vol->bps; (i & 1) == 0;
2029db0: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
2029db4: 02 bf ff fd be 2029da8 <fat_init_volume_info+0x108> <== NOT EXECUTED
2029db8: 88 00 e0 01 add %g3, 1, %g4 <== NOT EXECUTED
2029dbc: c6 2c 20 02 stb %g3, [ %l0 + 2 ] <== NOT EXECUTED
if ( (ret1 < 0) || (ret2 < 0) )
return -1;
return RC_OK;
}
2029dc0: c4 0f bf 55 ldub [ %fp + -171 ], %g2 <== NOT EXECUTED
for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
i >>= 1, vol->sec_mul++);
for (vol->sec_log2 = 0, i = vol->bps; (i & 1) == 0;
i >>= 1, vol->sec_log2++);
vol->spc = FAT_GET_BR_SECTORS_PER_CLUSTER(boot_rec);
2029dc4: c4 2c 20 04 stb %g2, [ %l0 + 4 ] <== NOT EXECUTED
/*
* "sectors per cluster" of zero is invalid
* (and would hang the following loop)
*/
if (vol->spc == 0)
2029dc8: 84 88 a0 ff andcc %g2, 0xff, %g2 <== NOT EXECUTED
2029dcc: 02 80 01 47 be 202a2e8 <fat_init_volume_info+0x648> <== NOT EXECUTED
2029dd0: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one(EINVAL);
}
for (vol->spc_log2 = 0, i = vol->spc; (i & 1) == 0;
2029dd4: c0 2c 20 05 clrb [ %l0 + 5 ] <== NOT EXECUTED
2029dd8: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2029ddc: 02 80 00 05 be 2029df0 <fat_init_volume_info+0x150> <== NOT EXECUTED
2029de0: 88 10 20 00 clr %g4 <== NOT EXECUTED
i >>= 1, vol->spc_log2++);
/*
* "bytes per cluster" value greater than 32K is invalid
*/
if ((vol->bpc = vol->bps << vol->spc_log2) > MS_BYTES_PER_CLUSTER_LIMIT)
2029de4: 10 80 00 0a b 2029e0c <fat_init_volume_info+0x16c> <== NOT EXECUTED
2029de8: 85 28 60 10 sll %g1, 0x10, %g2 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one(EINVAL);
}
for (vol->spc_log2 = 0, i = vol->spc; (i & 1) == 0;
2029dec: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
i >>= 1, vol->spc_log2++);
2029df0: 85 38 a0 01 sra %g2, 1, %g2 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one(EINVAL);
}
for (vol->spc_log2 = 0, i = vol->spc; (i & 1) == 0;
2029df4: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
2029df8: 02 bf ff fd be 2029dec <fat_init_volume_info+0x14c> <== NOT EXECUTED
2029dfc: 88 00 e0 01 add %g3, 1, %g4 <== NOT EXECUTED
2029e00: c6 2c 20 05 stb %g3, [ %l0 + 5 ] <== NOT EXECUTED
2029e04: 88 08 e0 ff and %g3, 0xff, %g4 <== NOT EXECUTED
i >>= 1, vol->spc_log2++);
/*
* "bytes per cluster" value greater than 32K is invalid
*/
if ((vol->bpc = vol->bps << vol->spc_log2) > MS_BYTES_PER_CLUSTER_LIMIT)
2029e08: 85 28 60 10 sll %g1, 0x10, %g2 <== NOT EXECUTED
2029e0c: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
2029e10: 85 28 80 04 sll %g2, %g4, %g2 <== NOT EXECUTED
2029e14: c4 34 20 06 sth %g2, [ %l0 + 6 ] <== NOT EXECUTED
2029e18: 07 00 00 20 sethi %hi(0x8000), %g3 <== NOT EXECUTED
2029e1c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2029e20: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
2029e24: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2029e28: 18 80 01 30 bgu 202a2e8 <fat_init_volume_info+0x648> <== NOT EXECUTED
2029e2c: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one(EINVAL);
}
for (vol->bpc_log2 = 0, i = vol->bpc; (i & 1) == 0;
2029e30: 12 80 00 0a bne 2029e58 <fat_init_volume_info+0x1b8> <== NOT EXECUTED
2029e34: c0 2c 20 08 clrb [ %l0 + 8 ] <== NOT EXECUTED
2029e38: 10 80 00 03 b 2029e44 <fat_init_volume_info+0x1a4> <== NOT EXECUTED
2029e3c: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
2029e40: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
i >>= 1, vol->bpc_log2++);
2029e44: 85 38 a0 01 sra %g2, 1, %g2 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one(EINVAL);
}
for (vol->bpc_log2 = 0, i = vol->bpc; (i & 1) == 0;
2029e48: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED
2029e4c: 02 bf ff fd be 2029e40 <fat_init_volume_info+0x1a0> <== NOT EXECUTED
2029e50: 88 00 e0 01 add %g3, 1, %g4 <== NOT EXECUTED
2029e54: c6 2c 20 08 stb %g3, [ %l0 + 8 ] <== NOT EXECUTED
if ( (ret1 < 0) || (ret2 < 0) )
return -1;
return RC_OK;
}
2029e58: e6 0f bf 58 ldub [ %fp + -168 ], %l3 <== NOT EXECUTED
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029e5c: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
}
for (vol->bpc_log2 = 0, i = vol->bpc; (i & 1) == 0;
i >>= 1, vol->bpc_log2++);
vol->fats = FAT_GET_BR_FAT_NUM(boot_rec);
2029e60: e6 2c 20 09 stb %l3, [ %l0 + 9 ] <== NOT EXECUTED
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
2029e64: c4 0f bf 56 ldub [ %fp + -170 ], %g2 <== NOT EXECUTED
2029e68: e4 0f bf 57 ldub [ %fp + -169 ], %l2 <== NOT EXECUTED
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029e6c: 83 30 60 10 srl %g1, 0x10, %g1 <== NOT EXECUTED
for (vol->bpc_log2 = 0, i = vol->bpc; (i & 1) == 0;
i >>= 1, vol->bpc_log2++);
vol->fats = FAT_GET_BR_FAT_NUM(boot_rec);
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
2029e70: a5 2c a0 08 sll %l2, 8, %l2 <== NOT EXECUTED
2029e74: a4 14 80 02 or %l2, %g2, %l2 <== NOT EXECUTED
2029e78: e4 34 20 14 sth %l2, [ %l0 + 0x14 ] <== NOT EXECUTED
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
2029e7c: c6 0f bf 59 ldub [ %fp + -167 ], %g3 <== NOT EXECUTED
2029e80: c4 0f bf 5a ldub [ %fp + -166 ], %g2 <== NOT EXECUTED
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029e84: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
i >>= 1, vol->bpc_log2++);
vol->fats = FAT_GET_BR_FAT_NUM(boot_rec);
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
2029e88: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2029e8c: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029e90: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2029e94: 87 28 a0 10 sll %g2, 0x10, %g3 <== NOT EXECUTED
i >>= 1, vol->bpc_log2++);
vol->fats = FAT_GET_BR_FAT_NUM(boot_rec);
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
2029e98: c4 34 20 20 sth %g2, [ %l0 + 0x20 ] <== NOT EXECUTED
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029e9c: 85 30 e0 0b srl %g3, 0xb, %g2 <== NOT EXECUTED
2029ea0: 40 00 e2 bb call 206298c <.div> <== NOT EXECUTED
2029ea4: 90 00 40 02 add %g1, %g2, %o0 <== NOT EXECUTED
vol->bps;
vol->rdir_size = vol->rdir_secs << vol->sec_log2;
2029ea8: c4 0c 20 02 ldub [ %l0 + 2 ], %g2 <== NOT EXECUTED
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029eac: d0 24 20 24 st %o0, [ %l0 + 0x24 ] <== NOT EXECUTED
vol->bps;
vol->rdir_size = vol->rdir_secs << vol->sec_log2;
2029eb0: 85 2a 00 02 sll %o0, %g2, %g2 <== NOT EXECUTED
vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);
vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);
/* calculate the count of sectors occupied by the root directory */
vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
2029eb4: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
vol->bps;
vol->rdir_size = vol->rdir_secs << vol->sec_log2;
2029eb8: c4 24 20 28 st %g2, [ %l0 + 0x28 ] <== NOT EXECUTED
if ( (FAT_GET_BR_SECTORS_PER_FAT(boot_rec)) != 0)
2029ebc: d0 0f bf 5f ldub [ %fp + -161 ], %o0 <== NOT EXECUTED
2029ec0: c4 0f bf 5e ldub [ %fp + -162 ], %g2 <== NOT EXECUTED
2029ec4: 91 2a 20 08 sll %o0, 8, %o0 <== NOT EXECUTED
2029ec8: 90 12 00 02 or %o0, %g2, %o0 <== NOT EXECUTED
2029ecc: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
2029ed0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029ed4: 22 80 00 ec be,a 202a284 <fat_init_volume_info+0x5e4> <== NOT EXECUTED
2029ed8: d0 0f bf 6d ldub [ %fp + -147 ], %o0 <== NOT EXECUTED
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT(boot_rec);
2029edc: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED
2029ee0: d0 24 20 18 st %o0, [ %l0 + 0x18 ] <== NOT EXECUTED
else
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT32(boot_rec);
vol->data_fsec = vol->fat_loc + vol->fats * vol->fat_length +
2029ee4: 92 0c e0 ff and %l3, 0xff, %o1 <== NOT EXECUTED
2029ee8: a5 2c a0 10 sll %l2, 0x10, %l2 <== NOT EXECUTED
2029eec: a5 34 a0 10 srl %l2, 0x10, %l2 <== NOT EXECUTED
2029ef0: 7f ff 63 27 call 2002b8c <.umul> <== NOT EXECUTED
2029ef4: a4 00 40 12 add %g1, %l2, %l2 <== NOT EXECUTED
vol->rdir_secs;
/* for FAT12/16 root dir starts at(sector) */
vol->rdir_loc = vol->fat_loc + vol->fats * vol->fat_length;
2029ef8: d2 04 20 18 ld [ %l0 + 0x18 ], %o1 <== NOT EXECUTED
if ( (FAT_GET_BR_SECTORS_PER_FAT(boot_rec)) != 0)
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT(boot_rec);
else
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT32(boot_rec);
vol->data_fsec = vol->fat_loc + vol->fats * vol->fat_length +
2029efc: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
vol->rdir_secs;
/* for FAT12/16 root dir starts at(sector) */
vol->rdir_loc = vol->fat_loc + vol->fats * vol->fat_length;
2029f00: d0 0c 20 09 ldub [ %l0 + 9 ], %o0 <== NOT EXECUTED
2029f04: 7f ff 63 22 call 2002b8c <.umul> <== NOT EXECUTED
2029f08: e4 24 20 30 st %l2, [ %l0 + 0x30 ] <== NOT EXECUTED
2029f0c: c2 14 20 14 lduh [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
2029f10: 82 02 00 01 add %o0, %g1, %g1 <== NOT EXECUTED
2029f14: c2 24 20 1c st %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
if ( (FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec)) != 0)
2029f18: d0 0f bf 5c ldub [ %fp + -164 ], %o0 <== NOT EXECUTED
2029f1c: c2 0f bf 5b ldub [ %fp + -165 ], %g1 <== NOT EXECUTED
2029f20: 91 2a 20 08 sll %o0, 8, %o0 <== NOT EXECUTED
2029f24: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
2029f28: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
2029f2c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029f30: 22 80 00 ca be,a 202a258 <fat_init_volume_info+0x5b8> <== NOT EXECUTED
2029f34: d0 0f bf 69 ldub [ %fp + -151 ], %o0 <== NOT EXECUTED
vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec);
2029f38: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED
2029f3c: d0 24 20 2c st %o0, [ %l0 + 0x2c ] <== NOT EXECUTED
else
vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM32(boot_rec);
data_secs = vol->tot_secs - vol->data_fsec;
vol->data_cls = data_secs / vol->spc;
2029f40: d2 0c 20 04 ldub [ %l0 + 4 ], %o1 <== NOT EXECUTED
2029f44: 40 00 e2 90 call 2062984 <.udiv> <== NOT EXECUTED
2029f48: 90 22 00 12 sub %o0, %l2, %o0 <== NOT EXECUTED
/* determine FAT type at least */
if ( vol->data_cls < FAT_FAT12_MAX_CLN)
2029f4c: 80 a2 2f f4 cmp %o0, 0xff4 <== NOT EXECUTED
2029f50: 18 80 00 56 bgu 202a0a8 <fat_init_volume_info+0x408> <== NOT EXECUTED
2029f54: d0 24 20 34 st %o0, [ %l0 + 0x34 ] <== NOT EXECUTED
{
vol->type = FAT_FAT12;
2029f58: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2029f5c: c2 2c 20 0a stb %g1, [ %l0 + 0xa ] <== NOT EXECUTED
vol->mask = FAT_FAT12_MASK;
2029f60: 82 10 2f ff mov 0xfff, %g1 <== NOT EXECUTED
2029f64: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
vol->eoc_val = FAT_FAT12_EOC;
2029f68: 82 10 2f f8 mov 0xff8, %g1 <== NOT EXECUTED
2029f6c: c2 24 20 10 st %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
else
{
vol->rdir_cl = 0;
vol->mirror = 0;
vol->afat = 0;
vol->free_cls = 0xFFFFFFFF;
2029f70: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
}
}
}
else
{
vol->rdir_cl = 0;
2029f74: c0 24 20 38 clr [ %l0 + 0x38 ] <== NOT EXECUTED
vol->mirror = 0;
2029f78: c0 2c 20 48 clrb [ %l0 + 0x48 ] <== NOT EXECUTED
vol->afat = 0;
2029f7c: c0 2c 20 50 clrb [ %l0 + 0x50 ] <== NOT EXECUTED
vol->free_cls = 0xFFFFFFFF;
vol->next_cl = 0xFFFFFFFF;
2029f80: c2 24 20 44 st %g1, [ %l0 + 0x44 ] <== NOT EXECUTED
else
{
vol->rdir_cl = 0;
vol->mirror = 0;
vol->afat = 0;
vol->free_cls = 0xFFFFFFFF;
2029f84: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
int
_fat_block_release(
rtems_filesystem_mount_table_entry_t *mt_entry)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
return fat_buf_release(fs_info);
2029f88: 7f ff fd 42 call 2029490 <fat_buf_release> <== NOT EXECUTED
2029f8c: d0 04 60 34 ld [ %l1 + 0x34 ], %o0 <== NOT EXECUTED
vol->next_cl = 0xFFFFFFFF;
}
_fat_block_release(mt_entry);
vol->afat_loc = vol->fat_loc + vol->fat_length * vol->afat;
2029f90: d2 04 20 18 ld [ %l0 + 0x18 ], %o1 <== NOT EXECUTED
2029f94: 7f ff 62 fe call 2002b8c <.umul> <== NOT EXECUTED
2029f98: d0 0c 20 50 ldub [ %l0 + 0x50 ], %o0 <== NOT EXECUTED
2029f9c: c2 14 20 14 lduh [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
/* set up collection of fat-files fd */
fs_info->vhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
2029fa0: 92 10 20 0c mov 0xc, %o1 <== NOT EXECUTED
vol->next_cl = 0xFFFFFFFF;
}
_fat_block_release(mt_entry);
vol->afat_loc = vol->fat_loc + vol->fat_length * vol->afat;
2029fa4: 82 02 00 01 add %o0, %g1, %g1 <== NOT EXECUTED
/* set up collection of fat-files fd */
fs_info->vhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
2029fa8: 90 10 20 02 mov 2, %o0 <== NOT EXECUTED
2029fac: 7f ff 78 aa call 2008254 <calloc> <== NOT EXECUTED
2029fb0: c2 24 20 4c st %g1, [ %l0 + 0x4c ] <== NOT EXECUTED
if ( fs_info->vhash == NULL )
2029fb4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029fb8: 02 80 01 1d be 202a42c <fat_init_volume_info+0x78c> <== NOT EXECUTED
2029fbc: d0 24 20 68 st %o0, [ %l0 + 0x68 ] <== NOT EXECUTED
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( ENOMEM );
}
for (i = 0; i < FAT_HASH_SIZE; i++)
rtems_chain_initialize_empty(fs_info->vhash + i);
2029fc0: 82 02 20 0c add %o0, 0xc, %g1 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2029fc4: c0 22 20 04 clr [ %o0 + 4 ] <== NOT EXECUTED
the_chain->last = _Chain_Head(the_chain);
2029fc8: d0 22 20 08 st %o0, [ %o0 + 8 ] <== NOT EXECUTED
2029fcc: c2 20 60 08 st %g1, [ %g1 + 8 ] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2029fd0: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2029fd4: 82 02 20 04 add %o0, 4, %g1 <== NOT EXECUTED
2029fd8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2029fdc: 82 02 20 10 add %o0, 0x10, %g1 <== NOT EXECUTED
fs_info->rhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
2029fe0: 92 10 20 0c mov 0xc, %o1 <== NOT EXECUTED
2029fe4: c2 22 20 0c st %g1, [ %o0 + 0xc ] <== NOT EXECUTED
2029fe8: 7f ff 78 9b call 2008254 <calloc> <== NOT EXECUTED
2029fec: 90 10 20 02 mov 2, %o0 <== NOT EXECUTED
if ( fs_info->rhash == NULL )
2029ff0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029ff4: 02 80 01 03 be 202a400 <fat_init_volume_info+0x760> <== NOT EXECUTED
2029ff8: d0 24 20 6c st %o0, [ %l0 + 0x6c ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
2029ffc: c0 22 20 04 clr [ %o0 + 4 ] <== NOT EXECUTED
the_chain->last = _Chain_Head(the_chain);
202a000: d0 22 20 08 st %o0, [ %o0 + 8 ] <== NOT EXECUTED
rtems_disk_release(vol->dd);
free(fs_info->vhash);
rtems_set_errno_and_return_minus_one( ENOMEM );
}
for (i = 0; i < FAT_HASH_SIZE; i++)
rtems_chain_initialize_empty(fs_info->rhash + i);
202a004: 82 02 20 0c add %o0, 0xc, %g1 <== NOT EXECUTED
202a008: c2 20 60 08 st %g1, [ %g1 + 8 ] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
202a00c: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
202a010: 82 02 20 04 add %o0, 4, %g1 <== NOT EXECUTED
202a014: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a018: 82 02 20 10 add %o0, 0x10, %g1 <== NOT EXECUTED
fs_info->uino_pool_size = FAT_UINO_POOL_INIT_SIZE;
fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;
202a01c: c4 04 20 2c ld [ %l0 + 0x2c ], %g2 <== NOT EXECUTED
202a020: c2 22 20 0c st %g1, [ %o0 + 0xc ] <== NOT EXECUTED
202a024: c2 0c 20 03 ldub [ %l0 + 3 ], %g1 <== NOT EXECUTED
fs_info->index = 0;
202a028: c0 24 20 74 clr [ %l0 + 0x74 ] <== NOT EXECUTED
}
for (i = 0; i < FAT_HASH_SIZE; i++)
rtems_chain_initialize_empty(fs_info->rhash + i);
fs_info->uino_pool_size = FAT_UINO_POOL_INIT_SIZE;
fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;
202a02c: 83 28 80 01 sll %g2, %g1, %g1 <== NOT EXECUTED
202a030: 83 28 60 04 sll %g1, 4, %g1 <== NOT EXECUTED
202a034: c2 24 20 7c st %g1, [ %l0 + 0x7c ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
}
for (i = 0; i < FAT_HASH_SIZE; i++)
rtems_chain_initialize_empty(fs_info->rhash + i);
fs_info->uino_pool_size = FAT_UINO_POOL_INIT_SIZE;
202a038: 82 10 21 00 mov 0x100, %g1 <== NOT EXECUTED
fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;
fs_info->index = 0;
fs_info->uino = (char *)calloc(fs_info->uino_pool_size, sizeof(char));
202a03c: 90 10 21 00 mov 0x100, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
}
for (i = 0; i < FAT_HASH_SIZE; i++)
rtems_chain_initialize_empty(fs_info->rhash + i);
fs_info->uino_pool_size = FAT_UINO_POOL_INIT_SIZE;
202a040: c2 24 20 78 st %g1, [ %l0 + 0x78 ] <== NOT EXECUTED
fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;
fs_info->index = 0;
fs_info->uino = (char *)calloc(fs_info->uino_pool_size, sizeof(char));
202a044: 7f ff 78 84 call 2008254 <calloc> <== NOT EXECUTED
202a048: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
if ( fs_info->uino == NULL )
202a04c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202a050: 02 80 00 d8 be 202a3b0 <fat_init_volume_info+0x710> <== NOT EXECUTED
202a054: d0 24 20 70 st %o0, [ %l0 + 0x70 ] <== NOT EXECUTED
rtems_disk_release(vol->dd);
free(fs_info->vhash);
free(fs_info->rhash);
rtems_set_errno_and_return_minus_one( ENOMEM );
}
fs_info->sec_buf = (uint8_t *)calloc(vol->bps, sizeof(uint8_t));
202a058: d0 14 00 00 lduh [ %l0 ], %o0 <== NOT EXECUTED
202a05c: 7f ff 78 7e call 2008254 <calloc> <== NOT EXECUTED
202a060: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
202a064: d0 24 20 8c st %o0, [ %l0 + 0x8c ] <== NOT EXECUTED
if (fs_info->sec_buf == NULL)
202a068: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202a06c: 02 80 00 a8 be 202a30c <fat_init_volume_info+0x66c> <== NOT EXECUTED
202a070: b0 10 20 00 clr %i0 <== NOT EXECUTED
free(fs_info->uino);
rtems_set_errno_and_return_minus_one( ENOMEM );
}
return RC_OK;
}
202a074: 81 c7 e0 08 ret <== NOT EXECUTED
202a078: 81 e8 00 00 restore <== NOT EXECUTED
}
/* Evaluate boot record */
vol->bps = FAT_GET_BR_BYTES_PER_SECTOR(boot_rec);
if ( (vol->bps != 512) &&
202a07c: 22 bf ff 3a be,a 2029d64 <fat_init_volume_info+0xc4> <== NOT EXECUTED
202a080: 83 30 60 19 srl %g1, 0x19, %g1 <== NOT EXECUTED
202a084: 80 a0 a8 00 cmp %g2, 0x800 <== NOT EXECUTED
202a088: 02 80 00 05 be 202a09c <fat_init_volume_info+0x3fc> <== NOT EXECUTED
202a08c: 07 00 00 04 sethi %hi(0x1000), %g3 <== NOT EXECUTED
202a090: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
202a094: 32 80 00 96 bne,a 202a2ec <fat_init_volume_info+0x64c> <== NOT EXECUTED
202a098: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EINVAL );
}
for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
202a09c: c0 2c 20 03 clrb [ %l0 + 3 ] <== NOT EXECUTED
202a0a0: 10 bf ff 34 b 2029d70 <fat_init_volume_info+0xd0> <== NOT EXECUTED
202a0a4: 83 30 60 19 srl %g1, 0x19, %g1 <== NOT EXECUTED
vol->mask = FAT_FAT12_MASK;
vol->eoc_val = FAT_FAT12_EOC;
}
else
{
if ( vol->data_cls < FAT_FAT16_MAX_CLN)
202a0a8: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
202a0ac: 84 10 63 f4 or %g1, 0x3f4, %g2 ! fff4 <PROM_START+0xfff4> <== NOT EXECUTED
202a0b0: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED
202a0b4: 08 80 00 7f bleu 202a2b0 <fat_init_volume_info+0x610> <== NOT EXECUTED
202a0b8: 84 10 63 f8 or %g1, 0x3f8, %g2 <== NOT EXECUTED
vol->eoc_val = FAT_FAT16_EOC;
}
else
{
vol->type = FAT_FAT32;
vol->mask = FAT_FAT32_MASK;
202a0bc: 03 03 ff ff sethi %hi(0xffffc00), %g1 <== NOT EXECUTED
vol->eoc_val = FAT_FAT32_EOC;
202a0c0: 84 10 63 f8 or %g1, 0x3f8, %g2 ! ffffff8 <RAM_END+0xdbffff8><== NOT EXECUTED
vol->eoc_val = FAT_FAT16_EOC;
}
else
{
vol->type = FAT_FAT32;
vol->mask = FAT_FAT32_MASK;
202a0c4: 82 10 63 ff or %g1, 0x3ff, %g1 <== NOT EXECUTED
vol->eoc_val = FAT_FAT32_EOC;
202a0c8: c4 24 20 10 st %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
vol->mask = FAT_FAT16_MASK;
vol->eoc_val = FAT_FAT16_EOC;
}
else
{
vol->type = FAT_FAT32;
202a0cc: 84 10 20 04 mov 4, %g2 <== NOT EXECUTED
vol->mask = FAT_FAT32_MASK;
202a0d0: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
vol->mask = FAT_FAT16_MASK;
vol->eoc_val = FAT_FAT16_EOC;
}
else
{
vol->type = FAT_FAT32;
202a0d4: c4 2c 20 0a stb %g2, [ %l0 + 0xa ] <== NOT EXECUTED
}
}
if (vol->type == FAT_FAT32)
{
vol->rdir_cl = FAT_GET_BR_FAT32_ROOT_CLUSTER(boot_rec);
202a0d8: c8 0f bf 75 ldub [ %fp + -139 ], %g4 <== NOT EXECUTED
202a0dc: c4 0f bf 76 ldub [ %fp + -138 ], %g2 <== NOT EXECUTED
202a0e0: c6 0f bf 74 ldub [ %fp + -140 ], %g3 <== NOT EXECUTED
202a0e4: c2 0f bf 77 ldub [ %fp + -137 ], %g1 <== NOT EXECUTED
202a0e8: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
202a0ec: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
202a0f0: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
202a0f4: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
202a0f8: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
202a0fc: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
202a100: c2 24 20 38 st %g1, [ %l0 + 0x38 ] <== NOT EXECUTED
vol->mirror = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_MIRROR;
202a104: c4 0f bf 71 ldub [ %fp + -143 ], %g2 <== NOT EXECUTED
202a108: c2 0f bf 70 ldub [ %fp + -144 ], %g1 <== NOT EXECUTED
202a10c: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
202a110: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
202a114: 82 08 7f 80 and %g1, -128, %g1 <== NOT EXECUTED
if (vol->mirror)
202a118: 80 88 60 80 btst 0x80, %g1 <== NOT EXECUTED
202a11c: 02 80 00 6b be 202a2c8 <fat_init_volume_info+0x628> <== NOT EXECUTED
202a120: c2 2c 20 48 stb %g1, [ %l0 + 0x48 ] <== NOT EXECUTED
vol->afat = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_FAT_NUM;
202a124: c2 0f bf 70 ldub [ %fp + -144 ], %g1 <== NOT EXECUTED
202a128: 82 08 60 0f and %g1, 0xf, %g1 <== NOT EXECUTED
202a12c: c2 2c 20 50 stb %g1, [ %l0 + 0x50 ] <== NOT EXECUTED
else
vol->afat = 0;
vol->info_sec = FAT_GET_BR_FAT32_FS_INFO_SECTOR(boot_rec);
202a130: c2 0f bf 79 ldub [ %fp + -135 ], %g1 <== NOT EXECUTED
202a134: c4 0f bf 78 ldub [ %fp + -136 ], %g2 <== NOT EXECUTED
202a138: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
202a13c: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
202a140: c2 34 20 3c sth %g1, [ %l0 + 0x3c ] <== NOT EXECUTED
if( vol->info_sec == 0 )
202a144: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
202a148: 93 30 60 10 srl %g1, 0x10, %o1 <== NOT EXECUTED
202a14c: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
202a150: 02 80 00 66 be 202a2e8 <fat_init_volume_info+0x648> <== NOT EXECUTED
202a154: a4 07 bf f0 add %fp, -16, %l2 <== NOT EXECUTED
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EINVAL );
}
else
{
ret = _fat_block_read(mt_entry, vol->info_sec , 0,
202a158: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202a15c: 94 10 20 00 clr %o2 <== NOT EXECUTED
202a160: 96 10 20 04 mov 4, %o3 <== NOT EXECUTED
202a164: 7f ff fe ad call 2029c18 <_fat_block_read> <== NOT EXECUTED
202a168: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
FAT_FSI_LEADSIG_SIZE, fs_info_sector);
if ( ret < 0 )
202a16c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202a170: 06 80 00 b8 bl 202a450 <fat_init_volume_info+0x7b0> <== NOT EXECUTED
202a174: c2 0f bf f3 ldub [ %fp + -13 ], %g1 <== NOT EXECUTED
{
rtems_disk_release(vol->dd);
return -1;
}
if (FAT_GET_FSINFO_LEAD_SIGNATURE(fs_info_sector) !=
202a178: c8 0f bf f1 ldub [ %fp + -15 ], %g4 <== NOT EXECUTED
202a17c: c4 0f bf f2 ldub [ %fp + -14 ], %g2 <== NOT EXECUTED
202a180: c6 0f bf f0 ldub [ %fp + -16 ], %g3 <== NOT EXECUTED
202a184: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
202a188: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
202a18c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
202a190: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
202a194: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
202a198: 84 10 80 01 or %g2, %g1, %g2 <== NOT EXECUTED
202a19c: 03 10 58 54 sethi %hi(0x41615000), %g1 <== NOT EXECUTED
202a1a0: 82 10 62 52 or %g1, 0x252, %g1 ! 41615252 <RAM_END+0x3f215252><== NOT EXECUTED
202a1a4: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
202a1a8: 12 80 00 71 bne 202a36c <fat_init_volume_info+0x6cc> <== NOT EXECUTED
202a1ac: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
rtems_disk_release(vol->dd);
rtems_set_errno_and_return_minus_one( EINVAL );
}
else
{
ret = _fat_block_read(mt_entry, vol->info_sec , FAT_FSI_INFO,
202a1b0: d2 14 20 3c lduh [ %l0 + 0x3c ], %o1 <== NOT EXECUTED
202a1b4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202a1b8: 94 10 21 e4 mov 0x1e4, %o2 <== NOT EXECUTED
202a1bc: 7f ff fe 97 call 2029c18 <_fat_block_read> <== NOT EXECUTED
202a1c0: 96 10 20 0c mov 0xc, %o3 <== NOT EXECUTED
FAT_USEFUL_INFO_SIZE, fs_info_sector);
if ( ret < 0 )
202a1c4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202a1c8: 06 80 00 87 bl 202a3e4 <fat_init_volume_info+0x744> <== NOT EXECUTED
202a1cc: c6 0f bf f4 ldub [ %fp + -12 ], %g3 <== NOT EXECUTED
_fat_block_release(mt_entry);
rtems_disk_release(vol->dd);
return -1;
}
vol->free_cls = FAT_GET_FSINFO_FREE_CLUSTER_COUNT(fs_info_sector);
202a1d0: c8 0f bf f5 ldub [ %fp + -11 ], %g4 <== NOT EXECUTED
202a1d4: c4 0f bf f6 ldub [ %fp + -10 ], %g2 <== NOT EXECUTED
202a1d8: c2 0f bf f7 ldub [ %fp + -9 ], %g1 <== NOT EXECUTED
202a1dc: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
202a1e0: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
202a1e4: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
202a1e8: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
202a1ec: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
202a1f0: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
202a1f4: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
vol->next_cl = FAT_GET_FSINFO_NEXT_FREE_CLUSTER(fs_info_sector);
202a1f8: c8 0f bf f9 ldub [ %fp + -7 ], %g4 <== NOT EXECUTED
202a1fc: c4 0f bf fa ldub [ %fp + -6 ], %g2 <== NOT EXECUTED
202a200: c6 0f bf f8 ldub [ %fp + -8 ], %g3 <== NOT EXECUTED
202a204: c2 0f bf fb ldub [ %fp + -5 ], %g1 <== NOT EXECUTED
202a208: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
202a20c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
202a210: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
202a214: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
202a218: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
202a21c: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
rc = fat_fat32_update_fsinfo_sector(mt_entry, 0xFFFFFFFF,
202a220: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_disk_release(vol->dd);
return -1;
}
vol->free_cls = FAT_GET_FSINFO_FREE_CLUSTER_COUNT(fs_info_sector);
vol->next_cl = FAT_GET_FSINFO_NEXT_FREE_CLUSTER(fs_info_sector);
202a224: c2 24 20 44 st %g1, [ %l0 + 0x44 ] <== NOT EXECUTED
rc = fat_fat32_update_fsinfo_sector(mt_entry, 0xFFFFFFFF,
202a228: 92 10 3f ff mov -1, %o1 <== NOT EXECUTED
202a22c: 7f ff fd b7 call 2029908 <fat_fat32_update_fsinfo_sector> <== NOT EXECUTED
202a230: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
0xFFFFFFFF);
if ( rc != RC_OK )
202a234: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
202a238: 02 bf ff 54 be 2029f88 <fat_init_volume_info+0x2e8> <== NOT EXECUTED
202a23c: 01 00 00 00 nop <== NOT EXECUTED
int
_fat_block_release(
rtems_filesystem_mount_table_entry_t *mt_entry)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
return fat_buf_release(fs_info);
202a240: 7f ff fc 94 call 2029490 <fat_buf_release> <== NOT EXECUTED
202a244: d0 04 60 34 ld [ %l1 + 0x34 ], %o0 <== NOT EXECUTED
rc = fat_fat32_update_fsinfo_sector(mt_entry, 0xFFFFFFFF,
0xFFFFFFFF);
if ( rc != RC_OK )
{
_fat_block_release(mt_entry);
rtems_disk_release(vol->dd);
202a248: 7f ff 74 7d call 200743c <rtems_disk_release> <== NOT EXECUTED
202a24c: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
return rc;
202a250: 81 c7 e0 08 ret <== NOT EXECUTED
202a254: 81 e8 00 00 restore <== NOT EXECUTED
vol->rdir_loc = vol->fat_loc + vol->fats * vol->fat_length;
if ( (FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec)) != 0)
vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec);
else
vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM32(boot_rec);
202a258: c6 0f bf 6a ldub [ %fp + -150 ], %g3 <== NOT EXECUTED
202a25c: c4 0f bf 68 ldub [ %fp + -152 ], %g2 <== NOT EXECUTED
202a260: c2 0f bf 6b ldub [ %fp + -149 ], %g1 <== NOT EXECUTED
202a264: 91 2a 20 08 sll %o0, 8, %o0 <== NOT EXECUTED
202a268: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
202a26c: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
202a270: 90 12 00 03 or %o0, %g3, %o0 <== NOT EXECUTED
202a274: 90 12 00 02 or %o0, %g2, %o0 <== NOT EXECUTED
202a278: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
202a27c: 10 bf ff 31 b 2029f40 <fat_init_volume_info+0x2a0> <== NOT EXECUTED
202a280: d0 24 20 2c st %o0, [ %l0 + 0x2c ] <== NOT EXECUTED
vol->rdir_size = vol->rdir_secs << vol->sec_log2;
if ( (FAT_GET_BR_SECTORS_PER_FAT(boot_rec)) != 0)
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT(boot_rec);
else
vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT32(boot_rec);
202a284: c8 0f bf 6e ldub [ %fp + -146 ], %g4 <== NOT EXECUTED
202a288: c6 0f bf 6c ldub [ %fp + -148 ], %g3 <== NOT EXECUTED
202a28c: c4 0f bf 6f ldub [ %fp + -145 ], %g2 <== NOT EXECUTED
202a290: 91 2a 20 08 sll %o0, 8, %o0 <== NOT EXECUTED
202a294: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
202a298: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
202a29c: 90 12 00 04 or %o0, %g4, %o0 <== NOT EXECUTED
202a2a0: 90 12 00 03 or %o0, %g3, %o0 <== NOT EXECUTED
202a2a4: 90 12 00 02 or %o0, %g2, %o0 <== NOT EXECUTED
202a2a8: 10 bf ff 0f b 2029ee4 <fat_init_volume_info+0x244> <== NOT EXECUTED
202a2ac: d0 24 20 18 st %o0, [ %l0 + 0x18 ] <== NOT EXECUTED
else
{
if ( vol->data_cls < FAT_FAT16_MAX_CLN)
{
vol->type = FAT_FAT16;
vol->mask = FAT_FAT16_MASK;
202a2b0: 82 10 63 ff or %g1, 0x3ff, %g1 <== NOT EXECUTED
vol->eoc_val = FAT_FAT16_EOC;
202a2b4: c4 24 20 10 st %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
else
{
if ( vol->data_cls < FAT_FAT16_MAX_CLN)
{
vol->type = FAT_FAT16;
vol->mask = FAT_FAT16_MASK;
202a2b8: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
}
else
{
if ( vol->data_cls < FAT_FAT16_MAX_CLN)
{
vol->type = FAT_FAT16;
202a2bc: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED
202a2c0: 10 bf ff 2c b 2029f70 <fat_init_volume_info+0x2d0> <== NOT EXECUTED
202a2c4: c4 2c 20 0a stb %g2, [ %l0 + 0xa ] <== NOT EXECUTED
vol->mirror = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_MIRROR;
if (vol->mirror)
vol->afat = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_FAT_NUM;
else
vol->afat = 0;
202a2c8: 10 bf ff 9a b 202a130 <fat_init_volume_info+0x490> <== NOT EXECUTED
202a2cc: c0 2c 20 50 clrb [ %l0 + 0x50 ] <== NOT EXECUTED
if (rc == -1)
return rc;
/* Must be a block device. */
if (!S_ISBLK(stat_buf.st_mode))
rtems_set_errno_and_return_minus_one(ENOTTY);
202a2d0: 40 00 80 6c call 204a480 <__errno> <== NOT EXECUTED
202a2d4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202a2d8: 82 10 20 19 mov 0x19, %g1 <== NOT EXECUTED
202a2dc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a2e0: 81 c7 e0 08 ret <== NOT EXECUTED
202a2e4: 81 e8 00 00 restore <== NOT EXECUTED
vol->afat = 0;
vol->info_sec = FAT_GET_BR_FAT32_FS_INFO_SECTOR(boot_rec);
if( vol->info_sec == 0 )
{
rtems_disk_release(vol->dd);
202a2e8: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a2ec: 7f ff 74 54 call 200743c <rtems_disk_release> <== NOT EXECUTED
202a2f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
202a2f4: 40 00 80 63 call 204a480 <__errno> <== NOT EXECUTED
202a2f8: 01 00 00 00 nop <== NOT EXECUTED
202a2fc: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
202a300: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a304: 81 c7 e0 08 ret <== NOT EXECUTED
202a308: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
}
fs_info->sec_buf = (uint8_t *)calloc(vol->bps, sizeof(uint8_t));
if (fs_info->sec_buf == NULL)
{
rtems_disk_release(vol->dd);
202a30c: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a310: 7f ff 74 4b call 200743c <rtems_disk_release> <== NOT EXECUTED
202a314: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free(fs_info->vhash);
202a318: 7f ff 79 71 call 20088dc <free> <== NOT EXECUTED
202a31c: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
free(fs_info->rhash);
202a320: 7f ff 79 6f call 20088dc <free> <== NOT EXECUTED
202a324: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED
free(fs_info->uino);
202a328: 7f ff 79 6d call 20088dc <free> <== NOT EXECUTED
202a32c: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
202a330: 40 00 80 54 call 204a480 <__errno> <== NOT EXECUTED
202a334: 01 00 00 00 nop <== NOT EXECUTED
202a338: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
202a33c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
return RC_OK;
}
202a340: 81 c7 e0 08 ret <== NOT EXECUTED
202a344: 81 e8 00 00 restore <== NOT EXECUTED
memcpy( boot_rec, block->buffer, FAT_MAX_BPB_SIZE);
sc = rtems_bdbuf_release( block);
if (sc != RTEMS_SUCCESSFUL)
{
rtems_disk_release(vol->dd);
202a348: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a34c: 7f ff 74 3c call 200743c <rtems_disk_release> <== NOT EXECUTED
202a350: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
202a354: 40 00 80 4b call 204a480 <__errno> <== NOT EXECUTED
202a358: 01 00 00 00 nop <== NOT EXECUTED
202a35c: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
202a360: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a364: 81 c7 e0 08 ret <== NOT EXECUTED
202a368: 81 e8 00 00 restore <== NOT EXECUTED
int
_fat_block_release(
rtems_filesystem_mount_table_entry_t *mt_entry)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
return fat_buf_release(fs_info);
202a36c: d0 04 60 34 ld [ %l1 + 0x34 ], %o0 <== NOT EXECUTED
202a370: 7f ff fc 48 call 2029490 <fat_buf_release> <== NOT EXECUTED
202a374: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
if (FAT_GET_FSINFO_LEAD_SIGNATURE(fs_info_sector) !=
FAT_FSINFO_LEAD_SIGNATURE_VALUE)
{
_fat_block_release(mt_entry);
rtems_disk_release(vol->dd);
202a378: 7f ff 74 31 call 200743c <rtems_disk_release> <== NOT EXECUTED
202a37c: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
202a380: 40 00 80 40 call 204a480 <__errno> <== NOT EXECUTED
202a384: 01 00 00 00 nop <== NOT EXECUTED
202a388: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
202a38c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a390: 81 c7 e0 08 ret <== NOT EXECUTED
202a394: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOTTY);
/* check that device is registred as block device and lock it */
vol->dd = rtems_disk_obtain(stat_buf.st_rdev);
if (vol->dd == NULL)
rtems_set_errno_and_return_minus_one(EIO);
202a398: 40 00 80 3a call 204a480 <__errno> <== NOT EXECUTED
202a39c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202a3a0: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
202a3a4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a3a8: 81 c7 e0 08 ret <== NOT EXECUTED
202a3ac: 81 e8 00 00 restore <== NOT EXECUTED
fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;
fs_info->index = 0;
fs_info->uino = (char *)calloc(fs_info->uino_pool_size, sizeof(char));
if ( fs_info->uino == NULL )
{
rtems_disk_release(vol->dd);
202a3b0: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a3b4: 7f ff 74 22 call 200743c <rtems_disk_release> <== NOT EXECUTED
202a3b8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free(fs_info->vhash);
202a3bc: 7f ff 79 48 call 20088dc <free> <== NOT EXECUTED
202a3c0: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
free(fs_info->rhash);
202a3c4: 7f ff 79 46 call 20088dc <free> <== NOT EXECUTED
202a3c8: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
202a3cc: 40 00 80 2d call 204a480 <__errno> <== NOT EXECUTED
202a3d0: 01 00 00 00 nop <== NOT EXECUTED
202a3d4: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
202a3d8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a3dc: 81 c7 e0 08 ret <== NOT EXECUTED
202a3e0: 81 e8 00 00 restore <== NOT EXECUTED
int
_fat_block_release(
rtems_filesystem_mount_table_entry_t *mt_entry)
{
fat_fs_info_t *fs_info = mt_entry->fs_info;
return fat_buf_release(fs_info);
202a3e4: d0 04 60 34 ld [ %l1 + 0x34 ], %o0 <== NOT EXECUTED
202a3e8: 7f ff fc 2a call 2029490 <fat_buf_release> <== NOT EXECUTED
202a3ec: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
ret = _fat_block_read(mt_entry, vol->info_sec , FAT_FSI_INFO,
FAT_USEFUL_INFO_SIZE, fs_info_sector);
if ( ret < 0 )
{
_fat_block_release(mt_entry);
rtems_disk_release(vol->dd);
202a3f0: 7f ff 74 13 call 200743c <rtems_disk_release> <== NOT EXECUTED
202a3f4: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
return -1;
202a3f8: 81 c7 e0 08 ret <== NOT EXECUTED
202a3fc: 81 e8 00 00 restore <== NOT EXECUTED
rtems_chain_initialize_empty(fs_info->vhash + i);
fs_info->rhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
if ( fs_info->rhash == NULL )
{
rtems_disk_release(vol->dd);
202a400: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a404: 7f ff 74 0e call 200743c <rtems_disk_release> <== NOT EXECUTED
202a408: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free(fs_info->vhash);
202a40c: 7f ff 79 34 call 20088dc <free> <== NOT EXECUTED
202a410: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
202a414: 40 00 80 1b call 204a480 <__errno> <== NOT EXECUTED
202a418: 01 00 00 00 nop <== NOT EXECUTED
202a41c: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
202a420: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a424: 81 c7 e0 08 ret <== NOT EXECUTED
202a428: 81 e8 00 00 restore <== NOT EXECUTED
/* set up collection of fat-files fd */
fs_info->vhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
if ( fs_info->vhash == NULL )
{
rtems_disk_release(vol->dd);
202a42c: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a430: 7f ff 74 03 call 200743c <rtems_disk_release> <== NOT EXECUTED
202a434: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOMEM );
202a438: 40 00 80 12 call 204a480 <__errno> <== NOT EXECUTED
202a43c: 01 00 00 00 nop <== NOT EXECUTED
202a440: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
202a444: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202a448: 81 c7 e0 08 ret <== NOT EXECUTED
202a44c: 81 e8 00 00 restore <== NOT EXECUTED
{
ret = _fat_block_read(mt_entry, vol->info_sec , 0,
FAT_FSI_LEADSIG_SIZE, fs_info_sector);
if ( ret < 0 )
{
rtems_disk_release(vol->dd);
202a450: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
202a454: 7f ff 73 fa call 200743c <rtems_disk_release> <== NOT EXECUTED
202a458: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return -1;
202a45c: 81 c7 e0 08 ret <== NOT EXECUTED
202a460: 81 e8 00 00 restore <== NOT EXECUTED
02029384 <fat_ino_is_unique>:
inline bool
fat_ino_is_unique(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t ino
)
{
2029384: c2 02 20 34 ld [ %o0 + 0x34 ], %g1 <== NOT EXECUTED
2029388: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 <== NOT EXECUTED
202938c: 80 a2 40 01 cmp %o1, %g1 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
return (ino >= fs_info->uino_base);
}
2029390: 81 c3 e0 08 retl <== NOT EXECUTED
2029394: 90 60 3f ff subx %g0, -1, %o0 <== NOT EXECUTED
020454f4 <fat_scan_fat_for_free_clusters>:
uint32_t *chain,
uint32_t count,
uint32_t *cls_added,
uint32_t *last_cl
)
{
20454f4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
20454f8: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
uint32_t cl4find = 2;
uint32_t next_cln = 0;
20454fc: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t save_cln = 0;
uint32_t data_cls_val = fs_info->vol.data_cls + 2;
2045500: e8 04 60 34 ld [ %l1 + 0x34 ], %l4 <== NOT EXECUTED
uint32_t i = 2;
*cls_added = 0;
2045504: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
uint32_t *chain,
uint32_t count,
uint32_t *cls_added,
uint32_t *last_cl
)
{
2045508: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
uint32_t data_cls_val = fs_info->vol.data_cls + 2;
uint32_t i = 2;
*cls_added = 0;
if (count == 0)
204550c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2045510: 02 80 00 47 be 204562c <fat_scan_fat_for_free_clusters+0x138><== NOT EXECUTED
2045514: b0 10 20 00 clr %i0 <== NOT EXECUTED
return rc;
if (fs_info->vol.next_cl != FAT_UNDEFINED_VALUE)
2045518: e4 04 60 44 ld [ %l1 + 0x44 ], %l2 <== NOT EXECUTED
204551c: 80 a4 bf ff cmp %l2, -1 <== NOT EXECUTED
2045520: 22 80 00 02 be,a 2045528 <fat_scan_fat_for_free_clusters+0x34><== NOT EXECUTED
2045524: a4 10 20 02 mov 2, %l2 <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t cl4find = 2;
uint32_t next_cln = 0;
uint32_t save_cln = 0;
uint32_t data_cls_val = fs_info->vol.data_cls + 2;
2045528: a8 05 20 02 add %l4, 2, %l4 <== NOT EXECUTED
/*
* fs_info->vol.data_cls is exactly the count of data clusters
* starting at cluster 2, so the maximum valid cluster number is
* (fs_info->vol.data_cls + 1)
*/
while (i < data_cls_val)
204552c: 80 a5 20 02 cmp %l4, 2 <== NOT EXECUTED
2045530: 08 80 00 41 bleu 2045634 <fat_scan_fat_for_free_clusters+0x140><== NOT EXECUTED
2045534: ac 10 20 00 clr %l6 <== NOT EXECUTED
2045538: a6 10 20 02 mov 2, %l3 <== NOT EXECUTED
204553c: 10 80 00 17 b 2045598 <fat_scan_fat_for_free_clusters+0xa4><== NOT EXECUTED
2045540: aa 07 bf fc add %fp, -4, %l5 <== NOT EXECUTED
* wouldn't work properly
*/
if (*cls_added == 0)
{
*chain = cl4find;
rc = fat_set_fat_cluster(mt_entry, cl4find, FAT_GENFAT_EOC);
2045544: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2045548: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
204554c: 7f ff fe 69 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
2045550: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
2045554: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2045558: 12 80 00 59 bne 20456bc <fat_scan_fat_for_free_clusters+0x1c8><== NOT EXECUTED
204555c: 01 00 00 00 nop <== NOT EXECUTED
return rc;
}
}
save_cln = cl4find;
(*cls_added)++;
2045560: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
2045564: 82 00 60 01 inc %g1 <== NOT EXECUTED
/* have we satisfied request ? */
if (*cls_added == count)
2045568: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED
204556c: 02 80 00 47 be 2045688 <fat_scan_fat_for_free_clusters+0x194><== NOT EXECUTED
2045570: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
fs_info->vol.next_cl = save_cln;
if (fs_info->vol.free_cls != 0xFFFFFFFF)
fs_info->vol.free_cls -= (*cls_added);
*last_cl = save_cln;
fat_buf_release(fs_info);
return rc;
2045574: ac 10 00 12 mov %l2, %l6 <== NOT EXECUTED
}
}
i++;
cl4find++;
2045578: a4 04 a0 01 inc %l2 <== NOT EXECUTED
if (cl4find >= data_cls_val)
204557c: 80 a5 00 12 cmp %l4, %l2 <== NOT EXECUTED
2045580: 18 80 00 03 bgu 204558c <fat_scan_fat_for_free_clusters+0x98><== NOT EXECUTED
2045584: a6 04 e0 01 inc %l3 <== NOT EXECUTED
2045588: a4 10 20 02 mov 2, %l2 <== NOT EXECUTED
/*
* fs_info->vol.data_cls is exactly the count of data clusters
* starting at cluster 2, so the maximum valid cluster number is
* (fs_info->vol.data_cls + 1)
*/
while (i < data_cls_val)
204558c: 80 a5 00 13 cmp %l4, %l3 <== NOT EXECUTED
2045590: 28 80 00 2a bleu,a 2045638 <fat_scan_fat_for_free_clusters+0x144><== NOT EXECUTED
2045594: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 <== NOT EXECUTED
{
rc = fat_get_fat_cluster(mt_entry, cl4find, &next_cln);
2045598: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204559c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20455a0: 7f ff ff 19 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
20455a4: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
20455a8: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
20455ac: 32 80 00 2f bne,a 2045668 <fat_scan_fat_for_free_clusters+0x174><== NOT EXECUTED
20455b0: c4 06 c0 00 ld [ %i3 ], %g2 <== NOT EXECUTED
if (*cls_added != 0)
fat_free_fat_clusters_chain(mt_entry, (*chain));
return rc;
}
if (next_cln == FAT_GENFAT_FREE)
20455b4: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
20455b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20455bc: 32 bf ff f0 bne,a 204557c <fat_scan_fat_for_free_clusters+0x88><== NOT EXECUTED
20455c0: a4 04 a0 01 inc %l2 <== NOT EXECUTED
/*
* We are enforced to process allocation of the first free cluster
* by separate 'if' statement because otherwise undo function
* wouldn't work properly
*/
if (*cls_added == 0)
20455c4: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
20455c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20455cc: 22 bf ff de be,a 2045544 <fat_scan_fat_for_free_clusters+0x50><== NOT EXECUTED
20455d0: e4 26 40 00 st %l2, [ %i1 ] <== NOT EXECUTED
}
}
else
{
/* set EOC value to new allocated cluster */
rc = fat_set_fat_cluster(mt_entry, cl4find, FAT_GENFAT_EOC);
20455d4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20455d8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20455dc: 7f ff fe 45 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
20455e0: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
20455e4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20455e8: 12 80 00 23 bne 2045674 <fat_scan_fat_for_free_clusters+0x180><== NOT EXECUTED
20455ec: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
/* cleanup activity */
fat_free_fat_clusters_chain(mt_entry, (*chain));
return rc;
}
rc = fat_set_fat_cluster(mt_entry, save_cln, cl4find);
20455f0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20455f4: 7f ff fe 3f call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
20455f8: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
20455fc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2045600: 22 bf ff d9 be,a 2045564 <fat_scan_fat_for_free_clusters+0x70><== NOT EXECUTED
2045604: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
{
/* cleanup activity */
fat_free_fat_clusters_chain(mt_entry, (*chain));
2045608: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
204560c: 7f ff ff 82 call 2045414 <fat_free_fat_clusters_chain> <== NOT EXECUTED
2045610: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
/* trying to save last allocated cluster for future use */
fat_set_fat_cluster(mt_entry, cl4find, FAT_GENFAT_FREE);
2045614: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2045618: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
204561c: 7f ff fe 35 call 2044ef0 <fat_set_fat_cluster> <== NOT EXECUTED
2045620: 94 10 20 00 clr %o2 <== NOT EXECUTED
fat_buf_release(fs_info);
2045624: 7f ff 8f 9b call 2029490 <fat_buf_release> <== NOT EXECUTED
2045628: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return rc;
204562c: 81 c7 e0 08 ret <== NOT EXECUTED
2045630: 81 e8 00 00 restore <== NOT EXECUTED
if (cl4find >= data_cls_val)
cl4find = 2;
}
fs_info->vol.next_cl = save_cln;
if (fs_info->vol.free_cls != 0xFFFFFFFF)
2045634: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 <== NOT EXECUTED
2045638: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
204563c: 02 80 00 05 be 2045650 <fat_scan_fat_for_free_clusters+0x15c><== NOT EXECUTED
2045640: ec 24 60 44 st %l6, [ %l1 + 0x44 ] <== NOT EXECUTED
fs_info->vol.free_cls -= (*cls_added);
2045644: c4 06 c0 00 ld [ %i3 ], %g2 <== NOT EXECUTED
2045648: 82 20 40 02 sub %g1, %g2, %g1 <== NOT EXECUTED
204564c: c2 24 60 40 st %g1, [ %l1 + 0x40 ] <== NOT EXECUTED
*last_cl = save_cln;
2045650: ec 27 00 00 st %l6, [ %i4 ] <== NOT EXECUTED
fat_buf_release(fs_info);
2045654: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2045658: 7f ff 8f 8e call 2029490 <fat_buf_release> <== NOT EXECUTED
204565c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
}
2045660: 81 c7 e0 08 ret <== NOT EXECUTED
2045664: 81 e8 00 00 restore <== NOT EXECUTED
while (i < data_cls_val)
{
rc = fat_get_fat_cluster(mt_entry, cl4find, &next_cln);
if ( rc != RC_OK )
{
if (*cls_added != 0)
2045668: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
204566c: 02 bf ff f0 be 204562c <fat_scan_fat_for_free_clusters+0x138><== NOT EXECUTED
2045670: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
/* set EOC value to new allocated cluster */
rc = fat_set_fat_cluster(mt_entry, cl4find, FAT_GENFAT_EOC);
if ( rc != RC_OK )
{
/* cleanup activity */
fat_free_fat_clusters_chain(mt_entry, (*chain));
2045674: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
2045678: 7f ff ff 67 call 2045414 <fat_free_fat_clusters_chain> <== NOT EXECUTED
204567c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
2045680: 81 c7 e0 08 ret <== NOT EXECUTED
2045684: 81 e8 00 00 restore <== NOT EXECUTED
/* have we satisfied request ? */
if (*cls_added == count)
{
fs_info->vol.next_cl = save_cln;
if (fs_info->vol.free_cls != 0xFFFFFFFF)
2045688: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 <== NOT EXECUTED
204568c: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
2045690: 02 80 00 05 be 20456a4 <fat_scan_fat_for_free_clusters+0x1b0><== NOT EXECUTED
2045694: e4 24 60 44 st %l2, [ %l1 + 0x44 ] <== NOT EXECUTED
fs_info->vol.free_cls -= (*cls_added);
2045698: c4 06 c0 00 ld [ %i3 ], %g2 <== NOT EXECUTED
204569c: 82 20 40 02 sub %g1, %g2, %g1 <== NOT EXECUTED
20456a0: c2 24 60 40 st %g1, [ %l1 + 0x40 ] <== NOT EXECUTED
*last_cl = save_cln;
20456a4: e4 27 00 00 st %l2, [ %i4 ] <== NOT EXECUTED
fat_buf_release(fs_info);
20456a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20456ac: 7f ff 8f 79 call 2029490 <fat_buf_release> <== NOT EXECUTED
20456b0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return rc;
20456b4: 81 c7 e0 08 ret <== NOT EXECUTED
20456b8: 81 e8 00 00 restore <== NOT EXECUTED
20456bc: 81 c7 e0 08 ret <== NOT EXECUTED
20456c0: 81 e8 00 00 restore <== NOT EXECUTED
02044ef0 <fat_set_fat_cluster>:
fat_set_fat_cluster(
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
uint32_t in_val
)
{
2044ef0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t sec = 0;
uint32_t ofs = 0;
uint16_t fat16_clv = 0;
uint32_t fat32_clv = 0;
rtems_bdbuf_buffer *block0 = NULL;
2044ef4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
2044ef8: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
2044efc: 08 80 00 93 bleu 2045148 <fat_set_fat_cluster+0x258> <== NOT EXECUTED
2044f00: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
2044f04: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
2044f08: 82 00 60 01 inc %g1 <== NOT EXECUTED
2044f0c: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2044f10: 18 80 00 8e bgu 2045148 <fat_set_fat_cluster+0x258> <== NOT EXECUTED
2044f14: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
2044f18: c2 0c 20 0a ldub [ %l0 + 0xa ], %g1 <== NOT EXECUTED
2044f1c: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2044f20: 12 80 00 24 bne 2044fb0 <fat_set_fat_cluster+0xc0> <== NOT EXECUTED
2044f24: e8 0c 20 02 ldub [ %l0 + 2 ], %l4 <== NOT EXECUTED
2044f28: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2044f2c: 02 80 00 27 be 2044fc8 <fat_set_fat_cluster+0xd8> <== NOT EXECUTED
2044f30: 01 00 00 00 nop <== NOT EXECUTED
2044f34: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
2044f38: a3 2e 60 01 sll %i1, 1, %l1 <== NOT EXECUTED
2044f3c: a9 34 40 14 srl %l1, %l4, %l4 <== NOT EXECUTED
2044f40: a8 05 00 01 add %l4, %g1, %l4 <== NOT EXECUTED
fs_info->vol.afat_loc;
ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
2044f44: ea 14 00 00 lduh [ %l0 ], %l5 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &block0);
2044f48: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
2044f4c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044f50: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2044f54: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2044f58: 7f ff 91 b5 call 202962c <fat_buf_access> <== NOT EXECUTED
2044f5c: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
if (rc != RC_OK)
2044f60: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2044f64: 12 80 00 11 bne 2044fa8 <fat_set_fat_cluster+0xb8> <== NOT EXECUTED
2044f68: ab 2d 60 10 sll %l5, 0x10, %l5 <== NOT EXECUTED
return rc;
switch ( fs_info->vol.type )
2044f6c: e4 0c 20 0a ldub [ %l0 + 0xa ], %l2 <== NOT EXECUTED
2044f70: 80 a4 a0 02 cmp %l2, 2 <== NOT EXECUTED
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
fs_info->vol.afat_loc;
ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
2044f74: ab 35 60 10 srl %l5, 0x10, %l5 <== NOT EXECUTED
2044f78: aa 05 7f ff add %l5, -1, %l5 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &block0);
if (rc != RC_OK)
return rc;
switch ( fs_info->vol.type )
2044f7c: 02 80 00 18 be 2044fdc <fat_set_fat_cluster+0xec> <== NOT EXECUTED
2044f80: a2 0c 40 15 and %l1, %l5, %l1 <== NOT EXECUTED
2044f84: 80 a4 a0 04 cmp %l2, 4 <== NOT EXECUTED
2044f88: 02 80 00 3e be 2045080 <fat_set_fat_cluster+0x190> <== NOT EXECUTED
2044f8c: 80 a4 a0 01 cmp %l2, 1 <== NOT EXECUTED
2044f90: 02 80 00 1e be 2045008 <fat_set_fat_cluster+0x118> <== NOT EXECUTED
2044f94: 80 8e 60 01 btst 1, %i1 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
break;
default:
rtems_set_errno_and_return_minus_one(EIO);
2044f98: 40 00 15 3a call 204a480 <__errno> <== NOT EXECUTED
2044f9c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2044fa0: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2044fa4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
break;
}
return RC_OK;
}
2044fa8: 81 c7 e0 08 ret <== NOT EXECUTED
2044fac: 81 e8 00 00 restore <== NOT EXECUTED
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
2044fb0: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
2044fb4: a3 36 60 01 srl %i1, 1, %l1 <== NOT EXECUTED
2044fb8: a2 04 40 19 add %l1, %i1, %l1 <== NOT EXECUTED
2044fbc: a9 34 40 14 srl %l1, %l4, %l4 <== NOT EXECUTED
2044fc0: 10 bf ff e1 b 2044f44 <fat_set_fat_cluster+0x54> <== NOT EXECUTED
2044fc4: a8 05 00 01 add %l4, %g1, %l4 <== NOT EXECUTED
2044fc8: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 <== NOT EXECUTED
2044fcc: a3 2e 60 02 sll %i1, 2, %l1 <== NOT EXECUTED
2044fd0: a9 34 40 14 srl %l1, %l4, %l4 <== NOT EXECUTED
2044fd4: 10 bf ff dc b 2044f44 <fat_set_fat_cluster+0x54> <== NOT EXECUTED
2044fd8: a8 05 00 01 add %l4, %g1, %l4 <== NOT EXECUTED
}
}
break;
case FAT_FAT16:
*((uint16_t *)(block0->buffer + ofs)) =
2044fdc: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2044fe0: b5 2e a0 10 sll %i2, 0x10, %i2 <== NOT EXECUTED
2044fe4: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
2044fe8: 85 36 a0 18 srl %i2, 0x18, %g2 <== NOT EXECUTED
2044fec: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
2044ff0: b4 16 80 02 or %i2, %g2, %i2 <== NOT EXECUTED
2044ff4: f4 30 40 11 sth %i2, [ %g1 + %l1 ] <== NOT EXECUTED
}
static inline void
fat_buf_mark_modified(fat_fs_info_t *fs_info)
{
fs_info->c.modified = true;
2044ff8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2044ffc: c2 2c 20 84 stb %g1, [ %l0 + 0x84 ] <== NOT EXECUTED
2045000: 81 c7 e0 08 ret <== NOT EXECUTED
2045004: 81 e8 00 00 restore <== NOT EXECUTED
return rc;
switch ( fs_info->vol.type )
{
case FAT_FAT12:
if ( FAT_CLUSTER_IS_ODD(cln) )
2045008: 02 80 00 35 be 20450dc <fat_set_fat_cluster+0x1ec> <== NOT EXECUTED
204500c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
{
fat16_clv = ((uint16_t )in_val) << FAT_FAT12_SHIFT;
*((uint8_t *)(block0->buffer + ofs)) =
(*((uint8_t *)(block0->buffer + ofs))) & 0x0F;
*((uint8_t *)(block0->buffer + ofs)) =
2045010: 85 2e a0 04 sll %i2, 4, %g2 <== NOT EXECUTED
case FAT_FAT12:
if ( FAT_CLUSTER_IS_ODD(cln) )
{
fat16_clv = ((uint16_t )in_val) << FAT_FAT12_SHIFT;
*((uint8_t *)(block0->buffer + ofs)) =
(*((uint8_t *)(block0->buffer + ofs))) & 0x0F;
2045014: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
{
case FAT_FAT12:
if ( FAT_CLUSTER_IS_ODD(cln) )
{
fat16_clv = ((uint16_t )in_val) << FAT_FAT12_SHIFT;
*((uint8_t *)(block0->buffer + ofs)) =
2045018: c6 08 40 11 ldub [ %g1 + %l1 ], %g3 <== NOT EXECUTED
204501c: 86 08 e0 0f and %g3, 0xf, %g3 <== NOT EXECUTED
2045020: c6 28 40 11 stb %g3, [ %g1 + %l1 ] <== NOT EXECUTED
(*((uint8_t *)(block0->buffer + ofs))) & 0x0F;
*((uint8_t *)(block0->buffer + ofs)) =
(*((uint8_t *)(block0->buffer + ofs))) |
2045024: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045028: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
{
fat16_clv = ((uint16_t )in_val) << FAT_FAT12_SHIFT;
*((uint8_t *)(block0->buffer + ofs)) =
(*((uint8_t *)(block0->buffer + ofs))) & 0x0F;
*((uint8_t *)(block0->buffer + ofs)) =
204502c: c6 08 40 11 ldub [ %g1 + %l1 ], %g3 <== NOT EXECUTED
2045030: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
2045034: c4 28 40 11 stb %g2, [ %g1 + %l1 ] <== NOT EXECUTED
(*((uint8_t *)(block0->buffer + ofs))) |
(uint8_t )(fat16_clv & 0x00FF);
fat_buf_mark_modified(fs_info);
if ( ofs == (fs_info->vol.bps - 1) )
2045038: c2 14 00 00 lduh [ %l0 ], %g1 <== NOT EXECUTED
204503c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2045040: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2045044: 02 80 00 5c be 20451b4 <fat_set_fat_cluster+0x2c4> <== NOT EXECUTED
2045048: e4 2c 20 84 stb %l2, [ %l0 + 0x84 ] <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) &= 0x00;
204504c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045050: a2 04 60 01 inc %l1 <== NOT EXECUTED
2045054: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
*((uint8_t *)(block0->buffer + ofs + 1)) =
2045058: b5 2e a0 14 sll %i2, 0x14, %i2 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) &= 0x00;
204505c: c0 28 40 11 clrb [ %g1 + %l1 ] <== NOT EXECUTED
*((uint8_t *)(block0->buffer + ofs + 1)) =
(*((uint8_t *)(block0->buffer + ofs + 1))) |
2045060: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) &= 0x00;
*((uint8_t *)(block0->buffer + ofs + 1)) =
2045064: b5 36 a0 18 srl %i2, 0x18, %i2 <== NOT EXECUTED
(*((uint8_t *)(block0->buffer + ofs + 1))) |
2045068: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) &= 0x00;
*((uint8_t *)(block0->buffer + ofs + 1)) =
204506c: c4 08 40 11 ldub [ %g1 + %l1 ], %g2 <== NOT EXECUTED
2045070: 84 10 80 1a or %g2, %i2, %g2 <== NOT EXECUTED
2045074: c4 28 40 11 stb %g2, [ %g1 + %l1 ] <== NOT EXECUTED
2045078: 81 c7 e0 08 ret <== NOT EXECUTED
204507c: 81 e8 00 00 restore <== NOT EXECUTED
case FAT_FAT32:
fat32_clv = CT_LE_L((in_val & FAT_FAT32_MASK));
*((uint32_t *)(block0->buffer + ofs)) =
(*((uint32_t *)(block0->buffer + ofs))) & (CT_LE_L(0xF0000000));
2045080: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
(uint16_t )(CT_LE_W(in_val));
fat_buf_mark_modified(fs_info);
break;
case FAT_FAT32:
fat32_clv = CT_LE_L((in_val & FAT_FAT32_MASK));
2045084: 05 3c 00 00 sethi %hi(0xf0000000), %g2 <== NOT EXECUTED
*((uint32_t *)(block0->buffer + ofs)) =
(*((uint32_t *)(block0->buffer + ofs))) & (CT_LE_L(0xF0000000));
2045088: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
*((uint32_t *)(block0->buffer + ofs)) =
204508c: 9b 2e a0 18 sll %i2, 0x18, %o5 <== NOT EXECUTED
break;
case FAT_FAT32:
fat32_clv = CT_LE_L((in_val & FAT_FAT32_MASK));
*((uint32_t *)(block0->buffer + ofs)) =
2045090: c6 00 40 11 ld [ %g1 + %l1 ], %g3 <== NOT EXECUTED
(uint16_t )(CT_LE_W(in_val));
fat_buf_mark_modified(fs_info);
break;
case FAT_FAT32:
fat32_clv = CT_LE_L((in_val & FAT_FAT32_MASK));
2045094: b4 2e 80 02 andn %i2, %g2, %i2 <== NOT EXECUTED
*((uint32_t *)(block0->buffer + ofs)) =
2045098: 86 08 e0 f0 and %g3, 0xf0, %g3 <== NOT EXECUTED
(*((uint32_t *)(block0->buffer + ofs))) & (CT_LE_L(0xF0000000));
*((uint32_t *)(block0->buffer + ofs)) =
204509c: 89 36 a0 10 srl %i2, 0x10, %g4 <== NOT EXECUTED
20450a0: 85 36 a0 18 srl %i2, 0x18, %g2 <== NOT EXECUTED
20450a4: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
20450a8: 84 13 40 02 or %o5, %g2, %g2 <== NOT EXECUTED
20450ac: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
20450b0: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
20450b4: b4 0e a0 ff and %i2, 0xff, %i2 <== NOT EXECUTED
20450b8: b5 2e a0 10 sll %i2, 0x10, %i2 <== NOT EXECUTED
20450bc: 84 10 80 1a or %g2, %i2, %g2 <== NOT EXECUTED
20450c0: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
20450c4: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
20450c8: c4 20 40 11 st %g2, [ %g1 + %l1 ] <== NOT EXECUTED
20450cc: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20450d0: c2 2c 20 84 stb %g1, [ %l0 + 0x84 ] <== NOT EXECUTED
20450d4: 81 c7 e0 08 ret <== NOT EXECUTED
20450d8: 81 e8 00 00 restore <== NOT EXECUTED
(uint8_t )((fat16_clv & 0xFF00)>>8);
}
}
else
{
fat16_clv = ((uint16_t )in_val) & FAT_FAT12_MASK;
20450dc: b4 0e af ff and %i2, 0xfff, %i2 <== NOT EXECUTED
*((uint8_t *)(block0->buffer + ofs)) &= 0x00;
20450e0: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
20450e4: c0 28 40 11 clrb [ %g1 + %l1 ] <== NOT EXECUTED
*((uint8_t *)(block0->buffer + ofs)) =
(*((uint8_t *)(block0->buffer + ofs))) |
20450e8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
20450ec: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
else
{
fat16_clv = ((uint16_t )in_val) & FAT_FAT12_MASK;
*((uint8_t *)(block0->buffer + ofs)) &= 0x00;
*((uint8_t *)(block0->buffer + ofs)) =
20450f0: c4 08 40 11 ldub [ %g1 + %l1 ], %g2 <== NOT EXECUTED
20450f4: 84 16 80 02 or %i2, %g2, %g2 <== NOT EXECUTED
20450f8: c4 28 40 11 stb %g2, [ %g1 + %l1 ] <== NOT EXECUTED
(*((uint8_t *)(block0->buffer + ofs))) |
(uint8_t )(fat16_clv & 0x00FF);
fat_buf_mark_modified(fs_info);
if ( ofs == (fs_info->vol.bps - 1) )
20450fc: c2 14 00 00 lduh [ %l0 ], %g1 <== NOT EXECUTED
2045100: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2045104: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2045108: 02 80 00 16 be 2045160 <fat_set_fat_cluster+0x270> <== NOT EXECUTED
204510c: e4 2c 20 84 stb %l2, [ %l0 + 0x84 ] <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) =
(*((uint8_t *)(block0->buffer + ofs + 1))) & 0xF0;
2045110: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045114: a2 04 60 01 inc %l1 <== NOT EXECUTED
2045118: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
*((uint8_t *)(block0->buffer + ofs+1)) =
204511c: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
}
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) =
2045120: c4 08 40 11 ldub [ %g1 + %l1 ], %g2 <== NOT EXECUTED
2045124: 84 08 bf f0 and %g2, -16, %g2 <== NOT EXECUTED
2045128: c4 28 40 11 stb %g2, [ %g1 + %l1 ] <== NOT EXECUTED
(*((uint8_t *)(block0->buffer + ofs + 1))) & 0xF0;
*((uint8_t *)(block0->buffer + ofs+1)) =
(*((uint8_t *)(block0->buffer + ofs+1))) |
204512c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045130: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
else
{
*((uint8_t *)(block0->buffer + ofs + 1)) =
(*((uint8_t *)(block0->buffer + ofs + 1))) & 0xF0;
*((uint8_t *)(block0->buffer + ofs+1)) =
2045134: c4 08 40 11 ldub [ %g1 + %l1 ], %g2 <== NOT EXECUTED
2045138: b4 10 80 1a or %g2, %i2, %i2 <== NOT EXECUTED
204513c: f4 28 40 11 stb %i2, [ %g1 + %l1 ] <== NOT EXECUTED
2045140: 81 c7 e0 08 ret <== NOT EXECUTED
2045144: 81 e8 00 00 restore <== NOT EXECUTED
uint32_t fat32_clv = 0;
rtems_bdbuf_buffer *block0 = NULL;
/* sanity check */
if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )
rtems_set_errno_and_return_minus_one(EIO);
2045148: 40 00 14 ce call 204a480 <__errno> <== NOT EXECUTED
204514c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045150: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2045154: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2045158: 81 c7 e0 08 ret <== NOT EXECUTED
204515c: 81 e8 00 00 restore <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
if ( ofs == (fs_info->vol.bps - 1) )
{
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
2045160: 92 05 20 01 add %l4, 1, %o1 <== NOT EXECUTED
2045164: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
2045168: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204516c: 7f ff 91 30 call 202962c <fat_buf_access> <== NOT EXECUTED
2045170: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
&block0);
if (rc != RC_OK)
2045174: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2045178: 12 bf ff 8c bne 2044fa8 <fat_set_fat_cluster+0xb8> <== NOT EXECUTED
204517c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
*((uint8_t *)(block0->buffer)) =
(*((uint8_t *)(block0->buffer))) & 0xF0;
*((uint8_t *)(block0->buffer)) =
2045180: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
&block0);
if (rc != RC_OK)
return rc;
*((uint8_t *)(block0->buffer)) =
(*((uint8_t *)(block0->buffer))) & 0xF0;
2045184: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
&block0);
if (rc != RC_OK)
return rc;
*((uint8_t *)(block0->buffer)) =
2045188: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
204518c: 84 08 bf f0 and %g2, -16, %g2 <== NOT EXECUTED
2045190: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
(*((uint8_t *)(block0->buffer))) & 0xF0;
*((uint8_t *)(block0->buffer)) =
(*((uint8_t *)(block0->buffer))) |
2045194: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2045198: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
return rc;
*((uint8_t *)(block0->buffer)) =
(*((uint8_t *)(block0->buffer))) & 0xF0;
*((uint8_t *)(block0->buffer)) =
204519c: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
20451a0: 84 16 80 02 or %i2, %g2, %g2 <== NOT EXECUTED
20451a4: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
20451a8: e4 2c 20 84 stb %l2, [ %l0 + 0x84 ] <== NOT EXECUTED
20451ac: 81 c7 e0 08 ret <== NOT EXECUTED
20451b0: 81 e8 00 00 restore <== NOT EXECUTED
fat_buf_mark_modified(fs_info);
if ( ofs == (fs_info->vol.bps - 1) )
{
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
20451b4: 92 05 20 01 add %l4, 1, %o1 <== NOT EXECUTED
20451b8: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
20451bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20451c0: 7f ff 91 1b call 202962c <fat_buf_access> <== NOT EXECUTED
20451c4: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
&block0);
if (rc != RC_OK)
20451c8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20451cc: 12 bf ff 77 bne 2044fa8 <fat_set_fat_cluster+0xb8> <== NOT EXECUTED
20451d0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
*((uint8_t *)(block0->buffer)) &= 0x00;
*((uint8_t *)(block0->buffer)) =
20451d4: 87 2e a0 14 sll %i2, 0x14, %g3 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
&block0);
if (rc != RC_OK)
return rc;
*((uint8_t *)(block0->buffer)) &= 0x00;
20451d8: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
*((uint8_t *)(block0->buffer)) =
20451dc: 87 30 e0 18 srl %g3, 0x18, %g3 <== NOT EXECUTED
rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
&block0);
if (rc != RC_OK)
return rc;
*((uint8_t *)(block0->buffer)) &= 0x00;
20451e0: c0 28 40 00 clrb [ %g1 ] <== NOT EXECUTED
*((uint8_t *)(block0->buffer)) =
(*((uint8_t *)(block0->buffer))) |
20451e4: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
20451e8: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
*((uint8_t *)(block0->buffer)) &= 0x00;
*((uint8_t *)(block0->buffer)) =
20451ec: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
20451f0: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
20451f4: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
20451f8: e4 2c 20 84 stb %l2, [ %l0 + 0x84 ] <== NOT EXECUTED
20451fc: 81 c7 e0 08 ret <== NOT EXECUTED
2045200: 81 e8 00 00 restore <== NOT EXECUTED
020299c8 <fat_shutdown_drive>:
* RC_OK on success, or -1 if error occured
* and errno set appropriately
*/
int
fat_shutdown_drive(rtems_filesystem_mount_table_entry_t *mt_entry)
{
20299c8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
fat_fs_info_t *fs_info = mt_entry->fs_info;
20299cc: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
int i = 0;
if (fs_info->vol.type & FAT_FAT32)
20299d0: c2 0c 20 0a ldub [ %l0 + 0xa ], %g1 <== NOT EXECUTED
20299d4: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
20299d8: 12 80 00 3a bne 2029ac0 <fat_shutdown_drive+0xf8> <== NOT EXECUTED
20299dc: a2 10 20 00 clr %l1 <== NOT EXECUTED
fs_info->vol.next_cl);
if ( rc != RC_OK )
rc = -1;
}
fat_buf_release(fs_info);
20299e0: 7f ff fe ac call 2029490 <fat_buf_release> <== NOT EXECUTED
20299e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rtems_bdbuf_syncdev(fs_info->vol.dev) != RTEMS_SUCCESSFUL)
20299e8: 7f ff 69 fc call 20041d8 <rtems_bdbuf_syncdev> <== NOT EXECUTED
20299ec: d0 1c 20 58 ldd [ %l0 + 0x58 ], %o0 <== NOT EXECUTED
20299f0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20299f4: 32 80 00 3b bne,a 2029ae0 <fat_shutdown_drive+0x118> <== NOT EXECUTED
20299f8: a2 10 3f ff mov -1, %l1 <== NOT EXECUTED
20299fc: a6 10 20 00 clr %l3 <== NOT EXECUTED
rc = -1;
for (i = 0; i < FAT_HASH_SIZE; i++)
{
rtems_chain_node *node = NULL;
rtems_chain_control *the_chain = fs_info->vhash + i;
2029a00: e4 04 20 68 ld [ %l0 + 0x68 ], %l2 <== NOT EXECUTED
while ( (node = rtems_chain_get(the_chain)) != NULL )
2029a04: 10 80 00 04 b 2029a14 <fat_shutdown_drive+0x4c> <== NOT EXECUTED
2029a08: a4 04 80 13 add %l2, %l3, %l2 <== NOT EXECUTED
free(node);
2029a0c: 7f ff 7b b4 call 20088dc <free> <== NOT EXECUTED
2029a10: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
2029a14: 7f ff 92 74 call 200e3e4 <_Chain_Get> <== NOT EXECUTED
2029a18: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
for (i = 0; i < FAT_HASH_SIZE; i++)
{
rtems_chain_node *node = NULL;
rtems_chain_control *the_chain = fs_info->vhash + i;
while ( (node = rtems_chain_get(the_chain)) != NULL )
2029a1c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029a20: 12 bf ff fb bne 2029a0c <fat_shutdown_drive+0x44> <== NOT EXECUTED
2029a24: 01 00 00 00 nop <== NOT EXECUTED
2029a28: a6 04 e0 0c add %l3, 0xc, %l3 <== NOT EXECUTED
fat_buf_release(fs_info);
if (rtems_bdbuf_syncdev(fs_info->vol.dev) != RTEMS_SUCCESSFUL)
rc = -1;
for (i = 0; i < FAT_HASH_SIZE; i++)
2029a2c: 80 a4 e0 18 cmp %l3, 0x18 <== NOT EXECUTED
2029a30: 32 bf ff f5 bne,a 2029a04 <fat_shutdown_drive+0x3c> <== NOT EXECUTED
2029a34: e4 04 20 68 ld [ %l0 + 0x68 ], %l2 <== NOT EXECUTED
2029a38: a6 10 20 00 clr %l3 <== NOT EXECUTED
}
for (i = 0; i < FAT_HASH_SIZE; i++)
{
rtems_chain_node *node = NULL;
rtems_chain_control *the_chain = fs_info->rhash + i;
2029a3c: e4 04 20 6c ld [ %l0 + 0x6c ], %l2 <== NOT EXECUTED
while ( (node = rtems_chain_get(the_chain)) != NULL )
2029a40: 10 80 00 04 b 2029a50 <fat_shutdown_drive+0x88> <== NOT EXECUTED
2029a44: a4 04 80 13 add %l2, %l3, %l2 <== NOT EXECUTED
free(node);
2029a48: 7f ff 7b a5 call 20088dc <free> <== NOT EXECUTED
2029a4c: 01 00 00 00 nop <== NOT EXECUTED
2029a50: 7f ff 92 65 call 200e3e4 <_Chain_Get> <== NOT EXECUTED
2029a54: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
for (i = 0; i < FAT_HASH_SIZE; i++)
{
rtems_chain_node *node = NULL;
rtems_chain_control *the_chain = fs_info->rhash + i;
while ( (node = rtems_chain_get(the_chain)) != NULL )
2029a58: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2029a5c: 12 bf ff fb bne 2029a48 <fat_shutdown_drive+0x80> <== NOT EXECUTED
2029a60: 01 00 00 00 nop <== NOT EXECUTED
2029a64: a6 04 e0 0c add %l3, 0xc, %l3 <== NOT EXECUTED
while ( (node = rtems_chain_get(the_chain)) != NULL )
free(node);
}
for (i = 0; i < FAT_HASH_SIZE; i++)
2029a68: 80 a4 e0 18 cmp %l3, 0x18 <== NOT EXECUTED
2029a6c: 32 bf ff f5 bne,a 2029a40 <fat_shutdown_drive+0x78> <== NOT EXECUTED
2029a70: e4 04 20 6c ld [ %l0 + 0x6c ], %l2 <== NOT EXECUTED
while ( (node = rtems_chain_get(the_chain)) != NULL )
free(node);
}
free(fs_info->vhash);
2029a74: 7f ff 7b 9a call 20088dc <free> <== NOT EXECUTED
2029a78: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
free(fs_info->rhash);
2029a7c: 7f ff 7b 98 call 20088dc <free> <== NOT EXECUTED
2029a80: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED
free(fs_info->uino);
2029a84: 7f ff 7b 96 call 20088dc <free> <== NOT EXECUTED
2029a88: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 <== NOT EXECUTED
free(fs_info->sec_buf);
2029a8c: 7f ff 7b 94 call 20088dc <free> <== NOT EXECUTED
2029a90: d0 04 20 8c ld [ %l0 + 0x8c ], %o0 <== NOT EXECUTED
rtems_disk_release(fs_info->vol.dd);
2029a94: 7f ff 76 6a call 200743c <rtems_disk_release> <== NOT EXECUTED
2029a98: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
if (rc)
2029a9c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2029aa0: 02 80 00 06 be 2029ab8 <fat_shutdown_drive+0xf0> <== NOT EXECUTED
2029aa4: 01 00 00 00 nop <== NOT EXECUTED
errno = EIO;
2029aa8: 40 00 82 76 call 204a480 <__errno> <== NOT EXECUTED
2029aac: 01 00 00 00 nop <== NOT EXECUTED
2029ab0: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
2029ab4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return rc;
}
2029ab8: 81 c7 e0 08 ret <== NOT EXECUTED
2029abc: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
fat_fs_info_t *fs_info = mt_entry->fs_info;
int i = 0;
if (fs_info->vol.type & FAT_FAT32)
{
rc = fat_fat32_update_fsinfo_sector(mt_entry, fs_info->vol.free_cls,
2029ac0: d2 04 20 40 ld [ %l0 + 0x40 ], %o1 <== NOT EXECUTED
2029ac4: d4 04 20 44 ld [ %l0 + 0x44 ], %o2 <== NOT EXECUTED
2029ac8: 7f ff ff 90 call 2029908 <fat_fat32_update_fsinfo_sector> <== NOT EXECUTED
2029acc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
fs_info->vol.next_cl);
if ( rc != RC_OK )
2029ad0: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2029ad4: 32 bf ff c3 bne,a 20299e0 <fat_shutdown_drive+0x18> <== NOT EXECUTED
2029ad8: a2 10 3f ff mov -1, %l1 <== NOT EXECUTED
2029adc: 30 bf ff c1 b,a 20299e0 <fat_shutdown_drive+0x18> <== NOT EXECUTED
rc = -1;
}
fat_buf_release(fs_info);
if (rtems_bdbuf_syncdev(fs_info->vol.dev) != RTEMS_SUCCESSFUL)
2029ae0: 10 bf ff c8 b 2029a00 <fat_shutdown_drive+0x38> <== NOT EXECUTED
2029ae4: a6 10 20 00 clr %l3 <== NOT EXECUTED
02045afc <fchdir>:
#include <rtems/seterr.h>
int fchdir(
int fd
)
{
2045afc: 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 );
2045b00: 03 00 81 c2 sethi %hi(0x2070800), %g1 <== NOT EXECUTED
2045b04: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops><== NOT EXECUTED
2045b08: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED
2045b0c: 1a 80 00 53 bcc 2045c58 <fchdir+0x15c> <== NOT EXECUTED
2045b10: 03 00 81 d3 sethi %hi(0x2074c00), %g1 <== NOT EXECUTED
iop = rtems_libio_iop( fd );
2045b14: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 ! 2074c64 <rtems_libio_iops><== NOT EXECUTED
2045b18: 85 2e 20 06 sll %i0, 6, %g2 <== NOT EXECUTED
2045b1c: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED
2045b20: b0 06 00 02 add %i0, %g2, %i0 <== NOT EXECUTED
2045b24: b0 00 40 18 add %g1, %i0, %i0 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
2045b28: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
2045b2c: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
2045b30: 02 80 00 4a be 2045c58 <fchdir+0x15c> <== NOT EXECUTED
2045b34: 01 00 00 00 nop <== NOT EXECUTED
/*
* Verify you can change directory into this node.
*/
if ( !iop->pathinfo.ops ) {
2045b38: c2 06 20 28 ld [ %i0 + 0x28 ], %g1 <== NOT EXECUTED
2045b3c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2045b40: 02 80 00 59 be 2045ca4 <fchdir+0x1a8> <== NOT EXECUTED
2045b44: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( !iop->pathinfo.ops->node_type_h ) {
2045b48: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 <== NOT EXECUTED
2045b4c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2045b50: 02 80 00 55 be 2045ca4 <fchdir+0x1a8> <== NOT EXECUTED
2045b54: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( (*iop->pathinfo.ops->node_type_h)( &iop->pathinfo ) !=
2045b58: 9f c0 40 00 call %g1 <== NOT EXECUTED
2045b5c: 90 06 20 1c add %i0, 0x1c, %o0 <== NOT EXECUTED
2045b60: 80 a2 20 01 cmp %o0, 1 <== NOT EXECUTED
2045b64: 12 80 00 37 bne 2045c40 <fchdir+0x144> <== NOT EXECUTED
2045b68: 21 00 81 c3 sethi %hi(0x2070c00), %l0 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045b6c: c2 04 22 24 ld [ %l0 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045b70: 11 00 81 bb sethi %hi(0x206ec00), %o0 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045b74: c4 00 60 04 ld [ %g1 + 4 ], %g2 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045b78: 90 12 23 48 or %o0, 0x348, %o0 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045b7c: c4 27 bf d8 st %g2, [ %fp + -40 ] <== NOT EXECUTED
2045b80: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045b84: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045b88: c4 27 bf dc st %g2, [ %fp + -36 ] <== NOT EXECUTED
2045b8c: c4 00 60 0c ld [ %g1 + 0xc ], %g2 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045b90: 94 10 20 00 clr %o2 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045b94: c4 27 bf e0 st %g2, [ %fp + -32 ] <== NOT EXECUTED
2045b98: c4 00 60 10 ld [ %g1 + 0x10 ], %g2 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045b9c: 96 07 bf ec add %fp, -20, %o3 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045ba0: c4 27 bf e4 st %g2, [ %fp + -28 ] <== NOT EXECUTED
2045ba4: c4 00 60 14 ld [ %g1 + 0x14 ], %g2 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045ba8: 98 10 20 00 clr %o4 <== NOT EXECUTED
* but note the race condition. Threads who
* share their rtems_filesystem_current better
* be synchronized!
*/
saved = rtems_filesystem_current;
2045bac: c4 27 bf e8 st %g2, [ %fp + -24 ] <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
2045bb0: c4 06 20 1c ld [ %i0 + 0x1c ], %g2 <== NOT EXECUTED
2045bb4: c4 20 60 04 st %g2, [ %g1 + 4 ] <== NOT EXECUTED
2045bb8: c4 06 20 20 ld [ %i0 + 0x20 ], %g2 <== NOT EXECUTED
2045bbc: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
2045bc0: c4 06 20 24 ld [ %i0 + 0x24 ], %g2 <== NOT EXECUTED
2045bc4: c4 20 60 0c st %g2, [ %g1 + 0xc ] <== NOT EXECUTED
2045bc8: c4 06 20 28 ld [ %i0 + 0x28 ], %g2 <== NOT EXECUTED
2045bcc: c4 20 60 10 st %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2045bd0: c4 06 20 2c ld [ %i0 + 0x2c ], %g2 <== NOT EXECUTED
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2045bd4: 7f ff 0b 23 call 2008860 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
2045bd8: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
2045bdc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2045be0: 12 80 00 24 bne 2045c70 <fchdir+0x174> <== NOT EXECUTED
2045be4: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
/* cloning failed; restore original and bail out */
rtems_filesystem_current = saved;
return -1;
}
/* release the old one */
rtems_filesystem_freenode( &saved );
2045be8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2045bec: 02 80 00 09 be 2045c10 <fchdir+0x114> <== NOT EXECUTED
2045bf0: c4 07 bf ec ld [ %fp + -20 ], %g2 <== NOT EXECUTED
2045bf4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2045bf8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2045bfc: 22 80 00 06 be,a 2045c14 <fchdir+0x118> <== NOT EXECUTED
2045c00: c2 04 22 24 ld [ %l0 + 0x224 ], %g1 <== NOT EXECUTED
2045c04: 9f c0 40 00 call %g1 <== NOT EXECUTED
2045c08: 90 07 bf d8 add %fp, -40, %o0 <== NOT EXECUTED
rtems_filesystem_current = loc;
2045c0c: c4 07 bf ec ld [ %fp + -20 ], %g2 <== NOT EXECUTED
2045c10: c2 04 22 24 ld [ %l0 + 0x224 ], %g1 <== NOT EXECUTED
2045c14: c4 20 60 04 st %g2, [ %g1 + 4 ] <== NOT EXECUTED
2045c18: c4 07 bf f0 ld [ %fp + -16 ], %g2 <== NOT EXECUTED
2045c1c: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
2045c20: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
2045c24: c4 20 60 0c st %g2, [ %g1 + 0xc ] <== NOT EXECUTED
2045c28: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
2045c2c: c4 20 60 10 st %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2045c30: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
2045c34: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
return 0;
}
2045c38: 81 c7 e0 08 ret <== NOT EXECUTED
2045c3c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( (*iop->pathinfo.ops->node_type_h)( &iop->pathinfo ) !=
RTEMS_FILESYSTEM_DIRECTORY ) {
rtems_set_errno_and_return_minus_one( ENOTDIR );
2045c40: 40 00 12 10 call 204a480 <__errno> <== NOT EXECUTED
2045c44: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045c48: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED
2045c4c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2045c50: 81 c7 e0 08 ret <== NOT EXECUTED
2045c54: 81 e8 00 00 restore <== NOT EXECUTED
rtems_libio_t *iop;
rtems_filesystem_location_info_t loc, saved;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
2045c58: 40 00 12 0a call 204a480 <__errno> <== NOT EXECUTED
2045c5c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045c60: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
2045c64: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2045c68: 81 c7 e0 08 ret <== NOT EXECUTED
2045c6c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
/* clone the current node */
if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
/* cloning failed; restore original and bail out */
rtems_filesystem_current = saved;
2045c70: c4 07 bf d8 ld [ %fp + -40 ], %g2 <== NOT EXECUTED
2045c74: c2 04 22 24 ld [ %l0 + 0x224 ], %g1 <== NOT EXECUTED
2045c78: c4 20 60 04 st %g2, [ %g1 + 4 ] <== NOT EXECUTED
2045c7c: c4 07 bf dc ld [ %fp + -36 ], %g2 <== NOT EXECUTED
2045c80: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
2045c84: c4 07 bf e0 ld [ %fp + -32 ], %g2 <== NOT EXECUTED
2045c88: c4 20 60 0c st %g2, [ %g1 + 0xc ] <== NOT EXECUTED
2045c8c: c4 07 bf e4 ld [ %fp + -28 ], %g2 <== NOT EXECUTED
2045c90: c4 20 60 10 st %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2045c94: c4 07 bf e8 ld [ %fp + -24 ], %g2 <== NOT EXECUTED
2045c98: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
return -1;
2045c9c: 81 c7 e0 08 ret <== NOT EXECUTED
2045ca0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
if ( !iop->pathinfo.ops ) {
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( !iop->pathinfo.ops->node_type_h ) {
rtems_set_errno_and_return_minus_one( ENOTSUP );
2045ca4: 40 00 11 f7 call 204a480 <__errno> <== NOT EXECUTED
2045ca8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045cac: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2045cb0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2045cb4: 81 c7 e0 08 ret <== NOT EXECUTED
2045cb8: 81 e8 00 00 restore <== NOT EXECUTED
0202c87c <fchmod>:
int fchmod(
int fd,
mode_t mode
)
{
202c87c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
202c880: 03 00 81 c2 sethi %hi(0x2070800), %g1 <== NOT EXECUTED
202c884: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops><== NOT EXECUTED
202c888: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED
202c88c: 1a 80 00 16 bcc 202c8e4 <fchmod+0x68> <== NOT EXECUTED
202c890: 03 00 81 d3 sethi %hi(0x2074c00), %g1 <== NOT EXECUTED
iop = rtems_libio_iop( fd );
202c894: d0 00 60 64 ld [ %g1 + 0x64 ], %o0 ! 2074c64 <rtems_libio_iops><== NOT EXECUTED
202c898: 83 2e 20 06 sll %i0, 6, %g1 <== NOT EXECUTED
202c89c: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED
202c8a0: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED
202c8a4: 90 02 00 18 add %o0, %i0, %o0 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
202c8a8: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 <== NOT EXECUTED
202c8ac: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
202c8b0: 02 80 00 0d be 202c8e4 <fchmod+0x68> <== NOT EXECUTED
202c8b4: 01 00 00 00 nop <== NOT EXECUTED
/*
* Now process the fchmod().
*/
if ( !iop->handlers->fchmod_h )
202c8b8: c2 02 20 40 ld [ %o0 + 0x40 ], %g1 <== NOT EXECUTED
202c8bc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202c8c0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202c8c4: 02 80 00 0e be 202c8fc <fchmod+0x80> <== NOT EXECUTED
202c8c8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->pathinfo.handlers->fchmod_h)( &iop->pathinfo, mode );
202c8cc: c2 02 20 24 ld [ %o0 + 0x24 ], %g1 <== NOT EXECUTED
202c8d0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202c8d4: 9f c0 40 00 call %g1 <== NOT EXECUTED
202c8d8: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
}
202c8dc: 81 c7 e0 08 ret <== NOT EXECUTED
202c8e0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
{
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
202c8e4: 40 00 76 e7 call 204a480 <__errno> <== NOT EXECUTED
202c8e8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c8ec: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
202c8f0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c8f4: 81 c7 e0 08 ret <== NOT EXECUTED
202c8f8: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Now process the fchmod().
*/
if ( !iop->handlers->fchmod_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
202c8fc: 40 00 76 e1 call 204a480 <__errno> <== NOT EXECUTED
202c900: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c904: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202c908: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c90c: 81 c7 e0 08 ret <== NOT EXECUTED
202c910: 81 e8 00 00 restore <== NOT EXECUTED
0202c914 <fchown>:
int fchown(
int fd,
uid_t owner,
gid_t group
)
{
202c914: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
202c918: 03 00 81 c2 sethi %hi(0x2070800), %g1 <== NOT EXECUTED
202c91c: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops><== NOT EXECUTED
202c920: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED
202c924: 1a 80 00 19 bcc 202c988 <fchown+0x74> <== NOT EXECUTED
202c928: 03 00 81 d3 sethi %hi(0x2074c00), %g1 <== NOT EXECUTED
iop = rtems_libio_iop( fd );
202c92c: d0 00 60 64 ld [ %g1 + 0x64 ], %o0 ! 2074c64 <rtems_libio_iops><== NOT EXECUTED
202c930: 83 2e 20 06 sll %i0, 6, %g1 <== NOT EXECUTED
202c934: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED
202c938: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED
202c93c: 90 02 00 18 add %o0, %i0, %o0 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
202c940: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 <== NOT EXECUTED
202c944: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
202c948: 02 80 00 10 be 202c988 <fchown+0x74> <== NOT EXECUTED
202c94c: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
202c950: 02 80 00 14 be 202c9a0 <fchown+0x8c> <== NOT EXECUTED
202c954: 01 00 00 00 nop <== NOT EXECUTED
if ( !iop->pathinfo.ops->chown_h )
202c958: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED
202c95c: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED
202c960: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202c964: 02 80 00 15 be 202c9b8 <fchown+0xa4> <== NOT EXECUTED
202c968: 93 2e 60 10 sll %i1, 0x10, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->pathinfo.ops->chown_h)( &iop->pathinfo, owner, group );
202c96c: 95 2e a0 10 sll %i2, 0x10, %o2 <== NOT EXECUTED
202c970: 93 32 60 10 srl %o1, 0x10, %o1 <== NOT EXECUTED
202c974: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
202c978: 9f c0 40 00 call %g1 <== NOT EXECUTED
202c97c: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
}
202c980: 81 c7 e0 08 ret <== NOT EXECUTED
202c984: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
{
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
202c988: 40 00 76 be call 204a480 <__errno> <== NOT EXECUTED
202c98c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c990: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
202c994: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c998: 81 c7 e0 08 ret <== NOT EXECUTED
202c99c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
202c9a0: 40 00 76 b8 call 204a480 <__errno> <== NOT EXECUTED
202c9a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c9a8: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
202c9ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c9b0: 81 c7 e0 08 ret <== NOT EXECUTED
202c9b4: 81 e8 00 00 restore <== NOT EXECUTED
if ( !iop->pathinfo.ops->chown_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
202c9b8: 40 00 76 b2 call 204a480 <__errno> <== NOT EXECUTED
202c9bc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202c9c0: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202c9c4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202c9c8: 81 c7 e0 08 ret <== NOT EXECUTED
202c9cc: 81 e8 00 00 restore <== NOT EXECUTED
02045ce4 <fcntl>:
int fcntl(
int fd,
int cmd,
...
)
{
2045ce4: 9d e3 bf 90 save %sp, -112, %sp
int fd2;
int flags;
int mask;
int ret = 0;
rtems_libio_check_fd( fd );
2045ce8: 03 00 81 c2 sethi %hi(0x2070800), %g1
2045cec: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops>
...
)
{
int ret;
va_list ap;
va_start( ap, cmd );
2045cf0: 84 07 a0 4c add %fp, 0x4c, %g2
2045cf4: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
2045cf8: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
2045cfc: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
2045d00: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
int fd2;
int flags;
int mask;
int ret = 0;
rtems_libio_check_fd( fd );
2045d04: 80 a6 00 01 cmp %i0, %g1
2045d08: 1a 80 00 7a bcc 2045ef0 <fcntl+0x20c> <== NEVER TAKEN
2045d0c: c4 27 bf fc st %g2, [ %fp + -4 ]
iop = rtems_libio_iop( fd );
2045d10: 21 00 81 d3 sethi %hi(0x2074c00), %l0
2045d14: c6 04 20 64 ld [ %l0 + 0x64 ], %g3 ! 2074c64 <rtems_libio_iops>
2045d18: 89 2e 20 06 sll %i0, 6, %g4
2045d1c: 93 2e 20 03 sll %i0, 3, %o1
2045d20: 92 02 40 04 add %o1, %g4, %o1
2045d24: 92 00 c0 09 add %g3, %o1, %o1
rtems_libio_check_is_open(iop);
2045d28: d0 02 60 18 ld [ %o1 + 0x18 ], %o0
2045d2c: 80 8a 21 00 btst 0x100, %o0
2045d30: 02 80 00 70 be 2045ef0 <fcntl+0x20c> <== NEVER TAKEN
2045d34: 80 a6 60 09 cmp %i1, 9
/*
* This switch should contain all the cases from POSIX.
*/
switch ( cmd ) {
2045d38: 08 80 00 08 bleu 2045d58 <fcntl+0x74>
2045d3c: 89 2e 60 02 sll %i1, 2, %g4
errno = ENOTSUP;
ret = -1;
break;
default:
errno = EINVAL;
2045d40: 40 00 11 d0 call 204a480 <__errno>
2045d44: b0 10 3f ff mov -1, %i0
2045d48: 82 10 20 16 mov 0x16, %g1
2045d4c: c2 22 00 00 st %g1, [ %o0 ]
2045d50: 81 c7 e0 08 ret
2045d54: 81 e8 00 00 restore
/*
* This switch should contain all the cases from POSIX.
*/
switch ( cmd ) {
2045d58: 1b 00 81 17 sethi %hi(0x2045c00), %o5
2045d5c: 9a 13 60 bc or %o5, 0xbc, %o5 ! 2045cbc <fchdir+0x1c0>
2045d60: c8 03 40 04 ld [ %o5 + %g4 ], %g4
2045d64: 81 c1 00 00 jmp %g4
2045d68: 01 00 00 00 nop
errno = ENOTSUP;
ret = -1;
break;
case F_GETOWN: /* for sockets. */
errno = ENOTSUP;
2045d6c: 40 00 11 c5 call 204a480 <__errno>
2045d70: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff>
2045d74: 82 10 20 86 mov 0x86, %g1
2045d78: c2 22 00 00 st %g1, [ %o0 ]
2045d7c: 81 c7 e0 08 ret
2045d80: 81 e8 00 00 restore
case F_GETFL: /* more flags (cloexec) */
ret = rtems_libio_to_fcntl_flags( iop->flags );
break;
case F_SETFL:
flags = rtems_libio_fcntl_flags( va_arg( ap, int ) );
2045d84: d0 00 80 00 ld [ %g2 ], %o0
2045d88: 7f ff 0c 3e call 2008e80 <rtems_libio_fcntl_flags>
2045d8c: d2 27 bf f4 st %o1, [ %fp + -12 ]
/*
* XXX If we are turning on append, should we seek to the end?
*/
iop->flags = (iop->flags & ~mask) | (flags & mask);
2045d90: d2 07 bf f4 ld [ %fp + -12 ], %o1
2045d94: 90 0a 22 01 and %o0, 0x201, %o0
2045d98: c2 02 60 18 ld [ %o1 + 0x18 ], %g1
2045d9c: b0 10 20 00 clr %i0
2045da0: 82 08 7d fe and %g1, -514, %g1
2045da4: 82 12 00 01 or %o0, %g1, %g1
2045da8: c2 22 60 18 st %g1, [ %o1 + 0x18 ]
* If we got this far successfully, then we give the optional
* filesystem specific handler a chance to process this.
*/
if (ret >= 0) {
if (iop->handlers->fcntl_h) {
2045dac: c2 02 60 40 ld [ %o1 + 0x40 ], %g1
2045db0: c2 00 60 30 ld [ %g1 + 0x30 ], %g1
2045db4: 80 a0 60 00 cmp %g1, 0
2045db8: 02 80 00 52 be 2045f00 <fcntl+0x21c> <== NEVER TAKEN
2045dbc: 01 00 00 00 nop
int err = (*iop->handlers->fcntl_h)( cmd, iop );
2045dc0: 9f c0 40 00 call %g1
2045dc4: 90 10 00 19 mov %i1, %o0
if (err) {
2045dc8: b2 92 20 00 orcc %o0, 0, %i1
2045dcc: 12 80 00 04 bne 2045ddc <fcntl+0xf8> <== NEVER TAKEN
2045dd0: 01 00 00 00 nop
va_list ap;
va_start( ap, cmd );
ret = vfcntl(fd,cmd,ap);
va_end(ap);
return ret;
}
2045dd4: 81 c7 e0 08 ret
2045dd8: 81 e8 00 00 restore
if (ret >= 0) {
if (iop->handlers->fcntl_h) {
int err = (*iop->handlers->fcntl_h)( cmd, iop );
if (err) {
errno = err;
2045ddc: 40 00 11 a9 call 204a480 <__errno> <== NOT EXECUTED
2045de0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045de4: f2 22 00 00 st %i1, [ %o0 ] <== NOT EXECUTED
va_list ap;
va_start( ap, cmd );
ret = vfcntl(fd,cmd,ap);
va_end(ap);
return ret;
}
2045de8: 81 c7 e0 08 ret <== NOT EXECUTED
2045dec: 81 e8 00 00 restore <== NOT EXECUTED
else
iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;
break;
case F_GETFL: /* more flags (cloexec) */
ret = rtems_libio_to_fcntl_flags( iop->flags );
2045df0: 7f ff 0b 74 call 2008bc0 <rtems_libio_to_fcntl_flags>
2045df4: d2 27 bf f4 st %o1, [ %fp + -12 ]
2045df8: d2 07 bf f4 ld [ %fp + -12 ], %o1
2045dfc: b0 10 00 08 mov %o0, %i0
/*
* If we got this far successfully, then we give the optional
* filesystem specific handler a chance to process this.
*/
if (ret >= 0) {
2045e00: 80 a6 20 00 cmp %i0, 0
2045e04: 36 bf ff eb bge,a 2045db0 <fcntl+0xcc> <== ALWAYS TAKEN
2045e08: c2 02 60 40 ld [ %o1 + 0x40 ], %g1
va_list ap;
va_start( ap, cmd );
ret = vfcntl(fd,cmd,ap);
va_end(ap);
return ret;
}
2045e0c: 81 c7 e0 08 ret <== NOT EXECUTED
2045e10: 81 e8 00 00 restore <== NOT EXECUTED
* 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 ) )
2045e14: c2 00 80 00 ld [ %g2 ], %g1
2045e18: 80 a0 60 00 cmp %g1, 0
2045e1c: 22 80 00 2c be,a 2045ecc <fcntl+0x1e8> <== NEVER TAKEN
2045e20: 90 0a 37 ff and %o0, -2049, %o0 <== NOT EXECUTED
iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC;
2045e24: 90 12 28 00 or %o0, 0x800, %o0
2045e28: b0 10 20 00 clr %i0
2045e2c: 10 bf ff e0 b 2045dac <fcntl+0xc8>
2045e30: d0 22 60 18 st %o0, [ %o1 + 0x18 ]
diop->pathinfo = iop->pathinfo;
ret = (int) (diop - rtems_libio_iops);
break;
case F_GETFD: /* get f_flags */
ret = ((iop->flags & LIBIO_FLAGS_CLOSE_ON_EXEC) != 0);
2045e34: b1 32 20 0b srl %o0, 0xb, %i0
2045e38: 10 bf ff dd b 2045dac <fcntl+0xc8>
2045e3c: b0 0e 20 01 and %i0, 1, %i0
* This switch should contain all the cases from POSIX.
*/
switch ( cmd ) {
case F_DUPFD: /* dup */
fd2 = va_arg( ap, int );
2045e40: c4 00 80 00 ld [ %g2 ], %g2
if ( fd2 )
2045e44: 80 a0 a0 00 cmp %g2, 0
2045e48: 02 80 00 30 be 2045f08 <fcntl+0x224> <== ALWAYS TAKEN
2045e4c: 80 a0 40 02 cmp %g1, %g2
diop = rtems_libio_iop( fd2 );
2045e50: b0 10 20 00 clr %i0 <== NOT EXECUTED
2045e54: 18 80 00 21 bgu 2045ed8 <fcntl+0x1f4> <== NOT EXECUTED
2045e58: 82 10 20 00 clr %g1 <== NOT EXECUTED
}
diop->handlers = iop->handlers;
diop->file_info = iop->file_info;
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e5c: c4 02 60 1c ld [ %o1 + 0x1c ], %g2
ret = -1;
break;
}
}
diop->handlers = iop->handlers;
2045e60: da 02 60 40 ld [ %o1 + 0x40 ], %o5
diop->file_info = iop->file_info;
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e64: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
2045e68: c4 02 60 20 ld [ %o1 + 0x20 ], %g2
break;
}
}
diop->handlers = iop->handlers;
diop->file_info = iop->file_info;
2045e6c: c8 02 60 3c ld [ %o1 + 0x3c ], %g4
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e70: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
2045e74: c4 02 60 24 ld [ %o1 + 0x24 ], %g2
ret = (int) (diop - rtems_libio_iops);
2045e78: 86 26 00 03 sub %i0, %g3, %g3
}
diop->handlers = iop->handlers;
diop->file_info = iop->file_info;
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e7c: c4 20 60 24 st %g2, [ %g1 + 0x24 ]
2045e80: c4 02 60 28 ld [ %o1 + 0x28 ], %g2
ret = (int) (diop - rtems_libio_iops);
2045e84: 87 38 e0 03 sra %g3, 3, %g3
}
diop->handlers = iop->handlers;
diop->file_info = iop->file_info;
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e88: c4 20 60 28 st %g2, [ %g1 + 0x28 ]
2045e8c: c4 02 60 2c ld [ %o1 + 0x2c ], %g2
ret = -1;
break;
}
}
diop->handlers = iop->handlers;
2045e90: da 20 60 40 st %o5, [ %g1 + 0x40 ]
diop->file_info = iop->file_info;
diop->flags = iop->flags;
diop->pathinfo = iop->pathinfo;
2045e94: c4 20 60 2c st %g2, [ %g1 + 0x2c ]
ret = (int) (diop - rtems_libio_iops);
2045e98: 85 28 e0 06 sll %g3, 6, %g2
break;
}
}
diop->handlers = iop->handlers;
diop->file_info = iop->file_info;
2045e9c: c8 20 60 3c st %g4, [ %g1 + 0x3c ]
diop->flags = iop->flags;
2045ea0: d0 20 60 18 st %o0, [ %g1 + 0x18 ]
diop->pathinfo = iop->pathinfo;
ret = (int) (diop - rtems_libio_iops);
2045ea4: 83 28 e0 03 sll %g3, 3, %g1
2045ea8: 82 20 80 01 sub %g2, %g1, %g1
2045eac: 85 28 60 06 sll %g1, 6, %g2
2045eb0: 82 00 40 02 add %g1, %g2, %g1
2045eb4: 82 00 40 03 add %g1, %g3, %g1
2045eb8: b1 28 60 0f sll %g1, 0xf, %i0
2045ebc: b0 26 00 01 sub %i0, %g1, %i0
2045ec0: b1 2e 20 03 sll %i0, 3, %i0
2045ec4: 10 bf ff cf b 2045e00 <fcntl+0x11c>
2045ec8: b0 06 00 03 add %i0, %g3, %i0
*/
if ( va_arg( ap, int ) )
iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC;
else
iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;
2045ecc: b0 10 20 00 clr %i0 <== NOT EXECUTED
2045ed0: 10 bf ff b7 b 2045dac <fcntl+0xc8> <== NOT EXECUTED
2045ed4: d0 22 60 18 st %o0, [ %o1 + 0x18 ] <== NOT EXECUTED
switch ( cmd ) {
case F_DUPFD: /* dup */
fd2 = va_arg( ap, int );
if ( fd2 )
diop = rtems_libio_iop( fd2 );
2045ed8: 83 28 a0 06 sll %g2, 6, %g1 <== NOT EXECUTED
2045edc: 85 28 a0 03 sll %g2, 3, %g2 <== NOT EXECUTED
2045ee0: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2045ee4: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
2045ee8: 10 bf ff dd b 2045e5c <fcntl+0x178> <== NOT EXECUTED
2045eec: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
int mask;
int ret = 0;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
2045ef0: 40 00 11 64 call 204a480 <__errno> <== NOT EXECUTED
2045ef4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2045ef8: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
2045efc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2045f00: 81 c7 e0 08 ret <== NOT EXECUTED
2045f04: 81 e8 00 00 restore <== NOT EXECUTED
fd2 = va_arg( ap, int );
if ( fd2 )
diop = rtems_libio_iop( fd2 );
else {
/* allocate a file control block */
diop = rtems_libio_allocate();
2045f08: 7f ff 0b 9d call 2008d7c <rtems_libio_allocate>
2045f0c: d2 27 bf f4 st %o1, [ %fp + -12 ]
if ( diop == 0 ) {
2045f10: b0 10 3f ff mov -1, %i0
2045f14: 82 92 20 00 orcc %o0, 0, %g1
2045f18: 02 bf ff 8e be 2045d50 <fcntl+0x6c> <== NEVER TAKEN
2045f1c: d2 07 bf f4 ld [ %fp + -12 ], %o1
2045f20: c6 04 20 64 ld [ %l0 + 0x64 ], %g3
2045f24: d0 02 60 18 ld [ %o1 + 0x18 ], %o0
2045f28: 10 bf ff cd b 2045e5c <fcntl+0x178>
2045f2c: b0 10 00 01 mov %g1, %i0
0200399c <fdatasync>:
#include <rtems/seterr.h>
int fdatasync(
int fd
)
{
200399c: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
20039a0: 03 00 80 81 sethi %hi(0x2020400), %g1
20039a4: c2 00 63 f4 ld [ %g1 + 0x3f4 ], %g1 ! 20207f4 <rtems_libio_number_iops>
20039a8: 80 a6 00 01 cmp %i0, %g1
20039ac: 1a 80 00 16 bcc 2003a04 <fdatasync+0x68> <== NEVER TAKEN
20039b0: 03 00 80 84 sethi %hi(0x2021000), %g1
iop = rtems_libio_iop( fd );
20039b4: d0 00 62 08 ld [ %g1 + 0x208 ], %o0 ! 2021208 <rtems_libio_iops>
20039b8: 83 2e 20 06 sll %i0, 6, %g1
20039bc: b1 2e 20 03 sll %i0, 3, %i0
20039c0: b0 06 00 01 add %i0, %g1, %i0
20039c4: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_is_open(iop);
20039c8: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
20039cc: 80 88 61 00 btst 0x100, %g1
20039d0: 02 80 00 0d be 2003a04 <fdatasync+0x68> <== NEVER TAKEN
20039d4: 80 88 60 04 btst 4, %g1
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
20039d8: 02 80 00 0b be 2003a04 <fdatasync+0x68>
20039dc: 01 00 00 00 nop
/*
* Now process the fdatasync().
*/
if ( !iop->handlers->fdatasync_h )
20039e0: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
20039e4: c2 00 60 2c ld [ %g1 + 0x2c ], %g1
20039e8: 80 a0 60 00 cmp %g1, 0
20039ec: 02 80 00 0c be 2003a1c <fdatasync+0x80> <== ALWAYS TAKEN
20039f0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->handlers->fdatasync_h)( iop );
20039f4: 9f c0 40 00 call %g1 <== NOT EXECUTED
20039f8: 01 00 00 00 nop <== NOT EXECUTED
}
20039fc: 81 c7 e0 08 ret <== NOT EXECUTED
2003a00: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
2003a04: 40 00 3d 62 call 2012f8c <__errno>
2003a08: b0 10 3f ff mov -1, %i0
2003a0c: 82 10 20 09 mov 9, %g1
2003a10: c2 22 00 00 st %g1, [ %o0 ]
2003a14: 81 c7 e0 08 ret
2003a18: 81 e8 00 00 restore
/*
* Now process the fdatasync().
*/
if ( !iop->handlers->fdatasync_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
2003a1c: 40 00 3d 5c call 2012f8c <__errno>
2003a20: b0 10 3f ff mov -1, %i0
2003a24: 82 10 20 86 mov 0x86, %g1
2003a28: c2 22 00 00 st %g1, [ %o0 ]
2003a2c: 81 c7 e0 08 ret
2003a30: 81 e8 00 00 restore
0200b0f0 <fifo_open>:
*/
int fifo_open(
pipe_control_t **pipep,
rtems_libio_t *iop
)
{
200b0f0: 9d e3 bf 98 save %sp, -104, %sp
)
{
pipe_control_t *pipe;
int err = 0;
if (rtems_semaphore_obtain(rtems_pipe_semaphore,
200b0f4: 21 00 80 7c sethi %hi(0x201f000), %l0
200b0f8: d0 04 20 48 ld [ %l0 + 0x48 ], %o0 ! 201f048 <rtems_pipe_semaphore>
*/
int fifo_open(
pipe_control_t **pipep,
rtems_libio_t *iop
)
{
200b0fc: a2 10 00 18 mov %i0, %l1
)
{
pipe_control_t *pipe;
int err = 0;
if (rtems_semaphore_obtain(rtems_pipe_semaphore,
200b100: 92 10 20 00 clr %o1
200b104: 94 10 20 00 clr %o2
200b108: 7f ff ed f3 call 20068d4 <rtems_semaphore_obtain>
200b10c: b0 10 3f fc mov -4, %i0
200b110: 80 a2 20 00 cmp %o0, 0
200b114: 12 80 00 f0 bne 200b4d4 <fifo_open+0x3e4> <== ALWAYS TAKEN
200b118: 01 00 00 00 nop
RTEMS_WAIT, RTEMS_NO_TIMEOUT) != RTEMS_SUCCESSFUL)
return -EINTR;
pipe = *pipep;
200b11c: e4 04 40 00 ld [ %l1 ], %l2 <== NOT EXECUTED
if (pipe == NULL) {
200b120: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
200b124: 02 80 00 4a be 200b24c <fifo_open+0x15c> <== NOT EXECUTED
200b128: 01 00 00 00 nop <== NOT EXECUTED
err = pipe_alloc(&pipe);
if (err)
goto out;
}
if (! PIPE_LOCK(pipe))
200b12c: d0 04 a0 28 ld [ %l2 + 0x28 ], %o0 <== NOT EXECUTED
200b130: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b134: 7f ff ed e8 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200b138: 94 10 20 00 clr %o2 <== NOT EXECUTED
err = -EINTR;
if (*pipep == NULL) {
200b13c: c2 04 40 00 ld [ %l1 ], %g1 <== NOT EXECUTED
err = pipe_alloc(&pipe);
if (err)
goto out;
}
if (! PIPE_LOCK(pipe))
200b140: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
200b144: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
err = -EINTR;
if (*pipep == NULL) {
200b148: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
err = pipe_alloc(&pipe);
if (err)
goto out;
}
if (! PIPE_LOCK(pipe))
200b14c: b0 0e 20 04 and %i0, 4, %i0 <== NOT EXECUTED
err = -EINTR;
if (*pipep == NULL) {
200b150: 02 80 00 ce be 200b488 <fifo_open+0x398> <== NOT EXECUTED
200b154: b0 06 3f fc add %i0, -4, %i0 <== NOT EXECUTED
else
*pipep = pipe;
}
out:
rtems_semaphore_release(rtems_pipe_semaphore);
200b158: 7f ff ee 26 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b15c: d0 04 20 48 ld [ %l0 + 0x48 ], %o0 <== NOT EXECUTED
pipe_control_t *pipe;
unsigned int prevCounter;
int err;
err = pipe_new(pipep);
if (err)
200b160: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200b164: 12 80 00 dc bne 200b4d4 <fifo_open+0x3e4> <== NOT EXECUTED
200b168: 01 00 00 00 nop <== NOT EXECUTED
return err;
pipe = *pipep;
switch (LIBIO_ACCMODE(iop)) {
200b16c: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
200b170: 82 08 60 06 and %g1, 6, %g1 <== NOT EXECUTED
200b174: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED
200b178: 02 80 00 9e be 200b3f0 <fifo_open+0x300> <== NOT EXECUTED
200b17c: e0 04 40 00 ld [ %l1 ], %l0 <== NOT EXECUTED
200b180: 80 a0 60 06 cmp %g1, 6 <== NOT EXECUTED
200b184: 02 80 00 86 be 200b39c <fifo_open+0x2ac> <== NOT EXECUTED
200b188: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
200b18c: 22 80 00 07 be,a 200b1a8 <fifo_open+0xb8> <== NOT EXECUTED
200b190: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
PIPE_WAKEUPREADERS(pipe);
break;
}
PIPE_UNLOCK(pipe);
200b194: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200b198: 7f ff ee 16 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b19c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
200b1a0: 81 c7 e0 08 ret <== NOT EXECUTED
200b1a4: 81 e8 00 00 restore <== NOT EXECUTED
return err;
pipe = *pipep;
switch (LIBIO_ACCMODE(iop)) {
case LIBIO_FLAGS_READ:
pipe->readerCounter ++;
200b1a8: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200b1ac: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
return err;
pipe = *pipep;
switch (LIBIO_ACCMODE(iop)) {
case LIBIO_FLAGS_READ:
pipe->readerCounter ++;
200b1b0: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200b1b4: c6 24 20 10 st %g3, [ %l0 + 0x10 ] <== NOT EXECUTED
200b1b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b1bc: 02 80 00 c8 be 200b4dc <fifo_open+0x3ec> <== NOT EXECUTED
200b1c0: c4 24 20 20 st %g2, [ %l0 + 0x20 ] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
if (pipe->Writers == 0) {
200b1c4: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
200b1c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b1cc: 32 bf ff f3 bne,a 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b1d0: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
/* Not an error */
if (LIBIO_NODELAY(iop))
200b1d4: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
200b1d8: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
200b1dc: 32 bf ff ef bne,a 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b1e0: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
break;
prevCounter = pipe->writerCounter;
200b1e4: 10 80 00 0c b 200b214 <fifo_open+0x124> <== NOT EXECUTED
200b1e8: e4 04 20 24 ld [ %l0 + 0x24 ], %l2 <== NOT EXECUTED
/* Wait until a writer opens the pipe */
do {
PIPE_UNLOCK(pipe);
if (! PIPE_READWAIT(pipe))
goto out_error;
if (! PIPE_LOCK(pipe))
200b1ec: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b1f0: 7f ff ed b9 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200b1f4: 94 10 20 00 clr %o2 <== NOT EXECUTED
200b1f8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b1fc: 12 80 00 0f bne 200b238 <fifo_open+0x148> <== NOT EXECUTED
200b200: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
goto out_error;
} while (prevCounter == pipe->writerCounter);
200b204: c2 04 20 24 ld [ %l0 + 0x24 ], %g1 <== NOT EXECUTED
200b208: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
200b20c: 32 bf ff e3 bne,a 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b210: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
prevCounter = pipe->writerCounter;
err = -EINTR;
/* Wait until a writer opens the pipe */
do {
PIPE_UNLOCK(pipe);
200b214: 7f ff ed f7 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b218: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
200b21c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200b220: 40 00 0a 9f call 200dc9c <rtems_barrier_wait> <== NOT EXECUTED
200b224: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b228: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b22c: 22 bf ff f0 be,a 200b1ec <fifo_open+0xfc> <== NOT EXECUTED
200b230: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
break;
}
PIPE_UNLOCK(pipe);
return 0;
200b234: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
out_error:
pipe_release(pipep, iop);
200b238: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200b23c: 7f ff ff 5c call 200afac <pipe_release> <== NOT EXECUTED
200b240: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
return err;
}
200b244: 81 c7 e0 08 ret <== NOT EXECUTED
200b248: 81 e8 00 00 restore <== NOT EXECUTED
{
static char c = 'a';
pipe_control_t *pipe;
int err = -ENOMEM;
pipe = malloc(sizeof(pipe_control_t));
200b24c: 7f ff df 90 call 200308c <malloc> <== NOT EXECUTED
200b250: 90 10 20 34 mov 0x34, %o0 <== NOT EXECUTED
if (pipe == NULL)
200b254: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
200b258: 02 80 00 bc be 200b548 <fifo_open+0x458> <== NOT EXECUTED
200b25c: a8 10 00 12 mov %l2, %l4 <== NOT EXECUTED
return err;
memset(pipe, 0, sizeof(pipe_control_t));
pipe->Size = PIPE_BUF;
200b260: 82 10 22 00 mov 0x200, %g1 <== NOT EXECUTED
int err = -ENOMEM;
pipe = malloc(sizeof(pipe_control_t));
if (pipe == NULL)
return err;
memset(pipe, 0, sizeof(pipe_control_t));
200b264: c0 24 80 00 clr [ %l2 ] <== NOT EXECUTED
200b268: c0 24 a0 08 clr [ %l2 + 8 ] <== NOT EXECUTED
200b26c: c0 24 a0 0c clr [ %l2 + 0xc ] <== NOT EXECUTED
200b270: c0 24 a0 10 clr [ %l2 + 0x10 ] <== NOT EXECUTED
200b274: c0 24 a0 14 clr [ %l2 + 0x14 ] <== NOT EXECUTED
200b278: c0 24 a0 18 clr [ %l2 + 0x18 ] <== NOT EXECUTED
200b27c: c0 24 a0 1c clr [ %l2 + 0x1c ] <== NOT EXECUTED
200b280: c0 24 a0 20 clr [ %l2 + 0x20 ] <== NOT EXECUTED
200b284: c0 24 a0 24 clr [ %l2 + 0x24 ] <== NOT EXECUTED
200b288: c0 24 a0 28 clr [ %l2 + 0x28 ] <== NOT EXECUTED
200b28c: c0 24 a0 2c clr [ %l2 + 0x2c ] <== NOT EXECUTED
200b290: c0 24 a0 30 clr [ %l2 + 0x30 ] <== NOT EXECUTED
pipe->Size = PIPE_BUF;
200b294: c2 24 a0 04 st %g1, [ %l2 + 4 ] <== NOT EXECUTED
pipe->Buffer = malloc(pipe->Size);
200b298: 7f ff df 7d call 200308c <malloc> <== NOT EXECUTED
200b29c: 90 10 22 00 mov 0x200, %o0 <== NOT EXECUTED
if (! pipe->Buffer)
200b2a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b2a4: 02 80 00 a7 be 200b540 <fifo_open+0x450> <== NOT EXECUTED
200b2a8: d0 24 80 00 st %o0, [ %l2 ] <== NOT EXECUTED
goto err_buf;
err = -ENOMEM;
if (rtems_barrier_create(
200b2ac: 27 00 80 7a sethi %hi(0x201e800), %l3 <== NOT EXECUTED
200b2b0: d0 4c e1 84 ldsb [ %l3 + 0x184 ], %o0 ! 201e984 <c.6910> <== NOT EXECUTED
200b2b4: 2b 14 12 5c sethi %hi(0x50497000), %l5 <== NOT EXECUTED
200b2b8: 82 15 62 00 or %l5, 0x200, %g1 ! 50497200 <RAM_END+0x4e097200><== NOT EXECUTED
200b2bc: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b2c0: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
200b2c4: 94 10 20 00 clr %o2 <== NOT EXECUTED
200b2c8: 40 00 0a 0c call 200daf8 <rtems_barrier_create> <== NOT EXECUTED
200b2cc: 96 04 a0 2c add %l2, 0x2c, %o3 <== NOT EXECUTED
200b2d0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b2d4: 12 80 00 99 bne 200b538 <fifo_open+0x448> <== NOT EXECUTED
200b2d8: d0 4c e1 84 ldsb [ %l3 + 0x184 ], %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(
200b2dc: 03 14 12 5d sethi %hi(0x50497400), %g1 <== NOT EXECUTED
200b2e0: 82 10 63 00 or %g1, 0x300, %g1 ! 50497700 <RAM_END+0x4e097700><== NOT EXECUTED
200b2e4: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b2e8: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
200b2ec: 94 10 20 00 clr %o2 <== NOT EXECUTED
200b2f0: 40 00 0a 02 call 200daf8 <rtems_barrier_create> <== NOT EXECUTED
200b2f4: 96 04 a0 30 add %l2, 0x30, %o3 <== NOT EXECUTED
200b2f8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b2fc: 12 80 00 8d bne 200b530 <fifo_open+0x440> <== NOT EXECUTED
200b300: d0 4c e1 84 ldsb [ %l3 + 0x184 ], %o0 <== 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(
200b304: aa 15 63 00 or %l5, 0x300, %l5 <== NOT EXECUTED
200b308: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
200b30c: 90 12 00 15 or %o0, %l5, %o0 <== NOT EXECUTED
200b310: 94 10 20 10 mov 0x10, %o2 <== NOT EXECUTED
200b314: 96 10 20 00 clr %o3 <== NOT EXECUTED
200b318: 7f ff ec ce call 2006650 <rtems_semaphore_create> <== NOT EXECUTED
200b31c: 98 04 a0 28 add %l2, 0x28, %o4 <== NOT EXECUTED
200b320: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b324: 12 80 00 81 bne 200b528 <fifo_open+0x438> <== NOT EXECUTED
200b328: ac 07 bf f8 add %fp, -8, %l6 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Get (
Objects_Id id,
Objects_Locations *location
)
{
return (Barrier_Control *)
200b32c: d2 04 a0 2c ld [ %l2 + 0x2c ], %o1 <== NOT EXECUTED
200b330: 2b 00 80 7f sethi %hi(0x201fc00), %l5 <== NOT EXECUTED
200b334: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
200b338: 7f ff f3 ed call 20082ec <_Objects_Get> <== NOT EXECUTED
200b33c: 90 15 60 c8 or %l5, 0xc8, %o0 <== NOT EXECUTED
/* Set barriers to be interruptible by signals. */
static void pipe_interruptible(pipe_control_t *pipe)
{
Objects_Locations location;
_Barrier_Get(pipe->readBarrier, &location)->Barrier.Wait_queue.state
200b340: c2 02 20 4c ld [ %o0 + 0x4c ], %g1 <== NOT EXECUTED
200b344: 29 04 00 00 sethi %hi(0x10000000), %l4 <== NOT EXECUTED
200b348: 82 10 40 14 or %g1, %l4, %g1 <== NOT EXECUTED
|= STATES_INTERRUPTIBLE_BY_SIGNAL;
_Thread_Enable_dispatch();
200b34c: 7f ff f6 95 call 2008da0 <_Thread_Enable_dispatch> <== NOT EXECUTED
200b350: c2 22 20 4c st %g1, [ %o0 + 0x4c ] <== NOT EXECUTED
200b354: d2 04 a0 30 ld [ %l2 + 0x30 ], %o1 <== NOT EXECUTED
200b358: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
200b35c: 7f ff f3 e4 call 20082ec <_Objects_Get> <== NOT EXECUTED
200b360: 90 15 60 c8 or %l5, 0xc8, %o0 <== NOT EXECUTED
_Barrier_Get(pipe->writeBarrier, &location)->Barrier.Wait_queue.state
200b364: c2 02 20 4c ld [ %o0 + 0x4c ], %g1 <== NOT EXECUTED
200b368: a8 10 40 14 or %g1, %l4, %l4 <== NOT EXECUTED
|= STATES_INTERRUPTIBLE_BY_SIGNAL;
_Thread_Enable_dispatch();
200b36c: 7f ff f6 8d call 2008da0 <_Thread_Enable_dispatch> <== NOT EXECUTED
200b370: e8 22 20 4c st %l4, [ %o0 + 0x4c ] <== NOT EXECUTED
#ifdef RTEMS_POSIX_API
pipe_interruptible(pipe);
#endif
*pipep = pipe;
if (c ++ == 'z')
200b374: c2 0c e1 84 ldub [ %l3 + 0x184 ], %g1 <== NOT EXECUTED
200b378: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
200b37c: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
200b380: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED
200b384: 80 a0 60 7a cmp %g1, 0x7a <== NOT EXECUTED
200b388: 12 bf ff 69 bne 200b12c <fifo_open+0x3c> <== NOT EXECUTED
200b38c: c4 2c e1 84 stb %g2, [ %l3 + 0x184 ] <== NOT EXECUTED
c = 'a';
200b390: 82 10 20 61 mov 0x61, %g1 <== NOT EXECUTED
200b394: 10 bf ff 66 b 200b12c <fifo_open+0x3c> <== NOT EXECUTED
200b398: c2 2c e1 84 stb %g1, [ %l3 + 0x184 ] <== NOT EXECUTED
}
break;
case LIBIO_FLAGS_READ_WRITE:
pipe->readerCounter ++;
if (pipe->Readers ++ == 0)
200b39c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter);
}
break;
case LIBIO_FLAGS_READ_WRITE:
pipe->readerCounter ++;
200b3a0: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200b3a4: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter);
}
break;
case LIBIO_FLAGS_READ_WRITE:
pipe->readerCounter ++;
200b3a8: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200b3ac: c6 24 20 10 st %g3, [ %l0 + 0x10 ] <== NOT EXECUTED
200b3b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b3b4: 02 80 00 54 be 200b504 <fifo_open+0x414> <== NOT EXECUTED
200b3b8: c4 24 20 20 st %g2, [ %l0 + 0x20 ] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
pipe->writerCounter ++;
if (pipe->Writers ++ == 0)
200b3bc: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE:
pipe->readerCounter ++;
if (pipe->Readers ++ == 0)
PIPE_WAKEUPWRITERS(pipe);
pipe->writerCounter ++;
200b3c0: c4 04 20 24 ld [ %l0 + 0x24 ], %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200b3c4: 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 ++;
200b3c8: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200b3cc: c6 24 20 14 st %g3, [ %l0 + 0x14 ] <== NOT EXECUTED
200b3d0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b3d4: 12 bf ff 70 bne 200b194 <fifo_open+0xa4> <== NOT EXECUTED
200b3d8: c4 24 20 24 st %g2, [ %l0 + 0x24 ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200b3dc: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200b3e0: 40 00 0a 18 call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b3e4: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
break;
}
PIPE_UNLOCK(pipe);
200b3e8: 10 bf ff 6c b 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b3ec: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
break;
case LIBIO_FLAGS_WRITE:
pipe->writerCounter ++;
if (pipe->Writers ++ == 0)
200b3f0: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
} while (prevCounter == pipe->writerCounter);
}
break;
case LIBIO_FLAGS_WRITE:
pipe->writerCounter ++;
200b3f4: c4 04 20 24 ld [ %l0 + 0x24 ], %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200b3f8: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
} while (prevCounter == pipe->writerCounter);
}
break;
case LIBIO_FLAGS_WRITE:
pipe->writerCounter ++;
200b3fc: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200b400: c6 24 20 14 st %g3, [ %l0 + 0x14 ] <== NOT EXECUTED
200b404: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b408: 02 80 00 3a be 200b4f0 <fifo_open+0x400> <== NOT EXECUTED
200b40c: c4 24 20 24 st %g2, [ %l0 + 0x24 ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
200b410: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200b414: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b418: 32 bf ff 60 bne,a 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b41c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200b420: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
200b424: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
200b428: 32 80 00 3c bne,a 200b518 <fifo_open+0x428> <== NOT EXECUTED
200b42c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
err = -ENXIO;
goto out_error;
}
if (pipe->Readers == 0) {
prevCounter = pipe->readerCounter;
200b430: 10 80 00 0c b 200b460 <fifo_open+0x370> <== NOT EXECUTED
200b434: e4 04 20 20 ld [ %l0 + 0x20 ], %l2 <== NOT EXECUTED
err = -EINTR;
do {
PIPE_UNLOCK(pipe);
if (! PIPE_WRITEWAIT(pipe))
goto out_error;
if (! PIPE_LOCK(pipe))
200b438: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b43c: 7f ff ed 26 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200b440: 94 10 20 00 clr %o2 <== NOT EXECUTED
200b444: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b448: 12 bf ff 7c bne 200b238 <fifo_open+0x148> <== NOT EXECUTED
200b44c: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
goto out_error;
} while (prevCounter == pipe->readerCounter);
200b450: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
200b454: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
200b458: 32 bf ff 50 bne,a 200b198 <fifo_open+0xa8> <== NOT EXECUTED
200b45c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (pipe->Readers == 0) {
prevCounter = pipe->readerCounter;
err = -EINTR;
do {
PIPE_UNLOCK(pipe);
200b460: 7f ff ed 64 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b464: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
200b468: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
200b46c: 40 00 0a 0c call 200dc9c <rtems_barrier_wait> <== NOT EXECUTED
200b470: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b474: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b478: 22 bf ff f0 be,a 200b438 <fifo_open+0x348> <== NOT EXECUTED
200b47c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
break;
}
PIPE_UNLOCK(pipe);
return 0;
200b480: 10 bf ff 6e b 200b238 <fifo_open+0x148> <== NOT EXECUTED
200b484: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe))
err = -EINTR;
if (*pipep == NULL) {
if (err)
200b488: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200b48c: 12 80 00 06 bne 200b4a4 <fifo_open+0x3b4> <== NOT EXECUTED
200b490: d0 04 20 48 ld [ %l0 + 0x48 ], %o0 <== NOT EXECUTED
else
*pipep = pipe;
}
out:
rtems_semaphore_release(rtems_pipe_semaphore);
200b494: 7f ff ed 57 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b498: e4 24 40 00 st %l2, [ %l1 ] <== NOT EXECUTED
err = pipe_new(pipep);
if (err)
return err;
pipe = *pipep;
switch (LIBIO_ACCMODE(iop)) {
200b49c: 10 bf ff 35 b 200b170 <fifo_open+0x80> <== NOT EXECUTED
200b4a0: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
/* Called with rtems_pipe_semaphore held. */
static inline void pipe_free(
pipe_control_t *pipe
)
{
rtems_barrier_delete(pipe->readBarrier);
200b4a4: 40 00 09 cd call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b4a8: d0 04 a0 2c ld [ %l2 + 0x2c ], %o0 <== NOT EXECUTED
rtems_barrier_delete(pipe->writeBarrier);
200b4ac: 40 00 09 cb call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b4b0: d0 04 a0 30 ld [ %l2 + 0x30 ], %o0 <== NOT EXECUTED
rtems_semaphore_delete(pipe->Semaphore);
200b4b4: 7f ff ec db call 2006820 <rtems_semaphore_delete> <== NOT EXECUTED
200b4b8: d0 04 a0 28 ld [ %l2 + 0x28 ], %o0 <== NOT EXECUTED
free(pipe->Buffer);
200b4bc: 7f ff de 0c call 2002cec <free> <== NOT EXECUTED
200b4c0: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
free(pipe);
200b4c4: 7f ff de 0a call 2002cec <free> <== NOT EXECUTED
200b4c8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
else
*pipep = pipe;
}
out:
rtems_semaphore_release(rtems_pipe_semaphore);
200b4cc: 7f ff ed 49 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b4d0: d0 04 20 48 ld [ %l0 + 0x48 ], %o0 <== NOT EXECUTED
200b4d4: 81 c7 e0 08 ret
200b4d8: 81 e8 00 00 restore
switch (LIBIO_ACCMODE(iop)) {
case LIBIO_FLAGS_READ:
pipe->readerCounter ++;
if (pipe->Readers ++ == 0)
PIPE_WAKEUPWRITERS(pipe);
200b4dc: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
200b4e0: 40 00 09 d8 call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b4e4: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
if (pipe->Writers == 0) {
200b4e8: 10 bf ff 38 b 200b1c8 <fifo_open+0xd8> <== NOT EXECUTED
200b4ec: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
case LIBIO_FLAGS_WRITE:
pipe->writerCounter ++;
if (pipe->Writers ++ == 0)
PIPE_WAKEUPREADERS(pipe);
200b4f0: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200b4f4: 40 00 09 d3 call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b4f8: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
200b4fc: 10 bf ff c6 b 200b414 <fifo_open+0x324> <== NOT EXECUTED
200b500: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
break;
case LIBIO_FLAGS_READ_WRITE:
pipe->readerCounter ++;
if (pipe->Readers ++ == 0)
PIPE_WAKEUPWRITERS(pipe);
200b504: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
200b508: 40 00 09 ce call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b50c: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
pipe->writerCounter ++;
if (pipe->Writers ++ == 0)
200b510: 10 bf ff ac b 200b3c0 <fifo_open+0x2d0> <== NOT EXECUTED
200b514: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
PIPE_WAKEUPREADERS(pipe);
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
PIPE_UNLOCK(pipe);
200b518: 7f ff ed 36 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b51c: b0 10 3f fa mov -6, %i0 <== NOT EXECUTED
err = -ENXIO;
goto out_error;
200b520: 10 bf ff 47 b 200b23c <fifo_open+0x14c> <== NOT EXECUTED
200b524: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
if (c ++ == 'z')
c = 'a';
return 0;
err_sem:
rtems_barrier_delete(pipe->writeBarrier);
200b528: 40 00 09 ac call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b52c: d0 04 a0 30 ld [ %l2 + 0x30 ], %o0 <== NOT EXECUTED
err_wbar:
rtems_barrier_delete(pipe->readBarrier);
200b530: 40 00 09 aa call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b534: d0 05 20 2c ld [ %l4 + 0x2c ], %o0 <== NOT EXECUTED
err_rbar:
free(pipe->Buffer);
200b538: 7f ff dd ed call 2002cec <free> <== NOT EXECUTED
200b53c: d0 05 00 00 ld [ %l4 ], %o0 <== NOT EXECUTED
err_buf:
free(pipe);
200b540: 7f ff dd eb call 2002cec <free> <== NOT EXECUTED
200b544: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
200b548: 10 bf ff e1 b 200b4cc <fifo_open+0x3dc> <== NOT EXECUTED
200b54c: b0 10 3f f4 mov -12, %i0 <== NOT EXECUTED
02003a64 <fpathconf>:
long fpathconf(
int fd,
int name
)
{
2003a64: 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);
2003a68: 03 00 80 81 sethi %hi(0x2020400), %g1
2003a6c: c2 00 63 f4 ld [ %g1 + 0x3f4 ], %g1 ! 20207f4 <rtems_libio_number_iops>
2003a70: 80 a6 00 01 cmp %i0, %g1
2003a74: 1a 80 00 3d bcc 2003b68 <fpathconf+0x104>
2003a78: 03 00 80 84 sethi %hi(0x2021000), %g1
iop = rtems_libio_iop(fd);
2003a7c: c2 00 62 08 ld [ %g1 + 0x208 ], %g1 ! 2021208 <rtems_libio_iops>
2003a80: 85 2e 20 06 sll %i0, 6, %g2
2003a84: b1 2e 20 03 sll %i0, 3, %i0
2003a88: b0 06 00 02 add %i0, %g2, %i0
2003a8c: b0 00 40 18 add %g1, %i0, %i0
rtems_libio_check_is_open(iop);
2003a90: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
2003a94: 80 88 61 00 btst 0x100, %g1
2003a98: 02 80 00 34 be 2003b68 <fpathconf+0x104> <== NEVER TAKEN
2003a9c: 80 a6 60 0b cmp %i1, 0xb
* Now process the information request.
*/
the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options;
switch ( name ) {
2003aa0: 08 80 00 08 bleu 2003ac0 <fpathconf+0x5c>
2003aa4: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
break;
case _PC_SYNC_IO:
return_value = the_limits->posix_sync_io;
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
2003aa8: 40 00 3d 39 call 2012f8c <__errno>
2003aac: b0 10 3f ff mov -1, %i0
2003ab0: 82 10 20 16 mov 0x16, %g1
2003ab4: c2 22 00 00 st %g1, [ %o0 ]
break;
}
return return_value;
}
2003ab8: 81 c7 e0 08 ret
2003abc: 81 e8 00 00 restore
* Now process the information request.
*/
the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options;
switch ( name ) {
2003ac0: b3 2e 60 02 sll %i1, 2, %i1
2003ac4: 05 00 80 0e sethi %hi(0x2003800), %g2
2003ac8: 84 10 a2 34 or %g2, 0x234, %g2 ! 2003a34 <fdatasync+0x98>
2003acc: c4 00 80 19 ld [ %g2 + %i1 ], %g2
2003ad0: 81 c0 80 00 jmp %g2
2003ad4: 01 00 00 00 nop
break;
case _PC_ASYNC_IO:
return_value = the_limits->posix_async_io;
break;
case _PC_PRIO_IO:
return_value = the_limits->posix_prio_io;
2003ad8: f0 00 60 5c ld [ %g1 + 0x5c ], %i0
break;
2003adc: 81 c7 e0 08 ret
2003ae0: 81 e8 00 00 restore
break;
case _PC_VDISABLE:
return_value = the_limits->posix_vdisable;
break;
case _PC_ASYNC_IO:
return_value = the_limits->posix_async_io;
2003ae4: f0 00 60 50 ld [ %g1 + 0x50 ], %i0
break;
2003ae8: 81 c7 e0 08 ret
2003aec: 81 e8 00 00 restore
break;
case _PC_NO_TRUNC:
return_value = the_limits->posix_no_trunc;
break;
case _PC_VDISABLE:
return_value = the_limits->posix_vdisable;
2003af0: f0 00 60 64 ld [ %g1 + 0x64 ], %i0
break;
2003af4: 81 c7 e0 08 ret
2003af8: 81 e8 00 00 restore
break;
case _PC_CHOWN_RESTRICTED:
return_value = the_limits->posix_chown_restrictions;
break;
case _PC_NO_TRUNC:
return_value = the_limits->posix_no_trunc;
2003afc: f0 00 60 58 ld [ %g1 + 0x58 ], %i0
break;
2003b00: 81 c7 e0 08 ret
2003b04: 81 e8 00 00 restore
break;
case _PC_PIPE_BUF:
return_value = the_limits->pipe_buf;
break;
case _PC_CHOWN_RESTRICTED:
return_value = the_limits->posix_chown_restrictions;
2003b08: f0 00 60 54 ld [ %g1 + 0x54 ], %i0
break;
2003b0c: 81 c7 e0 08 ret
2003b10: 81 e8 00 00 restore
break;
case _PC_PATH_MAX:
return_value = the_limits->path_max;
break;
case _PC_PIPE_BUF:
return_value = the_limits->pipe_buf;
2003b14: f0 00 60 4c ld [ %g1 + 0x4c ], %i0
break;
2003b18: 81 c7 e0 08 ret
2003b1c: 81 e8 00 00 restore
break;
case _PC_NAME_MAX:
return_value = the_limits->name_max;
break;
case _PC_PATH_MAX:
return_value = the_limits->path_max;
2003b20: f0 00 60 48 ld [ %g1 + 0x48 ], %i0
break;
2003b24: 81 c7 e0 08 ret
2003b28: 81 e8 00 00 restore
break;
case _PC_MAX_INPUT:
return_value = the_limits->max_input;
break;
case _PC_NAME_MAX:
return_value = the_limits->name_max;
2003b2c: f0 00 60 44 ld [ %g1 + 0x44 ], %i0
break;
2003b30: 81 c7 e0 08 ret
2003b34: 81 e8 00 00 restore
break;
case _PC_MAX_CANON:
return_value = the_limits->max_canon;
break;
case _PC_MAX_INPUT:
return_value = the_limits->max_input;
2003b38: f0 00 60 40 ld [ %g1 + 0x40 ], %i0
break;
2003b3c: 81 c7 e0 08 ret
2003b40: 81 e8 00 00 restore
switch ( name ) {
case _PC_LINK_MAX:
return_value = the_limits->link_max;
break;
case _PC_MAX_CANON:
return_value = the_limits->max_canon;
2003b44: f0 00 60 3c ld [ %g1 + 0x3c ], %i0
break;
2003b48: 81 c7 e0 08 ret
2003b4c: 81 e8 00 00 restore
the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options;
switch ( name ) {
case _PC_LINK_MAX:
return_value = the_limits->link_max;
2003b50: f0 00 60 38 ld [ %g1 + 0x38 ], %i0
break;
2003b54: 81 c7 e0 08 ret
2003b58: 81 e8 00 00 restore
break;
case _PC_PRIO_IO:
return_value = the_limits->posix_prio_io;
break;
case _PC_SYNC_IO:
return_value = the_limits->posix_sync_io;
2003b5c: f0 00 60 60 ld [ %g1 + 0x60 ], %i0
break;
2003b60: 81 c7 e0 08 ret
2003b64: 81 e8 00 00 restore
rtems_libio_t *iop;
rtems_filesystem_limits_and_options_t *the_limits;
rtems_libio_check_fd(fd);
iop = rtems_libio_iop(fd);
rtems_libio_check_is_open(iop);
2003b68: 40 00 3d 09 call 2012f8c <__errno>
2003b6c: b0 10 3f ff mov -1, %i0
2003b70: 82 10 20 09 mov 9, %g1
2003b74: c2 22 00 00 st %g1, [ %o0 ]
2003b78: 81 c7 e0 08 ret
2003b7c: 81 e8 00 00 restore
02002cec <free>:
void free(
void *ptr
)
{
MSBUMP(free_calls, 1);
2002cec: 9d e3 bf a0 save %sp, -96, %sp
2002cf0: 03 00 80 7c sethi %hi(0x201f000), %g1
2002cf4: 82 10 61 e0 or %g1, 0x1e0, %g1 ! 201f1e0 <rtems_malloc_statistics>
2002cf8: c4 00 60 0c ld [ %g1 + 0xc ], %g2
2002cfc: b2 10 00 18 mov %i0, %i1
2002d00: 84 00 a0 01 inc %g2
if ( !ptr )
2002d04: 80 a6 20 00 cmp %i0, 0
2002d08: 02 80 00 15 be 2002d5c <free+0x70>
2002d0c: 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()) &&
2002d10: 03 00 80 7d sethi %hi(0x201f400), %g1
2002d14: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 201f540 <_System_state_Current>
2002d18: 80 a0 60 03 cmp %g1, 3
2002d1c: 02 80 00 17 be 2002d78 <free+0x8c> <== ALWAYS TAKEN
2002d20: 03 00 80 7b sethi %hi(0x201ec00), %g1
#endif
/*
* If configured, update the statistics
*/
if ( rtems_malloc_statistics_helpers )
2002d24: c2 00 62 e8 ld [ %g1 + 0x2e8 ], %g1 ! 201eee8 <rtems_malloc_statistics_helpers>
2002d28: 80 a0 60 00 cmp %g1, 0
2002d2c: 02 80 00 06 be 2002d44 <free+0x58> <== ALWAYS TAKEN
2002d30: 21 00 80 79 sethi %hi(0x201e400), %l0
(*rtems_malloc_statistics_helpers->at_free)(ptr);
2002d34: c2 00 60 08 ld [ %g1 + 8 ], %g1 <== NOT EXECUTED
2002d38: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002d3c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) {
2002d40: 21 00 80 79 sethi %hi(0x201e400), %l0 <== NOT EXECUTED
2002d44: d0 04 23 c0 ld [ %l0 + 0x3c0 ], %o0 ! 201e7c0 <RTEMS_Malloc_Heap>
2002d48: 40 00 16 53 call 2008694 <_Protected_heap_Free>
2002d4c: 92 10 00 19 mov %i1, %o1
2002d50: 80 8a 20 ff btst 0xff, %o0
2002d54: 02 80 00 04 be 2002d64 <free+0x78> <== NEVER TAKEN
2002d58: c2 04 23 c0 ld [ %l0 + 0x3c0 ], %g1
2002d5c: 81 c7 e0 08 ret
2002d60: 81 e8 00 00 restore
printk( "Program heap: free of bad pointer %p -- range %p - %p \n",
2002d64: 31 00 80 75 sethi %hi(0x201d400), %i0 <== NOT EXECUTED
2002d68: f6 00 60 1c ld [ %g1 + 0x1c ], %i3 <== NOT EXECUTED
2002d6c: f4 00 60 18 ld [ %g1 + 0x18 ], %i2 <== NOT EXECUTED
2002d70: 40 00 03 f2 call 2003d38 <printk> <== NOT EXECUTED
2002d74: 91 ee 21 28 restore %i0, 0x128, %o0 <== NOT EXECUTED
/*
* Do not attempt to free memory if in a critical section or ISR.
*/
if ( _System_state_Is_up(_System_state_Get()) &&
2002d78: 40 00 00 62 call 2002f00 <malloc_is_system_state_OK>
2002d7c: 01 00 00 00 nop
2002d80: 80 8a 20 ff btst 0xff, %o0
2002d84: 12 bf ff e8 bne 2002d24 <free+0x38> <== ALWAYS TAKEN
2002d88: 03 00 80 7b sethi %hi(0x201ec00), %g1
!malloc_is_system_state_OK() ) {
malloc_deferred_free(ptr);
2002d8c: 40 00 00 6f call 2002f48 <malloc_deferred_free> <== NOT EXECUTED
2002d90: 81 e8 00 00 restore <== NOT EXECUTED
0202e0dc <free_user_env>:
* NOTE: this must be called with
* thread dispatching disabled!
*/
static void
free_user_env(void *venv)
{
202e0dc: 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
202e0e0: 03 00 81 d3 sethi %hi(0x2074c00), %g1 <== NOT EXECUTED
202e0e4: 82 10 60 bc or %g1, 0xbc, %g1 ! 2074cbc <rtems_global_user_env><== NOT EXECUTED
202e0e8: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED
202e0ec: 02 80 00 18 be 202e14c <free_user_env+0x70> <== NOT EXECUTED
202e0f0: 01 00 00 00 nop <== NOT EXECUTED
#ifdef HAVE_USERENV_REFCNT
&& --env->refcnt <= 0
#endif
) {
rtems_filesystem_freenode( &env->current_directory);
202e0f4: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
202e0f8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e0fc: 22 80 00 09 be,a 202e120 <free_user_env+0x44> <== NOT EXECUTED
202e100: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED
202e104: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e108: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e10c: 22 80 00 05 be,a 202e120 <free_user_env+0x44> <== NOT EXECUTED
202e110: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED
202e114: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e118: 90 06 20 04 add %i0, 4, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &env->root_directory);
202e11c: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED
202e120: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e124: 02 80 00 08 be 202e144 <free_user_env+0x68> <== NOT EXECUTED
202e128: 01 00 00 00 nop <== NOT EXECUTED
202e12c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e130: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e134: 02 80 00 04 be 202e144 <free_user_env+0x68> <== NOT EXECUTED
202e138: 01 00 00 00 nop <== NOT EXECUTED
202e13c: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e140: 90 06 20 18 add %i0, 0x18, %o0 <== NOT EXECUTED
free(env);
202e144: 7f ff 69 e6 call 20088dc <free> <== NOT EXECUTED
202e148: 81 e8 00 00 restore <== NOT EXECUTED
202e14c: 81 c7 e0 08 ret <== NOT EXECUTED
202e150: 81 e8 00 00 restore <== NOT EXECUTED
0201c3a0 <fstat>:
int fstat(
int fd,
struct stat *sbuf
)
{
201c3a0: 9d e3 bf a0 save %sp, -96, %sp
/*
* Check to see if we were passed a valid pointer.
*/
if ( !sbuf )
201c3a4: 80 a6 60 00 cmp %i1, 0
201c3a8: 02 80 00 3b be 201c494 <fstat+0xf4>
201c3ac: 03 00 80 79 sethi %hi(0x201e400), %g1
/*
* Now process the stat() request.
*/
iop = rtems_libio_iop( fd );
201c3b0: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
201c3b4: 80 a6 00 01 cmp %i0, %g1
201c3b8: 1a 80 00 2b bcc 201c464 <fstat+0xc4>
201c3bc: 03 00 80 7c sethi %hi(0x201f000), %g1
201c3c0: d0 00 61 c4 ld [ %g1 + 0x1c4 ], %o0 ! 201f1c4 <rtems_libio_iops>
201c3c4: 83 2e 20 06 sll %i0, 6, %g1
201c3c8: b1 2e 20 03 sll %i0, 3, %i0
201c3cc: b0 06 00 01 add %i0, %g1, %i0
201c3d0: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_fd( fd );
rtems_libio_check_is_open(iop);
201c3d4: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
201c3d8: 80 88 61 00 btst 0x100, %g1
201c3dc: 02 80 00 22 be 201c464 <fstat+0xc4> <== NEVER TAKEN
201c3e0: 01 00 00 00 nop
if ( !iop->handlers )
201c3e4: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
201c3e8: 80 a0 60 00 cmp %g1, 0
201c3ec: 02 80 00 1e be 201c464 <fstat+0xc4> <== NEVER TAKEN
201c3f0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EBADF );
if ( !iop->handlers->fstat_h )
201c3f4: c2 00 60 18 ld [ %g1 + 0x18 ], %g1
201c3f8: 80 a0 60 00 cmp %g1, 0
201c3fc: 02 80 00 20 be 201c47c <fstat+0xdc> <== NEVER TAKEN
201c400: 92 10 00 19 mov %i1, %o1
/*
* Zero out the stat structure so the various support
* versions of stat don't have to.
*/
memset( sbuf, 0, sizeof(struct stat) );
201c404: c0 26 40 00 clr [ %i1 ]
201c408: c0 26 60 04 clr [ %i1 + 4 ]
201c40c: c0 26 60 08 clr [ %i1 + 8 ]
201c410: c0 26 60 0c clr [ %i1 + 0xc ]
201c414: c0 26 60 10 clr [ %i1 + 0x10 ]
201c418: c0 26 60 14 clr [ %i1 + 0x14 ]
201c41c: c0 26 60 18 clr [ %i1 + 0x18 ]
201c420: c0 26 60 1c clr [ %i1 + 0x1c ]
201c424: c0 26 60 20 clr [ %i1 + 0x20 ]
201c428: c0 26 60 24 clr [ %i1 + 0x24 ]
201c42c: c0 26 60 28 clr [ %i1 + 0x28 ]
201c430: c0 26 60 2c clr [ %i1 + 0x2c ]
201c434: c0 26 60 30 clr [ %i1 + 0x30 ]
201c438: c0 26 60 34 clr [ %i1 + 0x34 ]
201c43c: c0 26 60 38 clr [ %i1 + 0x38 ]
201c440: c0 26 60 3c clr [ %i1 + 0x3c ]
201c444: c0 26 60 40 clr [ %i1 + 0x40 ]
201c448: c0 26 60 44 clr [ %i1 + 0x44 ]
return (*iop->handlers->fstat_h)( &iop->pathinfo, sbuf );
201c44c: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
201c450: c2 00 60 18 ld [ %g1 + 0x18 ], %g1
201c454: 9f c0 40 00 call %g1
201c458: 90 02 20 1c add %o0, 0x1c, %o0
}
201c45c: 81 c7 e0 08 ret
201c460: 91 e8 00 08 restore %g0, %o0, %o0
iop = rtems_libio_iop( fd );
rtems_libio_check_fd( fd );
rtems_libio_check_is_open(iop);
if ( !iop->handlers )
rtems_set_errno_and_return_minus_one( EBADF );
201c464: 7f ff d5 66 call 20119fc <__errno>
201c468: b0 10 3f ff mov -1, %i0
201c46c: 82 10 20 09 mov 9, %g1
201c470: c2 22 00 00 st %g1, [ %o0 ]
201c474: 81 c7 e0 08 ret
201c478: 81 e8 00 00 restore
if ( !iop->handlers->fstat_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
201c47c: 7f ff d5 60 call 20119fc <__errno> <== NOT EXECUTED
201c480: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201c484: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
201c488: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201c48c: 81 c7 e0 08 ret <== NOT EXECUTED
201c490: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Check to see if we were passed a valid pointer.
*/
if ( !sbuf )
rtems_set_errno_and_return_minus_one( EFAULT );
201c494: 7f ff d5 5a call 20119fc <__errno>
201c498: b0 10 3f ff mov -1, %i0
201c49c: 82 10 20 0e mov 0xe, %g1
201c4a0: c2 22 00 00 st %g1, [ %o0 ]
201c4a4: 81 c7 e0 08 ret
201c4a8: 81 e8 00 00 restore
0202caf4 <fsync>:
#include <rtems/seterr.h>
int fsync(
int fd
)
{
202caf4: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
202caf8: 03 00 81 c2 sethi %hi(0x2070800), %g1
202cafc: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops>
202cb00: 80 a6 00 01 cmp %i0, %g1
202cb04: 1a 80 00 17 bcc 202cb60 <fsync+0x6c> <== NEVER TAKEN
202cb08: 03 00 81 d3 sethi %hi(0x2074c00), %g1
iop = rtems_libio_iop( fd );
202cb0c: d0 00 60 64 ld [ %g1 + 0x64 ], %o0 ! 2074c64 <rtems_libio_iops>
202cb10: 83 2e 20 06 sll %i0, 6, %g1
202cb14: b1 2e 20 03 sll %i0, 3, %i0
202cb18: b0 06 00 01 add %i0, %g1, %i0
202cb1c: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_is_open(iop);
202cb20: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
202cb24: 80 88 61 00 btst 0x100, %g1
202cb28: 02 80 00 0e be 202cb60 <fsync+0x6c> <== NEVER TAKEN
202cb2c: 01 00 00 00 nop
/*
* Now process the fsync().
*/
if ( !iop->handlers )
202cb30: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
202cb34: 80 a0 60 00 cmp %g1, 0
202cb38: 02 80 00 0a be 202cb60 <fsync+0x6c> <== NEVER TAKEN
202cb3c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EBADF );
if ( !iop->handlers->fsync_h )
202cb40: c2 00 60 28 ld [ %g1 + 0x28 ], %g1
202cb44: 80 a0 60 00 cmp %g1, 0
202cb48: 02 80 00 0c be 202cb78 <fsync+0x84>
202cb4c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->handlers->fsync_h)( iop );
202cb50: 9f c0 40 00 call %g1
202cb54: 01 00 00 00 nop
}
202cb58: 81 c7 e0 08 ret
202cb5c: 91 e8 00 08 restore %g0, %o0, %o0
/*
* Now process the fsync().
*/
if ( !iop->handlers )
rtems_set_errno_and_return_minus_one( EBADF );
202cb60: 40 00 76 48 call 204a480 <__errno> <== NOT EXECUTED
202cb64: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202cb68: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
202cb6c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202cb70: 81 c7 e0 08 ret <== NOT EXECUTED
202cb74: 81 e8 00 00 restore <== NOT EXECUTED
if ( !iop->handlers->fsync_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
202cb78: 40 00 76 42 call 204a480 <__errno>
202cb7c: b0 10 3f ff mov -1, %i0
202cb80: 82 10 20 86 mov 0x86, %g1
202cb84: c2 22 00 00 st %g1, [ %o0 ]
202cb88: 81 c7 e0 08 ret
202cb8c: 81 e8 00 00 restore
0200ca04 <ftruncate>:
int ftruncate(
int fd,
off_t length
)
{
200ca04: 9d e3 bf 88 save %sp, -120, %sp
rtems_libio_t *iop;
rtems_filesystem_location_info_t loc;
rtems_libio_check_fd( fd );
200ca08: 03 00 80 79 sethi %hi(0x201e400), %g1
200ca0c: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
200ca10: 80 a6 00 01 cmp %i0, %g1
200ca14: 1a 80 00 2d bcc 200cac8 <ftruncate+0xc4> <== NEVER TAKEN
200ca18: 03 00 80 7c sethi %hi(0x201f000), %g1
iop = rtems_libio_iop( fd );
200ca1c: c2 00 61 c4 ld [ %g1 + 0x1c4 ], %g1 ! 201f1c4 <rtems_libio_iops>
200ca20: 85 2e 20 06 sll %i0, 6, %g2
200ca24: b1 2e 20 03 sll %i0, 3, %i0
200ca28: b0 06 00 02 add %i0, %g2, %i0
200ca2c: b0 00 40 18 add %g1, %i0, %i0
rtems_libio_check_is_open(iop);
200ca30: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
200ca34: 80 88 61 00 btst 0x100, %g1
200ca38: 02 80 00 24 be 200cac8 <ftruncate+0xc4> <== NEVER TAKEN
200ca3c: 80 88 60 04 btst 4, %g1
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
200ca40: 02 80 00 28 be 200cae0 <ftruncate+0xdc> <== NEVER TAKEN
200ca44: 01 00 00 00 nop
/*
* Make sure we are not working on a directory
*/
loc = iop->pathinfo;
200ca48: c2 06 20 1c ld [ %i0 + 0x1c ], %g1
200ca4c: c2 27 bf ec st %g1, [ %fp + -20 ]
200ca50: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
200ca54: c2 27 bf f0 st %g1, [ %fp + -16 ]
200ca58: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
200ca5c: c2 27 bf f4 st %g1, [ %fp + -12 ]
200ca60: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200ca64: c2 27 bf f8 st %g1, [ %fp + -8 ]
200ca68: c4 06 20 2c ld [ %i0 + 0x2c ], %g2
if ( !loc.ops->node_type_h )
200ca6c: c2 00 60 10 ld [ %g1 + 0x10 ], %g1
200ca70: 80 a0 60 00 cmp %g1, 0
200ca74: 02 80 00 21 be 200caf8 <ftruncate+0xf4> <== NEVER TAKEN
200ca78: c4 27 bf fc st %g2, [ %fp + -4 ]
rtems_set_errno_and_return_minus_one( ENOTSUP );
if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY )
200ca7c: 9f c0 40 00 call %g1
200ca80: 90 07 bf ec add %fp, -20, %o0
200ca84: 80 a2 20 01 cmp %o0, 1
200ca88: 02 80 00 22 be 200cb10 <ftruncate+0x10c>
200ca8c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EISDIR );
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
200ca90: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
200ca94: 80 88 60 04 btst 4, %g1
200ca98: 02 80 00 12 be 200cae0 <ftruncate+0xdc> <== NEVER TAKEN
200ca9c: 01 00 00 00 nop
if ( !iop->handlers->ftruncate_h )
200caa0: c2 06 20 40 ld [ %i0 + 0x40 ], %g1
200caa4: c2 00 60 20 ld [ %g1 + 0x20 ], %g1
200caa8: 80 a0 60 00 cmp %g1, 0
200caac: 02 80 00 13 be 200caf8 <ftruncate+0xf4> <== NEVER TAKEN
200cab0: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->handlers->ftruncate_h)( iop, length );
200cab4: 92 10 00 19 mov %i1, %o1
200cab8: 9f c0 40 00 call %g1
200cabc: 94 10 00 1a mov %i2, %o2
}
200cac0: 81 c7 e0 08 ret
200cac4: 91 e8 00 08 restore %g0, %o0, %o0
rtems_libio_t *iop;
rtems_filesystem_location_info_t loc;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
200cac8: 40 00 13 cd call 20119fc <__errno> <== NOT EXECUTED
200cacc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200cad0: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
200cad4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200cad8: 81 c7 e0 08 ret <== NOT EXECUTED
200cadc: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY )
rtems_set_errno_and_return_minus_one( EISDIR );
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
200cae0: 40 00 13 c7 call 20119fc <__errno> <== NOT EXECUTED
200cae4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200cae8: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200caec: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200caf0: 81 c7 e0 08 ret <== NOT EXECUTED
200caf4: 81 e8 00 00 restore <== NOT EXECUTED
if ( !iop->handlers->ftruncate_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
200caf8: 40 00 13 c1 call 20119fc <__errno> <== NOT EXECUTED
200cafc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200cb00: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
200cb04: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200cb08: 81 c7 e0 08 ret <== NOT EXECUTED
200cb0c: 81 e8 00 00 restore <== NOT EXECUTED
loc = iop->pathinfo;
if ( !loc.ops->node_type_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY )
rtems_set_errno_and_return_minus_one( EISDIR );
200cb10: 40 00 13 bb call 20119fc <__errno>
200cb14: b0 10 3f ff mov -1, %i0
200cb18: 82 10 20 15 mov 0x15, %g1
200cb1c: c2 22 00 00 st %g1, [ %o0 ]
200cb20: 81 c7 e0 08 ret
200cb24: 81 e8 00 00 restore
020028a0 <get_disk_entry>:
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
rtems_filesystem_split_dev_t(dev, major, minor);
if (major < disktab_size && disktab != NULL) {
20028a0: 03 00 80 8b sethi %hi(0x2022c00), %g1
20028a4: c2 00 62 5c ld [ %g1 + 0x25c ], %g1 ! 2022e5c <disktab_size>
20028a8: 80 a0 40 08 cmp %g1, %o0
20028ac: 18 80 00 05 bgu 20028c0 <get_disk_entry+0x20> <== ALWAYS TAKEN
20028b0: 03 00 80 8b sethi %hi(0x2022c00), %g1
if (minor < dtab->size && dtab->minor != NULL) {
rtems_disk_device *dd = dtab->minor [minor];
if (dd != NULL && !lookup_only) {
if (!dd->deleted) {
++dd->uses;
20028b4: 90 10 20 00 clr %o0 <== NOT EXECUTED
return dd;
}
}
return NULL;
}
20028b8: 81 c3 e0 08 retl
20028bc: 01 00 00 00 nop
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
rtems_filesystem_split_dev_t(dev, major, minor);
if (major < disktab_size && disktab != NULL) {
20028c0: c2 00 62 58 ld [ %g1 + 0x258 ], %g1
20028c4: 80 a0 60 00 cmp %g1, 0
20028c8: 22 bf ff fc be,a 20028b8 <get_disk_entry+0x18> <== NEVER TAKEN
20028cc: 90 10 20 00 clr %o0 <== NOT EXECUTED
rtems_disk_device_table *dtab = disktab + major;
20028d0: 91 2a 20 03 sll %o0, 3, %o0
20028d4: 84 00 40 08 add %g1, %o0, %g2
if (minor < dtab->size && dtab->minor != NULL) {
20028d8: c4 00 a0 04 ld [ %g2 + 4 ], %g2
20028dc: 80 a0 80 09 cmp %g2, %o1
20028e0: 28 bf ff f6 bleu,a 20028b8 <get_disk_entry+0x18> <== NEVER TAKEN
20028e4: 90 10 20 00 clr %o0 <== NOT EXECUTED
20028e8: c2 00 40 08 ld [ %g1 + %o0 ], %g1
20028ec: 80 a0 60 00 cmp %g1, 0
20028f0: 02 bf ff f2 be 20028b8 <get_disk_entry+0x18> <== NEVER TAKEN
20028f4: 90 10 20 00 clr %o0
rtems_disk_device *dd = dtab->minor [minor];
20028f8: 93 2a 60 02 sll %o1, 2, %o1
20028fc: d0 00 40 09 ld [ %g1 + %o1 ], %o0
if (dd != NULL && !lookup_only) {
2002900: 80 a2 20 00 cmp %o0, 0
2002904: 02 bf ff ed be 20028b8 <get_disk_entry+0x18>
2002908: 80 8a a0 ff btst 0xff, %o2
200290c: 12 bf ff eb bne 20028b8 <get_disk_entry+0x18>
2002910: 01 00 00 00 nop
if (!dd->deleted) {
2002914: c2 0a 20 30 ldub [ %o0 + 0x30 ], %g1
2002918: 80 a0 60 00 cmp %g1, 0
200291c: 32 bf ff e7 bne,a 20028b8 <get_disk_entry+0x18>
2002920: 90 10 20 00 clr %o0
++dd->uses;
2002924: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
2002928: 82 00 60 01 inc %g1
200292c: 81 c3 e0 08 retl
2002930: c2 22 20 14 st %g1, [ %o0 + 0x14 ]
02063f74 <getdents>:
int getdents(
int dd_fd,
char *dd_buf,
int dd_len
)
{
2063f74: 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 );
2063f78: 03 00 81 c2 sethi %hi(0x2070800), %g1
2063f7c: c2 00 61 f4 ld [ %g1 + 0x1f4 ], %g1 ! 20709f4 <rtems_libio_number_iops>
2063f80: 80 a6 00 01 cmp %i0, %g1
2063f84: 1a 80 00 08 bcc 2063fa4 <getdents+0x30> <== NEVER TAKEN
2063f88: a0 10 20 00 clr %l0
2063f8c: 03 00 81 d3 sethi %hi(0x2074c00), %g1
2063f90: e0 00 60 64 ld [ %g1 + 0x64 ], %l0 ! 2074c64 <rtems_libio_iops>
2063f94: 83 2e 20 06 sll %i0, 6, %g1
2063f98: b1 2e 20 03 sll %i0, 3, %i0
2063f9c: b0 06 00 01 add %i0, %g1, %i0
2063fa0: a0 04 00 18 add %l0, %i0, %l0
/*
* Make sure we are working on a directory
*/
loc = iop->pathinfo;
2063fa4: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
2063fa8: c2 27 bf ec st %g1, [ %fp + -20 ]
2063fac: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2063fb0: c2 27 bf f0 st %g1, [ %fp + -16 ]
2063fb4: c2 04 20 24 ld [ %l0 + 0x24 ], %g1
2063fb8: c2 27 bf f4 st %g1, [ %fp + -12 ]
2063fbc: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
2063fc0: c2 27 bf f8 st %g1, [ %fp + -8 ]
2063fc4: c4 04 20 2c ld [ %l0 + 0x2c ], %g2
if ( !loc.ops->node_type_h )
2063fc8: c2 00 60 10 ld [ %g1 + 0x10 ], %g1
2063fcc: 80 a0 60 00 cmp %g1, 0
2063fd0: 02 80 00 17 be 206402c <getdents+0xb8> <== NEVER TAKEN
2063fd4: c4 27 bf fc st %g2, [ %fp + -4 ]
rtems_set_errno_and_return_minus_one( ENOTSUP );
if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY )
2063fd8: 9f c0 40 00 call %g1
2063fdc: 90 07 bf ec add %fp, -20, %o0
2063fe0: 80 a2 20 01 cmp %o0, 1
2063fe4: 12 80 00 0c bne 2064014 <getdents+0xa0>
2063fe8: 01 00 00 00 nop
/*
* Return the number of bytes that were actually transfered as a result
* of the read attempt.
*/
if ( !iop->handlers->read_h )
2063fec: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
2063ff0: c2 00 60 08 ld [ %g1 + 8 ], %g1
2063ff4: 80 a0 60 00 cmp %g1, 0
2063ff8: 02 80 00 0d be 206402c <getdents+0xb8> <== NEVER TAKEN
2063ffc: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
return (*iop->handlers->read_h)( iop, dd_buf, dd_len );
2064000: 92 10 00 19 mov %i1, %o1
2064004: 9f c0 40 00 call %g1
2064008: 94 10 00 1a mov %i2, %o2
}
206400c: 81 c7 e0 08 ret
2064010: 91 e8 00 08 restore %g0, %o0, %o0
loc = iop->pathinfo;
if ( !loc.ops->node_type_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY )
rtems_set_errno_and_return_minus_one( ENOTDIR );
2064014: 7f ff 99 1b call 204a480 <__errno>
2064018: b0 10 3f ff mov -1, %i0
206401c: 82 10 20 14 mov 0x14, %g1
2064020: c2 22 00 00 st %g1, [ %o0 ]
2064024: 81 c7 e0 08 ret
2064028: 81 e8 00 00 restore
* Return the number of bytes that were actually transfered as a result
* of the read attempt.
*/
if ( !iop->handlers->read_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
206402c: 7f ff 99 15 call 204a480 <__errno> <== NOT EXECUTED
2064030: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2064034: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2064038: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
206403c: 81 c7 e0 08 ret <== NOT EXECUTED
2064040: 81 e8 00 00 restore <== NOT EXECUTED
0202ccd4 <getgid>:
* 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs,
* P1003.1b-1993, p. 84
*/
gid_t getgid( void )
{
202ccd4: 03 00 81 c3 sethi %hi(0x2070c00), %g1 <== NOT EXECUTED
202ccd8: c2 00 62 24 ld [ %g1 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
return _POSIX_types_Gid;
}
202ccdc: 81 c3 e0 08 retl <== NOT EXECUTED
202cce0: d0 10 60 34 lduh [ %g1 + 0x34 ], %o0 <== NOT EXECUTED
0202d3d0 <getgr_r>:
struct group *grp,
char *buffer,
size_t bufsize,
struct group **result
)
{
202d3d0: 9d e3 bf a0 save %sp, -96, %sp
FILE *fp;
int match;
init_etc_passwd_group();
202d3d4: 7f ff ff b3 call 202d2a0 <init_etc_passwd_group>
202d3d8: 01 00 00 00 nop
if ((fp = fopen("/etc/group", "r")) == NULL) {
202d3dc: 11 00 81 ab sethi %hi(0x206ac00), %o0
202d3e0: 13 00 81 ab sethi %hi(0x206ac00), %o1
202d3e4: 90 12 22 90 or %o0, 0x290, %o0
202d3e8: 40 00 76 ce call 204af20 <fopen>
202d3ec: 92 12 62 18 or %o1, 0x218, %o1
202d3f0: a0 92 20 00 orcc %o0, 0, %l0
202d3f4: 12 80 00 0b bne 202d420 <getgr_r+0x50> <== ALWAYS TAKEN
202d3f8: 92 10 00 1a mov %i2, %o1
202d3fc: 30 80 00 27 b,a 202d498 <getgr_r+0xc8> <== NOT EXECUTED
errno = EINVAL;
fclose(fp);
return -1;
}
if (name) {
match = (strcmp(grp->gr_name, name) == 0);
202d400: 40 00 8d db call 2050b6c <strcmp>
202d404: 92 10 00 18 mov %i0, %o1
202d408: 80 a0 00 08 cmp %g0, %o0
202d40c: 82 60 3f ff subx %g0, -1, %g1
}
else {
match = (grp->gr_gid == gid);
}
if (match) {
202d410: 80 a0 60 00 cmp %g1, 0
202d414: 12 80 00 14 bne 202d464 <getgr_r+0x94>
202d418: 90 10 00 10 mov %l0, %o0
if ((fp = fopen("/etc/group", "r")) == NULL) {
errno = EINVAL;
return -1;
}
for(;;) {
if (!scangr(fp, grp, buffer, bufsize)) {
202d41c: 92 10 00 1a mov %i2, %o1
202d420: 94 10 00 1b mov %i3, %o2
202d424: 96 10 00 1c mov %i4, %o3
202d428: 7f ff fe d1 call 202cf6c <scangr>
202d42c: 90 10 00 10 mov %l0, %o0
202d430: 80 a2 20 00 cmp %o0, 0
202d434: 02 80 00 11 be 202d478 <getgr_r+0xa8> <== NEVER TAKEN
202d438: 80 a6 20 00 cmp %i0, 0
errno = EINVAL;
fclose(fp);
return -1;
}
if (name) {
202d43c: 32 bf ff f1 bne,a 202d400 <getgr_r+0x30> <== ALWAYS TAKEN
202d440: d0 06 80 00 ld [ %i2 ], %o0
match = (strcmp(grp->gr_name, name) == 0);
}
else {
match = (grp->gr_gid == gid);
202d444: c2 16 a0 08 lduh [ %i2 + 8 ], %g1 <== NOT EXECUTED
202d448: 82 18 40 19 xor %g1, %i1, %g1 <== NOT EXECUTED
202d44c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
202d450: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
}
if (match) {
202d454: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d458: 02 bf ff f2 be 202d420 <getgr_r+0x50> <== NOT EXECUTED
202d45c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
fclose(fp);
202d460: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202d464: 40 00 74 5f call 204a5e0 <fclose>
202d468: b0 10 20 00 clr %i0
*result = grp;
202d46c: f4 27 40 00 st %i2, [ %i5 ]
}
}
fclose(fp);
errno = EINVAL;
return -1;
}
202d470: 81 c7 e0 08 ret
202d474: 81 e8 00 00 restore
errno = EINVAL;
return -1;
}
for(;;) {
if (!scangr(fp, grp, buffer, bufsize)) {
errno = EINVAL;
202d478: 40 00 74 02 call 204a480 <__errno> <== NOT EXECUTED
202d47c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202d480: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
202d484: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
fclose(fp);
202d488: 40 00 74 56 call 204a5e0 <fclose> <== NOT EXECUTED
202d48c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
202d490: 81 c7 e0 08 ret <== NOT EXECUTED
202d494: 81 e8 00 00 restore <== NOT EXECUTED
int match;
init_etc_passwd_group();
if ((fp = fopen("/etc/group", "r")) == NULL) {
errno = EINVAL;
202d498: 40 00 73 fa call 204a480 <__errno> <== NOT EXECUTED
202d49c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202d4a0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
202d4a4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
202d4a8: 81 c7 e0 08 ret <== NOT EXECUTED
202d4ac: 81 e8 00 00 restore <== NOT EXECUTED
0202d0ec <getgrent>:
return NULL;
return p;
}
struct group *getgrent(void)
{
202d0ec: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (group_fp == NULL)
202d0f0: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
202d0f4: d0 00 61 5c ld [ %g1 + 0x15c ], %o0 ! 207495c <group_fp> <== NOT EXECUTED
202d0f8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d0fc: 32 80 00 04 bne,a 202d10c <getgrent+0x20> <== NOT EXECUTED
202d100: 31 00 81 d2 sethi %hi(0x2074800), %i0 <== NOT EXECUTED
return NULL;
if (!scangr(group_fp, &grent, grbuf, sizeof grbuf))
return NULL;
return &grent;
}
202d104: 81 c7 e0 08 ret <== NOT EXECUTED
202d108: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
struct group *getgrent(void)
{
if (group_fp == NULL)
return NULL;
if (!scangr(group_fp, &grent, grbuf, sizeof grbuf))
202d10c: 15 00 81 d2 sethi %hi(0x2074800), %o2 <== NOT EXECUTED
202d110: 92 16 22 28 or %i0, 0x228, %o1 <== NOT EXECUTED
202d114: 94 12 a1 60 or %o2, 0x160, %o2 <== NOT EXECUTED
202d118: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED
202d11c: 7f ff ff 94 call 202cf6c <scangr> <== NOT EXECUTED
202d120: b0 16 22 28 or %i0, 0x228, %i0 <== NOT EXECUTED
202d124: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d128: 02 bf ff f7 be 202d104 <getgrent+0x18> <== NOT EXECUTED
202d12c: 01 00 00 00 nop <== NOT EXECUTED
return NULL;
return &grent;
}
202d130: 81 c7 e0 08 ret <== NOT EXECUTED
202d134: 81 e8 00 00 restore <== NOT EXECUTED
0202d4e4 <getgrgid>:
}
struct group *getgrgid(
gid_t gid
)
{
202d4e4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
struct group *p;
if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p))
202d4e8: 13 00 81 d2 sethi %hi(0x2074800), %o1 <== NOT EXECUTED
202d4ec: 91 2e 20 10 sll %i0, 0x10, %o0 <== NOT EXECUTED
202d4f0: 92 12 62 28 or %o1, 0x228, %o1 <== NOT EXECUTED
202d4f4: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED
202d4f8: 15 00 81 d2 sethi %hi(0x2074800), %o2 <== NOT EXECUTED
202d4fc: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED
202d500: 94 12 a1 60 or %o2, 0x160, %o2 <== NOT EXECUTED
202d504: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
202d508: 7f ff ff ea call 202d4b0 <getgrgid_r> <== NOT EXECUTED
202d50c: b0 10 20 00 clr %i0 <== NOT EXECUTED
202d510: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d514: 22 80 00 02 be,a 202d51c <getgrgid+0x38> <== NOT EXECUTED
202d518: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
return NULL;
return p;
}
202d51c: 81 c7 e0 08 ret <== NOT EXECUTED
202d520: 81 e8 00 00 restore <== NOT EXECUTED
0202d4b0 <getgrgid_r>:
struct group *grp,
char *buffer,
size_t bufsize,
struct group **result
)
{
202d4b0: 84 10 00 0a mov %o2, %g2 <== NOT EXECUTED
202d4b4: 82 10 00 0b mov %o3, %g1 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
202d4b8: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
struct group *grp,
char *buffer,
size_t bufsize,
struct group **result
)
{
202d4bc: 9a 10 00 0c mov %o4, %o5 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
202d4c0: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
202d4c4: 96 10 00 02 mov %g2, %o3 <== NOT EXECUTED
202d4c8: 93 32 20 10 srl %o0, 0x10, %o1 <== NOT EXECUTED
202d4cc: 98 10 00 01 mov %g1, %o4 <== NOT EXECUTED
202d4d0: 90 10 20 00 clr %o0 <== NOT EXECUTED
202d4d4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202d4d8: 7f ff ff be call 202d3d0 <getgr_r> <== NOT EXECUTED
202d4dc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0202d550 <getgrnam>:
}
struct group *getgrnam(
const char *name
)
{
202d550: 9d e3 bf 98 save %sp, -104, %sp
struct group *p;
if(getgrnam_r(name, &grent, grbuf, sizeof grbuf, &p))
202d554: 13 00 81 d2 sethi %hi(0x2074800), %o1
202d558: 90 10 00 18 mov %i0, %o0
202d55c: 92 12 62 28 or %o1, 0x228, %o1
202d560: 15 00 81 d2 sethi %hi(0x2074800), %o2
202d564: 96 10 20 c8 mov 0xc8, %o3
202d568: 94 12 a1 60 or %o2, 0x160, %o2
202d56c: 98 07 bf fc add %fp, -4, %o4
202d570: 7f ff ff ed call 202d524 <getgrnam_r>
202d574: b0 10 20 00 clr %i0
202d578: 80 a2 20 00 cmp %o0, 0
202d57c: 22 80 00 02 be,a 202d584 <getgrnam+0x34> <== ALWAYS TAKEN
202d580: f0 07 bf fc ld [ %fp + -4 ], %i0
return NULL;
return p;
}
202d584: 81 c7 e0 08 ret
202d588: 81 e8 00 00 restore
0202d5d0 <getpw_r>:
struct passwd *pwd,
char *buffer,
size_t bufsize,
struct passwd **result
)
{
202d5d0: 9d e3 bf a0 save %sp, -96, %sp
FILE *fp;
int match;
init_etc_passwd_group();
202d5d4: 7f ff ff 33 call 202d2a0 <init_etc_passwd_group>
202d5d8: 01 00 00 00 nop
if ((fp = fopen("/etc/passwd", "r")) == NULL) {
202d5dc: 11 00 81 ab sethi %hi(0x206ac00), %o0
202d5e0: 13 00 81 ab sethi %hi(0x206ac00), %o1
202d5e4: 90 12 22 08 or %o0, 0x208, %o0
202d5e8: 40 00 76 4e call 204af20 <fopen>
202d5ec: 92 12 62 18 or %o1, 0x218, %o1
202d5f0: a0 92 20 00 orcc %o0, 0, %l0
202d5f4: 12 80 00 0b bne 202d620 <getpw_r+0x50> <== ALWAYS TAKEN
202d5f8: 92 10 00 1a mov %i2, %o1
202d5fc: 30 80 00 27 b,a 202d698 <getpw_r+0xc8> <== NOT EXECUTED
errno = EINVAL;
fclose(fp);
return -1;
}
if (name) {
match = (strcmp(pwd->pw_name, name) == 0);
202d600: 40 00 8d 5b call 2050b6c <strcmp>
202d604: 92 10 00 18 mov %i0, %o1
202d608: 80 a0 00 08 cmp %g0, %o0
202d60c: 82 60 3f ff subx %g0, -1, %g1
}
else {
match = (pwd->pw_uid == uid);
}
if (match) {
202d610: 80 a0 60 00 cmp %g1, 0
202d614: 12 80 00 14 bne 202d664 <getpw_r+0x94>
202d618: 90 10 00 10 mov %l0, %o0
if ((fp = fopen("/etc/passwd", "r")) == NULL) {
errno = EINVAL;
return -1;
}
for(;;) {
if (!scanpw(fp, pwd, buffer, bufsize)) {
202d61c: 92 10 00 1a mov %i2, %o1
202d620: 94 10 00 1b mov %i3, %o2
202d624: 96 10 00 1c mov %i4, %o3
202d628: 7f ff fe c4 call 202d138 <scanpw>
202d62c: 90 10 00 10 mov %l0, %o0
202d630: 80 a2 20 00 cmp %o0, 0
202d634: 02 80 00 11 be 202d678 <getpw_r+0xa8> <== NEVER TAKEN
202d638: 80 a6 20 00 cmp %i0, 0
errno = EINVAL;
fclose(fp);
return -1;
}
if (name) {
202d63c: 32 bf ff f1 bne,a 202d600 <getpw_r+0x30> <== ALWAYS TAKEN
202d640: d0 06 80 00 ld [ %i2 ], %o0
match = (strcmp(pwd->pw_name, name) == 0);
}
else {
match = (pwd->pw_uid == uid);
202d644: c2 16 a0 08 lduh [ %i2 + 8 ], %g1 <== NOT EXECUTED
202d648: 82 18 40 19 xor %g1, %i1, %g1 <== NOT EXECUTED
202d64c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
202d650: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
}
if (match) {
202d654: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d658: 02 bf ff f2 be 202d620 <getpw_r+0x50> <== NOT EXECUTED
202d65c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
fclose(fp);
202d660: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202d664: 40 00 73 df call 204a5e0 <fclose>
202d668: b0 10 20 00 clr %i0
*result = pwd;
202d66c: f4 27 40 00 st %i2, [ %i5 ]
}
}
fclose(fp);
errno = EINVAL;
return -1;
}
202d670: 81 c7 e0 08 ret
202d674: 81 e8 00 00 restore
errno = EINVAL;
return -1;
}
for(;;) {
if (!scanpw(fp, pwd, buffer, bufsize)) {
errno = EINVAL;
202d678: 40 00 73 82 call 204a480 <__errno> <== NOT EXECUTED
202d67c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202d680: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
202d684: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
fclose(fp);
202d688: 40 00 73 d6 call 204a5e0 <fclose> <== NOT EXECUTED
202d68c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
202d690: 81 c7 e0 08 ret <== NOT EXECUTED
202d694: 81 e8 00 00 restore <== NOT EXECUTED
int match;
init_etc_passwd_group();
if ((fp = fopen("/etc/passwd", "r")) == NULL) {
errno = EINVAL;
202d698: 40 00 73 7a call 204a480 <__errno> <== NOT EXECUTED
202d69c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202d6a0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
202d6a4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
202d6a8: 81 c7 e0 08 ret <== NOT EXECUTED
202d6ac: 81 e8 00 00 restore <== NOT EXECUTED
0202d254 <getpwent>:
return NULL;
return p;
}
struct passwd *getpwent(void)
{
202d254: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (passwd_fp == NULL)
202d258: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
202d25c: d0 00 60 74 ld [ %g1 + 0x74 ], %o0 ! 2074874 <passwd_fp> <== NOT EXECUTED
202d260: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d264: 32 80 00 04 bne,a 202d274 <getpwent+0x20> <== NOT EXECUTED
202d268: 31 00 81 d2 sethi %hi(0x2074800), %i0 <== NOT EXECUTED
return NULL;
if (!scanpw(passwd_fp, &pwent, pwbuf, sizeof pwbuf))
return NULL;
return &pwent;
}
202d26c: 81 c7 e0 08 ret <== NOT EXECUTED
202d270: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
struct passwd *getpwent(void)
{
if (passwd_fp == NULL)
return NULL;
if (!scanpw(passwd_fp, &pwent, pwbuf, sizeof pwbuf))
202d274: 15 00 81 d2 sethi %hi(0x2074800), %o2 <== NOT EXECUTED
202d278: 92 16 21 40 or %i0, 0x140, %o1 <== NOT EXECUTED
202d27c: 94 12 a0 78 or %o2, 0x78, %o2 <== NOT EXECUTED
202d280: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED
202d284: 7f ff ff ad call 202d138 <scanpw> <== NOT EXECUTED
202d288: b0 16 21 40 or %i0, 0x140, %i0 <== NOT EXECUTED
202d28c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d290: 02 bf ff f7 be 202d26c <getpwent+0x18> <== NOT EXECUTED
202d294: 01 00 00 00 nop <== NOT EXECUTED
return NULL;
return &pwent;
}
202d298: 81 c7 e0 08 ret <== NOT EXECUTED
202d29c: 81 e8 00 00 restore <== NOT EXECUTED
0202d750 <getpwnam>:
}
struct passwd *getpwnam(
const char *name
)
{
202d750: 9d e3 bf 98 save %sp, -104, %sp
struct passwd *p;
if(getpwnam_r(name, &pwent, pwbuf, sizeof pwbuf, &p))
202d754: 13 00 81 d2 sethi %hi(0x2074800), %o1
202d758: 90 10 00 18 mov %i0, %o0
202d75c: 92 12 61 40 or %o1, 0x140, %o1
202d760: 15 00 81 d2 sethi %hi(0x2074800), %o2
202d764: 96 10 20 c8 mov 0xc8, %o3
202d768: 94 12 a0 78 or %o2, 0x78, %o2
202d76c: 98 07 bf fc add %fp, -4, %o4
202d770: 7f ff ff ed call 202d724 <getpwnam_r>
202d774: b0 10 20 00 clr %i0
202d778: 80 a2 20 00 cmp %o0, 0
202d77c: 22 80 00 02 be,a 202d784 <getpwnam+0x34> <== ALWAYS TAKEN
202d780: f0 07 bf fc ld [ %fp + -4 ], %i0
return NULL;
return p;
}
202d784: 81 c7 e0 08 ret
202d788: 81 e8 00 00 restore
0202d6e4 <getpwuid>:
}
struct passwd *getpwuid(
uid_t uid
)
{
202d6e4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
struct passwd *p;
if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p))
202d6e8: 13 00 81 d2 sethi %hi(0x2074800), %o1 <== NOT EXECUTED
202d6ec: 91 2e 20 10 sll %i0, 0x10, %o0 <== NOT EXECUTED
202d6f0: 92 12 61 40 or %o1, 0x140, %o1 <== NOT EXECUTED
202d6f4: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED
202d6f8: 15 00 81 d2 sethi %hi(0x2074800), %o2 <== NOT EXECUTED
202d6fc: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED
202d700: 94 12 a0 78 or %o2, 0x78, %o2 <== NOT EXECUTED
202d704: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
202d708: 7f ff ff ea call 202d6b0 <getpwuid_r> <== NOT EXECUTED
202d70c: b0 10 20 00 clr %i0 <== NOT EXECUTED
202d710: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d714: 22 80 00 02 be,a 202d71c <getpwuid+0x38> <== NOT EXECUTED
202d718: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
return NULL;
return p;
}
202d71c: 81 c7 e0 08 ret <== NOT EXECUTED
202d720: 81 e8 00 00 restore <== NOT EXECUTED
0202d6b0 <getpwuid_r>:
struct passwd *pwd,
char *buffer,
size_t bufsize,
struct passwd **result
)
{
202d6b0: 84 10 00 0a mov %o2, %g2 <== NOT EXECUTED
202d6b4: 82 10 00 0b mov %o3, %g1 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
202d6b8: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
struct passwd *pwd,
char *buffer,
size_t bufsize,
struct passwd **result
)
{
202d6bc: 9a 10 00 0c mov %o4, %o5 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
202d6c0: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
202d6c4: 96 10 00 02 mov %g2, %o3 <== NOT EXECUTED
202d6c8: 93 32 20 10 srl %o0, 0x10, %o1 <== NOT EXECUTED
202d6cc: 98 10 00 01 mov %g1, %o4 <== NOT EXECUTED
202d6d0: 90 10 20 00 clr %o0 <== NOT EXECUTED
202d6d4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202d6d8: 7f ff ff be call 202d5d0 <getpw_r> <== NOT EXECUTED
202d6dc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02002d98 <gettimeofday>:
*/
int gettimeofday(
struct timeval *tp,
void * __tz __attribute__((unused))
)
{
2002d98: 9d e3 bf 98 save %sp, -104, %sp
/* struct timezone* tzp = (struct timezone*) __tz; */
if ( !tp ) {
2002d9c: 80 a6 20 00 cmp %i0, 0
2002da0: 02 80 00 11 be 2002de4 <gettimeofday+0x4c> <== NEVER TAKEN
2002da4: 01 00 00 00 nop
{
ISR_Level level;
struct timespec now;
suseconds_t useconds;
_ISR_Disable(level);
2002da8: 7f ff fc bf call 20020a4 <sparc_disable_interrupts>
2002dac: 01 00 00 00 nop
2002db0: a0 10 00 08 mov %o0, %l0
_TOD_Get( &now );
2002db4: 40 00 12 8f call 20077f0 <_TOD_Get>
2002db8: 90 07 bf f8 add %fp, -8, %o0
_ISR_Enable(level);
2002dbc: 7f ff fc be call 20020b4 <sparc_enable_interrupts>
2002dc0: 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;
2002dc4: 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;
2002dc8: c2 07 bf f8 ld [ %fp + -8 ], %g1
time->tv_usec = useconds;
2002dcc: 92 10 23 e8 mov 0x3e8, %o1
2002dd0: 40 00 60 60 call 201af50 <.div>
2002dd4: c2 26 00 00 st %g1, [ %i0 ]
2002dd8: 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;
}
2002ddc: 81 c7 e0 08 ret
2002de0: 91 e8 20 00 restore %g0, 0, %o0
void * __tz __attribute__((unused))
)
{
/* struct timezone* tzp = (struct timezone*) __tz; */
if ( !tp ) {
errno = EFAULT;
2002de4: 40 00 3b 06 call 20119fc <__errno> <== NOT EXECUTED
2002de8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002dec: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
2002df0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
2002df4: 81 c7 e0 08 ret <== NOT EXECUTED
2002df8: 81 e8 00 00 restore <== NOT EXECUTED
02008a14 <getuid>:
* 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs,
* P1003.1b-1993, p. 84
*/
uid_t getuid( void )
{
2008a14: 03 00 81 c3 sethi %hi(0x2070c00), %g1 <== NOT EXECUTED
2008a18: c2 00 62 24 ld [ %g1 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
return _POSIX_types_Uid;
}
2008a1c: 81 c3 e0 08 retl <== NOT EXECUTED
2008a20: d0 10 60 32 lduh [ %g1 + 0x32 ], %o0 <== NOT EXECUTED
02010108 <imfs_dir_open>:
)
{
IMFS_jnode_t *the_jnode;
/* Is the node a directory ? */
the_jnode = (IMFS_jnode_t *) iop->file_info;
2010108: c4 02 20 3c ld [ %o0 + 0x3c ], %g2
201010c: c4 00 a0 4c ld [ %g2 + 0x4c ], %g2
2010110: 80 a0 a0 01 cmp %g2, 1
2010114: 12 80 00 05 bne 2010128 <imfs_dir_open+0x20> <== NEVER TAKEN
2010118: 82 10 3f ff mov -1, %g1
if ( the_jnode->type != IMFS_DIRECTORY )
return -1; /* It wasn't a directory --> return error */
iop->offset = 0;
201011c: c0 22 20 10 clr [ %o0 + 0x10 ]
2010120: c0 22 20 14 clr [ %o0 + 0x14 ]
2010124: 82 10 20 00 clr %g1
return 0;
}
2010128: 81 c3 e0 08 retl
201012c: 90 10 00 01 mov %g1, %o0
02010388 <imfs_dir_read>:
ssize_t imfs_dir_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
2010388: 9d e3 be 88 save %sp, -376, %sp
int current_entry;
int first_entry;
int last_entry;
struct dirent tmp_dirent;
the_jnode = (IMFS_jnode_t *)iop->file_info;
201038c: e4 06 20 3c ld [ %i0 + 0x3c ], %l2
ssize_t imfs_dir_read(
rtems_libio_t *iop,
void *buffer,
size_t count
)
{
2010390: a0 10 00 18 mov %i0, %l0
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
2010394: e2 04 a0 50 ld [ %l2 + 0x50 ], %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2010398: a4 04 a0 54 add %l2, 0x54, %l2
struct dirent tmp_dirent;
the_jnode = (IMFS_jnode_t *)iop->file_info;
the_chain = &the_jnode->info.directory.Entries;
if ( rtems_chain_is_empty( the_chain ) )
201039c: 80 a4 40 12 cmp %l1, %l2
20103a0: 02 80 00 36 be 2010478 <imfs_dir_read+0xf0>
20103a4: b0 10 20 00 clr %i0
/* Move to the first of the desired directory entries */
the_node = the_chain->first;
bytes_transferred = 0;
first_entry = iop->offset;
20103a8: ea 04 20 14 ld [ %l0 + 0x14 ], %l5
/* protect against using sizes that are not exact multiples of the */
/* -dirent- size. These could result in unexpected results */
last_entry = first_entry + (count/sizeof(struct dirent)) * sizeof(struct dirent);
20103ac: 90 10 00 1a mov %i2, %o0
20103b0: 40 00 2a e6 call 201af48 <.udiv>
20103b4: 92 10 21 18 mov 0x118, %o1
20103b8: 85 2a 20 05 sll %o0, 5, %g2
20103bc: 83 2a 20 03 sll %o0, 3, %g1
20103c0: 82 00 40 02 add %g1, %g2, %g1
20103c4: a9 28 60 03 sll %g1, 3, %l4
20103c8: a8 25 00 01 sub %l4, %g1, %l4
20103cc: a8 05 00 15 add %l4, %l5, %l4
/* The directory was not empty so try to move to the desired entry in chain*/
for (
20103d0: 80 a5 20 00 cmp %l4, 0
20103d4: 04 80 00 29 ble 2010478 <imfs_dir_read+0xf0> <== NEVER TAKEN
20103d8: a6 10 20 00 clr %l3
}
if( current_entry >= first_entry ) {
/* Move the entry to the return buffer */
tmp_dirent.d_off = current_entry;
tmp_dirent.d_reclen = sizeof( struct dirent );
20103dc: ba 10 21 18 mov 0x118, %i5
the_jnode = (IMFS_jnode_t *) the_node;
tmp_dirent.d_ino = the_jnode->st_ino;
tmp_dirent.d_namlen = strlen( the_jnode->name );
strcpy( tmp_dirent.d_name, the_jnode->name );
20103e0: ae 07 be e8 add %fp, -280, %l7
20103e4: 10 80 00 08 b 2010404 <imfs_dir_read+0x7c>
20103e8: ac 07 be fc add %fp, -260, %l6
/* protect against using sizes that are not exact multiples of the */
/* -dirent- size. These could result in unexpected results */
last_entry = first_entry + (count/sizeof(struct dirent)) * sizeof(struct dirent);
/* The directory was not empty so try to move to the desired entry in chain*/
for (
20103ec: 80 a4 c0 14 cmp %l3, %l4
20103f0: 16 80 00 22 bge 2010478 <imfs_dir_read+0xf0> <== NEVER TAKEN
20103f4: e2 04 40 00 ld [ %l1 ], %l1
current_entry = 0;
current_entry < last_entry;
current_entry = current_entry + sizeof(struct dirent) ){
if ( rtems_chain_is_tail( the_chain, the_node ) ){
20103f8: 80 a4 40 12 cmp %l1, %l2
20103fc: 02 80 00 21 be 2010480 <imfs_dir_read+0xf8>
2010400: 01 00 00 00 nop
/* entry in the read */
return bytes_transferred; /* Indicate that there are no more */
/* entries to return */
}
if( current_entry >= first_entry ) {
2010404: 80 a5 40 13 cmp %l5, %l3
2010408: 34 bf ff f9 bg,a 20103ec <imfs_dir_read+0x64>
201040c: a6 04 e1 18 add %l3, 0x118, %l3
/* Move the entry to the return buffer */
tmp_dirent.d_off = current_entry;
tmp_dirent.d_reclen = sizeof( struct dirent );
the_jnode = (IMFS_jnode_t *) the_node;
tmp_dirent.d_ino = the_jnode->st_ino;
2010410: c2 04 60 38 ld [ %l1 + 0x38 ], %g1
tmp_dirent.d_namlen = strlen( the_jnode->name );
2010414: b8 04 60 0c add %l1, 0xc, %i4
if( current_entry >= first_entry ) {
/* Move the entry to the return buffer */
tmp_dirent.d_off = current_entry;
tmp_dirent.d_reclen = sizeof( struct dirent );
the_jnode = (IMFS_jnode_t *) the_node;
tmp_dirent.d_ino = the_jnode->st_ino;
2010418: c2 27 be e8 st %g1, [ %fp + -280 ]
/* entries to return */
}
if( current_entry >= first_entry ) {
/* Move the entry to the return buffer */
tmp_dirent.d_off = current_entry;
201041c: 83 3c e0 1f sra %l3, 0x1f, %g1
2010420: e6 27 be f4 st %l3, [ %fp + -268 ]
2010424: c2 27 be f0 st %g1, [ %fp + -272 ]
tmp_dirent.d_reclen = sizeof( struct dirent );
2010428: fa 37 be f8 sth %i5, [ %fp + -264 ]
the_jnode = (IMFS_jnode_t *) the_node;
tmp_dirent.d_ino = the_jnode->st_ino;
tmp_dirent.d_namlen = strlen( the_jnode->name );
201042c: 40 00 09 41 call 2012930 <strlen>
2010430: 90 10 00 1c mov %i4, %o0
strcpy( tmp_dirent.d_name, the_jnode->name );
2010434: 92 10 00 1c mov %i4, %o1
/* Move the entry to the return buffer */
tmp_dirent.d_off = current_entry;
tmp_dirent.d_reclen = sizeof( struct dirent );
the_jnode = (IMFS_jnode_t *) the_node;
tmp_dirent.d_ino = the_jnode->st_ino;
tmp_dirent.d_namlen = strlen( the_jnode->name );
2010438: d0 37 be fa sth %o0, [ %fp + -262 ]
strcpy( tmp_dirent.d_name, the_jnode->name );
201043c: 40 00 09 05 call 2012850 <strcpy>
2010440: 90 10 00 16 mov %l6, %o0
memcpy(
2010444: 90 06 40 18 add %i1, %i0, %o0
2010448: 92 10 00 17 mov %l7, %o1
201044c: 40 00 07 a8 call 20122ec <memcpy>
2010450: 94 10 21 18 mov 0x118, %o2
buffer + bytes_transferred,
(void *)&tmp_dirent,
sizeof( struct dirent )
);
iop->offset = iop->offset + sizeof(struct dirent);
2010454: c4 1c 20 10 ldd [ %l0 + 0x10 ], %g2
* to the end of the exisiting file, the remaining entries will be placed in
* the buffer and the returned value will be equal to -m actual- times the
* size of a directory entry.
*/
ssize_t imfs_dir_read(
2010458: a6 04 e1 18 add %l3, 0x118, %l3
memcpy(
buffer + bytes_transferred,
(void *)&tmp_dirent,
sizeof( struct dirent )
);
iop->offset = iop->offset + sizeof(struct dirent);
201045c: 86 80 e1 18 addcc %g3, 0x118, %g3
2010460: 84 40 a0 00 addx %g2, 0, %g2
2010464: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
bytes_transferred = bytes_transferred + sizeof( struct dirent );
2010468: b0 06 21 18 add %i0, 0x118, %i0
/* protect against using sizes that are not exact multiples of the */
/* -dirent- size. These could result in unexpected results */
last_entry = first_entry + (count/sizeof(struct dirent)) * sizeof(struct dirent);
/* The directory was not empty so try to move to the desired entry in chain*/
for (
201046c: 80 a4 c0 14 cmp %l3, %l4
2010470: 06 bf ff e2 bl 20103f8 <imfs_dir_read+0x70> <== NEVER TAKEN
2010474: e2 04 40 00 ld [ %l1 ], %l1
the_node = the_node->next;
}
/* Success */
return bytes_transferred;
}
2010478: 81 c7 e0 08 ret
201047c: 81 e8 00 00 restore
2010480: 81 c7 e0 08 ret
2010484: 81 e8 00 00 restore
02010284 <imfs_dir_rmnod>:
int imfs_dir_rmnod(
rtems_filesystem_location_info_t *parent_pathloc, /* IN */
rtems_filesystem_location_info_t *pathloc /* IN */
)
{
2010284: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode;
the_jnode = (IMFS_jnode_t *) pathloc->node_access;
2010288: e0 06 40 00 ld [ %i1 ], %l0
201028c: c4 04 20 50 ld [ %l0 + 0x50 ], %g2
2010290: 82 04 20 54 add %l0, 0x54, %g1
2010294: 80 a0 80 01 cmp %g2, %g1
2010298: 12 80 00 30 bne 2010358 <imfs_dir_rmnod+0xd4>
201029c: 01 00 00 00 nop
/*
* You cannot remove the file system root node.
*/
if ( pathloc->mt_entry->mt_fs_root.node_access == pathloc->node_access )
20102a0: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
20102a4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20102a8: 80 a4 00 01 cmp %l0, %g1
20102ac: 02 80 00 31 be 2010370 <imfs_dir_rmnod+0xec>
20102b0: 01 00 00 00 nop
/*
* You cannot remove a mountpoint.
*/
if ( the_jnode->info.directory.mt_fs != NULL )
20102b4: c2 04 20 5c ld [ %l0 + 0x5c ], %g1
20102b8: 80 a0 60 00 cmp %g1, 0
20102bc: 12 80 00 2d bne 2010370 <imfs_dir_rmnod+0xec> <== NEVER TAKEN
20102c0: 01 00 00 00 nop
/*
* Take the node out of the parent's chain that contains this node
*/
if ( the_jnode->Parent != NULL ) {
20102c4: c2 04 20 08 ld [ %l0 + 8 ], %g1
20102c8: 80 a0 60 00 cmp %g1, 0
20102cc: 22 80 00 06 be,a 20102e4 <imfs_dir_rmnod+0x60>
20102d0: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
20102d4: 7f ff dc 1c call 2007344 <_Chain_Extract>
20102d8: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode );
the_jnode->Parent = NULL;
20102dc: c0 24 20 08 clr [ %l0 + 8 ]
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
20102e0: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
20102e4: 92 10 20 00 clr %o1
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
20102e8: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
20102ec: 90 07 bf f8 add %fp, -8, %o0
20102f0: 7f ff ca aa call 2002d98 <gettimeofday>
20102f4: c2 34 20 34 sth %g1, [ %l0 + 0x34 ]
20102f8: 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) ) {
20102fc: 90 10 00 10 mov %l0, %o0
2010300: 7f ff f2 2c call 200cbb0 <rtems_libio_is_file_open>
2010304: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
2010308: 80 a2 20 00 cmp %o0, 0
201030c: 12 80 00 11 bne 2010350 <imfs_dir_rmnod+0xcc>
2010310: 01 00 00 00 nop
2010314: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
2010318: 80 a0 60 00 cmp %g1, 0
201031c: 12 80 00 0d bne 2010350 <imfs_dir_rmnod+0xcc>
2010320: 03 00 80 7a sethi %hi(0x201e800), %g1
/*
* Is the rtems_filesystem_current is this node?
*/
if ( rtems_filesystem_current.node_access == pathloc->node_access )
2010324: c2 00 61 80 ld [ %g1 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
2010328: c4 06 40 00 ld [ %i1 ], %g2
201032c: c6 00 60 04 ld [ %g1 + 4 ], %g3
2010330: 80 a0 c0 02 cmp %g3, %g2
2010334: 22 80 00 02 be,a 201033c <imfs_dir_rmnod+0xb8> <== NEVER TAKEN
2010338: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
/*
* Free memory associated with a memory file.
*/
free( the_jnode );
201033c: 90 10 00 10 mov %l0, %o0
2010340: 7f ff ca 6b call 2002cec <free>
2010344: b0 10 20 00 clr %i0
2010348: 81 c7 e0 08 ret
201034c: 81 e8 00 00 restore
}
return 0;
}
2010350: 81 c7 e0 08 ret
2010354: 91 e8 20 00 restore %g0, 0, %o0
/*
* 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 );
2010358: 40 00 05 a9 call 20119fc <__errno>
201035c: b0 10 3f ff mov -1, %i0
2010360: 82 10 20 5a mov 0x5a, %g1
2010364: c2 22 00 00 st %g1, [ %o0 ]
2010368: 81 c7 e0 08 ret
201036c: 81 e8 00 00 restore
/*
* You cannot remove a mountpoint.
*/
if ( the_jnode->info.directory.mt_fs != NULL )
rtems_set_errno_and_return_minus_one( EBUSY );
2010370: 40 00 05 a3 call 20119fc <__errno>
2010374: b0 10 3f ff mov -1, %i0
2010378: 82 10 20 10 mov 0x10, %g1
201037c: c2 22 00 00 st %g1, [ %o0 ]
2010380: 81 c7 e0 08 ret
2010384: 81 e8 00 00 restore
0202d2a0 <init_etc_passwd_group>:
/*
* Initialize useable but dummy databases
*/
void init_etc_passwd_group(void)
{
202d2a0: 9d e3 bf a0 save %sp, -96, %sp
FILE *fp;
static char etc_passwd_initted = 0;
if (etc_passwd_initted)
202d2a4: 03 00 81 d2 sethi %hi(0x2074800), %g1
202d2a8: c4 48 60 70 ldsb [ %g1 + 0x70 ], %g2 ! 2074870 <etc_passwd_initted.6451>
202d2ac: 80 a0 a0 00 cmp %g2, 0
202d2b0: 02 80 00 04 be 202d2c0 <init_etc_passwd_group+0x20>
202d2b4: 84 10 20 01 mov 1, %g2
202d2b8: 81 c7 e0 08 ret
202d2bc: 81 e8 00 00 restore
return;
etc_passwd_initted = 1;
mkdir("/etc", 0777);
202d2c0: 92 10 21 ff mov 0x1ff, %o1
FILE *fp;
static char etc_passwd_initted = 0;
if (etc_passwd_initted)
return;
etc_passwd_initted = 1;
202d2c4: c4 28 60 70 stb %g2, [ %g1 + 0x70 ]
mkdir("/etc", 0777);
202d2c8: 11 00 81 ab sethi %hi(0x206ac00), %o0
202d2cc: 7f ff 6f dd call 2009240 <mkdir>
202d2d0: 90 12 22 00 or %o0, 0x200, %o0 ! 206ae00 <IMFS_memfile_handlers+0xa8>
/*
* Initialize /etc/passwd
*/
if ((fp = fopen("/etc/passwd", "r")) != NULL) {
202d2d4: 31 00 81 ab sethi %hi(0x206ac00), %i0
202d2d8: 21 00 81 ab sethi %hi(0x206ac00), %l0
202d2dc: 90 16 22 08 or %i0, 0x208, %o0
202d2e0: 40 00 77 10 call 204af20 <fopen>
202d2e4: 92 14 22 18 or %l0, 0x218, %o1
202d2e8: 80 a2 20 00 cmp %o0, 0
202d2ec: 22 80 00 0d be,a 202d320 <init_etc_passwd_group+0x80> <== ALWAYS TAKEN
202d2f0: 90 16 22 08 or %i0, 0x208, %o0
}
else if ((fp = fopen("/etc/passwd", "w")) != NULL) {
fprintf(fp, "root:*:0:0:root::/:/bin/sh\n"
"rtems:*:1:1:RTEMS Application::/:/bin/sh\n"
"tty:!:2:2:tty owner::/:/bin/false\n" );
fclose(fp);
202d2f4: 40 00 74 bb call 204a5e0 <fclose>
202d2f8: 01 00 00 00 nop
}
/*
* Initialize /etc/group
*/
if ((fp = fopen("/etc/group", "r")) != NULL) {
202d2fc: 92 14 22 18 or %l0, 0x218, %o1
202d300: 21 00 81 ab sethi %hi(0x206ac00), %l0
202d304: 40 00 77 07 call 204af20 <fopen>
202d308: 90 14 22 90 or %l0, 0x290, %o0 ! 206ae90 <IMFS_memfile_handlers+0x138>
202d30c: 80 a2 20 00 cmp %o0, 0
202d310: 22 80 00 11 be,a 202d354 <init_etc_passwd_group+0xb4> <== ALWAYS TAKEN
202d314: 90 14 22 90 or %l0, 0x290, %o0
fclose(fp);
202d318: 40 00 74 b2 call 204a5e0 <fclose> <== NOT EXECUTED
202d31c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
* Initialize /etc/passwd
*/
if ((fp = fopen("/etc/passwd", "r")) != NULL) {
fclose(fp);
}
else if ((fp = fopen("/etc/passwd", "w")) != NULL) {
202d320: 13 00 81 ab sethi %hi(0x206ac00), %o1
202d324: 40 00 76 ff call 204af20 <fopen>
202d328: 92 12 62 20 or %o1, 0x220, %o1 ! 206ae20 <IMFS_memfile_handlers+0xc8>
202d32c: b0 92 20 00 orcc %o0, 0, %i0
202d330: 02 bf ff f3 be 202d2fc <init_etc_passwd_group+0x5c> <== NEVER TAKEN
202d334: 92 10 20 01 mov 1, %o1
fprintf(fp, "root:*:0:0:root::/:/bin/sh\n"
202d338: 94 10 20 66 mov 0x66, %o2
202d33c: 96 10 00 18 mov %i0, %o3
202d340: 11 00 81 ab sethi %hi(0x206ac00), %o0
202d344: 40 00 7b d7 call 204c2a0 <fwrite>
202d348: 90 12 22 28 or %o0, 0x228, %o0 ! 206ae28 <IMFS_memfile_handlers+0xd0>
"rtems:*:1:1:RTEMS Application::/:/bin/sh\n"
"tty:!:2:2:tty owner::/:/bin/false\n" );
fclose(fp);
202d34c: 10 bf ff ea b 202d2f4 <init_etc_passwd_group+0x54>
202d350: 90 10 00 18 mov %i0, %o0
* Initialize /etc/group
*/
if ((fp = fopen("/etc/group", "r")) != NULL) {
fclose(fp);
}
else if ((fp = fopen("/etc/group", "w")) != NULL) {
202d354: 13 00 81 ab sethi %hi(0x206ac00), %o1
202d358: 40 00 76 f2 call 204af20 <fopen>
202d35c: 92 12 62 20 or %o1, 0x220, %o1 ! 206ae20 <IMFS_memfile_handlers+0xc8>
202d360: b0 92 20 00 orcc %o0, 0, %i0
202d364: 02 bf ff d5 be 202d2b8 <init_etc_passwd_group+0x18> <== NEVER TAKEN
202d368: 11 00 81 ab sethi %hi(0x206ac00), %o0
fprintf( fp, "root:x:0:root\n"
202d36c: 92 10 20 01 mov 1, %o1
202d370: 94 10 20 2a mov 0x2a, %o2
202d374: 96 10 00 18 mov %i0, %o3
202d378: 40 00 7b ca call 204c2a0 <fwrite>
202d37c: 90 12 22 a0 or %o0, 0x2a0, %o0
"rtems:x:1:rtems\n"
"tty:x:2:tty\n" );
fclose(fp);
202d380: 40 00 74 98 call 204a5e0 <fclose>
202d384: 81 e8 00 00 restore
02006794 <ioctl>:
int ioctl(
int fd,
ioctl_command_t command,
...
)
{
2006794: 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 );
2006798: 03 00 80 8a sethi %hi(0x2022800), %g1
200679c: c2 00 63 34 ld [ %g1 + 0x334 ], %g1 ! 2022b34 <rtems_libio_number_iops>
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
va_start(ap, command);
20067a0: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
20067a4: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
20067a8: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
va_list ap;
rtems_status_code rc;
rtems_libio_t *iop;
void *buffer;
rtems_libio_check_fd( fd );
20067ac: 80 a6 00 01 cmp %i0, %g1
20067b0: 1a 80 00 18 bcc 2006810 <ioctl+0x7c>
20067b4: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
iop = rtems_libio_iop( fd );
20067b8: 03 00 80 8d sethi %hi(0x2023400), %g1
20067bc: d0 00 62 18 ld [ %g1 + 0x218 ], %o0 ! 2023618 <rtems_libio_iops>
20067c0: 83 2e 20 06 sll %i0, 6, %g1
20067c4: b1 2e 20 03 sll %i0, 3, %i0
20067c8: b0 06 00 01 add %i0, %g1, %i0
20067cc: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_is_open(iop);
20067d0: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
20067d4: 80 88 61 00 btst 0x100, %g1
20067d8: 02 80 00 0e be 2006810 <ioctl+0x7c> <== NEVER TAKEN
20067dc: 84 07 a0 50 add %fp, 0x50, %g2
/*
* Now process the ioctl().
*/
if ( !iop->handlers )
20067e0: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
20067e4: 80 a0 60 00 cmp %g1, 0
20067e8: 02 80 00 0a be 2006810 <ioctl+0x7c> <== NEVER TAKEN
20067ec: c4 27 bf fc st %g2, [ %fp + -4 ]
rtems_set_errno_and_return_minus_one( EBADF );
if ( !iop->handlers->ioctl_h )
20067f0: c2 00 60 10 ld [ %g1 + 0x10 ], %g1
20067f4: 80 a0 60 00 cmp %g1, 0
20067f8: 02 80 00 0c be 2006828 <ioctl+0x94> <== NEVER TAKEN
20067fc: 92 10 00 19 mov %i1, %o1
rtems_set_errno_and_return_minus_one( ENOTSUP );
rc = (*iop->handlers->ioctl_h)( iop, command, buffer );
2006800: 9f c0 40 00 call %g1
2006804: 94 10 00 1a mov %i2, %o2
return rc;
}
2006808: 81 c7 e0 08 ret
200680c: 91 e8 00 08 restore %g0, %o0, %o0
/*
* Now process the ioctl().
*/
if ( !iop->handlers )
rtems_set_errno_and_return_minus_one( EBADF );
2006810: 40 00 3e 03 call 201601c <__errno>
2006814: b0 10 3f ff mov -1, %i0
2006818: 82 10 20 09 mov 9, %g1
200681c: c2 22 00 00 st %g1, [ %o0 ]
2006820: 81 c7 e0 08 ret
2006824: 81 e8 00 00 restore
if ( !iop->handlers->ioctl_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
2006828: 40 00 3d fd call 201601c <__errno> <== NOT EXECUTED
200682c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2006830: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2006834: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2006838: 81 c7 e0 08 ret <== NOT EXECUTED
200683c: 81 e8 00 00 restore <== NOT EXECUTED
02004a18 <iproc>:
/*
* Process a single input character
*/
static int
iproc (unsigned char c, struct rtems_termios_tty *tty)
{
2004a18: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP)
2004a1c: c2 06 60 30 ld [ %i1 + 0x30 ], %g1 <== NOT EXECUTED
2004a20: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
2004a24: 02 80 00 03 be 2004a30 <iproc+0x18> <== NOT EXECUTED
2004a28: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
c &= 0x7f;
2004a2c: a0 0e 20 7f and %i0, 0x7f, %l0 <== NOT EXECUTED
if (tty->termios.c_iflag & IUCLC)
2004a30: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED
2004a34: 02 80 00 0c be 2004a64 <iproc+0x4c> <== NOT EXECUTED
2004a38: 84 0c 20 ff and %l0, 0xff, %g2 <== NOT EXECUTED
c = tolower (c);
2004a3c: 05 00 80 7a sethi %hi(0x201e800), %g2 <== NOT EXECUTED
2004a40: c4 00 a2 2c ld [ %g2 + 0x22c ], %g2 ! 201ea2c <__ctype_ptr__><== NOT EXECUTED
2004a44: a0 0c 20 ff and %l0, 0xff, %l0 <== NOT EXECUTED
2004a48: 84 00 80 10 add %g2, %l0, %g2 <== NOT EXECUTED
2004a4c: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED
2004a50: 84 08 a0 03 and %g2, 3, %g2 <== NOT EXECUTED
2004a54: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
2004a58: 22 80 00 02 be,a 2004a60 <iproc+0x48> <== NOT EXECUTED
2004a5c: a0 04 20 20 add %l0, 0x20, %l0 <== NOT EXECUTED
if (c == '\r') {
2004a60: 84 0c 20 ff and %l0, 0xff, %g2 <== NOT EXECUTED
2004a64: 80 a0 a0 0d cmp %g2, 0xd <== NOT EXECUTED
2004a68: 02 80 00 16 be 2004ac0 <iproc+0xa8> <== NOT EXECUTED
2004a6c: 80 a0 a0 0a cmp %g2, 0xa <== 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)) {
2004a70: 02 80 00 41 be 2004b74 <iproc+0x15c> <== NOT EXECUTED
2004a74: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
c = '\r';
}
if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {
2004a78: 32 80 00 1a bne,a 2004ae0 <iproc+0xc8> <== NOT EXECUTED
2004a7c: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED
}
/*
* FIXME: Should do IMAXBEL handling somehow
*/
if (tty->ccount < (CBUFSIZE-1)) {
2004a80: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
2004a84: 05 00 80 7a sethi %hi(0x201e800), %g2 <== NOT EXECUTED
2004a88: c4 00 a1 70 ld [ %g2 + 0x170 ], %g2 ! 201e970 <rtems_termios_cbufsize><== NOT EXECUTED
2004a8c: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
2004a90: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004a94: 16 80 00 09 bge 2004ab8 <iproc+0xa0> <== NOT EXECUTED
2004a98: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
2004a9c: c4 06 60 3c ld [ %i1 + 0x3c ], %g2 <== NOT EXECUTED
2004aa0: 80 88 a0 08 btst 8, %g2 <== NOT EXECUTED
2004aa4: 12 80 00 39 bne 2004b88 <iproc+0x170> <== NOT EXECUTED
2004aa8: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
echo (c, tty);
tty->cbuf[tty->ccount++] = c;
2004aac: c6 06 60 1c ld [ %i1 + 0x1c ], %g3 <== NOT EXECUTED
2004ab0: e0 28 c0 01 stb %l0, [ %g3 + %g1 ] <== NOT EXECUTED
2004ab4: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED
2004ab8: 81 c7 e0 08 ret <== NOT EXECUTED
2004abc: 81 e8 00 00 restore <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP)
c &= 0x7f;
if (tty->termios.c_iflag & IUCLC)
c = tolower (c);
if (c == '\r') {
if (tty->termios.c_iflag & IGNCR)
2004ac0: 80 88 60 80 btst 0x80, %g1 <== NOT EXECUTED
2004ac4: 02 80 00 04 be 2004ad4 <iproc+0xbc> <== NOT EXECUTED
2004ac8: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
echo (c, tty);
tty->cbuf[tty->ccount++] = c;
}
return 0;
}
2004acc: 81 c7 e0 08 ret <== NOT EXECUTED
2004ad0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if (tty->termios.c_iflag & IUCLC)
c = tolower (c);
if (c == '\r') {
if (tty->termios.c_iflag & IGNCR)
return 0;
if (tty->termios.c_iflag & ICRNL)
2004ad4: 32 80 00 02 bne,a 2004adc <iproc+0xc4> <== NOT EXECUTED
2004ad8: 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)) {
2004adc: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED
2004ae0: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2004ae4: 22 bf ff e8 be,a 2004a84 <iproc+0x6c> <== NOT EXECUTED
2004ae8: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
if (c == tty->termios.c_cc[VERASE]) {
2004aec: c4 0e 60 43 ldub [ %i1 + 0x43 ], %g2 <== NOT EXECUTED
2004af0: 90 0c 20 ff and %l0, 0xff, %o0 <== NOT EXECUTED
2004af4: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2004af8: 22 80 00 43 be,a 2004c04 <iproc+0x1ec> <== NOT EXECUTED
2004afc: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
erase (tty, 0);
return 0;
}
else if (c == tty->termios.c_cc[VKILL]) {
2004b00: c4 0e 60 44 ldub [ %i1 + 0x44 ], %g2 <== NOT EXECUTED
2004b04: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2004b08: 22 80 00 2e be,a 2004bc0 <iproc+0x1a8> <== NOT EXECUTED
2004b0c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
erase (tty, 1);
return 0;
}
else if (c == tty->termios.c_cc[VEOF]) {
2004b10: c4 0e 60 45 ldub [ %i1 + 0x45 ], %g2 <== NOT EXECUTED
2004b14: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2004b18: 02 bf ff e8 be 2004ab8 <iproc+0xa0> <== NOT EXECUTED
2004b1c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
return 1;
}
else if (c == '\n') {
2004b20: 80 a2 20 0a cmp %o0, 0xa <== NOT EXECUTED
2004b24: 02 80 00 2c be 2004bd4 <iproc+0x1bc> <== NOT EXECUTED
2004b28: 80 88 60 48 btst 0x48, %g1 <== NOT EXECUTED
if (tty->termios.c_lflag & (ECHO | ECHONL))
echo (c, tty);
tty->cbuf[tty->ccount++] = c;
return 1;
}
else if ((c == tty->termios.c_cc[VEOL])
2004b2c: c4 0e 60 4c ldub [ %i1 + 0x4c ], %g2 <== NOT EXECUTED
2004b30: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2004b34: 02 80 00 07 be 2004b50 <iproc+0x138> <== NOT EXECUTED
2004b38: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
|| (c == tty->termios.c_cc[VEOL2])) {
2004b3c: c4 0e 60 51 ldub [ %i1 + 0x51 ], %g2 <== NOT EXECUTED
2004b40: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2004b44: 32 bf ff d0 bne,a 2004a84 <iproc+0x6c> <== NOT EXECUTED
2004b48: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
2004b4c: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
2004b50: 12 80 00 18 bne 2004bb0 <iproc+0x198> <== NOT EXECUTED
2004b54: 01 00 00 00 nop <== NOT EXECUTED
echo (c, tty);
tty->cbuf[tty->ccount++] = c;
2004b58: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
2004b5c: c6 06 60 1c ld [ %i1 + 0x1c ], %g3 <== NOT EXECUTED
2004b60: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
2004b64: e0 28 c0 01 stb %l0, [ %g3 + %g1 ] <== NOT EXECUTED
2004b68: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED
return 1;
2004b6c: 81 c7 e0 08 ret <== NOT EXECUTED
2004b70: 91 e8 20 01 restore %g0, 1, %o0 <== 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)) {
2004b74: 80 88 60 40 btst 0x40, %g1 <== NOT EXECUTED
2004b78: 32 bf ff d9 bne,a 2004adc <iproc+0xc4> <== NOT EXECUTED
2004b7c: a0 10 20 0d mov 0xd, %l0 <== NOT EXECUTED
c = '\r';
}
if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {
2004b80: 10 bf ff d8 b 2004ae0 <iproc+0xc8> <== NOT EXECUTED
2004b84: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED
/*
* FIXME: Should do IMAXBEL handling somehow
*/
if (tty->ccount < (CBUFSIZE-1)) {
if (tty->termios.c_lflag & ECHO)
echo (c, tty);
2004b88: 90 0c 20 ff and %l0, 0xff, %o0 <== NOT EXECUTED
2004b8c: 7f ff fe f6 call 2004764 <echo> <== NOT EXECUTED
2004b90: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2004b94: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2004b98: c6 06 60 1c ld [ %i1 + 0x1c ], %g3 <== NOT EXECUTED
2004b9c: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
2004ba0: e0 28 c0 01 stb %l0, [ %g3 + %g1 ] <== NOT EXECUTED
2004ba4: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED
2004ba8: 81 c7 e0 08 ret <== NOT EXECUTED
2004bac: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
return 1;
}
else if ((c == tty->termios.c_cc[VEOL])
|| (c == tty->termios.c_cc[VEOL2])) {
if (tty->termios.c_lflag & ECHO)
echo (c, tty);
2004bb0: 7f ff fe ed call 2004764 <echo> <== NOT EXECUTED
2004bb4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2004bb8: 10 bf ff e9 b 2004b5c <iproc+0x144> <== NOT EXECUTED
2004bbc: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
if (c == tty->termios.c_cc[VERASE]) {
erase (tty, 0);
return 0;
}
else if (c == tty->termios.c_cc[VKILL]) {
erase (tty, 1);
2004bc0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004bc4: 7f ff ff 08 call 20047e4 <erase> <== NOT EXECUTED
2004bc8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
2004bcc: 81 c7 e0 08 ret <== NOT EXECUTED
2004bd0: 81 e8 00 00 restore <== NOT EXECUTED
}
else if (c == tty->termios.c_cc[VEOF]) {
return 1;
}
else if (c == '\n') {
if (tty->termios.c_lflag & (ECHO | ECHONL))
2004bd4: 22 80 00 05 be,a 2004be8 <iproc+0x1d0> <== NOT EXECUTED
2004bd8: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
echo (c, tty);
2004bdc: 7f ff fe e2 call 2004764 <echo> <== NOT EXECUTED
2004be0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2004be4: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
2004be8: c4 06 60 1c ld [ %i1 + 0x1c ], %g2 <== NOT EXECUTED
2004bec: 86 10 20 0a mov 0xa, %g3 <== NOT EXECUTED
2004bf0: c6 28 80 01 stb %g3, [ %g2 + %g1 ] <== NOT EXECUTED
2004bf4: 82 00 60 01 inc %g1 <== NOT EXECUTED
2004bf8: c2 26 60 20 st %g1, [ %i1 + 0x20 ] <== NOT EXECUTED
return 1;
2004bfc: 81 c7 e0 08 ret <== NOT EXECUTED
2004c00: 91 e8 20 01 restore %g0, 1, %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]) {
erase (tty, 0);
2004c04: 92 10 20 00 clr %o1 <== NOT EXECUTED
2004c08: 7f ff fe f7 call 20047e4 <erase> <== NOT EXECUTED
2004c0c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
2004c10: 81 c7 e0 08 ret <== NOT EXECUTED
2004c14: 81 e8 00 00 restore <== NOT EXECUTED
020109f4 <killinfo>:
int killinfo(
pid_t pid,
int sig,
const union sigval *value
)
{
20109f4: 9d e3 bf 90 save %sp, -112, %sp
POSIX_signals_Siginfo_node *psiginfo;
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid != getpid() )
20109f8: 7f ff f0 54 call 200cb48 <getpid>
20109fc: 01 00 00 00 nop
2010a00: 80 a2 00 18 cmp %o0, %i0
2010a04: 12 80 00 b6 bne 2010cdc <killinfo+0x2e8> <== NEVER TAKEN
2010a08: 80 a6 60 00 cmp %i1, 0
rtems_set_errno_and_return_minus_one( ESRCH );
/*
* Validate the signal passed.
*/
if ( !sig )
2010a0c: 02 80 00 ba be 2010cf4 <killinfo+0x300> <== NEVER TAKEN
2010a10: 82 06 7f ff add %i1, -1, %g1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
2010a14: 80 a0 60 1f cmp %g1, 0x1f
2010a18: 18 80 00 b7 bgu 2010cf4 <killinfo+0x300> <== NEVER TAKEN
2010a1c: 23 00 80 7e sethi %hi(0x201f800), %l1
rtems_set_errno_and_return_minus_one( EINVAL );
/*
* If the signal is being ignored, then we are out of here.
*/
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN )
2010a20: a5 2e 60 02 sll %i1, 2, %l2
2010a24: a2 14 61 28 or %l1, 0x128, %l1
2010a28: a7 2e 60 04 sll %i1, 4, %l3
2010a2c: 84 24 c0 12 sub %l3, %l2, %g2
2010a30: 84 04 40 02 add %l1, %g2, %g2
2010a34: c4 00 a0 08 ld [ %g2 + 8 ], %g2
2010a38: 80 a0 a0 01 cmp %g2, 1
2010a3c: 02 80 00 45 be 2010b50 <killinfo+0x15c>
2010a40: b0 10 20 00 clr %i0
/*
* P1003.1c/Draft 10, p. 33 says that certain signals should always
* be directed to the executing thread such as those caused by hardware
* faults.
*/
if ( (sig == SIGFPE) || (sig == SIGILL) || (sig == SIGSEGV ) )
2010a44: 80 a6 60 04 cmp %i1, 4
2010a48: 02 80 00 44 be 2010b58 <killinfo+0x164>
2010a4c: 80 a6 60 08 cmp %i1, 8
2010a50: 02 80 00 42 be 2010b58 <killinfo+0x164>
2010a54: 80 a6 60 0b cmp %i1, 0xb
2010a58: 02 80 00 40 be 2010b58 <killinfo+0x164>
2010a5c: a0 10 20 01 mov 1, %l0
/*
* Build up a siginfo structure
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
2010a60: f2 27 bf f4 st %i1, [ %fp + -12 ]
siginfo->si_code = SI_USER;
2010a64: e0 27 bf f8 st %l0, [ %fp + -8 ]
if ( !value ) {
2010a68: 80 a6 a0 00 cmp %i2, 0
2010a6c: 02 80 00 41 be 2010b70 <killinfo+0x17c>
2010a70: a1 2c 00 01 sll %l0, %g1, %l0
siginfo->si_value.sival_int = 0;
} else {
siginfo->si_value = *value;
2010a74: c2 06 80 00 ld [ %i2 ], %g1
2010a78: c2 27 bf fc st %g1, [ %fp + -4 ]
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2010a7c: 03 00 80 7c sethi %hi(0x201f000), %g1
2010a80: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
2010a84: 84 00 a0 01 inc %g2
2010a88: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
/*
* Is the currently executing thread interested? If so then it will
* get it an execute it as soon as the dispatcher executes.
*/
the_thread = _Thread_Executing;
2010a8c: 03 00 80 7d sethi %hi(0x201f400), %g1
2010a90: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
2010a94: c4 00 61 6c ld [ %g1 + 0x16c ], %g2
2010a98: c4 00 a0 cc ld [ %g2 + 0xcc ], %g2
2010a9c: 80 ac 00 02 andncc %l0, %g2, %g0
2010aa0: 12 80 00 1a bne 2010b08 <killinfo+0x114>
2010aa4: 09 00 80 7e sethi %hi(0x201f800), %g4
/* XXX violation of visibility -- need to define thread queue support */
the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;
for ( the_node = the_chain->first ;
2010aa8: c4 01 22 b4 ld [ %g4 + 0x2b4 ], %g2 ! 201fab4 <_POSIX_signals_Wait_queue>
2010aac: 88 11 22 b4 or %g4, 0x2b4, %g4
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2010ab0: 88 01 20 04 add %g4, 4, %g4
2010ab4: 80 a0 80 04 cmp %g2, %g4
2010ab8: 02 80 00 30 be 2010b78 <killinfo+0x184>
2010abc: 82 10 00 02 mov %g2, %g1
#endif
/*
* Is this thread is actually blocked waiting for the signal?
*/
if (the_thread->Wait.option & mask)
2010ac0: c6 00 a0 30 ld [ %g2 + 0x30 ], %g3
2010ac4: 80 8c 00 03 btst %l0, %g3
2010ac8: 02 80 00 0c be 2010af8 <killinfo+0x104>
2010acc: c6 00 a1 6c ld [ %g2 + 0x16c ], %g3
* thread needs to do the post context switch extension so it can
* evaluate the signals pending.
*/
process_it:
the_thread->do_post_task_switch_extension = true;
2010ad0: 10 80 00 0f b 2010b0c <killinfo+0x118>
2010ad4: 84 10 20 01 mov 1, %g2
/* XXX violation of visibility -- need to define thread queue support */
the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;
for ( the_node = the_chain->first ;
2010ad8: 80 a0 80 04 cmp %g2, %g4
2010adc: 22 80 00 28 be,a 2010b7c <killinfo+0x188> <== ALWAYS TAKEN
2010ae0: 03 00 80 7a sethi %hi(0x201e800), %g1
#endif
/*
* Is this thread is actually blocked waiting for the signal?
*/
if (the_thread->Wait.option & mask)
2010ae4: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1 <== NOT EXECUTED
for ( the_node = the_chain->first ;
!_Chain_Is_tail( the_chain, the_node ) ;
the_node = the_node->next ) {
the_thread = (Thread_Control *)the_node;
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
2010ae8: c6 00 a1 6c ld [ %g2 + 0x16c ], %g3 <== NOT EXECUTED
#endif
/*
* Is this thread is actually blocked waiting for the signal?
*/
if (the_thread->Wait.option & mask)
2010aec: 80 8c 00 01 btst %l0, %g1 <== NOT EXECUTED
2010af0: 12 80 00 06 bne 2010b08 <killinfo+0x114> <== NOT EXECUTED
2010af4: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
/*
* Is this thread is blocked waiting for another signal but has
* not blocked this one?
*/
if (~api->signals_blocked & mask)
2010af8: c6 00 e0 cc ld [ %g3 + 0xcc ], %g3
2010afc: 80 ac 00 03 andncc %l0, %g3, %g0
2010b00: 22 bf ff f6 be,a 2010ad8 <killinfo+0xe4>
2010b04: c4 00 80 00 ld [ %g2 ], %g2
* thread needs to do the post context switch extension so it can
* evaluate the signals pending.
*/
process_it:
the_thread->do_post_task_switch_extension = true;
2010b08: 84 10 20 01 mov 1, %g2
/*
* Returns true if the signal was synchronously given to a thread
* blocked waiting for the signal.
*/
if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
2010b0c: 90 10 00 01 mov %g1, %o0
2010b10: 92 10 00 19 mov %i1, %o1
* thread needs to do the post context switch extension so it can
* evaluate the signals pending.
*/
process_it:
the_thread->do_post_task_switch_extension = true;
2010b14: c4 28 60 74 stb %g2, [ %g1 + 0x74 ]
/*
* Returns true if the signal was synchronously given to a thread
* blocked waiting for the signal.
*/
if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
2010b18: 40 00 01 10 call 2010f58 <_POSIX_signals_Unblock_thread>
2010b1c: 94 07 bf f4 add %fp, -12, %o2
2010b20: 80 8a 20 ff btst 0xff, %o0
2010b24: 12 80 00 5a bne 2010c8c <killinfo+0x298>
2010b28: 01 00 00 00 nop
/*
* We may have woken up a thread but we definitely need to post the
* signal to the process wide information set.
*/
_POSIX_signals_Set_process_signals( mask );
2010b2c: 40 00 00 fb call 2010f18 <_POSIX_signals_Set_process_signals>
2010b30: 90 10 00 10 mov %l0, %o0
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {
2010b34: a4 24 c0 12 sub %l3, %l2, %l2
2010b38: c2 04 40 12 ld [ %l1 + %l2 ], %g1
2010b3c: 80 a0 60 02 cmp %g1, 2
2010b40: 02 80 00 57 be 2010c9c <killinfo+0x2a8>
2010b44: 11 00 80 7e sethi %hi(0x201f800), %o0
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
}
DEBUG_STEP("\n");
_Thread_Enable_dispatch();
2010b48: 7f ff e0 96 call 2008da0 <_Thread_Enable_dispatch>
2010b4c: b0 10 20 00 clr %i0
return 0;
}
2010b50: 81 c7 e0 08 ret
2010b54: 81 e8 00 00 restore
* P1003.1c/Draft 10, p. 33 says that certain signals should always
* be directed to the executing thread such as those caused by hardware
* faults.
*/
if ( (sig == SIGFPE) || (sig == SIGILL) || (sig == SIGSEGV ) )
return pthread_kill( pthread_self(), sig );
2010b58: 40 00 01 d8 call 20112b8 <pthread_self>
2010b5c: 01 00 00 00 nop
2010b60: 40 00 01 9b call 20111cc <pthread_kill>
2010b64: 92 10 00 19 mov %i1, %o1
2010b68: 81 c7 e0 08 ret
2010b6c: 91 e8 00 08 restore %g0, %o0, %o0
*/
siginfo = &siginfo_struct;
siginfo->si_signo = sig;
siginfo->si_code = SI_USER;
if ( !value ) {
siginfo->si_value.sival_int = 0;
2010b70: 10 bf ff c3 b 2010a7c <killinfo+0x88>
2010b74: c0 27 bf fc clr [ %fp + -4 ]
* NOTES:
*
* + rtems internal threads do not receive signals.
*/
interested = NULL;
interested_priority = PRIORITY_MAXIMUM + 1;
2010b78: 03 00 80 7a sethi %hi(0x201e800), %g1
2010b7c: da 08 60 64 ldub [ %g1 + 0x64 ], %o5 ! 201e864 <rtems_maximum_priority>
2010b80: 13 00 80 7c sethi %hi(0x201f000), %o1
2010b84: 9a 03 60 01 inc %o5
2010b88: 92 12 63 08 or %o1, 0x308, %o1
*/
#define _POSIX_signals_Is_interested( _api, _mask ) \
( ~(_api)->signals_blocked & (_mask) )
int killinfo(
2010b8c: 82 10 20 00 clr %g1
2010b90: 90 02 60 0c add %o1, 0xc, %o0
continue;
}
DEBUG_STEP("6");
/* prefer blocked/interruptible over blocked/not interruptible */
if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
2010b94: 35 04 00 00 sethi %hi(0x10000000), %i2
for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
/*
* This can occur when no one is interested and ITRON is not configured.
*/
if ( !_Objects_Information_table[ the_api ] )
2010b98: c4 02 40 00 ld [ %o1 ], %g2
2010b9c: 80 a0 a0 00 cmp %g2, 0
2010ba0: 22 80 00 2d be,a 2010c54 <killinfo+0x260>
2010ba4: 92 02 60 04 add %o1, 4, %o1
continue;
the_info = _Objects_Information_table[ the_api ][ 1 ];
2010ba8: c4 00 a0 04 ld [ %g2 + 4 ], %g2
*/
if ( !the_info )
continue;
#endif
maximum = the_info->maximum;
2010bac: d8 10 a0 10 lduh [ %g2 + 0x10 ], %o4
object_table = the_info->local_table;
for ( index = 1 ; index <= maximum ; index++ ) {
2010bb0: 80 a3 20 00 cmp %o4, 0
2010bb4: 02 80 00 27 be 2010c50 <killinfo+0x25c>
2010bb8: d6 00 a0 1c ld [ %g2 + 0x1c ], %o3
2010bbc: 84 10 20 01 mov 1, %g2
the_thread = (Thread_Control *) object_table[ index ];
2010bc0: 87 28 a0 02 sll %g2, 2, %g3
2010bc4: c6 02 c0 03 ld [ %o3 + %g3 ], %g3
if ( !the_thread )
2010bc8: 80 a0 e0 00 cmp %g3, 0
2010bcc: 02 80 00 1e be 2010c44 <killinfo+0x250>
2010bd0: 84 00 a0 01 inc %g2
/*
* If this thread is of lower priority than the interested thread,
* go on to the next thread.
*/
if ( the_thread->current_priority > interested_priority )
2010bd4: c8 00 e0 14 ld [ %g3 + 0x14 ], %g4
2010bd8: 80 a1 00 0d cmp %g4, %o5
2010bdc: 18 80 00 1b bgu 2010c48 <killinfo+0x254>
2010be0: 80 a3 00 02 cmp %o4, %g2
DEBUG_STEP("2");
/*
* If this thread is not interested, then go on to the next thread.
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
2010be4: d4 00 e1 6c ld [ %g3 + 0x16c ], %o2
2010be8: d4 02 a0 cc ld [ %o2 + 0xcc ], %o2
2010bec: 80 ac 00 0a andncc %l0, %o2, %g0
2010bf0: 02 80 00 16 be 2010c48 <killinfo+0x254>
2010bf4: 80 a3 00 02 cmp %o4, %g2
*
* NOTE: We initialized interested_priority to PRIORITY_MAXIMUM + 1
* so we never have to worry about deferencing a NULL
* interested thread.
*/
if ( the_thread->current_priority < interested_priority ) {
2010bf8: 80 a1 00 0d cmp %g4, %o5
2010bfc: 2a 80 00 11 bcs,a 2010c40 <killinfo+0x24c>
2010c00: 9a 10 00 04 mov %g4, %o5
* and blocking interruptibutable by signal.
*
* If the interested thread is ready, don't think about changing.
*/
if ( !_States_Is_ready( interested->current_state ) ) {
2010c04: d4 00 60 10 ld [ %g1 + 0x10 ], %o2
2010c08: 80 a2 a0 00 cmp %o2, 0
2010c0c: 02 80 00 0f be 2010c48 <killinfo+0x254> <== NEVER TAKEN
2010c10: 80 a3 00 02 cmp %o4, %g2
/* preferred ready over blocked */
DEBUG_STEP("5");
if ( _States_Is_ready( the_thread->current_state ) ) {
2010c14: de 00 e0 10 ld [ %g3 + 0x10 ], %o7
2010c18: 80 a3 e0 00 cmp %o7, 0
2010c1c: 22 80 00 09 be,a 2010c40 <killinfo+0x24c>
2010c20: 9a 10 00 04 mov %g4, %o5
continue;
}
DEBUG_STEP("6");
/* prefer blocked/interruptible over blocked/not interruptible */
if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
2010c24: 80 8a 80 1a btst %o2, %i2
2010c28: 12 80 00 08 bne 2010c48 <killinfo+0x254>
2010c2c: 80 a3 00 02 cmp %o4, %g2
DEBUG_STEP("7");
if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) {
2010c30: 80 8b c0 1a btst %o7, %i2
2010c34: 02 80 00 05 be 2010c48 <killinfo+0x254>
2010c38: 80 a3 00 02 cmp %o4, %g2
2010c3c: 9a 10 00 04 mov %g4, %o5
2010c40: 82 10 00 03 mov %g3, %g1
#endif
maximum = the_info->maximum;
object_table = the_info->local_table;
for ( index = 1 ; index <= maximum ; index++ ) {
2010c44: 80 a3 00 02 cmp %o4, %g2
2010c48: 1a bf ff df bcc 2010bc4 <killinfo+0x1d0>
2010c4c: 87 28 a0 02 sll %g2, 2, %g3
2010c50: 92 02 60 04 add %o1, 4, %o1
* + rtems internal threads do not receive signals.
*/
interested = NULL;
interested_priority = PRIORITY_MAXIMUM + 1;
for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
2010c54: 80 a2 40 08 cmp %o1, %o0
2010c58: 32 bf ff d1 bne,a 2010b9c <killinfo+0x1a8>
2010c5c: c4 02 40 00 ld [ %o1 ], %g2
}
}
}
}
if ( interested ) {
2010c60: 80 a0 60 00 cmp %g1, 0
2010c64: 02 bf ff b2 be 2010b2c <killinfo+0x138>
2010c68: 84 10 20 01 mov 1, %g2
/*
* Returns true if the signal was synchronously given to a thread
* blocked waiting for the signal.
*/
if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
2010c6c: 90 10 00 01 mov %g1, %o0
2010c70: 92 10 00 19 mov %i1, %o1
* thread needs to do the post context switch extension so it can
* evaluate the signals pending.
*/
process_it:
the_thread->do_post_task_switch_extension = true;
2010c74: c4 28 60 74 stb %g2, [ %g1 + 0x74 ]
/*
* Returns true if the signal was synchronously given to a thread
* blocked waiting for the signal.
*/
if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
2010c78: 40 00 00 b8 call 2010f58 <_POSIX_signals_Unblock_thread>
2010c7c: 94 07 bf f4 add %fp, -12, %o2
2010c80: 80 8a 20 ff btst 0xff, %o0
2010c84: 02 bf ff aa be 2010b2c <killinfo+0x138> <== ALWAYS TAKEN
2010c88: 01 00 00 00 nop
_Thread_Enable_dispatch();
2010c8c: 7f ff e0 45 call 2008da0 <_Thread_Enable_dispatch>
2010c90: b0 10 20 00 clr %i0 ! 0 <PROM_START>
return 0;
2010c94: 81 c7 e0 08 ret
2010c98: 81 e8 00 00 restore
*/
_POSIX_signals_Set_process_signals( mask );
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {
psiginfo = (POSIX_signals_Siginfo_node *)
2010c9c: 7f ff d9 b4 call 200736c <_Chain_Get>
2010ca0: 90 12 22 a8 or %o0, 0x2a8, %o0
_Chain_Get( &_POSIX_signals_Inactive_siginfo );
if ( !psiginfo ) {
2010ca4: 80 a2 20 00 cmp %o0, 0
2010ca8: 02 80 00 19 be 2010d0c <killinfo+0x318>
2010cac: c2 07 bf f4 ld [ %fp + -12 ], %g1
rtems_set_errno_and_return_minus_one( EAGAIN );
}
psiginfo->Info = *siginfo;
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
2010cb0: 92 10 00 08 mov %o0, %o1
if ( !psiginfo ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( EAGAIN );
}
psiginfo->Info = *siginfo;
2010cb4: c2 22 20 08 st %g1, [ %o0 + 8 ]
2010cb8: c2 07 bf f8 ld [ %fp + -8 ], %g1
2010cbc: c2 22 20 0c st %g1, [ %o0 + 0xc ]
2010cc0: c2 07 bf fc ld [ %fp + -4 ], %g1
2010cc4: c2 22 20 10 st %g1, [ %o0 + 0x10 ]
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
2010cc8: 11 00 80 7e sethi %hi(0x201f800), %o0
2010ccc: 90 12 23 20 or %o0, 0x320, %o0 ! 201fb20 <_POSIX_signals_Siginfo>
2010cd0: 7f ff d9 91 call 2007314 <_Chain_Append>
2010cd4: 90 02 00 12 add %o0, %l2, %o0
2010cd8: 30 bf ff 9c b,a 2010b48 <killinfo+0x154>
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid != getpid() )
rtems_set_errno_and_return_minus_one( ESRCH );
2010cdc: 40 00 03 48 call 20119fc <__errno> <== NOT EXECUTED
2010ce0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2010ce4: 82 10 20 03 mov 3, %g1 <== NOT EXECUTED
2010ce8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2010cec: 81 c7 e0 08 ret <== NOT EXECUTED
2010cf0: 81 e8 00 00 restore <== NOT EXECUTED
*/
if ( !sig )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
rtems_set_errno_and_return_minus_one( EINVAL );
2010cf4: 40 00 03 42 call 20119fc <__errno> <== NOT EXECUTED
2010cf8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2010cfc: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2010d00: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2010d04: 81 c7 e0 08 ret <== NOT EXECUTED
2010d08: 81 e8 00 00 restore <== NOT EXECUTED
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {
psiginfo = (POSIX_signals_Siginfo_node *)
_Chain_Get( &_POSIX_signals_Inactive_siginfo );
if ( !psiginfo ) {
_Thread_Enable_dispatch();
2010d0c: 7f ff e0 25 call 2008da0 <_Thread_Enable_dispatch>
2010d10: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( EAGAIN );
2010d14: 40 00 03 3a call 20119fc <__errno>
2010d18: 01 00 00 00 nop
2010d1c: 82 10 20 0b mov 0xb, %g1 ! b <PROM_START+0xb>
2010d20: c2 22 00 00 st %g1, [ %o0 ]
2010d24: 81 c7 e0 08 ret
2010d28: 81 e8 00 00 restore
0201c67c <libc_wrapup>:
extern void _wrapup_reent(struct _reent *);
extern void _reclaim_reent(struct _reent *);
void libc_wrapup(void)
{
201c67c: 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()))
201c680: 03 00 80 7d sethi %hi(0x201f400), %g1
201c684: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 201f540 <_System_state_Current>
201c688: 80 a0 60 03 cmp %g1, 3
201c68c: 02 80 00 04 be 201c69c <libc_wrapup+0x20> <== ALWAYS TAKEN
201c690: 03 00 80 78 sethi %hi(0x201e000), %g1
201c694: 81 c7 e0 08 ret <== NOT EXECUTED
201c698: 81 e8 00 00 restore <== NOT EXECUTED
/*
* This was already done if the user called exit() directly .
_wrapup_reent(0);
*/
if (_REENT != _global_impure_ptr) {
201c69c: 21 00 80 7a sethi %hi(0x201e800), %l0
201c6a0: e2 00 62 d0 ld [ %g1 + 0x2d0 ], %l1
201c6a4: c2 04 22 30 ld [ %l0 + 0x230 ], %g1
201c6a8: 80 a0 40 11 cmp %g1, %l1
201c6ac: 02 80 00 05 be 201c6c0 <libc_wrapup+0x44>
201c6b0: 01 00 00 00 nop
_wrapup_reent(_global_impure_ptr);
201c6b4: 40 00 01 80 call 201ccb4 <_wrapup_reent>
201c6b8: 90 10 00 11 mov %l1, %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;
201c6bc: e2 24 22 30 st %l1, [ %l0 + 0x230 ]
*
* Should this be changed to do *all* file streams?
* _fwalk (_REENT, fclose);
*/
fclose (stdin);
201c6c0: 7f ff d5 27 call 2011b5c <fclose>
201c6c4: d0 04 60 04 ld [ %l1 + 4 ], %o0
fclose (stdout);
201c6c8: c2 04 22 30 ld [ %l0 + 0x230 ], %g1
201c6cc: 7f ff d5 24 call 2011b5c <fclose>
201c6d0: d0 00 60 08 ld [ %g1 + 8 ], %o0
fclose (stderr);
201c6d4: c2 04 22 30 ld [ %l0 + 0x230 ], %g1
201c6d8: f0 00 60 0c ld [ %g1 + 0xc ], %i0
201c6dc: 7f ff d5 20 call 2011b5c <fclose>
201c6e0: 81 e8 00 00 restore
0202d78c <link>:
int link(
const char *existing,
const char *new
)
{
202d78c: 9d e3 bf 70 save %sp, -144, %sp
/*
* Get the node we are linking to.
*/
result = rtems_filesystem_evaluate_path( existing, strlen( existing ),
202d790: 40 00 8e f8 call 2051370 <strlen>
202d794: 90 10 00 18 mov %i0, %o0
202d798: a0 07 bf e4 add %fp, -28, %l0
202d79c: 92 10 00 08 mov %o0, %o1
202d7a0: 94 10 20 00 clr %o2
202d7a4: 90 10 00 18 mov %i0, %o0
202d7a8: 96 10 00 10 mov %l0, %o3
202d7ac: 98 10 20 01 mov 1, %o4
202d7b0: 7f ff 6c 2c call 2008860 <rtems_filesystem_evaluate_path>
202d7b4: b0 10 3f ff mov -1, %i0
0, &existing_loc, true );
if ( result != 0 )
202d7b8: 80 a2 20 00 cmp %o0, 0
202d7bc: 12 80 00 31 bne 202d880 <link+0xf4>
202d7c0: a2 07 bf d0 add %fp, -48, %l1
/*
* Get the parent of the node we are creating.
*/
rtems_filesystem_get_start_loc( new, &i, &parent_loc );
202d7c4: 90 10 00 19 mov %i1, %o0
202d7c8: 92 07 bf fc add %fp, -4, %o1
202d7cc: 7f ff 73 47 call 200a4e8 <rtems_filesystem_get_start_loc>
202d7d0: 94 10 00 11 mov %l1, %o2
if ( !parent_loc.ops->evalformake_h ) {
202d7d4: c2 07 bf dc ld [ %fp + -36 ], %g1
202d7d8: c2 00 60 04 ld [ %g1 + 4 ], %g1
202d7dc: 80 a0 60 00 cmp %g1, 0
202d7e0: 02 80 00 53 be 202d92c <link+0x1a0> <== NEVER TAKEN
202d7e4: d0 07 bf fc ld [ %fp + -4 ], %o0
rtems_filesystem_freenode( &existing_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*parent_loc.ops->evalformake_h)( &new[i], &parent_loc, &name_start );
202d7e8: 92 10 00 11 mov %l1, %o1
202d7ec: 90 06 40 08 add %i1, %o0, %o0
202d7f0: 9f c0 40 00 call %g1
202d7f4: 94 07 bf f8 add %fp, -8, %o2
if ( result != 0 ) {
202d7f8: b2 92 20 00 orcc %o0, 0, %i1
202d7fc: 12 80 00 3d bne 202d8f0 <link+0x164>
202d800: c2 07 bf f4 ld [ %fp + -12 ], %g1
/*
* Check to see if the caller is trying to link across file system
* boundaries.
*/
if ( parent_loc.mt_entry != existing_loc.mt_entry ) {
202d804: c4 07 bf e0 ld [ %fp + -32 ], %g2
202d808: 80 a0 80 01 cmp %g2, %g1
202d80c: 12 80 00 1f bne 202d888 <link+0xfc>
202d810: c4 07 bf dc ld [ %fp + -36 ], %g2
rtems_filesystem_freenode( &existing_loc );
rtems_filesystem_freenode( &parent_loc );
rtems_set_errno_and_return_minus_one( EXDEV );
}
if ( !parent_loc.ops->link_h ) {
202d814: c2 00 a0 08 ld [ %g2 + 8 ], %g1
202d818: 80 a0 60 00 cmp %g1, 0
202d81c: 02 80 00 54 be 202d96c <link+0x1e0> <== NEVER TAKEN
202d820: d4 07 bf f8 ld [ %fp + -8 ], %o2
rtems_filesystem_freenode( &existing_loc );
rtems_filesystem_freenode( &parent_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*parent_loc.ops->link_h)( &existing_loc, &parent_loc, name_start );
202d824: 90 10 00 10 mov %l0, %o0
202d828: 9f c0 40 00 call %g1
202d82c: 92 10 00 11 mov %l1, %o1
rtems_filesystem_freenode( &existing_loc );
202d830: c2 07 bf f0 ld [ %fp + -16 ], %g1
202d834: 80 a0 60 00 cmp %g1, 0
202d838: 02 80 00 08 be 202d858 <link+0xcc> <== NEVER TAKEN
202d83c: b0 10 00 08 mov %o0, %i0
202d840: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202d844: 80 a0 60 00 cmp %g1, 0
202d848: 22 80 00 05 be,a 202d85c <link+0xd0> <== NEVER TAKEN
202d84c: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
202d850: 9f c0 40 00 call %g1
202d854: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &parent_loc );
202d858: c2 07 bf dc ld [ %fp + -36 ], %g1
202d85c: 80 a0 60 00 cmp %g1, 0
202d860: 02 80 00 41 be 202d964 <link+0x1d8> <== NEVER TAKEN
202d864: 01 00 00 00 nop
202d868: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202d86c: 80 a0 60 00 cmp %g1, 0
202d870: 02 80 00 3d be 202d964 <link+0x1d8> <== NEVER TAKEN
202d874: 01 00 00 00 nop
202d878: 9f c0 40 00 call %g1
202d87c: 90 10 00 11 mov %l1, %o0
return result;
}
202d880: 81 c7 e0 08 ret
202d884: 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 ) {
rtems_filesystem_freenode( &existing_loc );
202d888: c2 07 bf f0 ld [ %fp + -16 ], %g1
202d88c: 80 a0 60 00 cmp %g1, 0
202d890: 22 80 00 09 be,a 202d8b4 <link+0x128> <== NEVER TAKEN
202d894: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
202d898: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202d89c: 80 a0 60 00 cmp %g1, 0
202d8a0: 22 80 00 05 be,a 202d8b4 <link+0x128> <== NEVER TAKEN
202d8a4: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
202d8a8: 9f c0 40 00 call %g1
202d8ac: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &parent_loc );
202d8b0: c2 07 bf dc ld [ %fp + -36 ], %g1
202d8b4: 80 a0 60 00 cmp %g1, 0
202d8b8: 02 80 00 08 be 202d8d8 <link+0x14c> <== NEVER TAKEN
202d8bc: 01 00 00 00 nop
202d8c0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202d8c4: 80 a0 60 00 cmp %g1, 0
202d8c8: 02 80 00 04 be 202d8d8 <link+0x14c> <== NEVER TAKEN
202d8cc: 01 00 00 00 nop
202d8d0: 9f c0 40 00 call %g1
202d8d4: 90 10 00 11 mov %l1, %o0
rtems_set_errno_and_return_minus_one( EXDEV );
202d8d8: 40 00 72 ea call 204a480 <__errno>
202d8dc: b0 10 3f ff mov -1, %i0
202d8e0: 82 10 20 12 mov 0x12, %g1
202d8e4: c2 22 00 00 st %g1, [ %o0 ]
202d8e8: 81 c7 e0 08 ret
202d8ec: 81 e8 00 00 restore
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*parent_loc.ops->evalformake_h)( &new[i], &parent_loc, &name_start );
if ( result != 0 ) {
rtems_filesystem_freenode( &existing_loc );
202d8f0: c2 07 bf f0 ld [ %fp + -16 ], %g1
202d8f4: 80 a0 60 00 cmp %g1, 0
202d8f8: 02 80 00 08 be 202d918 <link+0x18c> <== NEVER TAKEN
202d8fc: 01 00 00 00 nop
202d900: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202d904: 80 a0 60 00 cmp %g1, 0
202d908: 02 80 00 04 be 202d918 <link+0x18c> <== NEVER TAKEN
202d90c: 01 00 00 00 nop
202d910: 9f c0 40 00 call %g1
202d914: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( result );
202d918: 40 00 72 da call 204a480 <__errno>
202d91c: b0 10 3f ff mov -1, %i0
202d920: f2 22 00 00 st %i1, [ %o0 ]
202d924: 81 c7 e0 08 ret
202d928: 81 e8 00 00 restore
*/
rtems_filesystem_get_start_loc( new, &i, &parent_loc );
if ( !parent_loc.ops->evalformake_h ) {
rtems_filesystem_freenode( &existing_loc );
202d92c: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
202d930: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d934: 02 80 00 08 be 202d954 <link+0x1c8> <== NOT EXECUTED
202d938: 01 00 00 00 nop <== NOT EXECUTED
202d93c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202d940: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d944: 02 80 00 04 be 202d954 <link+0x1c8> <== NOT EXECUTED
202d948: 01 00 00 00 nop <== NOT EXECUTED
202d94c: 9f c0 40 00 call %g1 <== NOT EXECUTED
202d950: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
if ( !parent_loc.ops->link_h ) {
rtems_filesystem_freenode( &existing_loc );
rtems_filesystem_freenode( &parent_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
202d954: 40 00 72 cb call 204a480 <__errno> <== NOT EXECUTED
202d958: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202d95c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202d960: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202d964: 81 c7 e0 08 ret <== NOT EXECUTED
202d968: 81 e8 00 00 restore <== NOT EXECUTED
rtems_filesystem_freenode( &parent_loc );
rtems_set_errno_and_return_minus_one( EXDEV );
}
if ( !parent_loc.ops->link_h ) {
rtems_filesystem_freenode( &existing_loc );
202d96c: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
202d970: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d974: 02 80 00 0a be 202d99c <link+0x210> <== NOT EXECUTED
202d978: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
202d97c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202d980: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d984: 02 80 00 06 be 202d99c <link+0x210> <== NOT EXECUTED
202d988: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
202d98c: 9f c0 40 00 call %g1 <== NOT EXECUTED
202d990: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202d994: c4 07 bf dc ld [ %fp + -36 ], %g2 <== NOT EXECUTED
rtems_filesystem_freenode( &parent_loc );
202d998: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
202d99c: 02 bf ff ee be 202d954 <link+0x1c8> <== NOT EXECUTED
202d9a0: 01 00 00 00 nop <== NOT EXECUTED
202d9a4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
202d9a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202d9ac: 02 bf ff ea be 202d954 <link+0x1c8> <== NOT EXECUTED
202d9b0: 01 00 00 00 nop <== NOT EXECUTED
202d9b4: 9f c0 40 00 call %g1 <== NOT EXECUTED
202d9b8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202d9bc: 30 bf ff e6 b,a 202d954 <link+0x1c8> <== NOT EXECUTED
0201c4d8 <lseek>:
off_t lseek(
int fd,
off_t offset,
int whence
)
{
201c4d8: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop;
off_t old_offset;
off_t status;
rtems_libio_check_fd( fd );
201c4dc: 03 00 80 79 sethi %hi(0x201e400), %g1
201c4e0: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
off_t lseek(
int fd,
off_t offset,
int whence
)
{
201c4e4: 84 10 00 19 mov %i1, %g2
rtems_libio_t *iop;
off_t old_offset;
off_t status;
rtems_libio_check_fd( fd );
201c4e8: 80 a6 00 01 cmp %i0, %g1
201c4ec: 1a 80 00 46 bcc 201c604 <lseek+0x12c> <== NEVER TAKEN
201c4f0: 86 10 00 1a mov %i2, %g3
iop = rtems_libio_iop( fd );
201c4f4: 03 00 80 7c sethi %hi(0x201f000), %g1
201c4f8: e0 00 61 c4 ld [ %g1 + 0x1c4 ], %l0 ! 201f1c4 <rtems_libio_iops>
201c4fc: 83 2e 20 06 sll %i0, 6, %g1
201c500: b1 2e 20 03 sll %i0, 3, %i0
201c504: b0 06 00 01 add %i0, %g1, %i0
201c508: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open(iop);
201c50c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
201c510: 80 88 61 00 btst 0x100, %g1
201c514: 02 80 00 3c be 201c604 <lseek+0x12c> <== NEVER TAKEN
201c518: 01 00 00 00 nop
/*
* Check as many errors as possible before touching iop->offset.
*/
if ( !iop->handlers->lseek_h )
201c51c: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
201c520: c8 00 60 14 ld [ %g1 + 0x14 ], %g4
201c524: 80 a1 20 00 cmp %g4, 0
201c528: 02 80 00 3f be 201c624 <lseek+0x14c> <== NEVER TAKEN
201c52c: 80 a6 e0 01 cmp %i3, 1
/*
* Now process the lseek().
*/
old_offset = iop->offset;
switch ( whence ) {
201c530: 02 80 00 31 be 201c5f4 <lseek+0x11c>
201c534: e4 1c 20 10 ldd [ %l0 + 0x10 ], %l2
201c538: 80 a6 e0 02 cmp %i3, 2
201c53c: 02 80 00 11 be 201c580 <lseek+0xa8>
201c540: 80 a6 e0 00 cmp %i3, 0
201c544: 12 80 00 22 bne 201c5cc <lseek+0xf4>
201c548: 01 00 00 00 nop
case SEEK_SET:
iop->offset = offset;
201c54c: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
/*
* At this time, handlers assume iop->offset has the desired
* new offset.
*/
status = (*iop->handlers->lseek_h)( iop, offset, whence );
201c550: c2 00 60 14 ld [ %g1 + 0x14 ], %g1
201c554: 92 10 00 02 mov %g2, %o1
201c558: 94 10 00 03 mov %g3, %o2
201c55c: 96 10 00 1b mov %i3, %o3
201c560: 9f c0 40 00 call %g1
201c564: 90 10 00 10 mov %l0, %o0
if ( status == (off_t) -1 )
201c568: 80 a2 3f ff cmp %o0, -1
201c56c: 02 80 00 13 be 201c5b8 <lseek+0xe0> <== NEVER TAKEN
201c570: 80 a2 7f ff cmp %o1, -1
/*
* So if the operation failed, we have to restore iop->offset.
*/
return status;
}
201c574: b2 10 00 09 mov %o1, %i1
201c578: 81 c7 e0 08 ret
201c57c: 91 e8 00 08 restore %g0, %o0, %o0
case SEEK_CUR:
iop->offset += offset;
break;
case SEEK_END:
iop->offset = iop->size + offset;
201c580: d8 1c 20 08 ldd [ %l0 + 8 ], %o4
/*
* At this time, handlers assume iop->offset has the desired
* new offset.
*/
status = (*iop->handlers->lseek_h)( iop, offset, whence );
201c584: c2 00 60 14 ld [ %g1 + 0x14 ], %g1
case SEEK_CUR:
iop->offset += offset;
break;
case SEEK_END:
iop->offset = iop->size + offset;
201c588: 9a 86 80 0d addcc %i2, %o5, %o5
201c58c: 98 46 40 0c addx %i1, %o4, %o4
/*
* At this time, handlers assume iop->offset has the desired
* new offset.
*/
status = (*iop->handlers->lseek_h)( iop, offset, whence );
201c590: 92 10 00 02 mov %g2, %o1
case SEEK_CUR:
iop->offset += offset;
break;
case SEEK_END:
iop->offset = iop->size + offset;
201c594: d8 3c 20 10 std %o4, [ %l0 + 0x10 ]
/*
* At this time, handlers assume iop->offset has the desired
* new offset.
*/
status = (*iop->handlers->lseek_h)( iop, offset, whence );
201c598: 94 10 00 03 mov %g3, %o2
201c59c: 96 10 00 1b mov %i3, %o3
201c5a0: 9f c0 40 00 call %g1
201c5a4: 90 10 00 10 mov %l0, %o0
if ( status == (off_t) -1 )
201c5a8: 80 a2 3f ff cmp %o0, -1
201c5ac: 12 bf ff f3 bne 201c578 <lseek+0xa0>
201c5b0: b2 10 00 09 mov %o1, %i1
201c5b4: 80 a2 7f ff cmp %o1, -1
201c5b8: 12 bf ff f0 bne 201c578 <lseek+0xa0> <== NEVER TAKEN
201c5bc: b2 10 00 09 mov %o1, %i1
iop->offset = old_offset;
201c5c0: e4 3c 20 10 std %l2, [ %l0 + 0x10 ]
/*
* So if the operation failed, we have to restore iop->offset.
*/
return status;
}
201c5c4: 81 c7 e0 08 ret
201c5c8: 91 e8 00 08 restore %g0, %o0, %o0
case SEEK_END:
iop->offset = iop->size + offset;
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
201c5cc: 7f ff d5 0c call 20119fc <__errno>
201c5d0: 01 00 00 00 nop
201c5d4: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16>
201c5d8: c2 22 00 00 st %g1, [ %o0 ]
201c5dc: 11 3f ff ff sethi %hi(0xfffffc00), %o0
201c5e0: 90 12 23 ff or %o0, 0x3ff, %o0 ! ffffffff <RAM_END+0xfdbfffff>
201c5e4: 92 10 00 08 mov %o0, %o1
/*
* So if the operation failed, we have to restore iop->offset.
*/
return status;
}
201c5e8: b0 10 00 08 mov %o0, %i0
201c5ec: 81 c7 e0 08 ret
201c5f0: 93 e8 00 09 restore %g0, %o1, %o1
case SEEK_SET:
iop->offset = offset;
break;
case SEEK_CUR:
iop->offset += offset;
201c5f4: 9a 86 80 13 addcc %i2, %l3, %o5
201c5f8: 98 46 40 12 addx %i1, %l2, %o4
break;
201c5fc: 10 bf ff d5 b 201c550 <lseek+0x78>
201c600: d8 3c 20 10 std %o4, [ %l0 + 0x10 ]
off_t old_offset;
off_t status;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open(iop);
201c604: 7f ff d4 fe call 20119fc <__errno> <== NOT EXECUTED
201c608: 01 00 00 00 nop <== NOT EXECUTED
201c60c: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
201c610: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201c614: 11 3f ff ff sethi %hi(0xfffffc00), %o0 <== NOT EXECUTED
201c618: 90 12 23 ff or %o0, 0x3ff, %o0 ! ffffffff <RAM_END+0xfdbfffff><== NOT EXECUTED
201c61c: 10 bf ff d6 b 201c574 <lseek+0x9c> <== NOT EXECUTED
201c620: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
/*
* Check as many errors as possible before touching iop->offset.
*/
if ( !iop->handlers->lseek_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
201c624: 7f ff d4 f6 call 20119fc <__errno> <== NOT EXECUTED
201c628: 01 00 00 00 nop <== NOT EXECUTED
201c62c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
201c630: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201c634: 11 3f ff ff sethi %hi(0xfffffc00), %o0 <== NOT EXECUTED
201c638: 90 12 23 ff or %o0, 0x3ff, %o0 ! ffffffff <RAM_END+0xfdbfffff><== NOT EXECUTED
201c63c: 10 bf ff ce b 201c574 <lseek+0x9c> <== NOT EXECUTED
201c640: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
0202db68 <lstat>:
int _STAT_NAME(
const char *path,
struct stat *buf
)
{
202db68: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
/*
* Check to see if we were passed a valid pointer.
*/
if ( !buf )
202db6c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
202db70: 02 80 00 34 be 202dc40 <lstat+0xd8> <== NOT EXECUTED
202db74: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EFAULT );
status = rtems_filesystem_evaluate_path( path, strlen( path ),
202db78: 40 00 8d fe call 2051370 <strlen> <== NOT EXECUTED
202db7c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202db80: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED
202db84: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
202db88: 94 10 20 00 clr %o2 <== NOT EXECUTED
202db8c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202db90: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
202db94: 98 10 20 00 clr %o4 <== NOT EXECUTED
202db98: 7f ff 6b 32 call 2008860 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
202db9c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
0, &loc, _STAT_FOLLOW_LINKS );
if ( status != 0 )
202dba0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202dba4: 12 80 00 25 bne 202dc38 <lstat+0xd0> <== NOT EXECUTED
202dba8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return -1;
if ( !loc.handlers->fstat_h ){
202dbac: c4 00 60 18 ld [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
202dbb0: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
202dbb4: 02 80 00 29 be 202dc58 <lstat+0xf0> <== NOT EXECUTED
202dbb8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
/*
* Zero out the stat structure so the various support
* versions of stat don't have to.
*/
memset( buf, 0, sizeof(struct stat) );
202dbbc: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
202dbc0: c0 26 60 04 clr [ %i1 + 4 ] <== NOT EXECUTED
202dbc4: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
202dbc8: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
202dbcc: c0 26 60 10 clr [ %i1 + 0x10 ] <== NOT EXECUTED
202dbd0: c0 26 60 14 clr [ %i1 + 0x14 ] <== NOT EXECUTED
202dbd4: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
202dbd8: c0 26 60 1c clr [ %i1 + 0x1c ] <== NOT EXECUTED
202dbdc: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
202dbe0: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
202dbe4: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
202dbe8: c0 26 60 2c clr [ %i1 + 0x2c ] <== NOT EXECUTED
202dbec: c0 26 60 30 clr [ %i1 + 0x30 ] <== NOT EXECUTED
202dbf0: c0 26 60 34 clr [ %i1 + 0x34 ] <== NOT EXECUTED
202dbf4: c0 26 60 38 clr [ %i1 + 0x38 ] <== NOT EXECUTED
202dbf8: c0 26 60 3c clr [ %i1 + 0x3c ] <== NOT EXECUTED
202dbfc: c0 26 60 40 clr [ %i1 + 0x40 ] <== NOT EXECUTED
202dc00: c0 26 60 44 clr [ %i1 + 0x44 ] <== NOT EXECUTED
status = (*loc.handlers->fstat_h)( &loc, buf );
202dc04: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED
202dc08: 9f c0 40 00 call %g1 <== NOT EXECUTED
202dc0c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
202dc10: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
202dc14: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202dc18: 02 80 00 08 be 202dc38 <lstat+0xd0> <== NOT EXECUTED
202dc1c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
202dc20: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202dc24: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202dc28: 02 80 00 1a be 202dc90 <lstat+0x128> <== NOT EXECUTED
202dc2c: 01 00 00 00 nop <== NOT EXECUTED
202dc30: 9f c0 40 00 call %g1 <== NOT EXECUTED
202dc34: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return status;
}
202dc38: 81 c7 e0 08 ret <== NOT EXECUTED
202dc3c: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Check to see if we were passed a valid pointer.
*/
if ( !buf )
rtems_set_errno_and_return_minus_one( EFAULT );
202dc40: 40 00 72 10 call 204a480 <__errno> <== NOT EXECUTED
202dc44: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202dc48: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
202dc4c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202dc50: 81 c7 e0 08 ret <== NOT EXECUTED
202dc54: 81 e8 00 00 restore <== NOT EXECUTED
0, &loc, _STAT_FOLLOW_LINKS );
if ( status != 0 )
return -1;
if ( !loc.handlers->fstat_h ){
rtems_filesystem_freenode( &loc );
202dc58: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
202dc5c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202dc60: 02 80 00 08 be 202dc80 <lstat+0x118> <== NOT EXECUTED
202dc64: 01 00 00 00 nop <== NOT EXECUTED
202dc68: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202dc6c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202dc70: 02 80 00 04 be 202dc80 <lstat+0x118> <== NOT EXECUTED
202dc74: 01 00 00 00 nop <== NOT EXECUTED
202dc78: 9f c0 40 00 call %g1 <== NOT EXECUTED
202dc7c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202dc80: 40 00 72 00 call 204a480 <__errno> <== NOT EXECUTED
202dc84: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202dc88: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202dc8c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202dc90: 81 c7 e0 08 ret <== NOT EXECUTED
202dc94: 81 e8 00 00 restore <== NOT EXECUTED
0200308c <malloc>:
size_t size
)
{
void *return_this;
MSBUMP(malloc_calls, 1);
200308c: 9d e3 bf a0 save %sp, -96, %sp
2003090: 03 00 80 7c sethi %hi(0x201f000), %g1
2003094: 82 10 61 e0 or %g1, 0x1e0, %g1 ! 201f1e0 <rtems_malloc_statistics>
2003098: c4 00 60 04 ld [ %g1 + 4 ], %g2
200309c: a0 10 00 18 mov %i0, %l0
20030a0: 84 00 a0 01 inc %g2
/*
* If some free's have been deferred, then do them now.
*/
malloc_deferred_frees_process();
20030a4: 7f ff ff b0 call 2002f64 <malloc_deferred_frees_process>
20030a8: c4 20 60 04 st %g2, [ %g1 + 4 ]
/*
* Validate the parameters
*/
if ( !size )
20030ac: 80 a6 20 00 cmp %i0, 0
20030b0: 02 80 00 24 be 2003140 <malloc+0xb4> <== NEVER TAKEN
20030b4: 03 00 80 7d sethi %hi(0x201f400), %g1
return (void *) 0;
/*
* Do not attempt to allocate memory if not in correct system state.
*/
if ( _System_state_Is_up(_System_state_Get()) &&
20030b8: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 201f540 <_System_state_Current>
20030bc: 80 a0 60 03 cmp %g1, 3
20030c0: 02 80 00 1b be 200312c <malloc+0xa0>
20030c4: 03 00 80 79 sethi %hi(0x201e400), %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 );
20030c8: d0 00 63 c0 ld [ %g1 + 0x3c0 ], %o0 ! 201e7c0 <RTEMS_Malloc_Heap>
20030cc: 92 10 00 10 mov %l0, %o1
20030d0: 94 10 20 00 clr %o2
20030d4: 40 00 15 62 call 200865c <_Protected_heap_Allocate_aligned_with_boundary>
20030d8: 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 ) {
20030dc: b0 92 20 00 orcc %o0, 0, %i0
20030e0: 02 80 00 1a be 2003148 <malloc+0xbc>
20030e4: a2 10 00 18 mov %i0, %l1
}
/*
* If the user wants us to dirty the allocated memory, then do it.
*/
if ( rtems_malloc_dirty_helper )
20030e8: 03 00 80 7b sethi %hi(0x201ec00), %g1
20030ec: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 201eef0 <rtems_malloc_dirty_helper>
20030f0: 80 a0 60 00 cmp %g1, 0
20030f4: 02 80 00 04 be 2003104 <malloc+0x78> <== ALWAYS TAKEN
20030f8: 92 10 00 10 mov %l0, %o1
(*rtems_malloc_dirty_helper)( return_this, size );
20030fc: 9f c0 40 00 call %g1 <== NOT EXECUTED
2003100: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
/*
* If configured, update the statistics
*/
if ( rtems_malloc_statistics_helpers )
2003104: 03 00 80 7b sethi %hi(0x201ec00), %g1
2003108: c2 00 62 e8 ld [ %g1 + 0x2e8 ], %g1 ! 201eee8 <rtems_malloc_statistics_helpers>
200310c: 80 a0 60 00 cmp %g1, 0
2003110: 02 80 00 05 be 2003124 <malloc+0x98>
2003114: b0 10 00 11 mov %l1, %i0
(*rtems_malloc_statistics_helpers->at_malloc)(return_this);
2003118: c2 00 60 04 ld [ %g1 + 4 ], %g1
200311c: 9f c0 40 00 call %g1
2003120: 90 10 00 11 mov %l1, %o0
2003124: 81 c7 e0 08 ret
2003128: 81 e8 00 00 restore
return (void *) 0;
/*
* Do not attempt to allocate memory if not in correct system state.
*/
if ( _System_state_Is_up(_System_state_Get()) &&
200312c: 7f ff ff 75 call 2002f00 <malloc_is_system_state_OK>
2003130: 01 00 00 00 nop
2003134: 80 8a 20 ff btst 0xff, %o0
2003138: 12 bf ff e4 bne 20030c8 <malloc+0x3c> <== ALWAYS TAKEN
200313c: 03 00 80 79 sethi %hi(0x201e400), %g1
if (rtems_malloc_boundary_helpers)
(*rtems_malloc_boundary_helpers->at_malloc)(return_this, size);
#endif
return return_this;
}
2003140: 81 c7 e0 08 ret <== NOT EXECUTED
2003144: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*/
return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size );
if ( !return_this ) {
if (rtems_malloc_sbrk_helpers)
2003148: 03 00 80 7b sethi %hi(0x201ec00), %g1
200314c: c2 00 62 ec ld [ %g1 + 0x2ec ], %g1 ! 201eeec <rtems_malloc_sbrk_helpers>
2003150: 80 a0 60 00 cmp %g1, 0
2003154: 02 80 00 08 be 2003174 <malloc+0xe8> <== ALWAYS TAKEN
2003158: 01 00 00 00 nop
return_this = (*rtems_malloc_sbrk_helpers->extend)( size );
200315c: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
2003160: 9f c0 40 00 call %g1 <== NOT EXECUTED
2003164: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( !return_this ) {
2003168: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
200316c: 12 bf ff e0 bne 20030ec <malloc+0x60> <== NOT EXECUTED
2003170: 03 00 80 7b sethi %hi(0x201ec00), %g1 <== NOT EXECUTED
errno = ENOMEM;
2003174: 40 00 3a 22 call 20119fc <__errno>
2003178: 01 00 00 00 nop
200317c: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc>
2003180: c2 22 00 00 st %g1, [ %o0 ]
return (void *) 0;
2003184: 81 c7 e0 08 ret
2003188: 81 e8 00 00 restore
02002f48 <malloc_deferred_free>:
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
2002f48: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2002f4c: 11 00 80 7c sethi %hi(0x201f000), %o0 <== NOT EXECUTED
2002f50: 90 12 21 d0 or %o0, 0x1d0, %o0 ! 201f1d0 <RTEMS_Malloc_GC_list><== NOT EXECUTED
2002f54: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2002f58: 40 00 10 ef call 2007314 <_Chain_Append> <== NOT EXECUTED
2002f5c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02002f64 <malloc_deferred_frees_process>:
void malloc_deferred_frees_process(void)
{
2002f64: 9d e3 bf a0 save %sp, -96, %sp
2002f68: 21 00 80 7c sethi %hi(0x201f000), %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)
2002f6c: 10 80 00 04 b 2002f7c <malloc_deferred_frees_process+0x18>
2002f70: a0 14 21 d0 or %l0, 0x1d0, %l0 ! 201f1d0 <RTEMS_Malloc_GC_list>
free(to_be_freed);
2002f74: 7f ff ff 5e call 2002cec <free> <== NOT EXECUTED
2002f78: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
2002f7c: 40 00 10 fc call 200736c <_Chain_Get>
2002f80: 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)
2002f84: 80 a2 20 00 cmp %o0, 0
2002f88: 12 bf ff fb bne 2002f74 <malloc_deferred_frees_process+0x10><== NEVER TAKEN
2002f8c: 01 00 00 00 nop
free(to_be_freed);
}
2002f90: 81 c7 e0 08 ret
2002f94: 81 e8 00 00 restore
02002f00 <malloc_is_system_state_OK>:
rtems_chain_control RTEMS_Malloc_GC_list;
bool malloc_is_system_state_OK(void)
{
if ( _Thread_Dispatch_disable_level > 0 )
2002f00: 03 00 80 7c sethi %hi(0x201f000), %g1
2002f04: c2 00 63 a0 ld [ %g1 + 0x3a0 ], %g1 ! 201f3a0 <_Thread_Dispatch_disable_level>
2002f08: 80 a0 60 00 cmp %g1, 0
2002f0c: 12 80 00 06 bne 2002f24 <malloc_is_system_state_OK+0x24> <== NEVER TAKEN
2002f10: 90 10 20 00 clr %o0
return false;
if ( _ISR_Nest_level > 0 )
2002f14: 03 00 80 7d sethi %hi(0x201f400), %g1
2002f18: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 ! 201f43c <_ISR_Nest_level>
#include "malloc_p.h"
rtems_chain_control RTEMS_Malloc_GC_list;
bool malloc_is_system_state_OK(void)
2002f1c: 80 a0 00 01 cmp %g0, %g1
2002f20: 90 60 3f ff subx %g0, -1, %o0
if ( _ISR_Nest_level > 0 )
return false;
return true;
}
2002f24: 81 c3 e0 08 retl
0200eccc <memfile_alloc_block>:
*/
int memfile_blocks_allocated = 0;
void *memfile_alloc_block(void)
{
200eccc: 9d e3 bf a0 save %sp, -96, %sp
void *memory;
memory = (void *)calloc(1, IMFS_MEMFILE_BYTES_PER_BLOCK);
200ecd0: 03 00 80 7b sethi %hi(0x201ec00), %g1
200ecd4: d2 00 63 38 ld [ %g1 + 0x338 ], %o1 ! 201ef38 <imfs_memfile_bytes_per_block>
200ecd8: 7f ff cf 62 call 2002a60 <calloc>
200ecdc: 90 10 20 01 mov 1, %o0
if ( memory )
200ece0: 80 a2 20 00 cmp %o0, 0
200ece4: 02 80 00 05 be 200ecf8 <memfile_alloc_block+0x2c> <== NEVER TAKEN
200ece8: 03 00 80 7c sethi %hi(0x201f000), %g1
memfile_blocks_allocated++;
200ecec: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 ! 201f04c <memfile_blocks_allocated>
200ecf0: 84 00 a0 01 inc %g2
200ecf4: c4 20 60 4c st %g2, [ %g1 + 0x4c ]
return memory;
}
200ecf8: 81 c7 e0 08 ret
200ecfc: 91 e8 00 08 restore %g0, %o0, %o0
0200f274 <memfile_check_rmnod>:
return memfile_check_rmnod( the_jnode );
}
int memfile_check_rmnod( IMFS_jnode_t *the_jnode ){
200f274: 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) ) {
200f278: 7f ff f6 4e call 200cbb0 <rtems_libio_is_file_open>
200f27c: 90 10 00 18 mov %i0, %o0
200f280: 80 a2 20 00 cmp %o0, 0
200f284: 12 80 00 13 bne 200f2d0 <memfile_check_rmnod+0x5c>
200f288: 01 00 00 00 nop
200f28c: c2 16 20 34 lduh [ %i0 + 0x34 ], %g1
200f290: 80 a0 60 00 cmp %g1, 0
200f294: 12 80 00 0f bne 200f2d0 <memfile_check_rmnod+0x5c> <== NEVER TAKEN
200f298: 03 00 80 7a sethi %hi(0x201e800), %g1
/*
* Is the rtems_filesystem_current is this node?
*/
if ( rtems_filesystem_current.node_access == the_jnode )
200f29c: c2 00 61 80 ld [ %g1 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
200f2a0: c4 00 60 04 ld [ %g1 + 4 ], %g2
200f2a4: 80 a0 80 18 cmp %g2, %i0
200f2a8: 22 80 00 02 be,a 200f2b0 <memfile_check_rmnod+0x3c> <== NEVER TAKEN
200f2ac: 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)
200f2b0: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200f2b4: 80 a0 60 06 cmp %g1, 6
200f2b8: 02 80 00 04 be 200f2c8 <memfile_check_rmnod+0x54> <== NEVER TAKEN
200f2bc: 01 00 00 00 nop
IMFS_memfile_remove( the_jnode );
200f2c0: 7f ff ff 7a call 200f0a8 <IMFS_memfile_remove>
200f2c4: 90 10 00 18 mov %i0, %o0
free( the_jnode );
200f2c8: 7f ff ce 89 call 2002cec <free>
200f2cc: 90 10 00 18 mov %i0, %o0
}
return 0;
}
200f2d0: 81 c7 e0 08 ret
200f2d4: 91 e8 20 00 restore %g0, 0, %o0
0200efc8 <memfile_free_blocks_in_table>:
void memfile_free_blocks_in_table(
block_p **block_table,
int entries
)
{
200efc8: 9d e3 bf a0 save %sp, -96, %sp
/*
* Perform internal consistency checks
*/
assert( block_table );
200efcc: 80 a6 20 00 cmp %i0, 0
200efd0: 02 80 00 16 be 200f028 <memfile_free_blocks_in_table+0x60><== NEVER TAKEN
200efd4: 80 a6 60 00 cmp %i1, 0
* Now go through all the slots in the table and free the memory.
*/
b = *block_table;
for ( i=0 ; i<entries ; i++ ) {
200efd8: 04 80 00 0f ble 200f014 <memfile_free_blocks_in_table+0x4c><== NEVER TAKEN
200efdc: d0 06 00 00 ld [ %i0 ], %o0
200efe0: a0 10 00 08 mov %o0, %l0
200efe4: a2 10 20 00 clr %l1
if ( b[i] ) {
200efe8: d0 04 00 00 ld [ %l0 ], %o0
200efec: 80 a2 20 00 cmp %o0, 0
200eff0: 02 80 00 05 be 200f004 <memfile_free_blocks_in_table+0x3c>
200eff4: a2 04 60 01 inc %l1
memfile_free_block( b[i] );
200eff8: 7f ff ff 2c call 200eca8 <memfile_free_block>
200effc: 01 00 00 00 nop
b[i] = 0;
200f000: 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++ ) {
200f004: 80 a6 40 11 cmp %i1, %l1
200f008: 14 bf ff f8 bg 200efe8 <memfile_free_blocks_in_table+0x20>
200f00c: a0 04 20 04 add %l0, 4, %l0
200f010: d0 06 00 00 ld [ %i0 ], %o0
/*
* Now that all the blocks in the block table are free, we can
* free the block table itself.
*/
memfile_free_block( *block_table );
200f014: 7f ff ff 25 call 200eca8 <memfile_free_block>
200f018: 01 00 00 00 nop
*block_table = 0;
200f01c: c0 26 00 00 clr [ %i0 ]
}
200f020: 81 c7 e0 08 ret
200f024: 81 e8 00 00 restore
/*
* Perform internal consistency checks
*/
assert( block_table );
200f028: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
200f02c: 15 00 80 77 sethi %hi(0x201dc00), %o2 <== NOT EXECUTED
200f030: 17 00 80 77 sethi %hi(0x201dc00), %o3 <== NOT EXECUTED
200f034: 90 12 21 20 or %o0, 0x120, %o0 <== NOT EXECUTED
200f038: 94 12 a2 90 or %o2, 0x290, %o2 <== NOT EXECUTED
200f03c: 96 12 e1 a8 or %o3, 0x1a8, %o3 <== NOT EXECUTED
200f040: 7f ff f6 2f call 200c8fc <__assert_func> <== NOT EXECUTED
200f044: 92 10 21 b3 mov 0x1b3, %o1 <== NOT EXECUTED
0200f594 <memfile_ftruncate>:
int memfile_ftruncate(
rtems_libio_t *iop,
rtems_off64_t length
)
{
200f594: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode;
the_jnode = iop->file_info;
200f598: e0 06 20 3c ld [ %i0 + 0x3c ], %l0
* 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 )
200f59c: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
200f5a0: 80 a0 40 19 cmp %g1, %i1
200f5a4: 06 80 00 13 bl 200f5f0 <memfile_ftruncate+0x5c> <== NEVER TAKEN
200f5a8: 90 10 00 10 mov %l0, %o0
200f5ac: 22 80 00 0d be,a 200f5e0 <memfile_ftruncate+0x4c> <== ALWAYS TAKEN
200f5b0: c2 04 20 54 ld [ %l0 + 0x54 ], %g1
* 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;
200f5b4: f2 24 20 50 st %i1, [ %l0 + 0x50 ] <== NOT EXECUTED
200f5b8: f4 24 20 54 st %i2, [ %l0 + 0x54 ]
iop->size = the_jnode->info.file.size;
200f5bc: f4 26 20 0c st %i2, [ %i0 + 0xc ]
200f5c0: f2 26 20 08 st %i1, [ %i0 + 8 ]
IMFS_update_atime( the_jnode );
200f5c4: 90 07 bf f8 add %fp, -8, %o0
200f5c8: 7f ff cd f4 call 2002d98 <gettimeofday>
200f5cc: 92 10 20 00 clr %o1
200f5d0: c2 07 bf f8 ld [ %fp + -8 ], %g1
200f5d4: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
return 0;
}
200f5d8: 81 c7 e0 08 ret
200f5dc: 91 e8 20 00 restore %g0, 0, %o0
* 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 )
200f5e0: 80 a0 40 1a cmp %g1, %i2
200f5e4: 3a bf ff f5 bcc,a 200f5b8 <memfile_ftruncate+0x24> <== ALWAYS TAKEN
200f5e8: f2 24 20 50 st %i1, [ %l0 + 0x50 ]
return IMFS_memfile_extend( the_jnode, length );
200f5ec: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200f5f0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
200f5f4: 7f ff ff 83 call 200f400 <IMFS_memfile_extend> <== NOT EXECUTED
200f5f8: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
200f5fc: 81 c7 e0 08 ret <== NOT EXECUTED
200f600: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0200f604 <memfile_lseek>:
rtems_off64_t memfile_lseek(
rtems_libio_t *iop,
rtems_off64_t offset,
int whence
)
{
200f604: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *the_jnode;
the_jnode = iop->file_info;
200f608: e0 06 20 3c ld [ %i0 + 0x3c ], %l0
if (the_jnode->type == IMFS_LINEAR_FILE) {
200f60c: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
200f610: 80 a0 60 06 cmp %g1, 6
200f614: 02 80 00 0f be 200f650 <memfile_lseek+0x4c> <== NEVER TAKEN
200f618: 90 10 00 10 mov %l0, %o0
if (iop->offset > the_jnode->info.linearfile.size)
iop->offset = the_jnode->info.linearfile.size;
}
else { /* Must be a block file (IMFS_MEMORY_FILE). */
if (IMFS_memfile_extend( the_jnode, iop->offset ))
200f61c: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2
200f620: 92 10 00 02 mov %g2, %o1
200f624: 7f ff ff 77 call 200f400 <IMFS_memfile_extend>
200f628: 94 10 00 03 mov %g3, %o2
200f62c: 80 a2 20 00 cmp %o0, 0
200f630: 12 80 00 1b bne 200f69c <memfile_lseek+0x98> <== NEVER TAKEN
200f634: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOSPC );
iop->size = the_jnode->info.file.size;
200f638: d8 1c 20 50 ldd [ %l0 + 0x50 ], %o4
200f63c: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2
200f640: d8 3e 20 08 std %o4, [ %i0 + 8 ]
}
return iop->offset;
}
200f644: b2 10 00 03 mov %g3, %i1
200f648: 81 c7 e0 08 ret
200f64c: 91 e8 00 02 restore %g0, %g2, %o0
IMFS_jnode_t *the_jnode;
the_jnode = iop->file_info;
if (the_jnode->type == IMFS_LINEAR_FILE) {
if (iop->offset > the_jnode->info.linearfile.size)
200f650: c4 1c 20 50 ldd [ %l0 + 0x50 ], %g2 <== NOT EXECUTED
200f654: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
200f658: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200f65c: 14 80 00 0c bg 200f68c <memfile_lseek+0x88> <== NOT EXECUTED
200f660: c8 06 20 14 ld [ %i0 + 0x14 ], %g4 <== NOT EXECUTED
200f664: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200f668: 02 80 00 07 be 200f684 <memfile_lseek+0x80> <== NOT EXECUTED
200f66c: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED
200f670: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
200f674: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSPC );
iop->size = the_jnode->info.file.size;
}
return iop->offset;
}
200f678: b0 10 00 02 mov %g2, %i0 <== NOT EXECUTED
200f67c: 81 c7 e0 08 ret <== NOT EXECUTED
200f680: 93 e8 00 03 restore %g0, %g3, %o1 <== NOT EXECUTED
IMFS_jnode_t *the_jnode;
the_jnode = iop->file_info;
if (the_jnode->type == IMFS_LINEAR_FILE) {
if (iop->offset > the_jnode->info.linearfile.size)
200f684: 28 bf ff fc bleu,a 200f674 <memfile_lseek+0x70> <== NOT EXECUTED
200f688: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
iop->offset = the_jnode->info.linearfile.size;
200f68c: c4 3e 20 10 std %g2, [ %i0 + 0x10 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOSPC );
iop->size = the_jnode->info.file.size;
}
return iop->offset;
}
200f690: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
200f694: 81 c7 e0 08 ret <== NOT EXECUTED
200f698: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
if (iop->offset > the_jnode->info.linearfile.size)
iop->offset = the_jnode->info.linearfile.size;
}
else { /* Must be a block file (IMFS_MEMORY_FILE). */
if (IMFS_memfile_extend( the_jnode, iop->offset ))
rtems_set_errno_and_return_minus_one( ENOSPC );
200f69c: 40 00 08 d8 call 20119fc <__errno> <== NOT EXECUTED
200f6a0: 01 00 00 00 nop <== NOT EXECUTED
200f6a4: 82 10 20 1c mov 0x1c, %g1 ! 1c <PROM_START+0x1c> <== NOT EXECUTED
200f6a8: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
200f6ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200f6b0: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
200f6b4: 10 bf ff e4 b 200f644 <memfile_lseek+0x40> <== NOT EXECUTED
200f6b8: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
0200f9b0 <memfile_open>:
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
200f9b0: 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))
200f9b4: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode
)
{
200f9b8: a0 10 00 18 mov %i0, %l0
the_jnode = iop->file_info;
/*
* Perform 'copy on write' for linear files
*/
if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
200f9bc: 80 88 62 04 btst 0x204, %g1
200f9c0: 02 80 00 06 be 200f9d8 <memfile_open+0x28>
200f9c4: e2 06 20 3c ld [ %i0 + 0x3c ], %l1
&& (the_jnode->type == IMFS_LINEAR_FILE)) {
200f9c8: c4 04 60 4c ld [ %l1 + 0x4c ], %g2
200f9cc: 80 a0 a0 06 cmp %g2, 6
200f9d0: 22 80 00 0c be,a 200fa00 <memfile_open+0x50> <== NEVER TAKEN
200f9d4: d8 04 60 54 ld [ %l1 + 0x54 ], %o4 <== 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)
200f9d8: c4 1c 60 50 ldd [ %l1 + 0x50 ], %g2
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))
return -1;
}
if (iop->flags & LIBIO_FLAGS_APPEND)
200f9dc: 80 88 62 00 btst 0x200, %g1
200f9e0: 22 80 00 05 be,a 200f9f4 <memfile_open+0x44>
200f9e4: c4 3c 20 08 std %g2, [ %l0 + 8 ]
iop->offset = the_jnode->info.file.size;
200f9e8: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
200f9ec: c4 1c 60 50 ldd [ %l1 + 0x50 ], %g2
iop->size = the_jnode->info.file.size;
200f9f0: c4 3c 20 08 std %g2, [ %l0 + 8 ]
200f9f4: b0 10 20 00 clr %i0
return 0;
}
200f9f8: 81 c7 e0 08 ret
200f9fc: 81 e8 00 00 restore
* Perform 'copy on write' for linear files
*/
if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
&& (the_jnode->type == IMFS_LINEAR_FILE)) {
uint32_t count = the_jnode->info.linearfile.size;
const unsigned char *buffer = the_jnode->info.linearfile.direct;
200fa00: d6 04 60 58 ld [ %l1 + 0x58 ], %o3 <== NOT EXECUTED
the_jnode->type = IMFS_MEMORY_FILE;
200fa04: 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;
200fa08: c0 24 60 5c clr [ %l1 + 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;
200fa0c: c0 24 60 50 clr [ %l1 + 0x50 ] <== NOT EXECUTED
200fa10: c0 24 60 54 clr [ %l1 + 0x54 ] <== NOT EXECUTED
the_jnode->info.file.indirect = 0;
the_jnode->info.file.doubly_indirect = 0;
the_jnode->info.file.triply_indirect = 0;
200fa14: c0 24 60 60 clr [ %l1 + 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;
200fa18: c0 24 60 58 clr [ %l1 + 0x58 ] <== NOT EXECUTED
the_jnode->info.file.doubly_indirect = 0;
the_jnode->info.file.triply_indirect = 0;
if ((count != 0)
200fa1c: 80 a3 20 00 cmp %o4, 0 <== NOT EXECUTED
200fa20: 12 80 00 06 bne 200fa38 <memfile_open+0x88> <== NOT EXECUTED
200fa24: c2 24 60 4c st %g1, [ %l1 + 0x4c ] <== NOT EXECUTED
200fa28: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
200fa2c: 84 10 20 00 clr %g2 <== NOT EXECUTED
200fa30: 10 bf ff eb b 200f9dc <memfile_open+0x2c> <== NOT EXECUTED
200fa34: 86 10 20 00 clr %g3 <== NOT EXECUTED
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))
200fa38: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200fa3c: 92 10 20 00 clr %o1 <== NOT EXECUTED
200fa40: 94 10 20 00 clr %o2 <== NOT EXECUTED
200fa44: 7f ff ff 1e call 200f6bc <IMFS_memfile_write> <== NOT EXECUTED
200fa48: 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)
200fa4c: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
200fa50: 02 bf ff ea be 200f9f8 <memfile_open+0x48> <== NOT EXECUTED
200fa54: 01 00 00 00 nop <== NOT EXECUTED
200fa58: 10 bf ff e0 b 200f9d8 <memfile_open+0x28> <== NOT EXECUTED
200fa5c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
0200f2d8 <memfile_rmnod>:
int memfile_rmnod(
rtems_filesystem_location_info_t *parent_pathloc, /* IN */
rtems_filesystem_location_info_t *pathloc /* IN */
)
{
200f2d8: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode;
the_jnode = (IMFS_jnode_t *) pathloc->node_access;
200f2dc: 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 ) {
200f2e0: c2 04 20 08 ld [ %l0 + 8 ], %g1
200f2e4: 80 a0 60 00 cmp %g1, 0
200f2e8: 22 80 00 06 be,a 200f300 <memfile_rmnod+0x28> <== NEVER TAKEN
200f2ec: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
200f2f0: 7f ff e0 15 call 2007344 <_Chain_Extract>
200f2f4: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode );
the_jnode->Parent = NULL;
200f2f8: c0 24 20 08 clr [ %l0 + 8 ]
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
200f2fc: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
200f300: 92 10 20 00 clr %o1
/*
* Decrement the link counter and see if we can free the space.
*/
the_jnode->st_nlink--;
200f304: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
200f308: 90 07 bf f8 add %fp, -8, %o0
200f30c: 7f ff ce a3 call 2002d98 <gettimeofday>
200f310: c2 34 20 34 sth %g1, [ %l0 + 0x34 ]
200f314: c2 07 bf f8 ld [ %fp + -8 ], %g1
return memfile_check_rmnod( the_jnode );
200f318: 90 10 00 10 mov %l0, %o0
200f31c: 7f ff ff d6 call 200f274 <memfile_check_rmnod>
200f320: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
}
200f324: 81 c7 e0 08 ret
200f328: 91 e8 00 08 restore %g0, %o0, %o0
020031ac <mknod>:
int mknod(
const char *pathname,
mode_t mode,
dev_t dev
)
{
20031ac: 9d e3 bf 80 save %sp, -128, %sp
int result;
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & S_IFMT)
20031b0: 03 00 00 3c sethi %hi(0xf000), %g1
20031b4: 05 00 00 10 sethi %hi(0x4000), %g2
20031b8: 82 0e 40 01 and %i1, %g1, %g1
20031bc: 80 a0 40 02 cmp %g1, %g2
20031c0: 02 80 00 18 be 2003220 <mknod+0x74>
20031c4: a0 07 bf e4 add %fp, -28, %l0
20031c8: 08 80 00 0f bleu 2003204 <mknod+0x58>
20031cc: 05 00 00 04 sethi %hi(0x1000), %g2
20031d0: 05 00 00 18 sethi %hi(0x6000), %g2
20031d4: 80 a0 40 02 cmp %g1, %g2
20031d8: 02 80 00 12 be 2003220 <mknod+0x74>
20031dc: 05 00 00 20 sethi %hi(0x8000), %g2
20031e0: 80 a0 40 02 cmp %g1, %g2
20031e4: 02 80 00 10 be 2003224 <mknod+0x78> <== ALWAYS TAKEN
20031e8: 90 10 00 18 mov %i0, %o0
case S_IFBLK:
case S_IFREG:
case S_IFIFO:
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
20031ec: 40 00 3a 04 call 20119fc <__errno> <== NOT EXECUTED
20031f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20031f4: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20031f8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20031fc: 81 c7 e0 08 ret
2003200: 81 e8 00 00 restore
int result;
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & S_IFMT)
2003204: 80 a0 40 02 cmp %g1, %g2
2003208: 02 80 00 05 be 200321c <mknod+0x70>
200320c: 05 00 00 08 sethi %hi(0x2000), %g2
2003210: 80 a0 40 02 cmp %g1, %g2
2003214: 12 bf ff f6 bne 20031ec <mknod+0x40> <== NEVER TAKEN
2003218: 01 00 00 00 nop
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
}
rtems_filesystem_get_start_loc( pathname, &i, &temp_loc );
200321c: a0 07 bf e4 add %fp, -28, %l0
2003220: 90 10 00 18 mov %i0, %o0
2003224: 92 07 bf fc add %fp, -4, %o1
2003228: 40 00 02 d0 call 2003d68 <rtems_filesystem_get_start_loc>
200322c: 94 10 00 10 mov %l0, %o2
if ( !temp_loc.ops->evalformake_h ) {
2003230: c2 07 bf f0 ld [ %fp + -16 ], %g1
2003234: c2 00 60 04 ld [ %g1 + 4 ], %g1
2003238: 80 a0 60 00 cmp %g1, 0
200323c: 02 80 00 25 be 20032d0 <mknod+0x124> <== NEVER TAKEN
2003240: d0 07 bf fc ld [ %fp + -4 ], %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*temp_loc.ops->evalformake_h)(
2003244: 92 10 00 10 mov %l0, %o1
2003248: 90 06 00 08 add %i0, %o0, %o0
200324c: 94 07 bf f8 add %fp, -8, %o2
2003250: 9f c0 40 00 call %g1
2003254: b0 10 3f ff mov -1, %i0
&pathname[i],
&temp_loc,
&name_start
);
if ( result != 0 )
2003258: 80 a2 20 00 cmp %o0, 0
200325c: 12 bf ff e8 bne 20031fc <mknod+0x50>
2003260: c4 07 bf f0 ld [ %fp + -16 ], %g2
return -1;
if ( !temp_loc.ops->mknod_h ) {
2003264: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1
2003268: 80 a0 60 00 cmp %g1, 0
200326c: 02 80 00 13 be 20032b8 <mknod+0x10c> <== NEVER TAKEN
2003270: d0 07 bf f8 ld [ %fp + -8 ], %o0
rtems_filesystem_freenode( &temp_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*temp_loc.ops->mknod_h)( name_start, mode, dev, &temp_loc );
2003274: 92 10 00 19 mov %i1, %o1
2003278: 94 10 00 1a mov %i2, %o2
200327c: 96 10 00 1b mov %i3, %o3
2003280: 9f c0 40 00 call %g1
2003284: 98 10 00 10 mov %l0, %o4
rtems_filesystem_freenode( &temp_loc );
2003288: c2 07 bf f0 ld [ %fp + -16 ], %g1
200328c: 80 a0 60 00 cmp %g1, 0
2003290: 02 bf ff db be 20031fc <mknod+0x50> <== NEVER TAKEN
2003294: b0 10 00 08 mov %o0, %i0
2003298: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
200329c: 80 a0 60 00 cmp %g1, 0
20032a0: 02 80 00 10 be 20032e0 <mknod+0x134>
20032a4: 01 00 00 00 nop
20032a8: 9f c0 40 00 call %g1
20032ac: 90 10 00 10 mov %l0, %o0
return result;
}
20032b0: 81 c7 e0 08 ret
20032b4: 81 e8 00 00 restore
);
if ( result != 0 )
return -1;
if ( !temp_loc.ops->mknod_h ) {
rtems_filesystem_freenode( &temp_loc );
20032b8: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
20032bc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20032c0: 02 80 00 04 be 20032d0 <mknod+0x124> <== NOT EXECUTED
20032c4: 01 00 00 00 nop <== NOT EXECUTED
20032c8: 9f c0 40 00 call %g1 <== NOT EXECUTED
20032cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
20032d0: 40 00 39 cb call 20119fc <__errno> <== NOT EXECUTED
20032d4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20032d8: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
20032dc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20032e0: 81 c7 e0 08 ret
20032e4: 81 e8 00 00 restore
02003370 <mount>:
const char *target,
const char *filesystemtype,
rtems_filesystem_options_t options,
const void *data
)
{
2003370: 9d e3 bf 88 save %sp, -120, %sp
/*
* Are the file system options valid?
*/
if ( options != RTEMS_FILESYSTEM_READ_ONLY &&
2003374: 80 a6 e0 01 cmp %i3, 1
2003378: 18 80 00 a4 bgu 2003608 <mount+0x298>
200337c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
/*
* Get mount handler
*/
mount_h = rtems_filesystem_get_mount_handler( filesystemtype );
2003380: 40 00 27 24 call 200d010 <rtems_filesystem_get_mount_handler>
2003384: 90 10 00 1a mov %i2, %o0
if ( !mount_h )
2003388: a4 92 20 00 orcc %o0, 0, %l2
200338c: 02 80 00 9f be 2003608 <mount+0x298>
2003390: 80 a0 00 19 cmp %g0, %i1
const char *target_or_null,
const char *filesystemtype,
size_t *target_length_ptr
)
{
const char *target = target_or_null != NULL ? target_or_null : "/";
2003394: a2 40 20 00 addx %g0, 0, %l1
2003398: 80 a4 60 00 cmp %l1, 0
200339c: 02 80 00 97 be 20035f8 <mount+0x288>
20033a0: 90 10 00 19 mov %i1, %o0
* 4) The mount point exists with the proper permissions to allow mounting
* 5) The selected mount point already has a file system mounted to it
*
*/
int mount(
20033a4: 40 00 3d 63 call 2012930 <strlen>
20033a8: ac 10 00 19 mov %i1, %l6
20033ac: a6 10 00 08 mov %o0, %l3
const char *filesystemtype,
size_t *target_length_ptr
)
{
const char *target = target_or_null != NULL ? target_or_null : "/";
size_t filesystemtype_size = strlen( filesystemtype ) + 1;
20033b0: 40 00 3d 60 call 2012930 <strlen>
20033b4: 90 10 00 1a mov %i2, %o0
size_t source_size = source_or_null != NULL ?
strlen( source_or_null ) + 1 : 0;
20033b8: 80 a6 20 00 cmp %i0, 0
const char *filesystemtype,
size_t *target_length_ptr
)
{
const char *target = target_or_null != NULL ? target_or_null : "/";
size_t filesystemtype_size = strlen( filesystemtype ) + 1;
20033bc: aa 02 20 01 add %o0, 1, %l5
size_t source_size = source_or_null != NULL ?
strlen( source_or_null ) + 1 : 0;
20033c0: 02 80 00 05 be 20033d4 <mount+0x64>
20033c4: a8 10 20 00 clr %l4
20033c8: 40 00 3d 5a call 2012930 <strlen>
20033cc: 90 10 00 18 mov %i0, %o0
20033d0: a8 02 20 01 add %o0, 1, %l4
size_t target_length = strlen( target );
size_t size = sizeof( rtems_filesystem_mount_table_entry_t )
+ filesystemtype_size + source_size + target_length + 1;
rtems_filesystem_mount_table_entry_t *mt_entry = calloc( 1, size );
20033d4: 92 04 e0 75 add %l3, 0x75, %o1
20033d8: 90 10 20 01 mov 1, %o0
20033dc: 92 02 40 15 add %o1, %l5, %o1
20033e0: 7f ff fd a0 call 2002a60 <calloc>
20033e4: 92 02 40 14 add %o1, %l4, %o1
if ( mt_entry != NULL ) {
20033e8: a0 92 20 00 orcc %o0, 0, %l0
20033ec: 02 80 00 7d be 20035e0 <mount+0x270> <== NEVER TAKEN
20033f0: 92 10 00 1a mov %i2, %o1
char *str = (char *) mt_entry + sizeof( *mt_entry );
20033f4: b4 04 20 74 add %l0, 0x74, %i2
strcpy( str, filesystemtype );
20033f8: 40 00 3d 16 call 2012850 <strcpy>
20033fc: 90 10 00 1a mov %i2, %o0
mt_entry->type = str;
2003400: f4 24 20 6c st %i2, [ %l0 + 0x6c ]
str += filesystemtype_size;
if ( source_or_null != NULL ) {
2003404: 80 a6 20 00 cmp %i0, 0
2003408: 02 80 00 07 be 2003424 <mount+0xb4>
200340c: b4 06 80 15 add %i2, %l5, %i2
strcpy( str, source_or_null );
2003410: 90 10 00 1a mov %i2, %o0
2003414: 40 00 3d 0f call 2012850 <strcpy>
2003418: 92 10 00 18 mov %i0, %o1
mt_entry->dev = str;
200341c: f4 24 20 70 st %i2, [ %l0 + 0x70 ]
str += source_size;
2003420: b4 06 80 14 add %i2, %l4, %i2
}
strcpy( str, target );
2003424: 92 10 00 16 mov %l6, %o1
2003428: 40 00 3d 0a call 2012850 <strcpy>
200342c: 90 10 00 1a mov %i2, %o0
if ( !mt_entry )
rtems_set_errno_and_return_minus_one( ENOMEM );
mt_entry->mt_fs_root.mt_entry = mt_entry;
mt_entry->options = options;
mt_entry->pathconf_limits_and_options = rtems_filesystem_default_pathconf;
2003430: 13 00 80 75 sethi %hi(0x201d400), %o1
mt_entry->dev = str;
str += source_size;
}
strcpy( str, target );
mt_entry->target = str;
2003434: f4 24 20 68 st %i2, [ %l0 + 0x68 ]
);
if ( !mt_entry )
rtems_set_errno_and_return_minus_one( ENOMEM );
mt_entry->mt_fs_root.mt_entry = mt_entry;
mt_entry->options = options;
2003438: f6 24 20 30 st %i3, [ %l0 + 0x30 ]
&target_length
);
if ( !mt_entry )
rtems_set_errno_and_return_minus_one( ENOMEM );
mt_entry->mt_fs_root.mt_entry = mt_entry;
200343c: e0 24 20 2c st %l0, [ %l0 + 0x2c ]
mt_entry->options = options;
mt_entry->pathconf_limits_and_options = rtems_filesystem_default_pathconf;
2003440: 92 12 61 68 or %o1, 0x168, %o1
2003444: 90 04 20 38 add %l0, 0x38, %o0
2003448: 40 00 3b a9 call 20122ec <memcpy>
200344c: 94 10 20 30 mov 0x30, %o2
/*
* The mount_point should be a directory with read/write/execute
* permissions in the existing tree.
*/
if ( has_target ) {
2003450: 80 a4 60 00 cmp %l1, 0
2003454: 12 80 00 2b bne 2003500 <mount+0x190>
2003458: 03 00 80 7a sethi %hi(0x201e800), %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200345c: c4 00 61 60 ld [ %g1 + 0x160 ], %g2 ! 201e960 <mount_chain>
}
} else {
/*
* Do we already have a base file system ?
*/
if ( !rtems_chain_is_empty( &mount_chain ) ) {
2003460: 82 10 61 60 or %g1, 0x160, %g1
2003464: 82 00 60 04 add %g1, 4, %g1
2003468: 80 a0 80 01 cmp %g2, %g1
200346c: 12 80 00 7b bne 2003658 <mount+0x2e8> <== NEVER TAKEN
2003470: a6 10 20 00 clr %l3
* mt_point_node.node_access will be left to null to indicate that this
* is the root of the entire file system.
*/
}
if ( (*mount_h)( mt_entry, data ) ) {
2003474: 92 10 00 1c mov %i4, %o1
2003478: 9f c4 80 00 call %l2
200347c: 90 10 00 10 mov %l0, %o0
2003480: 80 a2 20 00 cmp %o0, 0
2003484: 12 80 00 67 bne 2003620 <mount+0x2b0> <== NEVER TAKEN
2003488: 25 00 80 7c sethi %hi(0x201f000), %l2
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 );
200348c: d0 04 a1 cc ld [ %l2 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
2003490: 94 10 20 00 clr %o2
2003494: 40 00 0d 10 call 20068d4 <rtems_semaphore_obtain>
2003498: 92 10 20 00 clr %o1
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200349c: 92 10 00 10 mov %l0, %o1
20034a0: 11 00 80 7a sethi %hi(0x201e800), %o0
20034a4: 40 00 0f 9c call 2007314 <_Chain_Append>
20034a8: 90 12 21 60 or %o0, 0x160, %o0 ! 201e960 <mount_chain>
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
20034ac: d0 04 a1 cc ld [ %l2 + 0x1cc ], %o0
20034b0: 40 00 0d 50 call 20069f0 <rtems_semaphore_release>
20034b4: b0 10 20 00 clr %i0
*/
rtems_libio_lock();
rtems_chain_append( &mount_chain, &mt_entry->Node );
rtems_libio_unlock();
if ( !has_target )
20034b8: 80 a4 60 00 cmp %l1, 0
20034bc: 22 80 00 04 be,a 20034cc <mount+0x15c>
20034c0: c4 04 20 1c ld [ %l0 + 0x1c ], %g2
if ( loc_to_free )
rtems_filesystem_freenode( loc_to_free );
return -1;
}
20034c4: 81 c7 e0 08 ret
20034c8: 81 e8 00 00 restore
rtems_libio_lock();
rtems_chain_append( &mount_chain, &mt_entry->Node );
rtems_libio_unlock();
if ( !has_target )
rtems_filesystem_root = mt_entry->mt_fs_root;
20034cc: 03 00 80 7a sethi %hi(0x201e800), %g1
20034d0: c2 00 61 80 ld [ %g1 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
20034d4: c4 20 60 18 st %g2, [ %g1 + 0x18 ]
20034d8: c4 04 20 20 ld [ %l0 + 0x20 ], %g2
20034dc: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
20034e0: c4 04 20 24 ld [ %l0 + 0x24 ], %g2
20034e4: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
20034e8: c4 04 20 28 ld [ %l0 + 0x28 ], %g2
20034ec: c4 20 60 24 st %g2, [ %g1 + 0x24 ]
20034f0: c4 04 20 2c ld [ %l0 + 0x2c ], %g2
20034f4: c4 20 60 28 st %g2, [ %g1 + 0x28 ]
20034f8: 81 c7 e0 08 ret
20034fc: 81 e8 00 00 restore
* The mount_point should be a directory with read/write/execute
* permissions in the existing tree.
*/
if ( has_target ) {
if ( rtems_filesystem_evaluate_path(
2003500: 90 10 00 19 mov %i1, %o0
2003504: 92 10 00 13 mov %l3, %o1
2003508: b6 07 bf ec add %fp, -20, %i3
200350c: 94 10 20 07 mov 7, %o2
2003510: 96 10 00 1b mov %i3, %o3
2003514: 7f ff fd d7 call 2002c70 <rtems_filesystem_evaluate_path>
2003518: 98 10 20 01 mov 1, %o4
200351c: 80 a2 3f ff cmp %o0, -1
2003520: 02 80 00 52 be 2003668 <mount+0x2f8> <== NEVER TAKEN
2003524: c2 07 bf f8 ld [ %fp + -8 ], %g1
/*
* Test for node_type_h
*/
if (!loc.ops->node_type_h) {
2003528: c2 00 60 10 ld [ %g1 + 0x10 ], %g1
200352c: 80 a0 60 00 cmp %g1, 0
2003530: 02 80 00 5d be 20036a4 <mount+0x334> <== NEVER TAKEN
2003534: 01 00 00 00 nop
/*
* Test to see if it is a directory
*/
if ( loc.ops->node_type_h( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
2003538: 9f c0 40 00 call %g1
200353c: 90 10 00 1b mov %i3, %o0
2003540: 80 a2 20 01 cmp %o0, 1
2003544: 12 80 00 4e bne 200367c <mount+0x30c>
2003548: d2 07 bf ec ld [ %fp + -20 ], %o1
/*
* You can only mount one file system onto a single mount point.
*/
if ( rtems_filesystem_mount_iterate( is_node_fs_root, loc.node_access ) ) {
200354c: 11 00 80 0c sethi %hi(0x2003000), %o0
2003550: 7f ff ff 6b call 20032fc <rtems_filesystem_mount_iterate>
2003554: 90 12 22 e8 or %o0, 0x2e8, %o0 ! 20032e8 <is_node_fs_root>
2003558: 80 8a 20 ff btst 0xff, %o0
200355c: 12 80 00 4d bne 2003690 <mount+0x320>
2003560: c6 07 bf ec ld [ %fp + -20 ], %g3
* traverse the tree.
*/
mt_entry->mt_point_node.node_access = loc.node_access;
mt_entry->mt_point_node.handlers = loc.handlers;
mt_entry->mt_point_node.ops = loc.ops;
2003564: c4 07 bf f8 ld [ %fp + -8 ], %g2
* 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.
*/
mt_entry->mt_point_node.node_access = loc.node_access;
2003568: c6 24 20 08 st %g3, [ %l0 + 8 ]
mt_entry->mt_point_node.handlers = loc.handlers;
200356c: c6 07 bf f4 ld [ %fp + -12 ], %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 ){
2003570: c2 00 a0 20 ld [ %g2 + 0x20 ], %g1
* until the system is unmounted. It may be needed to correctly
* traverse the tree.
*/
mt_entry->mt_point_node.node_access = loc.node_access;
mt_entry->mt_point_node.handlers = loc.handlers;
2003574: c6 24 20 10 st %g3, [ %l0 + 0x10 ]
mt_entry->mt_point_node.ops = loc.ops;
mt_entry->mt_point_node.mt_entry = loc.mt_entry;
2003578: c6 07 bf fc ld [ %fp + -4 ], %g3
* traverse the tree.
*/
mt_entry->mt_point_node.node_access = loc.node_access;
mt_entry->mt_point_node.handlers = loc.handlers;
mt_entry->mt_point_node.ops = loc.ops;
200357c: c4 24 20 14 st %g2, [ %l0 + 0x14 ]
/*
* This link to the parent is only done when we are dealing with system
* below the base file system
*/
if ( !loc.ops->mount_h ){
2003580: 80 a0 60 00 cmp %g1, 0
2003584: 02 80 00 48 be 20036a4 <mount+0x334> <== NEVER TAKEN
2003588: c6 24 20 18 st %g3, [ %l0 + 0x18 ]
errno = ENOTSUP;
goto cleanup_and_bail;
}
if ( loc.ops->mount_h( mt_entry ) ) {
200358c: 90 10 00 10 mov %l0, %o0
2003590: 9f c0 40 00 call %g1
2003594: a6 10 00 1b mov %i3, %l3
2003598: 80 a2 20 00 cmp %o0, 0
200359c: 02 bf ff b7 be 2003478 <mount+0x108> <== ALWAYS TAKEN
20035a0: 92 10 00 1c mov %i4, %o1
return 0;
cleanup_and_bail:
free( mt_entry );
20035a4: 90 10 00 10 mov %l0, %o0
20035a8: 7f ff fd d1 call 2002cec <free>
20035ac: a6 10 00 1b mov %i3, %l3
if ( loc_to_free )
rtems_filesystem_freenode( loc_to_free );
20035b0: c2 04 e0 0c ld [ %l3 + 0xc ], %g1
20035b4: 80 a0 60 00 cmp %g1, 0
20035b8: 02 80 00 26 be 2003650 <mount+0x2e0> <== NEVER TAKEN
20035bc: 01 00 00 00 nop
20035c0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20035c4: 80 a0 60 00 cmp %g1, 0
20035c8: 02 80 00 22 be 2003650 <mount+0x2e0> <== NEVER TAKEN
20035cc: 90 10 00 13 mov %l3, %o0
20035d0: 9f c0 40 00 call %g1
20035d4: b0 10 3f ff mov -1, %i0
20035d8: 81 c7 e0 08 ret
20035dc: 81 e8 00 00 restore
target,
filesystemtype,
&target_length
);
if ( !mt_entry )
rtems_set_errno_and_return_minus_one( ENOMEM );
20035e0: 40 00 39 07 call 20119fc <__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 <== NOT EXECUTED
20035f4: 81 e8 00 00 restore <== NOT EXECUTED
const char *target_or_null,
const char *filesystemtype,
size_t *target_length_ptr
)
{
const char *target = target_or_null != NULL ? target_or_null : "/";
20035f8: 2d 00 80 75 sethi %hi(0x201d400), %l6
20035fc: a6 10 20 01 mov 1, %l3
2003600: 10 bf ff 6c b 20033b0 <mount+0x40>
2003604: ac 15 a1 60 or %l6, 0x160, %l6
/*
* Get mount handler
*/
mount_h = rtems_filesystem_get_mount_handler( filesystemtype );
if ( !mount_h )
rtems_set_errno_and_return_minus_one( EINVAL );
2003608: 40 00 38 fd call 20119fc <__errno>
200360c: b0 10 3f ff mov -1, %i0
2003610: 82 10 20 16 mov 0x16, %g1
2003614: c2 22 00 00 st %g1, [ %o0 ]
2003618: 81 c7 e0 08 ret
200361c: 81 e8 00 00 restore
if ( (*mount_h)( mt_entry, data ) ) {
/*
* Try to undo the mount operation
*/
if ( loc.ops->unmount_h ) {
2003620: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2003624: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 <== NOT EXECUTED
2003628: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200362c: 02 80 00 04 be 200363c <mount+0x2cc> <== NOT EXECUTED
2003630: 01 00 00 00 nop <== NOT EXECUTED
loc.ops->unmount_h( mt_entry );
2003634: 9f c0 40 00 call %g1 <== NOT EXECUTED
2003638: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return 0;
cleanup_and_bail:
free( mt_entry );
200363c: 7f ff fd ac call 2002cec <free> <== NOT EXECUTED
2003640: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( loc_to_free )
2003644: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2003648: 32 bf ff db bne,a 20035b4 <mount+0x244> <== NOT EXECUTED
200364c: c2 04 e0 0c ld [ %l3 + 0xc ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( loc_to_free );
return -1;
}
2003650: 81 c7 e0 08 ret <== NOT EXECUTED
2003654: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
} else {
/*
* Do we already have a base file system ?
*/
if ( !rtems_chain_is_empty( &mount_chain ) ) {
errno = EINVAL;
2003658: 40 00 38 e9 call 20119fc <__errno> <== NOT EXECUTED
200365c: 01 00 00 00 nop <== NOT EXECUTED
2003660: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
2003664: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return 0;
cleanup_and_bail:
free( mt_entry );
2003668: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200366c: 7f ff fd a0 call 2002cec <free> <== NOT EXECUTED
2003670: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2003674: 81 c7 e0 08 ret <== NOT EXECUTED
2003678: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Test to see if it is a directory
*/
if ( loc.ops->node_type_h( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
errno = ENOTDIR;
200367c: 40 00 38 e0 call 20119fc <__errno>
2003680: 01 00 00 00 nop
2003684: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14>
goto cleanup_and_bail;
2003688: 10 bf ff c7 b 20035a4 <mount+0x234>
200368c: c2 22 00 00 st %g1, [ %o0 ]
/*
* You can only mount one file system onto a single mount point.
*/
if ( rtems_filesystem_mount_iterate( is_node_fs_root, loc.node_access ) ) {
errno = EBUSY;
2003690: 40 00 38 db call 20119fc <__errno>
2003694: 01 00 00 00 nop
2003698: 82 10 20 10 mov 0x10, %g1 ! 10 <PROM_START+0x10>
goto cleanup_and_bail;
200369c: 10 bf ff c2 b 20035a4 <mount+0x234>
20036a0: c2 22 00 00 st %g1, [ %o0 ]
* 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;
20036a4: 40 00 38 d6 call 20119fc <__errno> <== NOT EXECUTED
20036a8: 01 00 00 00 nop <== NOT EXECUTED
20036ac: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
goto cleanup_and_bail;
20036b0: 10 bf ff bd b 20035a4 <mount+0x234> <== NOT EXECUTED
20036b4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
0200b7f8 <mq_open>:
int oflag,
...
/* mode_t mode, */
/* struct mq_attr attr */
)
{
200b7f8: 9d e3 bf 90 save %sp, -112, %sp
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
200b7fc: 03 00 80 a5 sethi %hi(0x2029400), %g1
200b800: c4 00 62 60 ld [ %g1 + 0x260 ], %g2 ! 2029660 <_Thread_Dispatch_disable_level>
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
va_start(arg, oflag);
200b804: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
200b808: 84 00 a0 01 inc %g2
200b80c: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
200b810: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
200b814: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
200b818: c4 20 62 60 st %g2, [ %g1 + 0x260 ]
POSIX_Message_queue_Control_fd *the_mq_fd;
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
200b81c: a6 8e 62 00 andcc %i1, 0x200, %l3
200b820: 12 80 00 34 bne 200b8f0 <mq_open+0xf8>
200b824: 23 00 80 a6 sethi %hi(0x2029800), %l1
200b828: a8 10 20 00 clr %l4
*/
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *
_POSIX_Message_queue_Allocate_fd( void )
{
return (POSIX_Message_queue_Control_fd *)
200b82c: 40 00 0c 69 call 200e9d0 <_Objects_Allocate>
200b830: 90 14 63 7c or %l1, 0x37c, %o0
attr = (struct mq_attr *) va_arg( arg, struct mq_attr * );
va_end(arg);
}
the_mq_fd = _POSIX_Message_queue_Allocate_fd();
if ( !the_mq_fd ) {
200b834: a0 92 20 00 orcc %o0, 0, %l0
200b838: 02 80 00 36 be 200b910 <mq_open+0x118> <== NEVER TAKEN
200b83c: 01 00 00 00 nop
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one( ENFILE );
}
the_mq_fd->oflag = oflag;
200b840: f2 24 20 14 st %i1, [ %l0 + 0x14 ]
status = _POSIX_Message_queue_Name_to_id( name, &the_mq_id );
200b844: 90 10 00 18 mov %i0, %o0
200b848: 40 00 22 c3 call 2014354 <_POSIX_Message_queue_Name_to_id>
200b84c: 92 07 bf f8 add %fp, -8, %o1
* If the name to id translation worked, then the message queue exists
* and we can just return a pointer to the id. Otherwise we may
* need to check to see if this is a "message queue does not exist"
* or some other miscellaneous error on the name.
*/
if ( status ) {
200b850: a4 92 20 00 orcc %o0, 0, %l2
200b854: 22 80 00 0f be,a 200b890 <mq_open+0x98>
200b858: b2 0e 6a 00 and %i1, 0xa00, %i1
/*
* Unless provided a valid name that did not already exist
* and we are willing to create then it is an error.
*/
if ( !( status == ENOENT && (oflag & O_CREAT) ) ) {
200b85c: 80 a4 a0 02 cmp %l2, 2
200b860: 02 80 00 3f be 200b95c <mq_open+0x164>
200b864: 80 a4 e0 00 cmp %l3, 0
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free_fd (
POSIX_Message_queue_Control_fd *the_mq_fd
)
{
_Objects_Free( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
200b868: 90 14 63 7c or %l1, 0x37c, %o0
200b86c: 40 00 0d 45 call 200ed80 <_Objects_Free>
200b870: 92 10 00 10 mov %l0, %o1
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
200b874: 40 00 10 3c call 200f964 <_Thread_Enable_dispatch>
200b878: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one_cast( status, mqd_t );
200b87c: 40 00 34 88 call 2018a9c <__errno>
200b880: 01 00 00 00 nop
200b884: e4 22 00 00 st %l2, [ %o0 ]
200b888: 81 c7 e0 08 ret
200b88c: 81 e8 00 00 restore
} else { /* name -> ID translation succeeded */
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
200b890: 80 a6 6a 00 cmp %i1, 0xa00
200b894: 02 80 00 27 be 200b930 <mq_open+0x138>
200b898: d2 07 bf f8 ld [ %fp + -8 ], %o1
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control *_POSIX_Message_queue_Get (
Objects_Id id,
Objects_Locations *location
)
{
return (POSIX_Message_queue_Control *)
200b89c: 94 07 bf f0 add %fp, -16, %o2
200b8a0: 11 00 80 a6 sethi %hi(0x2029800), %o0
200b8a4: 40 00 0d 9f call 200ef20 <_Objects_Get>
200b8a8: 90 12 21 f0 or %o0, 0x1f0, %o0 ! 20299f0 <_POSIX_Message_queue_Information>
/*
* In this case we need to do an ID->pointer conversion to
* check the mode.
*/
the_mq = _POSIX_Message_queue_Get( the_mq_id, &location );
the_mq->open_count += 1;
200b8ac: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
200b8b0: a2 14 63 7c or %l1, 0x37c, %l1
200b8b4: 82 00 60 01 inc %g1
200b8b8: c4 04 60 1c ld [ %l1 + 0x1c ], %g2
200b8bc: c2 22 20 18 st %g1, [ %o0 + 0x18 ]
200b8c0: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
/*
* In this case we need to do an ID->pointer conversion to
* check the mode.
*/
the_mq = _POSIX_Message_queue_Get( the_mq_id, &location );
200b8c4: d0 27 bf f4 st %o0, [ %fp + -12 ]
200b8c8: 83 28 60 02 sll %g1, 2, %g1
200b8cc: e0 20 80 01 st %l0, [ %g2 + %g1 ]
the_mq->open_count += 1;
the_mq_fd->Queue = the_mq;
200b8d0: d0 24 20 10 st %o0, [ %l0 + 0x10 ]
_Objects_Open_string(
&_POSIX_Message_queue_Information_fds,
&the_mq_fd->Object,
NULL
);
_Thread_Enable_dispatch();
200b8d4: 40 00 10 24 call 200f964 <_Thread_Enable_dispatch>
200b8d8: c0 24 20 0c clr [ %l0 + 0xc ]
_Thread_Enable_dispatch();
200b8dc: 40 00 10 22 call 200f964 <_Thread_Enable_dispatch>
200b8e0: 01 00 00 00 nop
return (mqd_t)the_mq_fd->Object.id;
200b8e4: f0 04 20 08 ld [ %l0 + 8 ], %i0
200b8e8: 81 c7 e0 08 ret
200b8ec: 81 e8 00 00 restore
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
va_start(arg, oflag);
mode = (mode_t) va_arg( arg, unsigned int );
attr = (struct mq_attr *) va_arg( arg, struct mq_attr * );
200b8f0: 82 07 a0 54 add %fp, 0x54, %g1
200b8f4: e8 07 a0 50 ld [ %fp + 0x50 ], %l4
200b8f8: c2 27 bf fc st %g1, [ %fp + -4 ]
*/
RTEMS_INLINE_ROUTINE POSIX_Message_queue_Control_fd *
_POSIX_Message_queue_Allocate_fd( void )
{
return (POSIX_Message_queue_Control_fd *)
200b8fc: 40 00 0c 35 call 200e9d0 <_Objects_Allocate>
200b900: 90 14 63 7c or %l1, 0x37c, %o0
va_end(arg);
}
the_mq_fd = _POSIX_Message_queue_Allocate_fd();
if ( !the_mq_fd ) {
200b904: a0 92 20 00 orcc %o0, 0, %l0
200b908: 32 bf ff cf bne,a 200b844 <mq_open+0x4c>
200b90c: f2 24 20 14 st %i1, [ %l0 + 0x14 ]
_Thread_Enable_dispatch();
200b910: 40 00 10 15 call 200f964 <_Thread_Enable_dispatch>
200b914: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( ENFILE );
200b918: 40 00 34 61 call 2018a9c <__errno>
200b91c: 01 00 00 00 nop
200b920: 82 10 20 17 mov 0x17, %g1 ! 17 <PROM_START+0x17>
200b924: c2 22 00 00 st %g1, [ %o0 ]
200b928: 81 c7 e0 08 ret
200b92c: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE void _POSIX_Message_queue_Free_fd (
POSIX_Message_queue_Control_fd *the_mq_fd
)
{
_Objects_Free( &_POSIX_Message_queue_Information_fds, &the_mq_fd->Object );
200b930: 90 14 63 7c or %l1, 0x37c, %o0
200b934: 40 00 0d 13 call 200ed80 <_Objects_Free>
200b938: 92 10 00 10 mov %l0, %o1
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
200b93c: 40 00 10 0a call 200f964 <_Thread_Enable_dispatch>
200b940: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one_cast( EEXIST, mqd_t );
200b944: 40 00 34 56 call 2018a9c <__errno>
200b948: 01 00 00 00 nop
200b94c: 82 10 20 11 mov 0x11, %g1 ! 11 <PROM_START+0x11>
200b950: c2 22 00 00 st %g1, [ %o0 ]
200b954: 81 c7 e0 08 ret
200b958: 81 e8 00 00 restore
if ( status ) {
/*
* Unless provided a valid name that did not already exist
* and we are willing to create then it is an error.
*/
if ( !( status == ENOENT && (oflag & O_CREAT) ) ) {
200b95c: 02 bf ff c4 be 200b86c <mq_open+0x74>
200b960: 90 14 63 7c or %l1, 0x37c, %o0
/*
* At this point, the message queue does not exist and everything has been
* checked. We should go ahead and create a message queue.
*/
status = _POSIX_Message_queue_Create_support(
200b964: 90 10 00 18 mov %i0, %o0
200b968: 94 10 00 14 mov %l4, %o2
200b96c: 92 10 20 01 mov 1, %o1
200b970: 40 00 22 16 call 20141c8 <_POSIX_Message_queue_Create_support>
200b974: 96 07 bf f4 add %fp, -12, %o3
);
/*
* errno was set by Create_support, so don't set it again.
*/
if ( status == -1 ) {
200b978: 80 a2 3f ff cmp %o0, -1
200b97c: 02 80 00 0e be 200b9b4 <mq_open+0x1bc>
200b980: 90 14 63 7c or %l1, 0x37c, %o0
200b984: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
200b988: a2 14 63 7c or %l1, 0x37c, %l1
200b98c: c4 04 60 1c ld [ %l1 + 0x1c ], %g2
200b990: 83 28 60 02 sll %g1, 2, %g1
200b994: e0 20 80 01 st %l0, [ %g2 + %g1 ]
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
return (mqd_t) -1;
}
the_mq_fd->Queue = the_mq;
200b998: c2 07 bf f4 ld [ %fp + -12 ], %g1
the_object
);
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
/* ASSERT: information->is_string */
the_object->name.name_p = name;
200b99c: c0 24 20 0c clr [ %l0 + 0xc ]
&_POSIX_Message_queue_Information_fds,
&the_mq_fd->Object,
NULL
);
_Thread_Enable_dispatch();
200b9a0: 40 00 0f f1 call 200f964 <_Thread_Enable_dispatch>
200b9a4: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
return (mqd_t) the_mq_fd->Object.id;
200b9a8: f0 04 20 08 ld [ %l0 + 8 ], %i0
}
200b9ac: 81 c7 e0 08 ret
200b9b0: 81 e8 00 00 restore
200b9b4: 92 10 00 10 mov %l0, %o1
200b9b8: 40 00 0c f2 call 200ed80 <_Objects_Free>
200b9bc: b0 10 3f ff mov -1, %i0
/*
* errno was set by Create_support, so don't set it again.
*/
if ( status == -1 ) {
_POSIX_Message_queue_Free_fd( the_mq_fd );
_Thread_Enable_dispatch();
200b9c0: 40 00 0f e9 call 200f964 <_Thread_Enable_dispatch>
200b9c4: 01 00 00 00 nop
return (mqd_t) -1;
200b9c8: 81 c7 e0 08 ret
200b9cc: 81 e8 00 00 restore
0203b878 <msdos_creat_node>:
msdos_node_type_t type,
const char *name,
int name_len,
mode_t mode,
const fat_file_fd_t *link_fd)
{
203b878: 9d e3 bf 00 save %sp, -256, %sp <== NOT EXECUTED
int rc = RC_OK;
ssize_t ret = 0;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
203b87c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
uint32_t byte = 0;
fat_dir_pos_init(&dir_pos);
memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);
203b880: a6 07 bf 68 add %fp, -152, %l3 <== NOT EXECUTED
mode_t mode,
const fat_file_fd_t *link_fd)
{
int rc = RC_OK;
ssize_t ret = 0;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
203b884: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203b888: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
uint32_t sec = 0;
uint32_t byte = 0;
fat_dir_pos_init(&dir_pos);
memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203b88c: a4 07 bf c8 add %fp, -56, %l2 <== NOT EXECUTED
203b890: c0 27 bf c8 clr [ %fp + -56 ] <== NOT EXECUTED
203b894: c0 27 bf cc clr [ %fp + -52 ] <== NOT EXECUTED
memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);
203b898: c0 27 bf 68 clr [ %fp + -152 ] <== NOT EXECUTED
203b89c: c0 27 bf 6c clr [ %fp + -148 ] <== NOT EXECUTED
203b8a0: c0 24 e0 08 clr [ %l3 + 8 ] <== NOT EXECUTED
203b8a4: c0 24 e0 0c clr [ %l3 + 0xc ] <== NOT EXECUTED
203b8a8: c0 24 e0 10 clr [ %l3 + 0x10 ] <== NOT EXECUTED
203b8ac: c0 24 e0 14 clr [ %l3 + 0x14 ] <== NOT EXECUTED
203b8b0: c0 24 e0 18 clr [ %l3 + 0x18 ] <== NOT EXECUTED
203b8b4: c0 24 e0 1c clr [ %l3 + 0x1c ] <== NOT EXECUTED
203b8b8: c0 24 e0 20 clr [ %l3 + 0x20 ] <== NOT EXECUTED
203b8bc: c0 24 e0 24 clr [ %l3 + 0x24 ] <== NOT EXECUTED
203b8c0: c0 24 e0 28 clr [ %l3 + 0x28 ] <== NOT EXECUTED
203b8c4: c0 24 e0 2c clr [ %l3 + 0x2c ] <== NOT EXECUTED
203b8c8: c0 24 e0 30 clr [ %l3 + 0x30 ] <== NOT EXECUTED
203b8cc: c0 24 e0 34 clr [ %l3 + 0x34 ] <== NOT EXECUTED
203b8d0: c0 24 e0 38 clr [ %l3 + 0x38 ] <== NOT EXECUTED
203b8d4: c0 24 e0 3c clr [ %l3 + 0x3c ] <== NOT EXECUTED
uint32_t sec = 0;
uint32_t byte = 0;
fat_dir_pos_init(&dir_pos);
memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203b8d8: c0 24 a0 08 clr [ %l2 + 8 ] <== NOT EXECUTED
203b8dc: c0 24 a0 0c clr [ %l2 + 0xc ] <== NOT EXECUTED
203b8e0: c0 24 a0 10 clr [ %l2 + 0x10 ] <== NOT EXECUTED
203b8e4: c0 24 a0 14 clr [ %l2 + 0x14 ] <== NOT EXECUTED
203b8e8: c0 24 a0 18 clr [ %l2 + 0x18 ] <== NOT EXECUTED
203b8ec: c0 24 a0 1c clr [ %l2 + 0x1c ] <== NOT EXECUTED
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203b8f0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203b8f4: c2 27 bf f0 st %g1, [ %fp + -16 ] <== NOT EXECUTED
memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);
name_type = msdos_long_to_short (name, name_len,
203b8f8: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
203b8fc: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
203b900: 96 10 20 0b mov 0xb, %o3 <== NOT EXECUTED
{
int rc = RC_OK;
ssize_t ret = 0;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
fat_file_fd_t *parent_fat_fd = parent_loc->node_access;
fat_file_fd_t *fat_fd = NULL;
203b904: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
time_t time_ret = 0;
uint16_t time_val = 0;
203b908: c0 37 bf fe clrh [ %fp + -2 ] <== NOT EXECUTED
uint16_t date = 0;
203b90c: c0 37 bf fc clrh [ %fp + -4 ] <== NOT EXECUTED
static inline void
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
203b910: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
dir_pos->sname.ofs = 0;
203b914: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
const fat_file_fd_t *link_fd)
{
int rc = RC_OK;
ssize_t ret = 0;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
fat_file_fd_t *parent_fat_fd = parent_loc->node_access;
203b918: e8 06 00 00 ld [ %i0 ], %l4 <== NOT EXECUTED
fat_dir_pos_init(&dir_pos);
memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);
name_type = msdos_long_to_short (name, name_len,
203b91c: 40 00 08 c7 call 203dc38 <msdos_long_to_short> <== NOT EXECUTED
203b920: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
msdos_node_type_t type,
const char *name,
int name_len,
mode_t mode,
const fat_file_fd_t *link_fd)
{
203b924: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
fat_dir_pos_init(&dir_pos);
memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);
name_type = msdos_long_to_short (name, name_len,
203b928: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
MSDOS_DIR_NAME(short_node),
MSDOS_NAME_MAX);
/* fill reserved field */
*MSDOS_DIR_NT_RES(short_node) = MSDOS_RES_NT_VALUE;
203b92c: c0 2c a0 0c clrb [ %l2 + 0xc ] <== NOT EXECUTED
/* set up last write date and time */
time_ret = time(NULL);
203b930: 40 00 6b 8a call 2056758 <time> <== NOT EXECUTED
203b934: 90 10 20 00 clr %o0 <== NOT EXECUTED
if ( time_ret == -1 )
203b938: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
203b93c: 02 80 00 28 be 203b9dc <msdos_creat_node+0x164> <== NOT EXECUTED
203b940: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
203b944: 40 00 33 14 call 2048594 <msdos_date_unix2dos> <== NOT EXECUTED
203b948: 94 07 bf fe add %fp, -2, %o2 <== NOT EXECUTED
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b94c: c4 17 bf fe lduh [ %fp + -2 ], %g2 <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
203b950: c2 17 bf fc lduh [ %fp + -4 ], %g1 <== NOT EXECUTED
time_ret = time(NULL);
if ( time_ret == -1 )
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b954: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
203b958: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
time_ret = time(NULL);
if ( time_ret == -1 )
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b95c: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
203b960: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
time_ret = time(NULL);
if ( time_ret == -1 )
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b964: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
203b968: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
time_ret = time(NULL);
if ( time_ret == -1 )
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b96c: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
203b970: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
/* initialize directory/file size */
*MSDOS_DIR_FILE_SIZE(short_node) = MSDOS_INIT_DIR_SIZE;
203b974: c0 27 bf e4 clr [ %fp + -28 ] <== NOT EXECUTED
time_ret = time(NULL);
if ( time_ret == -1 )
return -1;
msdos_date_unix2dos(time_ret, &date, &time_val);
*MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);
203b978: c4 34 a0 16 sth %g2, [ %l2 + 0x16 ] <== NOT EXECUTED
*MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);
/* initialize directory/file size */
*MSDOS_DIR_FILE_SIZE(short_node) = MSDOS_INIT_DIR_SIZE;
if (type == MSDOS_DIRECTORY) {
203b97c: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
203b980: 02 80 00 19 be 203b9e4 <msdos_creat_node+0x16c> <== NOT EXECUTED
203b984: c2 34 a0 18 sth %g1, [ %l2 + 0x18 ] <== NOT EXECUTED
*MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_DIRECTORY;
}
else if (type == MSDOS_HARD_LINK) {
203b988: 80 a6 60 03 cmp %i1, 3 <== NOT EXECUTED
203b98c: 02 80 00 88 be 203bbac <msdos_creat_node+0x334> <== NOT EXECUTED
203b990: c2 0f bf d3 ldub [ %fp + -45 ], %g1 <== NOT EXECUTED
* set "last access" date to today
*/
*MSDOS_DIR_LAST_ACCESS_DATE(short_node) = CT_LE_W(date);
}
else { /* regular file... */
*MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;
203b994: 82 10 60 20 or %g1, 0x20, %g1 <== NOT EXECUTED
203b998: c2 2c a0 0b stb %g1, [ %l2 + 0xb ] <== NOT EXECUTED
/*
* find free space in the parent directory and write new initialized
* FAT 32 Bytes Directory Entry Structure to the disk
*/
rc = msdos_get_name_node(parent_loc, true, name, name_len,
203b99c: 98 10 00 15 mov %l5, %o4 <== NOT EXECUTED
203b9a0: e4 23 a0 5c st %l2, [ %sp + 0x5c ] <== NOT EXECUTED
203b9a4: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
203b9a8: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
203b9ac: aa 07 bf e8 add %fp, -24, %l5 <== NOT EXECUTED
203b9b0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203b9b4: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
203b9b8: 40 00 09 df call 203e134 <msdos_get_name_node> <== NOT EXECUTED
203b9bc: 9a 10 00 15 mov %l5, %o5 <== NOT EXECUTED
name_type, &dir_pos, short_node);
if ( rc != RC_OK )
203b9c0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203b9c4: 12 80 00 04 bne 203b9d4 <msdos_creat_node+0x15c> <== NOT EXECUTED
203b9c8: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
/*
* if we create a new file we are done, if directory there are more steps
* to do
*/
if (type == MSDOS_DIRECTORY)
203b9cc: 22 80 00 0a be,a 203b9f4 <msdos_creat_node+0x17c> <== NOT EXECUTED
203b9d0: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
err:
/* mark the used 32bytes structure on the disk as free */
msdos_set_first_char4file_name(parent_loc->mt_entry, &dir_pos, 0xE5);
return rc;
}
203b9d4: 81 c7 e0 08 ret <== NOT EXECUTED
203b9d8: 81 e8 00 00 restore <== NOT EXECUTED
203b9dc: 81 c7 e0 08 ret <== NOT EXECUTED
203b9e0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
/* initialize directory/file size */
*MSDOS_DIR_FILE_SIZE(short_node) = MSDOS_INIT_DIR_SIZE;
if (type == MSDOS_DIRECTORY) {
*MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_DIRECTORY;
203b9e4: c2 0f bf d3 ldub [ %fp + -45 ], %g1 <== NOT EXECUTED
203b9e8: 82 10 60 10 or %g1, 0x10, %g1 <== NOT EXECUTED
203b9ec: 10 bf ff ec b 203b99c <msdos_creat_node+0x124> <== NOT EXECUTED
203b9f0: c2 2c a0 0b stb %g1, [ %l2 + 0xb ] <== NOT EXECUTED
* to do
*/
if (type == MSDOS_DIRECTORY)
{
/* open new directory as fat-file */
rc = fat_file_open(parent_loc->mt_entry, &dir_pos, &fat_fd);
203b9f4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
203b9f8: 7f ff b5 a9 call 202909c <fat_file_open> <== NOT EXECUTED
203b9fc: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
if (rc != RC_OK)
203ba00: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203ba04: 32 80 00 59 bne,a 203bb68 <msdos_creat_node+0x2f0> <== NOT EXECUTED
203ba08: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
/*
* we opened fat-file for node we just created, so initialize fat-file
* descritor
*/
fat_fd->fat_file_size = 0;
203ba0c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203ba10: 05 00 08 00 sethi %hi(0x200000), %g2 <== NOT EXECUTED
/*
* we opened fat-file for node we just created, so initialize fat-file
* descritor
*/
fat_fd->fat_file_size = 0;
fat_fd->fat_file_type = FAT_DIRECTORY;
203ba14: f2 20 60 10 st %i1, [ %g1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203ba18: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
/*
* we opened fat-file for node we just created, so initialize fat-file
* descritor
*/
fat_fd->fat_file_size = 0;
203ba1c: c0 20 60 18 clr [ %g1 + 0x18 ] <== NOT EXECUTED
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(MSDOS_DIR_NAME(DOT_NODE_P(dot_dotdot)), MSDOS_DOT_NAME,
203ba20: 03 00 81 c5 sethi %hi(0x2071400), %g1 <== NOT EXECUTED
/*
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
203ba24: d4 1c a0 08 ldd [ %l2 + 8 ], %o2 <== NOT EXECUTED
203ba28: c4 1c a0 18 ldd [ %l2 + 0x18 ], %g2 <== NOT EXECUTED
203ba2c: d8 1c a0 10 ldd [ %l2 + 0x10 ], %o4 <== NOT EXECUTED
203ba30: ec 1c 80 00 ldd [ %l2 ], %l6 <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(MSDOS_DIR_NAME(DOT_NODE_P(dot_dotdot)), MSDOS_DOT_NAME,
203ba34: d2 00 61 6c ld [ %g1 + 0x16c ], %o1 <== NOT EXECUTED
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
203ba38: a4 07 bf 88 add %fp, -120, %l2 <== NOT EXECUTED
/*
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
203ba3c: d4 3c e0 08 std %o2, [ %l3 + 8 ] <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
203ba40: d4 3c a0 08 std %o2, [ %l2 + 8 ] <== NOT EXECUTED
/*
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
203ba44: d8 3c e0 10 std %o4, [ %l3 + 0x10 ] <== NOT EXECUTED
203ba48: c4 3c e0 18 std %g2, [ %l3 + 0x18 ] <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
203ba4c: d8 3c a0 10 std %o4, [ %l2 + 0x10 ] <== NOT EXECUTED
203ba50: c4 3c a0 18 std %g2, [ %l2 + 0x18 ] <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(MSDOS_DIR_NAME(DOT_NODE_P(dot_dotdot)), MSDOS_DOT_NAME,
203ba54: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
203ba58: ec 3f bf 88 std %l6, [ %fp + -120 ] <== NOT EXECUTED
/*
* dot and dotdot entries are identical to new node except the
* names
*/
memcpy(DOT_NODE_P(dot_dotdot), short_node,
203ba5c: ec 3f bf 68 std %l6, [ %fp + -152 ] <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
memcpy(MSDOS_DIR_NAME(DOT_NODE_P(dot_dotdot)), MSDOS_DOT_NAME,
203ba60: 40 00 47 d4 call 204d9b0 <memcpy> <== NOT EXECUTED
203ba64: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
MSDOS_NAME_MAX);
memcpy(MSDOS_DIR_NAME(DOTDOT_NODE_P(dot_dotdot)), MSDOS_DOTDOT_NAME,
203ba68: 03 00 81 c5 sethi %hi(0x2071400), %g1 <== NOT EXECUTED
203ba6c: d2 00 61 70 ld [ %g1 + 0x170 ], %o1 ! 2071570 <MSDOS_DOTDOT_NAME><== NOT EXECUTED
203ba70: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
203ba74: 40 00 47 cf call 204d9b0 <memcpy> <== NOT EXECUTED
203ba78: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
/*
* here we can ommit FAT32 condition because for all FAT types dirs
* right under root dir should contain 0 in dotdot entry but for
* FAT12/16 parent_fat_fd->cluster_num always contains such value
*/
if ((FAT_FD_OF_ROOT_DIR(parent_fat_fd)) &&
203ba7c: c2 05 20 20 ld [ %l4 + 0x20 ], %g1 <== NOT EXECUTED
203ba80: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203ba84: 22 80 00 40 be,a 203bb84 <msdos_creat_node+0x30c> <== NOT EXECUTED
203ba88: c2 05 20 24 ld [ %l4 + 0x24 ], %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
203ba8c: c4 05 20 1c ld [ %l4 + 0x1c ], %g2 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )(((parent_fat_fd->cln) & 0xFFFF0000)>>16));
203ba90: 83 30 a0 10 srl %g2, 0x10, %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
203ba94: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
203ba98: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
203ba9c: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
203baa0: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
203baa4: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
203baa8: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
203baac: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
203bab0: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
}
else
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) =
203bab4: c4 34 e0 3a sth %g2, [ %l3 + 0x3a ] <== NOT EXECUTED
CT_LE_W((uint16_t )((parent_fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =
203bab8: c2 34 e0 34 sth %g1, [ %l3 + 0x34 ] <== NOT EXECUTED
/*
* write dot and dotdot entries to new fat-file: currently fat-file
* correspondes to a new node is zero length, so it will be extended
* by one cluster and entries will be written
*/
ret = fat_file_write(parent_loc->mt_entry, fat_fd, 0,
203babc: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203bac0: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
203bac4: 94 10 20 00 clr %o2 <== NOT EXECUTED
203bac8: 96 10 20 40 mov 0x40, %o3 <== NOT EXECUTED
203bacc: 7f ff b4 1b call 2028b38 <fat_file_write> <== NOT EXECUTED
203bad0: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2,
(uint8_t *)dot_dotdot);
if (ret < 0)
203bad4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bad8: 06 80 00 29 bl 203bb7c <msdos_creat_node+0x304> <== NOT EXECUTED
203badc: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
rc = -1;
goto error;
}
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
203bae0: c2 14 60 06 lduh [ %l1 + 6 ], %g1 <== NOT EXECUTED
203bae4: c6 02 60 18 ld [ %o1 + 0x18 ], %g3 <== NOT EXECUTED
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
203bae8: c4 02 60 1c ld [ %o1 + 0x1c ], %g2 <== NOT EXECUTED
rc = -1;
goto error;
}
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
203baec: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )(((fat_fd->cln) & 0xFFFF0000) >> 16));
/* rewrite dot entry */
ret = fat_file_write(parent_loc->mt_entry, fat_fd, 0,
203baf0: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
rc = -1;
goto error;
}
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
203baf4: c2 22 60 18 st %g1, [ %o1 + 0x18 ] <== NOT EXECUTED
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
CT_LE_W((uint16_t )(((fat_fd->cln) & 0xFFFF0000) >> 16));
203baf8: 83 30 a0 10 srl %g2, 0x10, %g1 <== NOT EXECUTED
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
203bafc: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
203bb00: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
203bb04: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
203bb08: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
203bb0c: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
203bb10: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
203bb14: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
203bb18: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
CT_LE_W((uint16_t )(((fat_fd->cln) & 0xFFFF0000) >> 16));
/* rewrite dot entry */
ret = fat_file_write(parent_loc->mt_entry, fat_fd, 0,
203bb1c: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
/* increment fat-file size by cluster size */
fat_fd->fat_file_size += fs_info->fat.vol.bpc;
/* set up cluster num for dot entry */
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =
203bb20: c4 34 e0 1a sth %g2, [ %l3 + 0x1a ] <== NOT EXECUTED
CT_LE_W((uint16_t )((fat_fd->cln) & 0x0000FFFF));
*MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =
203bb24: c2 34 e0 14 sth %g1, [ %l3 + 0x14 ] <== NOT EXECUTED
CT_LE_W((uint16_t )(((fat_fd->cln) & 0xFFFF0000) >> 16));
/* rewrite dot entry */
ret = fat_file_write(parent_loc->mt_entry, fat_fd, 0,
203bb28: 94 10 20 00 clr %o2 <== NOT EXECUTED
203bb2c: 7f ff b4 03 call 2028b38 <fat_file_write> <== NOT EXECUTED
203bb30: 96 10 20 20 mov 0x20, %o3 <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE,
(uint8_t *)DOT_NODE_P(dot_dotdot));
if (ret < 0)
203bb34: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bb38: 06 80 00 08 bl 203bb58 <msdos_creat_node+0x2e0> <== NOT EXECUTED
203bb3c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rc = -1;
goto error;
}
/* write first cluster num of a new directory to disk */
rc = msdos_set_first_cluster_num(parent_loc->mt_entry, fat_fd);
203bb40: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203bb44: 40 00 06 fd call 203d738 <msdos_set_first_cluster_num> <== NOT EXECUTED
203bb48: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
if (rc != RC_OK)
203bb4c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203bb50: 22 80 00 4b be,a 203bc7c <msdos_creat_node+0x404> <== NOT EXECUTED
203bb54: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
fat_file_close(parent_loc->mt_entry, fat_fd);
}
return RC_OK;
error:
fat_file_close(parent_loc->mt_entry, fat_fd);
203bb58: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203bb5c: 7f ff b5 1e call 2028fd4 <fat_file_close> <== NOT EXECUTED
203bb60: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
err:
/* mark the used 32bytes structure on the disk as free */
msdos_set_first_char4file_name(parent_loc->mt_entry, &dir_pos, 0xE5);
203bb64: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203bb68: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
203bb6c: 40 00 07 2b call 203d818 <msdos_set_first_char4file_name> <== NOT EXECUTED
203bb70: 94 10 20 e5 mov 0xe5, %o2 <== NOT EXECUTED
return rc;
203bb74: 81 c7 e0 08 ret <== NOT EXECUTED
203bb78: 81 e8 00 00 restore <== NOT EXECUTED
/* write first cluster num of a new directory to disk */
rc = msdos_set_first_cluster_num(parent_loc->mt_entry, fat_fd);
if (rc != RC_OK)
goto error;
fat_file_close(parent_loc->mt_entry, fat_fd);
203bb7c: 10 bf ff f7 b 203bb58 <msdos_creat_node+0x2e0> <== NOT EXECUTED
203bb80: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
/*
* here we can ommit FAT32 condition because for all FAT types dirs
* right under root dir should contain 0 in dotdot entry but for
* FAT12/16 parent_fat_fd->cluster_num always contains such value
*/
if ((FAT_FD_OF_ROOT_DIR(parent_fat_fd)) &&
203bb84: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203bb88: 32 bf ff c2 bne,a 203ba90 <msdos_creat_node+0x218> <== NOT EXECUTED
203bb8c: c4 05 20 1c ld [ %l4 + 0x1c ], %g2 <== NOT EXECUTED
(fs_info->fat.vol.type & FAT_FAT32))
203bb90: c2 0c 60 0a ldub [ %l1 + 0xa ], %g1 <== NOT EXECUTED
203bb94: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
203bb98: 22 bf ff be be,a 203ba90 <msdos_creat_node+0x218> <== NOT EXECUTED
203bb9c: c4 05 20 1c ld [ %l4 + 0x1c ], %g2 <== NOT EXECUTED
{
*MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
203bba0: c0 34 e0 3a clrh [ %l3 + 0x3a ] <== NOT EXECUTED
/*
* here we can ommit FAT32 condition because for all FAT types dirs
* right under root dir should contain 0 in dotdot entry but for
* FAT12/16 parent_fat_fd->cluster_num always contains such value
*/
if ((FAT_FD_OF_ROOT_DIR(parent_fat_fd)) &&
203bba4: 10 bf ff c6 b 203babc <msdos_creat_node+0x244> <== NOT EXECUTED
203bba8: c0 34 e0 34 clrh [ %l3 + 0x34 ] <== NOT EXECUTED
* node to the newly created
*/
/*
* read the original directory entry
*/
sec = fat_cluster_num_to_sector_num(parent_loc->mt_entry,
203bbac: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
203bbb0: c4 07 60 20 ld [ %i5 + 0x20 ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203bbb4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203bbb8: 12 80 00 2b bne 203bc64 <msdos_creat_node+0x3ec> <== NOT EXECUTED
203bbbc: c2 02 20 34 ld [ %o0 + 0x34 ], %g1 <== NOT EXECUTED
203bbc0: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
203bbc4: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
203bbc8: 22 80 00 28 be,a 203bc68 <msdos_creat_node+0x3f0> <== NOT EXECUTED
203bbcc: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
203bbd0: d2 00 60 1c ld [ %g1 + 0x1c ], %o1 <== NOT EXECUTED
link_fd->dir_pos.sname.cln);
sec += (link_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203bbd4: c2 07 60 24 ld [ %i5 + 0x24 ], %g1 <== NOT EXECUTED
byte = (link_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
ret = _fat_block_read(parent_loc->mt_entry,
203bbd8: c4 0c 60 02 ldub [ %l1 + 2 ], %g2 <== NOT EXECUTED
203bbdc: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
203bbe0: 85 30 40 02 srl %g1, %g2, %g2 <== NOT EXECUTED
203bbe4: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
203bbe8: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
203bbec: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
203bbf0: ac 07 bf a8 add %fp, -88, %l6 <== NOT EXECUTED
203bbf4: 96 10 20 20 mov 0x20, %o3 <== NOT EXECUTED
203bbf8: 7f ff b8 08 call 2029c18 <_fat_block_read> <== NOT EXECUTED
203bbfc: 98 10 00 16 mov %l6, %o4 <== NOT EXECUTED
sec, byte, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE,
link_node);
if (ret < 0) {
203bc00: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bc04: 06 bf ff 76 bl 203b9dc <msdos_creat_node+0x164> <== NOT EXECUTED
203bc08: 01 00 00 00 nop <== NOT EXECUTED
*MSDOS_DIR_CRT_DATE(short_node) =*MSDOS_DIR_CRT_DATE(link_node);
/*
* copy/set "file size", "first cluster"
*/
*MSDOS_DIR_FILE_SIZE(short_node) =*MSDOS_DIR_FILE_SIZE(link_node);
203bc0c: da 05 a0 1c ld [ %l6 + 0x1c ], %o5 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(short_node) =
*MSDOS_DIR_FIRST_CLUSTER_LOW(link_node);
*MSDOS_DIR_FIRST_CLUSTER_HI(short_node) =
203bc10: c2 15 a0 14 lduh [ %l6 + 0x14 ], %g1 <== NOT EXECUTED
/*
* copy/set "file size", "first cluster"
*/
*MSDOS_DIR_FILE_SIZE(short_node) =*MSDOS_DIR_FILE_SIZE(link_node);
*MSDOS_DIR_FIRST_CLUSTER_LOW(short_node) =
203bc14: c4 15 a0 1a lduh [ %l6 + 0x1a ], %g2 <== NOT EXECUTED
/*
* copy various attributes
*/
*MSDOS_DIR_ATTR(short_node) =*MSDOS_DIR_ATTR(link_node);
*MSDOS_DIR_CRT_TIME_TENTH(short_node)=*MSDOS_DIR_CRT_TIME_TENTH(link_node);
*MSDOS_DIR_CRT_TIME(short_node) =*MSDOS_DIR_CRT_TIME(link_node);
203bc18: c8 15 a0 0e lduh [ %l6 + 0xe ], %g4 <== NOT EXECUTED
*MSDOS_DIR_CRT_DATE(short_node) =*MSDOS_DIR_CRT_DATE(link_node);
203bc1c: c6 15 a0 10 lduh [ %l6 + 0x10 ], %g3 <== NOT EXECUTED
/*
* copy/set "file size", "first cluster"
*/
*MSDOS_DIR_FILE_SIZE(short_node) =*MSDOS_DIR_FILE_SIZE(link_node);
203bc20: da 27 bf e4 st %o5, [ %fp + -28 ] <== NOT EXECUTED
}
/*
* copy various attributes
*/
*MSDOS_DIR_ATTR(short_node) =*MSDOS_DIR_ATTR(link_node);
*MSDOS_DIR_CRT_TIME_TENTH(short_node)=*MSDOS_DIR_CRT_TIME_TENTH(link_node);
203bc24: da 0f bf b5 ldub [ %fp + -75 ], %o5 <== NOT EXECUTED
*MSDOS_DIR_CRT_TIME(short_node) =*MSDOS_DIR_CRT_TIME(link_node);
203bc28: c8 34 a0 0e sth %g4, [ %l2 + 0xe ] <== NOT EXECUTED
}
/*
* copy various attributes
*/
*MSDOS_DIR_ATTR(short_node) =*MSDOS_DIR_ATTR(link_node);
*MSDOS_DIR_CRT_TIME_TENTH(short_node)=*MSDOS_DIR_CRT_TIME_TENTH(link_node);
203bc2c: da 2c a0 0d stb %o5, [ %l2 + 0xd ] <== NOT EXECUTED
*MSDOS_DIR_CRT_TIME(short_node) =*MSDOS_DIR_CRT_TIME(link_node);
*MSDOS_DIR_CRT_DATE(short_node) =*MSDOS_DIR_CRT_DATE(link_node);
203bc30: c6 34 a0 10 sth %g3, [ %l2 + 0x10 ] <== NOT EXECUTED
/*
* copy/set "file size", "first cluster"
*/
*MSDOS_DIR_FILE_SIZE(short_node) =*MSDOS_DIR_FILE_SIZE(link_node);
*MSDOS_DIR_FIRST_CLUSTER_LOW(short_node) =
203bc34: c4 34 a0 1a sth %g2, [ %l2 + 0x1a ] <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_LOW(link_node);
*MSDOS_DIR_FIRST_CLUSTER_HI(short_node) =
203bc38: c2 34 a0 14 sth %g1, [ %l2 + 0x14 ] <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_HI(link_node);
/*
* set "archive bit" due to changes
*/
*MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;
203bc3c: c4 0f bf b3 ldub [ %fp + -77 ], %g2 <== NOT EXECUTED
/*
* set "last access" date to today
*/
*MSDOS_DIR_LAST_ACCESS_DATE(short_node) = CT_LE_W(date);
203bc40: c2 17 bf fc lduh [ %fp + -4 ], %g1 <== NOT EXECUTED
*MSDOS_DIR_FIRST_CLUSTER_HI(short_node) =
*MSDOS_DIR_FIRST_CLUSTER_HI(link_node);
/*
* set "archive bit" due to changes
*/
*MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;
203bc44: 84 10 a0 20 or %g2, 0x20, %g2 <== NOT EXECUTED
203bc48: c4 2f bf d3 stb %g2, [ %fp + -45 ] <== NOT EXECUTED
/*
* set "last access" date to today
*/
*MSDOS_DIR_LAST_ACCESS_DATE(short_node) = CT_LE_W(date);
203bc4c: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
203bc50: 85 30 60 18 srl %g1, 0x18, %g2 <== NOT EXECUTED
203bc54: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203bc58: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
203bc5c: 10 bf ff 50 b 203b99c <msdos_creat_node+0x124> <== NOT EXECUTED
203bc60: c2 34 a0 12 sth %g1, [ %l2 + 0x12 ] <== NOT EXECUTED
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
203bc64: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 <== NOT EXECUTED
203bc68: c2 08 60 05 ldub [ %g1 + 5 ], %g1 <== NOT EXECUTED
203bc6c: 84 00 bf fe add %g2, -2, %g2 <== NOT EXECUTED
203bc70: 93 28 80 01 sll %g2, %g1, %o1 <== NOT EXECUTED
203bc74: 10 bf ff d8 b 203bbd4 <msdos_creat_node+0x35c> <== NOT EXECUTED
203bc78: 92 02 40 03 add %o1, %g3, %o1 <== NOT EXECUTED
/* write first cluster num of a new directory to disk */
rc = msdos_set_first_cluster_num(parent_loc->mt_entry, fat_fd);
if (rc != RC_OK)
goto error;
fat_file_close(parent_loc->mt_entry, fat_fd);
203bc7c: 7f ff b4 d6 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203bc80: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
203bc84: 81 c7 e0 08 ret <== NOT EXECUTED
203bc88: 81 e8 00 00 restore <== NOT EXECUTED
02048708 <msdos_date_dos2unix>:
* called from the stat(), and fstat() system calls and so probably need
* not be too efficient.
*/
unsigned int
msdos_date_dos2unix(unsigned int dd, unsigned int dt)
{
2048708: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
+ ((dt & MSDOS_DT_HOURS_MASK) >> MSDOS_DT_HOURS_SHIFT) * 3600;
/*
* If the year, month, and day from the last conversion are the
* same then use the saved value.
*/
if (lastdosdate != dd) {
204870c: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
2048710: c4 10 62 60 lduh [ %g1 + 0x260 ], %g2 ! 2074a60 <lastdosdate><== NOT EXECUTED
2048714: 80 a0 80 18 cmp %g2, %i0 <== NOT EXECUTED
2048718: 02 80 00 4e be 2048850 <msdos_date_dos2unix+0x148> <== NOT EXECUTED
204871c: 09 00 00 3f sethi %hi(0xfc00), %g4 <== NOT EXECUTED
lastdosdate = dd;
days = 0;
year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;
2048720: 88 11 22 00 or %g4, 0x200, %g4 ! fe00 <PROM_START+0xfe00> <== NOT EXECUTED
2048724: 88 0e 00 04 and %i0, %g4, %g4 <== NOT EXECUTED
2048728: 89 31 20 09 srl %g4, 9, %g4 <== NOT EXECUTED
for (y = 0; y < year; y++)
204872c: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
2048730: 02 80 00 4b be 204885c <msdos_date_dos2unix+0x154> <== NOT EXECUTED
2048734: f0 30 62 60 sth %i0, [ %g1 + 0x260 ] <== NOT EXECUTED
2048738: 84 10 20 00 clr %g2 <== NOT EXECUTED
204873c: 82 10 20 00 clr %g1 <== NOT EXECUTED
2048740: 86 10 21 6e mov 0x16e, %g3 <== NOT EXECUTED
days += y & 0x03 ? 365 : 366;
2048744: 10 80 00 05 b 2048758 <msdos_date_dos2unix+0x50> <== NOT EXECUTED
2048748: 9a 10 21 6e mov 0x16e, %o5 <== NOT EXECUTED
204874c: 86 08 a0 03 and %g2, 3, %g3 <== NOT EXECUTED
2048750: 80 a0 00 03 cmp %g0, %g3 <== NOT EXECUTED
2048754: 86 63 60 00 subx %o5, 0, %g3 <== NOT EXECUTED
*/
if (lastdosdate != dd) {
lastdosdate = dd;
days = 0;
year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;
for (y = 0; y < year; y++)
2048758: 84 00 a0 01 inc %g2 <== NOT EXECUTED
204875c: 80 a1 00 02 cmp %g4, %g2 <== NOT EXECUTED
2048760: 18 bf ff fb bgu 204874c <msdos_date_dos2unix+0x44> <== NOT EXECUTED
2048764: 82 00 40 03 add %g1, %g3, %g1 <== NOT EXECUTED
days += y & 0x03 ? 365 : 366;
months = year & 0x03 ? regyear : leapyear;
2048768: 07 00 81 c5 sethi %hi(0x2071400), %g3 <== NOT EXECUTED
204876c: 80 89 20 03 btst 3, %g4 <== NOT EXECUTED
2048770: 02 80 00 30 be 2048830 <msdos_date_dos2unix+0x128> <== NOT EXECUTED
2048774: 86 10 e1 cc or %g3, 0x1cc, %g3 <== NOT EXECUTED
/*
* Prevent going from 0 to 0xffffffff in the following
* loop.
*/
month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;
2048778: 9a 0e 21 e0 and %i0, 0x1e0, %o5 <== NOT EXECUTED
204877c: 9b 33 60 05 srl %o5, 5, %o5 <== NOT EXECUTED
if (month == 0) {
2048780: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
2048784: 22 80 00 0c be,a 20487b4 <msdos_date_dos2unix+0xac> <== NOT EXECUTED
2048788: b0 0e 20 1f and %i0, 0x1f, %i0 <== NOT EXECUTED
month = 1;
}
for (m = 0; m < month - 1; m++)
204878c: 9a 83 7f ff addcc %o5, -1, %o5 <== NOT EXECUTED
2048790: 02 80 00 08 be 20487b0 <msdos_date_dos2unix+0xa8> <== NOT EXECUTED
2048794: 84 10 20 00 clr %g2 <== NOT EXECUTED
days += months[m];
2048798: c8 10 c0 00 lduh [ %g3 ], %g4 <== NOT EXECUTED
*/
month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;
if (month == 0) {
month = 1;
}
for (m = 0; m < month - 1; m++)
204879c: 84 00 a0 01 inc %g2 <== NOT EXECUTED
days += months[m];
20487a0: 82 00 40 04 add %g1, %g4, %g1 <== NOT EXECUTED
*/
month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;
if (month == 0) {
month = 1;
}
for (m = 0; m < month - 1; m++)
20487a4: 80 a0 80 0d cmp %g2, %o5 <== NOT EXECUTED
20487a8: 0a bf ff fc bcs 2048798 <msdos_date_dos2unix+0x90> <== NOT EXECUTED
20487ac: 86 00 e0 02 add %g3, 2, %g3 <== NOT EXECUTED
days += months[m];
days += ((dd & MSDOS_DD_DAY_MASK) >> MSDOS_DD_DAY_SHIFT) - 1;
lastseconds = (days + DAYSTO1980) * SECONDSPERDAY;
20487b0: b0 0e 20 1f and %i0, 0x1f, %i0 <== NOT EXECUTED
20487b4: b0 06 3f ff add %i0, -1, %i0 <== NOT EXECUTED
20487b8: 82 06 00 01 add %i0, %g1, %g1 <== NOT EXECUTED
20487bc: 85 28 60 09 sll %g1, 9, %g2 <== NOT EXECUTED
20487c0: 83 28 60 07 sll %g1, 7, %g1 <== NOT EXECUTED
20487c4: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
20487c8: 87 28 60 04 sll %g1, 4, %g3 <== NOT EXECUTED
20487cc: 82 20 c0 01 sub %g3, %g1, %g1 <== NOT EXECUTED
20487d0: 87 28 60 04 sll %g1, 4, %g3 <== NOT EXECUTED
20487d4: 82 20 c0 01 sub %g3, %g1, %g1 <== NOT EXECUTED
20487d8: 05 04 b3 a9 sethi %hi(0x12cea400), %g2 <== NOT EXECUTED
20487dc: 84 10 a2 00 or %g2, 0x200, %g2 ! 12cea600 <RAM_END+0x108ea600><== NOT EXECUTED
20487e0: 86 00 40 02 add %g1, %g2, %g3 <== NOT EXECUTED
20487e4: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20487e8: c6 20 62 64 st %g3, [ %g1 + 0x264 ] ! 2074a64 <lastseconds><== NOT EXECUTED
20487ec: 85 36 60 0b srl %i1, 0xb, %g2 <== NOT EXECUTED
20487f0: 84 08 a0 1f and %g2, 0x1f, %g2 <== NOT EXECUTED
20487f4: 83 28 a0 08 sll %g2, 8, %g1 <== NOT EXECUTED
20487f8: 85 28 a0 04 sll %g2, 4, %g2 <== NOT EXECUTED
20487fc: 82 20 40 02 sub %g1, %g2, %g1 <== NOT EXECUTED
2048800: b1 28 60 04 sll %g1, 4, %i0 <== NOT EXECUTED
2048804: 88 0e 60 1f and %i1, 0x1f, %g4 <== NOT EXECUTED
2048808: 82 26 00 01 sub %i0, %g1, %g1 <== NOT EXECUTED
204880c: b2 0e 67 e0 and %i1, 0x7e0, %i1 <== NOT EXECUTED
2048810: b3 36 60 05 srl %i1, 5, %i1 <== NOT EXECUTED
2048814: 85 2e 60 06 sll %i1, 6, %g2 <== NOT EXECUTED
2048818: b3 2e 60 02 sll %i1, 2, %i1 <== NOT EXECUTED
204881c: b2 20 80 19 sub %g2, %i1, %i1 <== NOT EXECUTED
2048820: b0 00 40 19 add %g1, %i1, %i0 <== NOT EXECUTED
2048824: b0 06 00 04 add %i0, %g4, %i0 <== NOT EXECUTED
}
return seconds + lastseconds;
}
2048828: 81 c7 e0 08 ret <== NOT EXECUTED
204882c: 91 ee 00 03 restore %i0, %g3, %o0 <== NOT EXECUTED
lastdosdate = dd;
days = 0;
year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;
for (y = 0; y < year; y++)
days += y & 0x03 ? 365 : 366;
months = year & 0x03 ? regyear : leapyear;
2048830: 07 00 81 c5 sethi %hi(0x2071400), %g3 <== NOT EXECUTED
/*
* Prevent going from 0 to 0xffffffff in the following
* loop.
*/
month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;
2048834: 9a 0e 21 e0 and %i0, 0x1e0, %o5 <== NOT EXECUTED
2048838: 9b 33 60 05 srl %o5, 5, %o5 <== NOT EXECUTED
if (month == 0) {
204883c: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
2048840: 02 bf ff dc be 20487b0 <msdos_date_dos2unix+0xa8> <== NOT EXECUTED
2048844: 86 10 e1 e4 or %g3, 0x1e4, %g3 <== NOT EXECUTED
month = 1;
}
for (m = 0; m < month - 1; m++)
2048848: 10 bf ff d2 b 2048790 <msdos_date_dos2unix+0x88> <== NOT EXECUTED
204884c: 9a 83 7f ff addcc %o5, -1, %o5 <== NOT EXECUTED
+ ((dt & MSDOS_DT_HOURS_MASK) >> MSDOS_DT_HOURS_SHIFT) * 3600;
/*
* If the year, month, and day from the last conversion are the
* same then use the saved value.
*/
if (lastdosdate != dd) {
2048850: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
2048854: 10 bf ff e6 b 20487ec <msdos_date_dos2unix+0xe4> <== NOT EXECUTED
2048858: c6 00 62 64 ld [ %g1 + 0x264 ], %g3 ! 2074a64 <lastseconds><== NOT EXECUTED
lastdosdate = dd;
days = 0;
year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;
for (y = 0; y < year; y++)
204885c: 07 00 81 c5 sethi %hi(0x2071400), %g3 <== NOT EXECUTED
2048860: 82 10 20 00 clr %g1 <== NOT EXECUTED
2048864: 10 bf ff c5 b 2048778 <msdos_date_dos2unix+0x70> <== NOT EXECUTED
2048868: 86 10 e1 e4 or %g3, 0x1e4, %g3 <== NOT EXECUTED
02048594 <msdos_date_unix2dos>:
* file timestamps. The passed in unix time is assumed to be in GMT.
*/
void
msdos_date_unix2dos(unsigned int t, uint16_t *ddp,
uint16_t *dtp)
{
2048594: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* If the time from the last conversion is the same as now, then
* skip the computations and use the saved result.
*/
if (lasttime != t) {
2048598: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
204859c: c4 00 62 54 ld [ %g1 + 0x254 ], %g2 ! 2074a54 <lasttime> <== NOT EXECUTED
20485a0: 80 a0 80 18 cmp %g2, %i0 <== NOT EXECUTED
20485a4: 02 80 00 4b be 20486d0 <msdos_date_unix2dos+0x13c> <== NOT EXECUTED
20485a8: 92 10 20 3c mov 0x3c, %o1 <== NOT EXECUTED
lasttime = t;
20485ac: f0 20 62 54 st %i0, [ %g1 + 0x254 ] <== NOT EXECUTED
lastdtime = (((t % 60) >> 1) << MSDOS_DT_2SECONDS_SHIFT)
20485b0: 40 00 68 f5 call 2062984 <.udiv> <== NOT EXECUTED
20485b4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20485b8: 40 00 69 9f call 2062c34 <.urem> <== NOT EXECUTED
20485bc: 92 10 20 3c mov 0x3c, %o1 <== NOT EXECUTED
20485c0: 92 10 2e 10 mov 0xe10, %o1 <== NOT EXECUTED
20485c4: a1 2a 20 05 sll %o0, 5, %l0 <== NOT EXECUTED
20485c8: 40 00 68 ef call 2062984 <.udiv> <== NOT EXECUTED
20485cc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20485d0: 40 00 69 99 call 2062c34 <.urem> <== NOT EXECUTED
20485d4: 92 10 20 18 mov 0x18, %o1 <== NOT EXECUTED
20485d8: 91 2a 20 0b sll %o0, 0xb, %o0 <== NOT EXECUTED
20485dc: 92 10 20 3c mov 0x3c, %o1 <== NOT EXECUTED
20485e0: a0 04 00 08 add %l0, %o0, %l0 <== NOT EXECUTED
20485e4: 40 00 69 94 call 2062c34 <.urem> <== NOT EXECUTED
20485e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20485ec: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20485f0: 91 32 20 01 srl %o0, 1, %o0 <== NOT EXECUTED
/*
* If the number of days since 1970 is the same as the last
* time we did the computation then skip all this leap year
* and month stuff.
*/
days = t / (SECONDSPERDAY);
20485f4: 13 00 00 54 sethi %hi(0x15000), %o1 <== NOT EXECUTED
* If the time from the last conversion is the same as now, then
* skip the computations and use the saved result.
*/
if (lasttime != t) {
lasttime = t;
lastdtime = (((t % 60) >> 1) << MSDOS_DT_2SECONDS_SHIFT)
20485f8: a0 04 00 08 add %l0, %o0, %l0 <== NOT EXECUTED
/*
* If the number of days since 1970 is the same as the last
* time we did the computation then skip all this leap year
* and month stuff.
*/
days = t / (SECONDSPERDAY);
20485fc: 92 12 61 80 or %o1, 0x180, %o1 <== NOT EXECUTED
2048600: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2048604: 40 00 68 e0 call 2062984 <.udiv> <== NOT EXECUTED
2048608: e0 30 62 5e sth %l0, [ %g1 + 0x25e ] <== NOT EXECUTED
if (days != lastday) {
204860c: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
2048610: c4 00 62 58 ld [ %g1 + 0x258 ], %g2 ! 2074a58 <lastday> <== NOT EXECUTED
2048614: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED
2048618: 02 80 00 36 be 20486f0 <msdos_date_unix2dos+0x15c> <== NOT EXECUTED
204861c: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
lastday = days;
2048620: d0 20 62 58 st %o0, [ %g1 + 0x258 ] <== NOT EXECUTED
for (year = 1970;; year++) {
inc = year & 0x03 ? 365 : 366;
2048624: 88 10 21 6e mov 0x16e, %g4 <== NOT EXECUTED
* time we did the computation then skip all this leap year
* and month stuff.
*/
days = t / (SECONDSPERDAY);
if (days != lastday) {
lastday = days;
2048628: 10 80 00 03 b 2048634 <msdos_date_unix2dos+0xa0> <== NOT EXECUTED
204862c: 82 10 27 b2 mov 0x7b2, %g1 <== NOT EXECUTED
for (year = 1970;; year++) {
2048630: 82 00 60 01 inc %g1 <== NOT EXECUTED
inc = year & 0x03 ? 365 : 366;
2048634: 86 08 60 03 and %g1, 3, %g3 <== NOT EXECUTED
2048638: 80 a0 00 03 cmp %g0, %g3 <== NOT EXECUTED
204863c: 84 61 20 00 subx %g4, 0, %g2 <== NOT EXECUTED
if (days < inc)
2048640: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED
2048644: 3a bf ff fb bcc,a 2048630 <msdos_date_unix2dos+0x9c> <== NOT EXECUTED
2048648: 90 22 00 02 sub %o0, %g2, %o0 <== NOT EXECUTED
break;
days -= inc;
}
months = year & 0x03 ? regyear : leapyear;
204864c: 09 00 81 c5 sethi %hi(0x2071400), %g4 <== NOT EXECUTED
2048650: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2048654: 02 80 00 1c be 20486c4 <msdos_date_unix2dos+0x130> <== NOT EXECUTED
2048658: 88 11 21 cc or %g4, 0x1cc, %g4 <== NOT EXECUTED
204865c: 84 10 20 00 clr %g2 <== NOT EXECUTED
for (month = 0; month < 12; month++) {
if (days < months[month])
2048660: 87 28 a0 01 sll %g2, 1, %g3 <== NOT EXECUTED
2048664: c6 11 00 03 lduh [ %g4 + %g3 ], %g3 <== NOT EXECUTED
2048668: 80 a0 c0 08 cmp %g3, %o0 <== NOT EXECUTED
204866c: 18 80 00 06 bgu 2048684 <msdos_date_unix2dos+0xf0> <== NOT EXECUTED
2048670: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (days < inc)
break;
days -= inc;
}
months = year & 0x03 ? regyear : leapyear;
for (month = 0; month < 12; month++) {
2048674: 80 a0 a0 0c cmp %g2, 0xc <== NOT EXECUTED
2048678: 12 bf ff fa bne 2048660 <msdos_date_unix2dos+0xcc> <== NOT EXECUTED
204867c: 90 22 00 03 sub %o0, %g3, %o0 <== NOT EXECUTED
if (days < months[month])
break;
days -= months[month];
}
lastddate = ((days + 1) << MSDOS_DD_DAY_SHIFT)
2048680: 84 00 a0 01 inc %g2 <== NOT EXECUTED
2048684: 85 28 a0 05 sll %g2, 5, %g2 <== NOT EXECUTED
2048688: 90 02 20 01 inc %o0 <== NOT EXECUTED
204868c: 90 02 00 02 add %o0, %g2, %o0 <== NOT EXECUTED
2048690: 05 00 81 d2 sethi %hi(0x2074800), %g2 <== NOT EXECUTED
2048694: d0 30 a2 5c sth %o0, [ %g2 + 0x25c ] ! 2074a5c <lastddate><== NOT EXECUTED
* Remember dos's idea of time is relative to 1980.
* unix's is relative to 1970. If somehow we get a
* time before 1980 then don't give totally crazy
* results.
*/
if (year > 1980)
2048698: 80 a0 67 bc cmp %g1, 0x7bc <== NOT EXECUTED
204869c: 08 80 00 06 bleu 20486b4 <msdos_date_unix2dos+0x120> <== NOT EXECUTED
20486a0: 86 10 00 08 mov %o0, %g3 <== NOT EXECUTED
lastddate += (year - 1980) <<
20486a4: 86 00 78 44 add %g1, -1980, %g3 <== NOT EXECUTED
20486a8: 87 28 e0 09 sll %g3, 9, %g3 <== NOT EXECUTED
20486ac: 86 02 00 03 add %o0, %g3, %g3 <== NOT EXECUTED
20486b0: c6 30 a2 5c sth %g3, [ %g2 + 0x25c ] <== NOT EXECUTED
MSDOS_DD_YEAR_SHIFT;
}
}
*dtp = lastdtime;
20486b4: f0 36 80 00 sth %i0, [ %i2 ] <== NOT EXECUTED
*ddp = lastddate;
20486b8: c6 36 40 00 sth %g3, [ %i1 ] <== NOT EXECUTED
}
20486bc: 81 c7 e0 08 ret <== NOT EXECUTED
20486c0: 81 e8 00 00 restore <== NOT EXECUTED
inc = year & 0x03 ? 365 : 366;
if (days < inc)
break;
days -= inc;
}
months = year & 0x03 ? regyear : leapyear;
20486c4: 09 00 81 c5 sethi %hi(0x2071400), %g4 <== NOT EXECUTED
20486c8: 10 bf ff e5 b 204865c <msdos_date_unix2dos+0xc8> <== NOT EXECUTED
20486cc: 88 11 21 e4 or %g4, 0x1e4, %g4 ! 20715e4 <leapyear> <== NOT EXECUTED
/*
* If the time from the last conversion is the same as now, then
* skip the computations and use the saved result.
*/
if (lasttime != t) {
20486d0: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20486d4: f0 10 62 5e lduh [ %g1 + 0x25e ], %i0 ! 2074a5e <lastdtime><== NOT EXECUTED
20486d8: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20486dc: c6 10 62 5c lduh [ %g1 + 0x25c ], %g3 ! 2074a5c <lastddate><== NOT EXECUTED
if (year > 1980)
lastddate += (year - 1980) <<
MSDOS_DD_YEAR_SHIFT;
}
}
*dtp = lastdtime;
20486e0: f0 36 80 00 sth %i0, [ %i2 ] <== NOT EXECUTED
*ddp = lastddate;
20486e4: c6 36 40 00 sth %g3, [ %i1 ] <== NOT EXECUTED
}
20486e8: 81 c7 e0 08 ret <== NOT EXECUTED
20486ec: 81 e8 00 00 restore <== NOT EXECUTED
* If the number of days since 1970 is the same as the last
* time we did the computation then skip all this leap year
* and month stuff.
*/
days = t / (SECONDSPERDAY);
if (days != lastday) {
20486f0: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20486f4: c6 10 62 5c lduh [ %g1 + 0x25c ], %g3 ! 2074a5c <lastddate><== NOT EXECUTED
if (year > 1980)
lastddate += (year - 1980) <<
MSDOS_DD_YEAR_SHIFT;
}
}
*dtp = lastdtime;
20486f8: f0 36 80 00 sth %i0, [ %i2 ] <== NOT EXECUTED
*ddp = lastddate;
20486fc: c6 36 40 00 sth %g3, [ %i1 ] <== NOT EXECUTED
}
2048700: 81 c7 e0 08 ret <== NOT EXECUTED
2048704: 81 e8 00 00 restore <== NOT EXECUTED
02048a60 <msdos_dir_chmod>:
int
msdos_dir_chmod(rtems_filesystem_location_info_t *pathloc,
mode_t mode)
{
return RC_OK;
}
2048a60: 81 c3 e0 08 retl <== NOT EXECUTED
2048a64: 90 10 20 00 clr %o0 <== NOT EXECUTED
02049288 <msdos_dir_close>:
* RC_OK, if directory closed successfully, or -1 if error occured (errno
* set apropriately.
*/
int
msdos_dir_close(rtems_libio_t *iop)
{
2049288: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
204928c: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
2049290: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
int
msdos_dir_close(rtems_libio_t *iop)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2049294: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2049298: 92 10 20 00 clr %o1 <== NOT EXECUTED
204929c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
20492a0: 7f ff 10 e6 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20492a4: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
20492a8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20492ac: 12 80 00 10 bne 20492ec <msdos_dir_close+0x64> <== NOT EXECUTED
20492b0: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
rc = fat_file_close(iop->pathinfo.mt_entry, fat_fd);
20492b4: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
20492b8: 7f ff 7f 47 call 2028fd4 <fat_file_close> <== NOT EXECUTED
20492bc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
20492c0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20492c4: 12 80 00 06 bne 20492dc <msdos_dir_close+0x54> <== NOT EXECUTED
20492c8: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
rtems_semaphore_release(fs_info->vol_sema);
20492cc: 7f ff 11 22 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20492d0: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return RC_OK;
}
20492d4: 81 c7 e0 08 ret <== NOT EXECUTED
20492d8: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
rc = fat_file_close(iop->pathinfo.mt_entry, fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
20492dc: 7f ff 11 1e call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20492e0: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
20492e4: 81 c7 e0 08 ret <== NOT EXECUTED
20492e8: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one( EIO );
20492ec: 40 00 04 65 call 204a480 <__errno> <== NOT EXECUTED
20492f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20492f4: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20492f8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20492fc: 81 c7 e0 08 ret <== NOT EXECUTED
2049300: 81 e8 00 00 restore <== NOT EXECUTED
0203d520 <msdos_dir_is_empty>:
msdos_dir_is_empty(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd,
bool *ret_val
)
{
203d520: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203d524: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 <== NOT EXECUTED
*/
if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
MSDOS_THIS_DIR_ENTRY_EMPTY) ||
((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
MSDOS_ATTR_LFN) ||
(strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,
203d528: 23 00 81 c5 sethi %hi(0x2071400), %l1 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t j = 0, i = 0;
/* dir is not empty */
*ret_val = false;
203d52c: f8 14 00 00 lduh [ %l0 ], %i4 <== NOT EXECUTED
203d530: e8 04 20 9c ld [ %l0 + 0x9c ], %l4 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_EMPTY) ||
((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
MSDOS_ATTR_LFN) ||
(strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,
MSDOS_SHORT_NAME_LEN) == 0) ||
(strncmp(MSDOS_DIR_NAME((entry)),
203d534: 27 00 81 c5 sethi %hi(0x2071400), %l3 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t j = 0, i = 0;
/* dir is not empty */
*ret_val = false;
203d538: c0 2e 80 00 clrb [ %i2 ] <== NOT EXECUTED
203d53c: b9 2f 20 10 sll %i4, 0x10, %i4 <== NOT EXECUTED
*/
if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
MSDOS_THIS_DIR_ENTRY_EMPTY) ||
((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
MSDOS_ATTR_LFN) ||
(strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,
203d540: a2 14 61 6c or %l1, 0x16c, %l1 <== NOT EXECUTED
MSDOS_SHORT_NAME_LEN) == 0) ||
(strncmp(MSDOS_DIR_NAME((entry)),
203d544: a6 14 e1 70 or %l3, 0x170, %l3 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t j = 0, i = 0;
/* dir is not empty */
*ret_val = false;
203d548: a4 10 20 00 clr %l2 <== NOT EXECUTED
while ((ret = fat_file_read(mt_entry, fat_fd, j * fs_info->fat.vol.bps,
203d54c: b9 37 20 10 srl %i4, 0x10, %i4 <== NOT EXECUTED
203d550: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
203d554: 7f ff 15 8e call 2002b8c <.umul> <== NOT EXECUTED
203d558: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
203d55c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203d560: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
203d564: 96 10 00 1c mov %i4, %o3 <== NOT EXECUTED
203d568: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203d56c: 7f ff ae 0f call 2028da8 <fat_file_read> <== NOT EXECUTED
203d570: 98 10 00 14 mov %l4, %o4 <== NOT EXECUTED
203d574: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203d578: 02 80 00 37 be 203d654 <msdos_dir_is_empty+0x134> <== NOT EXECUTED
203d57c: 80 a7 60 1f cmp %i5, 0x1f <== NOT EXECUTED
fs_info->fat.vol.bps,
fs_info->cl_buf)) != FAT_EOF)
{
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203d580: 04 80 00 39 ble 203d664 <msdos_dir_is_empty+0x144> <== NOT EXECUTED
203d584: 01 00 00 00 nop <== NOT EXECUTED
return -1;
assert(ret == fs_info->fat.vol.bps);
203d588: f8 14 00 00 lduh [ %l0 ], %i4 <== NOT EXECUTED
203d58c: b9 2f 20 10 sll %i4, 0x10, %i4 <== NOT EXECUTED
203d590: 83 37 20 10 srl %i4, 0x10, %g1 <== NOT EXECUTED
203d594: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203d598: 12 80 00 35 bne 203d66c <msdos_dir_is_empty+0x14c> <== NOT EXECUTED
203d59c: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
/* have to look at the DIR_NAME as "raw" 8-bit data */
for (i = 0;
203d5a0: 02 80 00 2a be 203d648 <msdos_dir_is_empty+0x128> <== NOT EXECUTED
203d5a4: ac 10 20 00 clr %l6 <== NOT EXECUTED
fs_info->cl_buf)) != FAT_EOF)
{
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
return -1;
assert(ret == fs_info->fat.vol.bps);
203d5a8: e8 04 20 9c ld [ %l0 + 0x9c ], %l4 <== NOT EXECUTED
203d5ac: aa 10 00 14 mov %l4, %l5 <== NOT EXECUTED
* then consider it as empty.
*
* Just ignore long file name entries. They must have a short entry to
* be valid.
*/
if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
203d5b0: ee 0d 40 00 ldub [ %l5 ], %l7 <== NOT EXECUTED
203d5b4: 80 a5 e0 e5 cmp %l7, 0xe5 <== NOT EXECUTED
203d5b8: 22 80 00 1b be,a 203d624 <msdos_dir_is_empty+0x104> <== NOT EXECUTED
203d5bc: ac 05 a0 20 add %l6, 0x20, %l6 <== NOT EXECUTED
203d5c0: c2 0d 60 0b ldub [ %l5 + 0xb ], %g1 <== NOT EXECUTED
203d5c4: 82 08 60 3f and %g1, 0x3f, %g1 <== NOT EXECUTED
203d5c8: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED
203d5cc: 02 80 00 15 be 203d620 <msdos_dir_is_empty+0x100> <== NOT EXECUTED
203d5d0: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_EMPTY) ||
((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
MSDOS_ATTR_LFN) ||
(strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,
203d5d4: d2 04 40 00 ld [ %l1 ], %o1 <== NOT EXECUTED
203d5d8: 40 00 4f ce call 2051510 <strncmp> <== NOT EXECUTED
203d5dc: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
* then consider it as empty.
*
* Just ignore long file name entries. They must have a short entry to
* be valid.
*/
if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
203d5e0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d5e4: 22 80 00 10 be,a 203d624 <msdos_dir_is_empty+0x104> <== NOT EXECUTED
203d5e8: ac 05 a0 20 add %l6, 0x20, %l6 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_EMPTY) ||
((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
MSDOS_ATTR_LFN) ||
(strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,
MSDOS_SHORT_NAME_LEN) == 0) ||
(strncmp(MSDOS_DIR_NAME((entry)),
203d5ec: d2 04 c0 00 ld [ %l3 ], %o1 <== NOT EXECUTED
203d5f0: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
203d5f4: 40 00 4f c7 call 2051510 <strncmp> <== NOT EXECUTED
203d5f8: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
* then consider it as empty.
*
* Just ignore long file name entries. They must have a short entry to
* be valid.
*/
if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
203d5fc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d600: 22 80 00 09 be,a 203d624 <msdos_dir_is_empty+0x104> <== NOT EXECUTED
203d604: ac 05 a0 20 add %l6, 0x20, %l6 <== NOT EXECUTED
continue;
/*
* Nothing more to look at.
*/
if ((*MSDOS_DIR_NAME(entry)) ==
203d608: af 2d e0 18 sll %l7, 0x18, %l7 <== NOT EXECUTED
203d60c: 80 a5 e0 00 cmp %l7, 0 <== NOT EXECUTED
203d610: 02 80 00 0a be 203d638 <msdos_dir_is_empty+0x118> <== NOT EXECUTED
203d614: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
j++;
}
*ret_val = true;
return RC_OK;
}
203d618: 81 c7 e0 08 ret <== NOT EXECUTED
203d61c: 81 e8 00 00 restore <== NOT EXECUTED
assert(ret == fs_info->fat.vol.bps);
/* have to look at the DIR_NAME as "raw" 8-bit data */
for (i = 0;
i < fs_info->fat.vol.bps;
i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203d620: ac 05 a0 20 add %l6, 0x20, %l6 <== NOT EXECUTED
return -1;
assert(ret == fs_info->fat.vol.bps);
/* have to look at the DIR_NAME as "raw" 8-bit data */
for (i = 0;
203d624: 80 a7 40 16 cmp %i5, %l6 <== NOT EXECUTED
203d628: 18 bf ff e2 bgu 203d5b0 <msdos_dir_is_empty+0x90> <== NOT EXECUTED
203d62c: aa 05 60 20 add %l5, 0x20, %l5 <== NOT EXECUTED
/*
* Short file name entries mean not empty.
*/
return RC_OK;
}
j++;
203d630: 10 bf ff c7 b 203d54c <msdos_dir_is_empty+0x2c> <== NOT EXECUTED
203d634: a4 04 a0 01 inc %l2 <== NOT EXECUTED
* Nothing more to look at.
*/
if ((*MSDOS_DIR_NAME(entry)) ==
MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY)
{
*ret_val = true;
203d638: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
203d63c: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
return RC_OK;
203d640: 81 c7 e0 08 ret <== NOT EXECUTED
203d644: 81 e8 00 00 restore <== NOT EXECUTED
203d648: e8 04 20 9c ld [ %l0 + 0x9c ], %l4 <== NOT EXECUTED
/*
* Short file name entries mean not empty.
*/
return RC_OK;
}
j++;
203d64c: 10 bf ff c0 b 203d54c <msdos_dir_is_empty+0x2c> <== NOT EXECUTED
203d650: a4 04 a0 01 inc %l2 <== NOT EXECUTED
}
*ret_val = true;
203d654: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
203d658: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
return RC_OK;
}
203d65c: 81 c7 e0 08 ret <== NOT EXECUTED
203d660: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
while ((ret = fat_file_read(mt_entry, fat_fd, j * fs_info->fat.vol.bps,
fs_info->fat.vol.bps,
fs_info->cl_buf)) != FAT_EOF)
{
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203d664: 81 c7 e0 08 ret <== NOT EXECUTED
203d668: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
return -1;
assert(ret == fs_info->fat.vol.bps);
203d66c: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203d670: 15 00 81 b8 sethi %hi(0x206e000), %o2 <== NOT EXECUTED
203d674: 17 00 81 b8 sethi %hi(0x206e000), %o3 <== NOT EXECUTED
203d678: 90 12 22 90 or %o0, 0x290, %o0 <== NOT EXECUTED
203d67c: 94 12 a3 e0 or %o2, 0x3e0, %o2 <== NOT EXECUTED
203d680: 96 12 e3 08 or %o3, 0x308, %o3 <== NOT EXECUTED
203d684: 7f ff bb 33 call 202c350 <__assert_func> <== NOT EXECUTED
203d688: 92 10 23 b5 mov 0x3b5, %o1 <== NOT EXECUTED
02048a68 <msdos_dir_lseek>:
* RC_OK on success, or -1 if error occured (errno
* set apropriately).
*/
rtems_off64_t
msdos_dir_lseek(rtems_libio_t *iop, rtems_off64_t offset, int whence)
{
2048a68: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
switch (whence)
2048a6c: 84 10 20 00 clr %g2 <== NOT EXECUTED
2048a70: 80 a6 e0 01 cmp %i3, 1 <== NOT EXECUTED
2048a74: 08 80 00 09 bleu 2048a98 <msdos_dir_lseek+0x30> <== NOT EXECUTED
2048a78: 86 10 20 00 clr %g3 <== NOT EXECUTED
* Movement past the end of the directory via lseek is not a
* permitted operation
*/
case SEEK_END:
default:
rtems_set_errno_and_return_minus_one( EINVAL );
2048a7c: 40 00 06 81 call 204a480 <__errno> <== NOT EXECUTED
2048a80: 01 00 00 00 nop <== NOT EXECUTED
2048a84: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
2048a88: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
2048a8c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048a90: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
2048a94: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
break;
}
return RC_OK;
}
2048a98: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
2048a9c: 81 c7 e0 08 ret <== NOT EXECUTED
2048aa0: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
02049304 <msdos_dir_open>:
* set apropriately)
*/
int
msdos_dir_open(rtems_libio_t *iop, const char *pathname, uint32_t flag,
uint32_t mode)
{
2049304: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2049308: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
204930c: e4 06 20 3c ld [ %i0 + 0x3c ], %l2 <== NOT EXECUTED
msdos_dir_open(rtems_libio_t *iop, const char *pathname, uint32_t flag,
uint32_t mode)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2049310: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2049314: 92 10 20 00 clr %o1 <== NOT EXECUTED
2049318: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
204931c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2049320: 7f ff 10 c6 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2049324: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2049328: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
204932c: 12 80 00 11 bne 2049370 <msdos_dir_open+0x6c> <== NOT EXECUTED
2049330: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
rc = fat_file_reopen(fat_fd);
2049334: 7f ff 7c 45 call 2028448 <fat_file_reopen> <== NOT EXECUTED
2049338: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (rc != RC_OK)
204933c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2049340: 12 80 00 08 bne 2049360 <msdos_dir_open+0x5c> <== NOT EXECUTED
2049344: 01 00 00 00 nop <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
iop->offset = 0;
rtems_semaphore_release(fs_info->vol_sema);
2049348: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
iop->offset = 0;
204934c: c0 24 20 10 clr [ %l0 + 0x10 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
2049350: 7f ff 11 01 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2049354: c0 24 20 14 clr [ %l0 + 0x14 ] <== NOT EXECUTED
return RC_OK;
}
2049358: 81 c7 e0 08 ret <== NOT EXECUTED
204935c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
rc = fat_file_reopen(fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
2049360: 7f ff 10 fd call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2049364: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
2049368: 81 c7 e0 08 ret <== NOT EXECUTED
204936c: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one( EIO );
2049370: 40 00 04 44 call 204a480 <__errno> <== NOT EXECUTED
2049374: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2049378: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
204937c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2049380: 81 c7 e0 08 ret <== NOT EXECUTED
2049384: 81 e8 00 00 restore <== NOT EXECUTED
02048cc0 <msdos_dir_read>:
* the number of bytes read on success, or -1 if error occured (errno
* set apropriately).
*/
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
{
2048cc0: 9d e3 be 60 save %sp, -416, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
fat_file_fd_t *fat_fd = iop->file_info;
2048cc4: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2048cc8: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
* optimization: we know that root directory for FAT12/16 volumes is
* sequential set of sectors and any cluster is sequential set of sectors
* too, so read such set of sectors is quick operation for low-level IO
* layer.
*/
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
2048ccc: c4 04 60 20 ld [ %l1 + 0x20 ], %g2 <== NOT EXECUTED
* the number of bytes read on success, or -1 if error occured (errno
* set apropriately).
*/
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
{
2048cd0: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED
2048cd4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
* optimization: we know that root directory for FAT12/16 volumes is
* sequential set of sectors and any cluster is sequential set of sectors
* too, so read such set of sectors is quick operation for low-level IO
* layer.
*/
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
2048cd8: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2048cdc: f2 00 60 34 ld [ %g1 + 0x34 ], %i1 <== NOT EXECUTED
* optimization: we know that root directory for FAT12/16 volumes is
* sequential set of sectors and any cluster is sequential set of sectors
* too, so read such set of sectors is quick operation for low-level IO
* layer.
*/
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
2048ce0: 02 80 00 eb be 204908c <msdos_dir_read+0x3cc> <== NOT EXECUTED
2048ce4: e4 1e 20 10 ldd [ %i0 + 0x10 ], %l2 <== NOT EXECUTED
2048ce8: c8 16 60 06 lduh [ %i1 + 6 ], %g4 <== NOT EXECUTED
2048cec: c8 27 be c8 st %g4, [ %fp + -312 ] <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?
fat_fd->fat_file_size :
fs_info->fat.vol.bpc;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2048cf0: d0 06 60 98 ld [ %i1 + 0x98 ], %o0 <== NOT EXECUTED
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
fat_file_fd_t *fat_fd = iop->file_info;
fat_file_fd_t *tmp_fat_fd = NULL;
2048cf4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t start = 0;
ssize_t ret = 0;
uint32_t cmpltd = 0;
uint32_t j = 0, i = 0;
uint32_t bts2rd = 0;
uint32_t cur_cln = 0;
2048cf8: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?
fat_fd->fat_file_size :
fs_info->fat.vol.bpc;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2048cfc: 92 10 20 00 clr %o1 <== NOT EXECUTED
2048d00: 7f ff 12 4e call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2048d04: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2048d08: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048d0c: 12 80 01 58 bne 204926c <msdos_dir_read+0x5ac> <== NOT EXECUTED
2048d10: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
* cast start and count - protect against using sizes that are not exact
* multiples of the -dirent- size. These could result in unexpected
* results
*/
start = iop->offset / sizeof(struct dirent);
count = (count / sizeof(struct dirent)) * sizeof(struct dirent);
2048d14: 40 00 67 1c call 2062984 <.udiv> <== NOT EXECUTED
2048d18: 92 10 21 18 mov 0x118, %o1 <== NOT EXECUTED
2048d1c: 83 2a 20 05 sll %o0, 5, %g1 <== NOT EXECUTED
2048d20: 91 2a 20 03 sll %o0, 3, %o0 <== NOT EXECUTED
2048d24: 82 02 00 01 add %o0, %g1, %g1 <== NOT EXECUTED
2048d28: 85 28 60 03 sll %g1, 3, %g2 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
while (count > 0)
2048d2c: 84 a0 80 01 subcc %g2, %g1, %g2 <== NOT EXECUTED
2048d30: 02 80 01 4d be 2049264 <msdos_dir_read+0x5a4> <== NOT EXECUTED
2048d34: c4 27 be cc st %g2, [ %fp + -308 ] <== NOT EXECUTED
/*
* cast start and count - protect against using sizes that are not exact
* multiples of the -dirent- size. These could result in unexpected
* results
*/
start = iop->offset / sizeof(struct dirent);
2048d38: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2048d3c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2048d40: 94 10 20 00 clr %o2 <== NOT EXECUTED
2048d44: 40 00 68 ce call 206307c <__divdi3> <== NOT EXECUTED
2048d48: 96 10 21 18 mov 0x118, %o3 <== NOT EXECUTED
2048d4c: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
2048d50: 39 00 81 c5 sethi %hi(0x2071400), %i4 <== NOT EXECUTED
2048d54: ac 10 00 09 mov %o1, %l6 <== NOT EXECUTED
2048d58: b8 17 21 fc or %i4, 0x1fc, %i4 <== NOT EXECUTED
2048d5c: b0 10 20 00 clr %i0 <== NOT EXECUTED
2048d60: b6 10 20 00 clr %i3 <== NOT EXECUTED
2048d64: ba 10 20 00 clr %i5 <== NOT EXECUTED
2048d68: b4 10 20 00 clr %i2 <== NOT EXECUTED
2048d6c: ae 10 3f ff mov -1, %l7 <== NOT EXECUTED
}
/* fill in dirent structure */
/* XXX: from what and in what d_off should be computed ?! */
tmp_dirent.d_off = start + cmpltd;
tmp_dirent.d_reclen = sizeof(struct dirent);
2048d70: aa 10 00 11 mov %l1, %l5 <== NOT EXECUTED
* fat-file is already opened by open call, so read it
* Always read directory fat-file from the beggining because of MSDOS
* directories feature :( - we should count elements currently
* present in the directory because there may be holes :)
*/
ret = fat_file_read(iop->pathinfo.mt_entry, fat_fd, (j * bts2rd),
2048d74: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
2048d78: d6 07 be c8 ld [ %fp + -312 ], %o3 <== NOT EXECUTED
2048d7c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2048d80: 7f ff 80 0a call 2028da8 <fat_file_read> <== NOT EXECUTED
2048d84: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
bts2rd, fs_info->cl_buf);
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
2048d88: 80 a2 20 1f cmp %o0, 0x1f <== NOT EXECUTED
2048d8c: 04 80 01 2c ble 204923c <msdos_dir_read+0x57c> <== NOT EXECUTED
2048d90: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + i;
2048d94: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
/*
* Is this directory from here on empty ?
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
2048d98: c6 0b 00 00 ldub [ %o4 ], %g3 <== NOT EXECUTED
2048d9c: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2048da0: 02 80 00 b5 be 2049074 <msdos_dir_read+0x3b4> <== NOT EXECUTED
2048da4: a6 10 00 0c mov %o4, %l3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + i;
2048da8: a4 10 00 0c mov %o4, %l2 <== NOT EXECUTED
2048dac: 10 80 00 0e b 2048de4 <msdos_dir_read+0x124> <== NOT EXECUTED
2048db0: a2 10 20 00 clr %l1 <== NOT EXECUTED
/* Is the directory entry empty */
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) == MSDOS_THIS_DIR_ENTRY_EMPTY)
continue;
/* Is the directory entry empty a volume label */
if (((*MSDOS_DIR_ATTR(entry)) & MSDOS_ATTR_VOLUME_ID) &&
2048db4: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED
2048db8: 02 80 00 20 be 2048e38 <msdos_dir_read+0x178> <== NOT EXECUTED
2048dbc: 80 a5 ff ff cmp %l7, -1 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
2048dc0: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
2048dc4: 80 a4 40 14 cmp %l1, %l4 <== NOT EXECUTED
2048dc8: 1a 80 00 19 bcc 2048e2c <msdos_dir_read+0x16c> <== NOT EXECUTED
2048dcc: c2 07 be c8 ld [ %fp + -312 ], %g1 <== NOT EXECUTED
char* entry = (char*) fs_info->cl_buf + i;
/*
* Is this directory from here on empty ?
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
2048dd0: c6 0b 00 11 ldub [ %o4 + %l1 ], %g3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + i;
2048dd4: a4 03 00 11 add %o4, %l1, %l2 <== NOT EXECUTED
/*
* Is this directory from here on empty ?
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
2048dd8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2048ddc: 02 80 00 a6 be 2049074 <msdos_dir_read+0x3b4> <== NOT EXECUTED
2048de0: a6 10 00 12 mov %l2, %l3 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return cmpltd;
}
/* Is the directory entry empty */
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) == MSDOS_THIS_DIR_ENTRY_EMPTY)
2048de4: 80 a0 e0 e5 cmp %g3, 0xe5 <== NOT EXECUTED
2048de8: 22 bf ff f7 be,a 2048dc4 <msdos_dir_read+0x104> <== NOT EXECUTED
2048dec: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
continue;
/* Is the directory entry empty a volume label */
if (((*MSDOS_DIR_ATTR(entry)) & MSDOS_ATTR_VOLUME_ID) &&
2048df0: c2 0c e0 0b ldub [ %l3 + 0xb ], %g1 <== NOT EXECUTED
2048df4: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
2048df8: 12 bf ff ef bne 2048db4 <msdos_dir_read+0xf4> <== NOT EXECUTED
2048dfc: 82 08 60 3f and %g1, 0x3f, %g1 <== NOT EXECUTED
/*
* Check the attribute to see if the entry is for a long file
* name.
*/
if ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
2048e00: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED
2048e04: 02 80 00 0c be 2048e34 <msdos_dir_read+0x174> <== NOT EXECUTED
2048e08: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED
fat_dir_pos_t dir_pos;
/*
* Skip active entries until get the entry to start from.
*/
if (start)
2048e0c: 22 80 00 18 be,a 2048e6c <msdos_dir_read+0x1ac> <== NOT EXECUTED
2048e10: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
2048e14: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
* Skip active entries until get the entry to start from.
*/
if (start)
{
lfn_start = FAT_FILE_SHORT_NAME;
start--;
2048e18: ac 05 bf ff add %l6, -1, %l6 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
rtems_set_errno_and_return_minus_one(EIO);
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
2048e1c: 80 a4 40 14 cmp %l1, %l4 <== NOT EXECUTED
2048e20: 0a bf ff ec bcs 2048dd0 <msdos_dir_read+0x110> <== NOT EXECUTED
2048e24: ae 10 3f ff mov -1, %l7 <== NOT EXECUTED
2048e28: c2 07 be c8 ld [ %fp + -312 ], %g1 <== NOT EXECUTED
2048e2c: 10 bf ff d2 b 2048d74 <msdos_dir_read+0xb4> <== NOT EXECUTED
2048e30: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED
int q;
/*
* Is this is the first entry of a LFN ?
*/
if (lfn_start == FAT_FILE_SHORT_NAME)
2048e34: 80 a5 ff ff cmp %l7, -1 <== NOT EXECUTED
2048e38: 82 10 00 1d mov %i5, %g1 <== NOT EXECUTED
2048e3c: 02 80 00 71 be 2049000 <msdos_dir_read+0x340> <== NOT EXECUTED
2048e40: 84 10 00 1a mov %i2, %g2 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These could
* be orphaned entries depending on the history of the
* disk.
*/
if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
2048e44: fa 0c c0 00 ldub [ %l3 ], %i5 <== NOT EXECUTED
2048e48: ba 0f 60 3f and %i5, 0x3f, %i5 <== NOT EXECUTED
2048e4c: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
2048e50: 22 80 00 80 be,a 2049050 <msdos_dir_read+0x390> <== NOT EXECUTED
2048e54: f4 0c e0 0d ldub [ %l3 + 0xd ], %i2 <== NOT EXECUTED
2048e58: ba 10 00 01 mov %g1, %i5 <== NOT EXECUTED
2048e5c: b4 10 00 02 mov %g2, %i2 <== NOT EXECUTED
2048e60: ae 10 3f ff mov -1, %l7 <== NOT EXECUTED
2048e64: 10 bf ff d7 b 2048dc0 <msdos_dir_read+0x100> <== NOT EXECUTED
2048e68: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
* unfortunately there is no method to extract ino except to
* open fat-file descriptor :( ... so, open it
*/
/* get number of cluster we are working with */
rc = fat_file_ioctl(iop->pathinfo.mt_entry, fat_fd, F_CLU_NUM,
2048e6c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2048e70: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2048e74: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
2048e78: 7f ff 7e 3d call 202876c <fat_file_ioctl> <== NOT EXECUTED
2048e7c: 98 07 bf f8 add %fp, -8, %o4 <== NOT EXECUTED
j * bts2rd, &cur_cln);
if (rc != RC_OK)
2048e80: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048e84: 12 80 00 c5 bne 2049198 <msdos_dir_read+0x4d8> <== NOT EXECUTED
2048e88: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
}
fat_dir_pos_init(&dir_pos);
dir_pos.sname.cln = cur_cln;
dir_pos.sname.ofs = i;
rc = fat_file_open(iop->pathinfo.mt_entry, &dir_pos, &tmp_fat_fd);
2048e8c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
fat_dir_pos_init(&dir_pos);
dir_pos.sname.cln = cur_cln;
2048e90: c2 27 bf e8 st %g1, [ %fp + -24 ] <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
2048e94: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
dir_pos.sname.ofs = i;
2048e98: e2 27 bf ec st %l1, [ %fp + -20 ] <== NOT EXECUTED
2048e9c: c2 27 bf f0 st %g1, [ %fp + -16 ] <== NOT EXECUTED
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
2048ea0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
rc = fat_file_open(iop->pathinfo.mt_entry, &dir_pos, &tmp_fat_fd);
2048ea4: 92 07 bf e8 add %fp, -24, %o1 <== NOT EXECUTED
2048ea8: 7f ff 80 7d call 202909c <fat_file_open> <== NOT EXECUTED
2048eac: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (rc != RC_OK)
2048eb0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048eb4: 12 80 00 b9 bne 2049198 <msdos_dir_read+0x4d8> <== NOT EXECUTED
2048eb8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
}
/* fill in dirent structure */
/* XXX: from what and in what d_off should be computed ?! */
tmp_dirent.d_off = start + cmpltd;
tmp_dirent.d_reclen = sizeof(struct dirent);
2048ebc: 88 10 21 18 mov 0x118, %g4 <== NOT EXECUTED
tmp_dirent.d_ino = tmp_fat_fd->ino;
2048ec0: c2 00 60 0c ld [ %g1 + 0xc ], %g1 <== NOT EXECUTED
return rc;
}
/* fill in dirent structure */
/* XXX: from what and in what d_off should be computed ?! */
tmp_dirent.d_off = start + cmpltd;
2048ec4: c0 27 be d8 clr [ %fp + -296 ] <== NOT EXECUTED
2048ec8: f6 27 be dc st %i3, [ %fp + -292 ] <== NOT EXECUTED
tmp_dirent.d_reclen = sizeof(struct dirent);
tmp_dirent.d_ino = tmp_fat_fd->ino;
2048ecc: c2 27 be d0 st %g1, [ %fp + -304 ] <== NOT EXECUTED
/*
* If a long file name check if the correct number of
* entries have been found and if the checksum is correct.
* If not return the short file name.
*/
if (lfn_start != FAT_FILE_SHORT_NAME)
2048ed0: 80 a5 ff ff cmp %l7, -1 <== NOT EXECUTED
2048ed4: 02 80 00 16 be 2048f2c <msdos_dir_read+0x26c> <== NOT EXECUTED
2048ed8: c8 37 be e0 sth %g4, [ %fp + -288 ] <== NOT EXECUTED
2048edc: 82 10 20 00 clr %g1 <== NOT EXECUTED
2048ee0: 84 10 20 00 clr %g2 <== NOT EXECUTED
2048ee4: 10 80 00 06 b 2048efc <msdos_dir_read+0x23c> <== NOT EXECUTED
2048ee8: 86 10 20 00 clr %g3 <== NOT EXECUTED
uint8_t cs = 0;
uint8_t* p = (uint8_t*) entry;
int i;
for (i = 0; i < 11; i++, p++)
cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
2048eec: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
2048ef0: 84 08 e0 01 and %g3, 1, %g2 <== NOT EXECUTED
2048ef4: 84 20 00 02 neg %g2 <== NOT EXECUTED
2048ef8: 84 08 a0 80 and %g2, 0x80, %g2 <== NOT EXECUTED
2048efc: c8 0c c0 01 ldub [ %l3 + %g1 ], %g4 <== NOT EXECUTED
2048f00: 87 30 e0 01 srl %g3, 1, %g3 <== NOT EXECUTED
2048f04: 84 00 80 04 add %g2, %g4, %g2 <== NOT EXECUTED
{
uint8_t cs = 0;
uint8_t* p = (uint8_t*) entry;
int i;
for (i = 0; i < 11; i++, p++)
2048f08: 82 00 60 01 inc %g1 <== NOT EXECUTED
2048f0c: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
2048f10: 12 bf ff f7 bne 2048eec <msdos_dir_read+0x22c> <== NOT EXECUTED
2048f14: 86 00 80 03 add %g2, %g3, %g3 <== NOT EXECUTED
cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
if (lfn_entries || (lfn_checksum != cs))
2048f18: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
2048f1c: 82 0e a0 ff and %i2, 0xff, %g1 <== NOT EXECUTED
2048f20: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
2048f24: 02 80 00 1d be 2048f98 <msdos_dir_read+0x2d8> <== NOT EXECUTED
2048f28: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
/*
* copy base name to destination
*/
src_tmp = src;
len = i;
while (i-- > 0) {
2048f2c: 86 10 20 08 mov 8, %g3 <== NOT EXECUTED
const char *src_tmp;
/*
* find last non-blank character of base name
*/
for ((i = MSDOS_SHORT_BASE_LEN ,
2048f30: 82 04 80 03 add %l2, %g3, %g1 <== NOT EXECUTED
2048f34: c2 48 7f ff ldsb [ %g1 + -1 ], %g1 <== NOT EXECUTED
2048f38: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
2048f3c: 12 80 00 83 bne 2049148 <msdos_dir_read+0x488> <== NOT EXECUTED
2048f40: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2048f44: 86 80 ff ff addcc %g3, -1, %g3 <== NOT EXECUTED
2048f48: 12 bf ff fb bne 2048f34 <msdos_dir_read+0x274> <== NOT EXECUTED
2048f4c: 82 04 80 03 add %l2, %g3, %g1 <== NOT EXECUTED
/*
* copy base name to destination
*/
src_tmp = src;
len = i;
while (i-- > 0) {
2048f50: 84 07 be e4 add %fp, -284, %g2 <== NOT EXECUTED
*dst++ = tolower((unsigned char)(*src_tmp++));
}
/*
* find last non-blank character of extension
*/
for ((i = MSDOS_SHORT_EXT_LEN ,
2048f54: c2 4c a0 0a ldsb [ %l2 + 0xa ], %g1 <== NOT EXECUTED
2048f58: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
2048f5c: 12 80 00 9c bne 20491cc <msdos_dir_read+0x50c> <== NOT EXECUTED
2048f60: 96 10 20 03 mov 3, %o3 <== NOT EXECUTED
2048f64: c2 4c a0 09 ldsb [ %l2 + 9 ], %g1 <== NOT EXECUTED
src_tmp = src + MSDOS_SHORT_BASE_LEN+MSDOS_SHORT_EXT_LEN-1);
((i > 0) &&
(*src_tmp == ' '));
i--,src_tmp--)
2048f68: 88 04 a0 09 add %l2, 9, %g4 <== NOT EXECUTED
*dst++ = tolower((unsigned char)(*src_tmp++));
}
/*
* find last non-blank character of extension
*/
for ((i = MSDOS_SHORT_EXT_LEN ,
2048f6c: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
2048f70: 12 80 00 97 bne 20491cc <msdos_dir_read+0x50c> <== NOT EXECUTED
2048f74: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
2048f78: c2 49 3f ff ldsb [ %g4 + -1 ], %g1 <== NOT EXECUTED
2048f7c: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
2048f80: 12 80 00 93 bne 20491cc <msdos_dir_read+0x50c> <== NOT EXECUTED
2048f84: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
while (i-- > 0) {
*dst++ = tolower((unsigned char)(*src_tmp++));
len++;
}
}
*dst = '\0'; /* terminate string */
2048f88: c0 28 80 00 clrb [ %g2 ] <== NOT EXECUTED
{
/*
* convert dir entry from fixed 8+3 format (without dot)
* to 0..8 + 1dot + 0..3 format
*/
tmp_dirent.d_namlen = msdos_format_dirent_with_dot(
2048f8c: c6 37 be e2 sth %g3, [ %fp + -286 ] <== NOT EXECUTED
2048f90: 10 80 00 07 b 2048fac <msdos_dir_read+0x2ec> <== NOT EXECUTED
2048f94: ae 10 3f ff mov -1, %l7 <== NOT EXECUTED
int i;
for (i = 0; i < 11; i++, p++)
cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
if (lfn_entries || (lfn_checksum != cs))
2048f98: 12 bf ff e6 bne 2048f30 <msdos_dir_read+0x270> <== NOT EXECUTED
2048f9c: 86 10 20 08 mov 8, %g3 <== NOT EXECUTED
tmp_dirent.d_namlen = msdos_format_dirent_with_dot(
tmp_dirent.d_name, entry); /* src text */
}
else
{
tmp_dirent.d_namlen = strlen(tmp_dirent.d_name);
2048fa0: 40 00 20 f4 call 2051370 <strlen> <== NOT EXECUTED
2048fa4: 90 07 be e4 add %fp, -284, %o0 <== NOT EXECUTED
2048fa8: d0 37 be e2 sth %o0, [ %fp + -286 ] <== NOT EXECUTED
}
memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
2048fac: c2 07 a0 48 ld [ %fp + 0x48 ], %g1 <== NOT EXECUTED
2048fb0: 92 07 be d0 add %fp, -304, %o1 <== NOT EXECUTED
2048fb4: 94 10 21 18 mov 0x118, %o2 <== NOT EXECUTED
2048fb8: 40 00 12 7e call 204d9b0 <memcpy> <== NOT EXECUTED
2048fbc: 90 00 40 1b add %g1, %i3, %o0 <== NOT EXECUTED
iop->offset = iop->offset + sizeof(struct dirent);
2048fc0: c4 1c 20 10 ldd [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
cmpltd += (sizeof(struct dirent));
count -= (sizeof(struct dirent));
/* inode number extracted, close fat-file */
rc = fat_file_close(iop->pathinfo.mt_entry, tmp_fat_fd);
2048fc4: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
2048fc8: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
tmp_dirent.d_namlen = strlen(tmp_dirent.d_name);
}
memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
iop->offset = iop->offset + sizeof(struct dirent);
2048fcc: 86 80 e1 18 addcc %g3, 0x118, %g3 <== NOT EXECUTED
2048fd0: 84 40 a0 00 addx %g2, 0, %g2 <== NOT EXECUTED
cmpltd += (sizeof(struct dirent));
count -= (sizeof(struct dirent));
/* inode number extracted, close fat-file */
rc = fat_file_close(iop->pathinfo.mt_entry, tmp_fat_fd);
2048fd4: 7f ff 80 00 call 2028fd4 <fat_file_close> <== NOT EXECUTED
2048fd8: c4 3c 20 10 std %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
if (rc != RC_OK)
2048fdc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048fe0: 12 80 00 6e bne 2049198 <msdos_dir_read+0x4d8> <== NOT EXECUTED
2048fe4: c8 07 be cc ld [ %fp + -308 ], %g4 <== NOT EXECUTED
}
memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
iop->offset = iop->offset + sizeof(struct dirent);
cmpltd += (sizeof(struct dirent));
2048fe8: b6 06 e1 18 add %i3, 0x118, %i3 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
}
if (count <= 0)
2048fec: 88 81 3e e8 addcc %g4, -280, %g4 <== NOT EXECUTED
2048ff0: 02 80 00 71 be 20491b4 <msdos_dir_read+0x4f4> <== NOT EXECUTED
2048ff4: c8 27 be cc st %g4, [ %fp + -308 ] <== NOT EXECUTED
2048ff8: 10 bf ff 72 b 2048dc0 <msdos_dir_read+0x100> <== NOT EXECUTED
2048ffc: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
if (lfn_start == FAT_FILE_SHORT_NAME)
{
/*
* The first entry must have the last long entry flag set.
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry) &
2049000: 80 88 e0 40 btst 0x40, %g3 <== NOT EXECUTED
2049004: 22 bf ff 70 be,a 2048dc4 <msdos_dir_read+0x104> <== NOT EXECUTED
2049008: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
* Get the number of entries so we can count down and
* also the checksum of the short entry.
*/
lfn_entries = (*MSDOS_DIR_ENTRY_TYPE(entry) &
MSDOS_LAST_LONG_ENTRY_MASK);
lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);
204900c: c4 0c e0 0d ldub [ %l3 + 0xd ], %g2 <== NOT EXECUTED
/*
* Get the number of entries so we can count down and
* also the checksum of the short entry.
*/
lfn_entries = (*MSDOS_DIR_ENTRY_TYPE(entry) &
2049010: 82 08 e0 3f and %g3, 0x3f, %g1 <== NOT EXECUTED
MSDOS_LAST_LONG_ENTRY_MASK);
lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);
memset (tmp_dirent.d_name, 0, sizeof(tmp_dirent.d_name));
2049014: c4 27 be c4 st %g2, [ %fp + -316 ] <== NOT EXECUTED
2049018: c2 27 be c0 st %g1, [ %fp + -320 ] <== NOT EXECUTED
204901c: 90 07 be e4 add %fp, -284, %o0 <== NOT EXECUTED
2049020: 92 10 20 00 clr %o1 <== NOT EXECUTED
2049024: 40 00 12 f6 call 204dbfc <memset> <== NOT EXECUTED
2049028: 94 10 21 00 mov 0x100, %o2 <== NOT EXECUTED
204902c: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These could
* be orphaned entries depending on the history of the
* disk.
*/
if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
2049030: fa 0c c0 00 ldub [ %l3 ], %i5 <== NOT EXECUTED
continue;
/*
* Remember the start location of the long file name.
*/
lfn_start =
2049034: ae 06 00 11 add %i0, %l1, %l7 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These could
* be orphaned entries depending on the history of the
* disk.
*/
if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
2049038: ba 0f 60 3f and %i5, 0x3f, %i5 <== NOT EXECUTED
continue;
/*
* Remember the start location of the long file name.
*/
lfn_start =
204903c: af 35 e0 05 srl %l7, 5, %l7 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These could
* be orphaned entries depending on the history of the
* disk.
*/
if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
2049040: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
2049044: 12 bf ff 85 bne 2048e58 <msdos_dir_read+0x198> <== NOT EXECUTED
2049048: c4 07 be c4 ld [ %fp + -316 ], %g2 <== NOT EXECUTED
MSDOS_LAST_LONG_ENTRY_MASK)) ||
(lfn_checksum != *MSDOS_DIR_LFN_CHECKSUM(entry)))
204904c: f4 0c e0 0d ldub [ %l3 + 0xd ], %i2 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These could
* be orphaned entries depending on the history of the
* disk.
*/
if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
2049050: 86 08 a0 ff and %g2, 0xff, %g3 <== NOT EXECUTED
2049054: 88 0e a0 ff and %i2, 0xff, %g4 <== NOT EXECUTED
2049058: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED
204905c: 22 80 00 17 be,a 20490b8 <msdos_dir_read+0x3f8> <== NOT EXECUTED
2049060: ba 00 7f ff add %g1, -1, %i5 <== NOT EXECUTED
2049064: b4 10 00 02 mov %g2, %i2 <== NOT EXECUTED
2049068: ae 10 3f ff mov -1, %l7 <== NOT EXECUTED
204906c: 10 bf ff 55 b 2048dc0 <msdos_dir_read+0x100> <== NOT EXECUTED
2049070: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
* Is this directory from here on empty ?
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY)
{
rtems_semaphore_release(fs_info->vol_sema);
2049074: d0 06 60 98 ld [ %i1 + 0x98 ], %o0 <== NOT EXECUTED
2049078: 7f ff 11 b7 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
204907c: f6 27 be c0 st %i3, [ %fp + -320 ] <== NOT EXECUTED
return cmpltd;
2049080: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
j++;
}
rtems_semaphore_release(fs_info->vol_sema);
return cmpltd;
}
2049084: 81 c7 e0 08 ret <== NOT EXECUTED
2049088: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
* optimization: we know that root directory for FAT12/16 volumes is
* sequential set of sectors and any cluster is sequential set of sectors
* too, so read such set of sectors is quick operation for low-level IO
* layer.
*/
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
204908c: c2 04 60 24 ld [ %l1 + 0x24 ], %g1 <== NOT EXECUTED
2049090: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2049094: 32 bf ff 16 bne,a 2048cec <msdos_dir_read+0x2c> <== NOT EXECUTED
2049098: c8 16 60 06 lduh [ %i1 + 6 ], %g4 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?
204909c: c2 0e 60 0a ldub [ %i1 + 0xa ], %g1 <== NOT EXECUTED
20490a0: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
20490a4: 22 bf ff 12 be,a 2048cec <msdos_dir_read+0x2c> <== NOT EXECUTED
20490a8: c8 16 60 06 lduh [ %i1 + 6 ], %g4 <== NOT EXECUTED
* optimization: we know that root directory for FAT12/16 volumes is
* sequential set of sectors and any cluster is sequential set of sectors
* too, so read such set of sectors is quick operation for low-level IO
* layer.
*/
bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&
20490ac: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 <== NOT EXECUTED
20490b0: 10 bf ff 10 b 2048cf0 <msdos_dir_read+0x30> <== NOT EXECUTED
20490b4: c2 27 be c8 st %g1, [ %fp + -312 ] <== NOT EXECUTED
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
20490b8: 85 2f 60 04 sll %i5, 4, %g2 <== NOT EXECUTED
20490bc: 83 2f 60 02 sll %i5, 2, %g1 <== NOT EXECUTED
20490c0: 88 07 be d0 add %fp, -304, %g4 <== NOT EXECUTED
20490c4: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
* trailing nul character. We need to range check the length to
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
20490c8: a4 04 a0 01 inc %l2 <== NOT EXECUTED
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
20490cc: 82 00 40 1d add %g1, %i5, %g1 <== NOT EXECUTED
20490d0: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
20490d4: 86 01 00 01 add %g4, %g1, %g3 <== NOT EXECUTED
20490d8: 86 00 e0 14 add %g3, 0x14, %g3 <== NOT EXECUTED
for (q = 0; q < MSDOS_LFN_LEN_PER_ENTRY; q++)
{
if (o >= (sizeof(tmp_dirent.d_name) - 1))
20490dc: 80 a0 60 fe cmp %g1, 0xfe <== NOT EXECUTED
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
20490e0: 88 00 bf ff add %g2, -1, %g4 <== NOT EXECUTED
for (q = 0; q < MSDOS_LFN_LEN_PER_ENTRY; q++)
{
if (o >= (sizeof(tmp_dirent.d_name) - 1))
20490e4: 18 bf ff c5 bgu 2048ff8 <msdos_dir_read+0x338> <== NOT EXECUTED
20490e8: 82 00 60 01 inc %g1 <== NOT EXECUTED
break;
tmp_dirent.d_name[o++] = *p;
20490ec: da 0c 80 00 ldub [ %l2 ], %o5 <== NOT EXECUTED
20490f0: da 28 c0 00 stb %o5, [ %g3 ] <== NOT EXECUTED
if (*p == '\0')
20490f4: da 4c 80 00 ldsb [ %l2 ], %o5 <== NOT EXECUTED
20490f8: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
20490fc: 02 bf ff bf be 2048ff8 <msdos_dir_read+0x338> <== NOT EXECUTED
2049100: 80 a1 20 04 cmp %g4, 4 <== NOT EXECUTED
break;
switch (q)
2049104: 02 80 00 0d be 2049138 <msdos_dir_read+0x478> <== NOT EXECUTED
2049108: 80 a1 20 0a cmp %g4, 0xa <== NOT EXECUTED
204910c: 02 80 00 07 be 2049128 <msdos_dir_read+0x468> <== NOT EXECUTED
2049110: 80 a0 a0 0c cmp %g2, 0xc <== NOT EXECUTED
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
for (q = 0; q < MSDOS_LFN_LEN_PER_ENTRY; q++)
2049114: 14 bf ff b9 bg 2048ff8 <msdos_dir_read+0x338> <== NOT EXECUTED
2049118: 84 00 a0 01 inc %g2 <== NOT EXECUTED
break;
case 10:
p += 4;
break;
default:
p += 2;
204911c: a4 04 a0 02 add %l2, 2, %l2 <== NOT EXECUTED
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
2049120: 10 bf ff ef b 20490dc <msdos_dir_read+0x41c> <== NOT EXECUTED
2049124: 86 00 e0 01 inc %g3 <== NOT EXECUTED
{
case 4:
p += 5;
break;
case 10:
p += 4;
2049128: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
204912c: 84 00 a0 01 inc %g2 <== NOT EXECUTED
2049130: 10 bf ff eb b 20490dc <msdos_dir_read+0x41c> <== NOT EXECUTED
2049134: 86 00 e0 01 inc %g3 <== NOT EXECUTED
break;
switch (q)
{
case 4:
p += 5;
2049138: a4 04 a0 05 add %l2, 5, %l2 <== NOT EXECUTED
* fit in the directory entry name field.
*/
lfn_entries--;
p = entry + 1;
o = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;
204913c: 84 00 a0 01 inc %g2 <== NOT EXECUTED
2049140: 10 bf ff e7 b 20490dc <msdos_dir_read+0x41c> <== NOT EXECUTED
2049144: 86 00 e0 01 inc %g3 <== NOT EXECUTED
* RETURNS:
* the number of bytes read on success, or -1 if error occured (errno
* set apropriately).
*/
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
2049148: 82 10 20 00 clr %g1 <== NOT EXECUTED
/*
* copy base name to destination
*/
src_tmp = src;
len = i;
while (i-- > 0) {
204914c: 14 80 00 08 bg 204916c <msdos_dir_read+0x4ac> <== NOT EXECUTED
2049150: 84 07 be e4 add %fp, -284, %g2 <== NOT EXECUTED
*dst++ = tolower((unsigned char)(*src_tmp++));
}
/*
* find last non-blank character of extension
*/
for ((i = MSDOS_SHORT_EXT_LEN ,
2049154: 10 bf ff 81 b 2048f58 <msdos_dir_read+0x298> <== NOT EXECUTED
2049158: c2 4c a0 0a ldsb [ %l2 + 0xa ], %g1 <== NOT EXECUTED
* copy base name to destination
*/
src_tmp = src;
len = i;
while (i-- > 0) {
*dst++ = tolower((unsigned char)(*src_tmp++));
204915c: da 28 80 00 stb %o5, [ %g2 ] <== NOT EXECUTED
/*
* copy base name to destination
*/
src_tmp = src;
len = i;
while (i-- > 0) {
2049160: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
2049164: 02 bf ff 7c be 2048f54 <msdos_dir_read+0x294> <== NOT EXECUTED
2049168: 84 00 a0 01 inc %g2 <== NOT EXECUTED
*dst++ = tolower((unsigned char)(*src_tmp++));
204916c: c8 0c 80 01 ldub [ %l2 + %g1 ], %g4 <== NOT EXECUTED
2049170: d8 07 00 00 ld [ %i4 ], %o4 <== NOT EXECUTED
2049174: 9a 10 00 04 mov %g4, %o5 <== NOT EXECUTED
2049178: 88 03 00 04 add %o4, %g4, %g4 <== NOT EXECUTED
204917c: c8 09 20 01 ldub [ %g4 + 1 ], %g4 <== NOT EXECUTED
2049180: 88 09 20 03 and %g4, 3, %g4 <== NOT EXECUTED
2049184: 80 a1 20 01 cmp %g4, 1 <== NOT EXECUTED
2049188: 12 bf ff f5 bne 204915c <msdos_dir_read+0x49c> <== NOT EXECUTED
204918c: 82 00 60 01 inc %g1 <== NOT EXECUTED
2049190: 10 bf ff f3 b 204915c <msdos_dir_read+0x49c> <== NOT EXECUTED
2049194: 9a 03 60 20 add %o5, 0x20, %o5 <== NOT EXECUTED
2049198: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
/* inode number extracted, close fat-file */
rc = fat_file_close(iop->pathinfo.mt_entry, tmp_fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
204919c: d0 06 60 98 ld [ %i1 + 0x98 ], %o0 <== NOT EXECUTED
20491a0: 7f ff 11 6d call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20491a4: c2 27 be c0 st %g1, [ %fp + -320 ] <== NOT EXECUTED
return rc;
20491a8: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
j++;
}
rtems_semaphore_release(fs_info->vol_sema);
return cmpltd;
}
20491ac: 81 c7 e0 08 ret <== NOT EXECUTED
20491b0: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
* RETURNS:
* the number of bytes read on success, or -1 if error occured (errno
* set apropriately).
*/
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
20491b4: 82 10 00 1b mov %i3, %g1 <== NOT EXECUTED
break;
}
j++;
}
rtems_semaphore_release(fs_info->vol_sema);
20491b8: d0 06 60 98 ld [ %i1 + 0x98 ], %o0 <== NOT EXECUTED
20491bc: 7f ff 11 66 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20491c0: c2 27 be c0 st %g1, [ %fp + -320 ] <== NOT EXECUTED
return cmpltd;
20491c4: 10 bf ff b0 b 2049084 <msdos_dir_read+0x3c4> <== NOT EXECUTED
20491c8: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
/*
* extension is not empty
*/
if (i > 0) {
*dst++ = '.'; /* append dot */
len += i + 1; /* extension + dot */
20491cc: 86 00 e0 01 inc %g3 <== NOT EXECUTED
{};
/*
* extension is not empty
*/
if (i > 0) {
*dst++ = '.'; /* append dot */
20491d0: 88 10 20 2e mov 0x2e, %g4 <== NOT EXECUTED
len += i + 1; /* extension + dot */
20491d4: 86 00 c0 0b add %g3, %o3, %g3 <== NOT EXECUTED
{};
/*
* extension is not empty
*/
if (i > 0) {
*dst++ = '.'; /* append dot */
20491d8: c8 28 80 00 stb %g4, [ %g2 ] <== NOT EXECUTED
20491dc: 94 00 a0 01 add %g2, 1, %o2 <== NOT EXECUTED
* RETURNS:
* the number of bytes read on success, or -1 if error occured (errno
* set apropriately).
*/
ssize_t
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)
20491e0: 10 80 00 06 b 20491f8 <msdos_dir_read+0x538> <== NOT EXECUTED
20491e4: 82 10 20 00 clr %g1 <== NOT EXECUTED
if (i > 0) {
*dst++ = '.'; /* append dot */
len += i + 1; /* extension + dot */
src_tmp = src + MSDOS_SHORT_BASE_LEN;
while (i-- > 0) {
*dst++ = tolower((unsigned char)(*src_tmp++));
20491e8: 82 00 60 01 inc %g1 <== NOT EXECUTED
*/
if (i > 0) {
*dst++ = '.'; /* append dot */
len += i + 1; /* extension + dot */
src_tmp = src + MSDOS_SHORT_BASE_LEN;
while (i-- > 0) {
20491ec: 80 a0 40 0b cmp %g1, %o3 <== NOT EXECUTED
20491f0: 02 80 00 10 be 2049230 <msdos_dir_read+0x570> <== NOT EXECUTED
20491f4: c8 2b 60 01 stb %g4, [ %o5 + 1 ] <== NOT EXECUTED
*dst++ = tolower((unsigned char)(*src_tmp++));
20491f8: 88 04 80 01 add %l2, %g1, %g4 <== NOT EXECUTED
20491fc: d8 07 00 00 ld [ %i4 ], %o4 <== NOT EXECUTED
2049200: c8 09 20 08 ldub [ %g4 + 8 ], %g4 <== NOT EXECUTED
2049204: 98 03 00 04 add %o4, %g4, %o4 <== NOT EXECUTED
2049208: d8 0b 20 01 ldub [ %o4 + 1 ], %o4 <== NOT EXECUTED
204920c: 98 0b 20 03 and %o4, 3, %o4 <== NOT EXECUTED
2049210: 80 a3 20 01 cmp %o4, 1 <== NOT EXECUTED
2049214: 12 bf ff f5 bne 20491e8 <msdos_dir_read+0x528> <== NOT EXECUTED
2049218: 9a 00 80 01 add %g2, %g1, %o5 <== NOT EXECUTED
204921c: 88 01 20 20 add %g4, 0x20, %g4 <== NOT EXECUTED
2049220: 82 00 60 01 inc %g1 <== NOT EXECUTED
*/
if (i > 0) {
*dst++ = '.'; /* append dot */
len += i + 1; /* extension + dot */
src_tmp = src + MSDOS_SHORT_BASE_LEN;
while (i-- > 0) {
2049224: 80 a0 40 0b cmp %g1, %o3 <== NOT EXECUTED
2049228: 12 bf ff f4 bne 20491f8 <msdos_dir_read+0x538> <== NOT EXECUTED
204922c: c8 2b 60 01 stb %g4, [ %o5 + 1 ] <== NOT EXECUTED
2049230: 86 00 c0 01 add %g3, %g1, %g3 <== NOT EXECUTED
2049234: 10 bf ff 55 b 2048f88 <msdos_dir_read+0x2c8> <== NOT EXECUTED
2049238: 84 02 80 01 add %o2, %g1, %g2 <== NOT EXECUTED
*/
ret = fat_file_read(iop->pathinfo.mt_entry, fat_fd, (j * bts2rd),
bts2rd, fs_info->cl_buf);
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
rtems_semaphore_release(fs_info->vol_sema);
204923c: d0 06 60 98 ld [ %i1 + 0x98 ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
2049240: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
*/
ret = fat_file_read(iop->pathinfo.mt_entry, fat_fd, (j * bts2rd),
bts2rd, fs_info->cl_buf);
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
rtems_semaphore_release(fs_info->vol_sema);
2049244: 7f ff 11 44 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2049248: c2 27 be c0 st %g1, [ %fp + -320 ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
204924c: 40 00 04 8d call 204a480 <__errno> <== NOT EXECUTED
2049250: 01 00 00 00 nop <== NOT EXECUTED
2049254: 84 10 20 05 mov 5, %g2 ! 5 <PROM_START+0x5> <== NOT EXECUTED
2049258: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
204925c: 10 bf ff 8a b 2049084 <msdos_dir_read+0x3c4> <== NOT EXECUTED
2049260: c4 22 00 00 st %g2, [ %o0 ] <== NOT EXECUTED
}
for (i = 0; i < ret; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
2049264: 10 bf ff d5 b 20491b8 <msdos_dir_read+0x4f8> <== NOT EXECUTED
2049268: 82 10 20 00 clr %g1 <== NOT EXECUTED
fs_info->fat.vol.bpc;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
204926c: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
2049270: 40 00 04 84 call 204a480 <__errno> <== NOT EXECUTED
2049274: c2 27 be c0 st %g1, [ %fp + -320 ] <== NOT EXECUTED
2049278: 84 10 20 05 mov 5, %g2 <== NOT EXECUTED
204927c: c2 07 be c0 ld [ %fp + -320 ], %g1 <== NOT EXECUTED
2049280: 10 bf ff 81 b 2049084 <msdos_dir_read+0x3c4> <== NOT EXECUTED
2049284: c4 22 00 00 st %g2, [ %o0 ] <== NOT EXECUTED
02048b44 <msdos_dir_rmnod>:
* RC_OK on success, or -1 if error occured (errno set apropriately).
*/
int
msdos_dir_rmnod(rtems_filesystem_location_info_t *parent_pathloc,
rtems_filesystem_location_info_t *pathloc)
{
2048b44: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
2048b48: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = pathloc->node_access;
bool is_empty = false;
2048b4c: c0 2f bf ff clrb [ %fp + -1 ] <== NOT EXECUTED
msdos_dir_rmnod(rtems_filesystem_location_info_t *parent_pathloc,
rtems_filesystem_location_info_t *pathloc)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
2048b50: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = pathloc->node_access;
2048b54: e0 06 40 00 ld [ %i1 ], %l0 <== NOT EXECUTED
bool is_empty = false;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2048b58: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
2048b5c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2048b60: 7f ff 12 b6 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2048b64: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2048b68: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048b6c: 12 80 00 2e bne 2048c24 <msdos_dir_rmnod+0xe0> <== NOT EXECUTED
2048b70: 01 00 00 00 nop <== NOT EXECUTED
/*
* We deny attempts to delete open directory (if directory is current
* directory we assume it is open one)
*/
if (fat_fd->links_num > 1)
2048b74: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
2048b78: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2048b7c: 18 80 00 21 bgu 2048c00 <msdos_dir_rmnod+0xbc> <== NOT EXECUTED
2048b80: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
}
/*
* You cannot remove a node that still has children
*/
rc = msdos_dir_is_empty(pathloc->mt_entry, fat_fd, &is_empty);
2048b84: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
2048b88: 7f ff d2 66 call 203d520 <msdos_dir_is_empty> <== NOT EXECUTED
2048b8c: 94 07 bf ff add %fp, -1, %o2 <== NOT EXECUTED
if (rc != RC_OK)
2048b90: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2048b94: 12 80 00 17 bne 2048bf0 <msdos_dir_rmnod+0xac> <== NOT EXECUTED
2048b98: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
if (!is_empty)
2048b9c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2048ba0: 22 80 00 27 be,a 2048c3c <msdos_dir_rmnod+0xf8> <== NOT EXECUTED
2048ba4: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
}
/*
* You cannot remove the file system root node.
*/
if (pathloc->mt_entry->mt_fs_root.node_access == pathloc->node_access)
2048ba8: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
2048bac: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
2048bb0: c4 02 20 1c ld [ %o0 + 0x1c ], %g2 <== NOT EXECUTED
2048bb4: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2048bb8: 02 80 00 12 be 2048c00 <msdos_dir_rmnod+0xbc> <== NOT EXECUTED
2048bbc: 92 04 20 20 add %l0, 0x20, %o1 <== NOT EXECUTED
* You cannot remove a mountpoint.
* not used - mount() not implemenetd yet.
*/
/* mark file removed */
rc = msdos_set_first_char4file_name(pathloc->mt_entry, &fat_fd->dir_pos,
2048bc0: 7f ff d3 16 call 203d818 <msdos_set_first_char4file_name> <== NOT EXECUTED
2048bc4: 94 10 20 e5 mov 0xe5, %o2 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_EMPTY);
if (rc != RC_OK)
2048bc8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2048bcc: 12 80 00 09 bne 2048bf0 <msdos_dir_rmnod+0xac> <== NOT EXECUTED
2048bd0: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
fat_file_mark_removed(pathloc->mt_entry, fat_fd);
2048bd4: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
2048bd8: 7f ff 7e d0 call 2028718 <fat_file_mark_removed> <== NOT EXECUTED
2048bdc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
2048be0: 7f ff 12 dd call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048be4: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
2048be8: 81 c7 e0 08 ret <== NOT EXECUTED
2048bec: 81 e8 00 00 restore <== NOT EXECUTED
/* mark file removed */
rc = msdos_set_first_char4file_name(pathloc->mt_entry, &fat_fd->dir_pos,
MSDOS_THIS_DIR_ENTRY_EMPTY);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
2048bf0: 7f ff 12 d9 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048bf4: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
2048bf8: 81 c7 e0 08 ret <== NOT EXECUTED
2048bfc: 81 e8 00 00 restore <== NOT EXECUTED
/*
* You cannot remove the file system root node.
*/
if (pathloc->mt_entry->mt_fs_root.node_access == pathloc->node_access)
{
rtems_semaphore_release(fs_info->vol_sema);
2048c00: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
2048c04: 7f ff 12 d4 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048c08: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EBUSY);
2048c0c: 40 00 06 1d call 204a480 <__errno> <== NOT EXECUTED
2048c10: 01 00 00 00 nop <== NOT EXECUTED
2048c14: 82 10 20 10 mov 0x10, %g1 ! 10 <PROM_START+0x10> <== NOT EXECUTED
2048c18: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048c1c: 81 c7 e0 08 ret <== NOT EXECUTED
2048c20: 81 e8 00 00 restore <== NOT EXECUTED
bool is_empty = false;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2048c24: 40 00 06 17 call 204a480 <__errno> <== NOT EXECUTED
2048c28: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2048c2c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2048c30: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048c34: 81 c7 e0 08 ret <== NOT EXECUTED
2048c38: 81 e8 00 00 restore <== NOT EXECUTED
return rc;
}
if (!is_empty)
{
rtems_semaphore_release(fs_info->vol_sema);
2048c3c: 7f ff 12 c6 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048c40: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOTEMPTY);
2048c44: 40 00 06 0f call 204a480 <__errno> <== NOT EXECUTED
2048c48: 01 00 00 00 nop <== NOT EXECUTED
2048c4c: 82 10 20 5a mov 0x5a, %g1 ! 5a <PROM_START+0x5a> <== NOT EXECUTED
2048c50: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048c54: 81 c7 e0 08 ret <== NOT EXECUTED
2048c58: 81 e8 00 00 restore <== NOT EXECUTED
02048aa4 <msdos_dir_stat>:
int
msdos_dir_stat(
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
2048aa4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
2048aa8: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
2048aac: e2 06 00 00 ld [ %i0 ], %l1 <== NOT EXECUTED
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
2048ab0: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2048ab4: 92 10 20 00 clr %o1 <== NOT EXECUTED
2048ab8: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
2048abc: 7f ff 12 df call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2048ac0: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2048ac4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048ac8: 12 80 00 19 bne 2048b2c <msdos_dir_stat+0x88> <== NOT EXECUTED
2048acc: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
2048ad0: c2 04 60 0c ld [ %l1 + 0xc ], %g1 <== NOT EXECUTED
buf->st_mode = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
2048ad4: c4 14 00 00 lduh [ %l0 ], %g2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
2048ad8: c2 26 60 08 st %g1, [ %i1 + 8 ] <== NOT EXECUTED
buf->st_mode = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;
2048adc: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
2048ae0: 82 10 61 ff or %g1, 0x1ff, %g1 ! 41ff <PROM_START+0x41ff> <== NOT EXECUTED
2048ae4: c2 26 60 0c st %g1, [ %i1 + 0xc ] <== NOT EXECUTED
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
2048ae8: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 <== NOT EXECUTED
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
2048aec: c4 26 60 40 st %g2, [ %i1 + 0x40 ] <== NOT EXECUTED
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
buf->st_mode = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
2048af0: 85 30 60 09 srl %g1, 9, %g2 <== NOT EXECUTED
2048af4: c4 26 60 44 st %g2, [ %i1 + 0x44 ] <== NOT EXECUTED
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
2048af8: c8 04 60 40 ld [ %l1 + 0x40 ], %g4 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
2048afc: c4 1c 20 58 ldd [ %l0 + 0x58 ], %g2 <== NOT EXECUTED
buf->st_mode = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
2048b00: c8 26 60 30 st %g4, [ %i1 + 0x30 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
2048b04: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
2048b08: c4 3e 40 00 std %g2, [ %i1 ] <== NOT EXECUTED
buf->st_ino = fat_fd->ino;
buf->st_mode = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
2048b0c: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
2048b10: c0 26 60 1c clr [ %i1 + 0x1c ] <== NOT EXECUTED
buf->st_size = fat_fd->fat_file_size;
2048b14: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
2048b18: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
rtems_semaphore_release(fs_info->vol_sema);
2048b1c: 7f ff 13 0e call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048b20: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
}
2048b24: 81 c7 e0 08 ret <== NOT EXECUTED
2048b28: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2048b2c: 40 00 06 55 call 204a480 <__errno> <== NOT EXECUTED
2048b30: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2048b34: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2048b38: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048b3c: 81 c7 e0 08 ret <== NOT EXECUTED
2048b40: 81 e8 00 00 restore <== NOT EXECUTED
02048c5c <msdos_dir_sync>:
* RETURNS:
* RC_OK on success, or -1 if error occured (errno set apropriately).
*/
int
msdos_dir_sync(rtems_libio_t *iop)
{
2048c5c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2048c60: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
int
msdos_dir_sync(rtems_libio_t *iop)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
2048c64: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
2048c68: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
2048c6c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2048c70: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
2048c74: 7f ff 12 71 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2048c78: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2048c7c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2048c80: 12 80 00 0a bne 2048ca8 <msdos_dir_sync+0x4c> <== NOT EXECUTED
2048c84: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_datasync(iop->pathinfo.mt_entry, fat_fd);
2048c88: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
2048c8c: 7f ff 7e 58 call 20285ec <fat_file_datasync> <== NOT EXECUTED
2048c90: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2048c94: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
2048c98: 7f ff 12 af call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2048c9c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
2048ca0: 81 c7 e0 08 ret <== NOT EXECUTED
2048ca4: 81 e8 00 00 restore <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2048ca8: 40 00 05 f6 call 204a480 <__errno> <== NOT EXECUTED
2048cac: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2048cb0: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2048cb4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2048cb8: 81 c7 e0 08 ret <== NOT EXECUTED
2048cbc: 81 e8 00 00 restore <== NOT EXECUTED
0203bf38 <msdos_eval4make>:
msdos_eval4make(
const char *path,
rtems_filesystem_location_info_t *pathloc,
const char **name
)
{
203bf38: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203bf3c: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
int i = 0;
int token_len;
const char *token;
bool done = false;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203bf40: 92 10 20 00 clr %o1 <== NOT EXECUTED
const char **name
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203bf44: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
int i = 0;
int token_len;
const char *token;
bool done = false;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203bf48: 94 10 20 00 clr %o2 <== NOT EXECUTED
203bf4c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203bf50: 7f ff 45 ba call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203bf54: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203bf58: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bf5c: 12 80 00 ac bne 203c20c <msdos_eval4make+0x2d4> <== NOT EXECUTED
203bf60: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
if (!pathloc->node_access)
203bf64: d0 06 40 00 ld [ %i1 ], %o0 <== NOT EXECUTED
203bf68: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bf6c: 02 80 00 72 be 203c134 <msdos_eval4make+0x1fc> <== NOT EXECUTED
203bf70: 01 00 00 00 nop <== NOT EXECUTED
goto err;
}
fat_fd = pathloc->node_access;
rc = fat_file_reopen(fat_fd);
203bf74: 7f ff b1 35 call 2028448 <fat_file_reopen> <== NOT EXECUTED
203bf78: 01 00 00 00 nop <== NOT EXECUTED
if (rc != RC_OK)
203bf7c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203bf80: 12 80 00 22 bne 203c008 <msdos_eval4make+0xd0> <== NOT EXECUTED
203bf84: ba 10 00 18 mov %i0, %i5 <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203bf88: 2b 00 81 c3 sethi %hi(0x2070c00), %l5 <== NOT EXECUTED
}
fat_fd = pathloc->node_access;
rc = fat_file_reopen(fat_fd);
if (rc != RC_OK)
203bf8c: a4 10 20 00 clr %l2 <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203bf90: aa 15 62 24 or %l5, 0x224, %l5 <== NOT EXECUTED
203bf94: a8 07 bf f8 add %fp, -8, %l4 <== NOT EXECUTED
203bf98: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
if (rc != RC_OK)
goto err;
while (!done)
{
type = msdos_get_token(&path[i], strlen(&path[i]), &token, &token_len);
203bf9c: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
203bfa0: 40 00 54 f4 call 2051370 <strlen> <== NOT EXECUTED
203bfa4: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
203bfa8: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
203bfac: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
203bfb0: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203bfb4: 40 00 06 e5 call 203db48 <msdos_get_token> <== NOT EXECUTED
203bfb8: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
i += token_len;
203bfbc: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
if (rc != RC_OK)
goto err;
while (!done)
{
type = msdos_get_token(&path[i], strlen(&path[i]), &token, &token_len);
203bfc0: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
i += token_len;
fat_fd = pathloc->node_access;
switch (type)
203bfc4: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
goto err;
while (!done)
{
type = msdos_get_token(&path[i], strlen(&path[i]), &token, &token_len);
i += token_len;
203bfc8: a4 04 80 0a add %l2, %o2, %l2 <== NOT EXECUTED
fat_fd = pathloc->node_access;
switch (type)
203bfcc: 02 80 00 43 be 203c0d8 <msdos_eval4make+0x1a0> <== NOT EXECUTED
203bfd0: ee 06 40 00 ld [ %i1 ], %l7 <== NOT EXECUTED
203bfd4: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
203bfd8: 18 80 00 11 bgu 203c01c <msdos_eval4make+0xe4> <== NOT EXECUTED
203bfdc: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
203bfe0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bfe4: 32 bf ff ef bne,a 203bfa0 <msdos_eval4make+0x68> <== NOT EXECUTED
203bfe8: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
done = true;
}
break;
case MSDOS_NO_MORE_PATH:
errno = EEXIST;
203bfec: 40 00 39 25 call 204a480 <__errno> <== NOT EXECUTED
203bff0: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203bff4: 82 10 20 11 mov 0x11, %g1 <== NOT EXECUTED
203bff8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return RC_OK;
error:
fat_file_close(pathloc->mt_entry, fat_fd);
203bffc: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
203c000: 7f ff b3 f5 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203c004: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
err:
rtems_semaphore_release(fs_info->vol_sema);
203c008: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c00c: 7f ff 45 d2 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c010: b0 10 00 1d mov %i5, %i0 <== NOT EXECUTED
return rc;
}
203c014: 81 c7 e0 08 ret <== NOT EXECUTED
203c018: 81 e8 00 00 restore <== NOT EXECUTED
{
type = msdos_get_token(&path[i], strlen(&path[i]), &token, &token_len);
i += token_len;
fat_fd = pathloc->node_access;
switch (type)
203c01c: 02 80 00 09 be 203c040 <msdos_eval4make+0x108> <== NOT EXECUTED
203c020: 80 a2 20 04 cmp %o0, 4 <== NOT EXECUTED
203c024: 32 bf ff df bne,a 203bfa0 <msdos_eval4make+0x68> <== NOT EXECUTED
203c028: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
case MSDOS_CURRENT_DIR:
break;
case MSDOS_INVALID_TOKEN:
errno = ENAMETOOLONG;
203c02c: 40 00 39 15 call 204a480 <__errno> <== NOT EXECUTED
203c030: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203c034: 82 10 20 5b mov 0x5b, %g1 <== NOT EXECUTED
rc = -1;
goto error;
203c038: 10 bf ff f1 b 203bffc <msdos_eval4make+0xc4> <== NOT EXECUTED
203c03c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
case MSDOS_NAME:
/*
* Only a directory can be decended into.
*/
if (fat_fd->fat_file_type != FAT_DIRECTORY)
203c040: c2 05 e0 10 ld [ %l7 + 0x10 ], %g1 <== NOT EXECUTED
203c044: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203c048: 12 80 00 77 bne 203c224 <msdos_eval4make+0x2ec> <== NOT EXECUTED
203c04c: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
/*
* Otherwise find the token name in the present location and
* set the node access to the point we have found.
*/
rc = msdos_find_name(pathloc, token, token_len);
203c050: 40 00 08 7d call 203e244 <msdos_find_name> <== NOT EXECUTED
203c054: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
if (rc)
203c058: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c05c: 02 bf ff d1 be 203bfa0 <msdos_eval4make+0x68> <== NOT EXECUTED
203c060: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
{
if (rc != MSDOS_NAME_NOT_FOUND_ERR)
203c064: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
203c068: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203c06c: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
203c070: 12 80 00 15 bne 203c0c4 <msdos_eval4make+0x18c> <== NOT EXECUTED
203c074: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
break;
}
}
*name = &path[i - token_len];
203c078: 82 24 80 01 sub %l2, %g1, %g1 <== NOT EXECUTED
203c07c: 82 04 40 01 add %l1, %g1, %g1 <== NOT EXECUTED
203c080: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
/*
* We have evaluated the path as far as we can.
* Verify there is not any invalid stuff at the end of the name.
*/
for( ; path[i] != '\0'; i++)
203c084: d0 0c 40 12 ldub [ %l1 + %l2 ], %o0 <== NOT EXECUTED
203c088: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
203c08c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c090: 02 80 00 52 be 203c1d8 <msdos_eval4make+0x2a0> <== NOT EXECUTED
203c094: 84 04 40 12 add %l1, %l2, %g2 <== NOT EXECUTED
203c098: 10 80 00 06 b 203c0b0 <msdos_eval4make+0x178> <== NOT EXECUTED
203c09c: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
203c0a0: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
203c0a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c0a8: 02 80 00 4c be 203c1d8 <msdos_eval4make+0x2a0> <== NOT EXECUTED
203c0ac: a2 04 60 01 inc %l1 <== NOT EXECUTED
{
if (!msdos_is_separator(path[i]))
203c0b0: 7f ff 39 31 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
203c0b4: 91 3a 20 18 sra %o0, 0x18, %o0 <== NOT EXECUTED
203c0b8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c0bc: 32 bf ff f9 bne,a 203c0a0 <msdos_eval4make+0x168> <== NOT EXECUTED
203c0c0: d0 0c 60 01 ldub [ %l1 + 1 ], %o0 <== NOT EXECUTED
{
errno = ENOENT;
203c0c4: 40 00 38 ef call 204a480 <__errno> <== NOT EXECUTED
203c0c8: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203c0cc: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
rc = -1;
goto error;
203c0d0: 10 bf ff cb b 203bffc <msdos_eval4make+0xc4> <== NOT EXECUTED
203c0d4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
{
case MSDOS_UP_DIR:
/*
* Only a directory can be decended into.
*/
if (fat_fd->fat_file_type != FAT_DIRECTORY)
203c0d8: c2 05 e0 10 ld [ %l7 + 0x10 ], %g1 <== NOT EXECUTED
203c0dc: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203c0e0: 12 80 00 51 bne 203c224 <msdos_eval4make+0x2ec> <== NOT EXECUTED
203c0e4: 01 00 00 00 nop <== NOT EXECUTED
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
pathloc->mt_entry->mt_fs_root.node_access)
203c0e8: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
}
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
203c0ec: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 <== NOT EXECUTED
203c0f0: 80 a5 c0 02 cmp %l7, %g2 <== NOT EXECUTED
203c0f4: 02 80 00 19 be 203c158 <msdos_eval4make+0x220> <== NOT EXECUTED
203c0f8: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
pathloc, name);
}
}
else
{
rc = msdos_find_name(pathloc, token, token_len);
203c0fc: 40 00 08 52 call 203e244 <msdos_find_name> <== NOT EXECUTED
203c100: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203c104: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203c108: 22 bf ff a6 be,a 203bfa0 <msdos_eval4make+0x68> <== NOT EXECUTED
203c10c: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
{
if (rc == MSDOS_NAME_NOT_FOUND_ERR)
203c110: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
203c114: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203c118: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203c11c: 32 bf ff b9 bne,a 203c000 <msdos_eval4make+0xc8> <== NOT EXECUTED
203c120: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
{
errno = ENOENT;
203c124: 40 00 38 d7 call 204a480 <__errno> <== NOT EXECUTED
203c128: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203c12c: 10 bf ff b4 b 203bffc <msdos_eval4make+0xc4> <== NOT EXECUTED
203c130: ec 22 00 00 st %l6, [ %o0 ] <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
if (!pathloc->node_access)
{
errno = ENOENT;
203c134: 40 00 38 d3 call 204a480 <__errno> <== NOT EXECUTED
203c138: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203c13c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
203c140: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
error:
fat_file_close(pathloc->mt_entry, fat_fd);
err:
rtems_semaphore_release(fs_info->vol_sema);
203c144: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c148: 7f ff 45 83 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c14c: b0 10 00 1d mov %i5, %i0 <== NOT EXECUTED
return rc;
}
203c150: 81 c7 e0 08 ret <== NOT EXECUTED
203c154: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203c158: c4 05 40 00 ld [ %l5 ], %g2 <== NOT EXECUTED
203c15c: c4 00 a0 18 ld [ %g2 + 0x18 ], %g2 <== NOT EXECUTED
203c160: 80 a5 c0 02 cmp %l7, %g2 <== NOT EXECUTED
203c164: 02 bf ff 8f be 203bfa0 <msdos_eval4make+0x68> <== NOT EXECUTED
203c168: ac 04 40 12 add %l1, %l2, %l6 <== NOT EXECUTED
{
break; /* Throw out the .. in this case */
}
else
{
newloc = pathloc->mt_entry->mt_point_node;
203c16c: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
203c170: d0 00 60 18 ld [ %g1 + 0x18 ], %o0 <== NOT EXECUTED
203c174: c8 00 60 14 ld [ %g1 + 0x14 ], %g4 <== NOT EXECUTED
203c178: c6 00 60 10 ld [ %g1 + 0x10 ], %g3 <== NOT EXECUTED
203c17c: c2 00 60 0c ld [ %g1 + 0xc ], %g1 <== NOT EXECUTED
*pathloc = newloc;
203c180: c8 26 60 0c st %g4, [ %i1 + 0xc ] <== NOT EXECUTED
203c184: c6 26 60 08 st %g3, [ %i1 + 8 ] <== NOT EXECUTED
203c188: c2 26 60 04 st %g1, [ %i1 + 4 ] <== NOT EXECUTED
203c18c: c4 26 40 00 st %g2, [ %i1 ] <== NOT EXECUTED
203c190: d0 26 60 10 st %o0, [ %i1 + 0x10 ] <== NOT EXECUTED
rc = fat_file_close(pathloc->mt_entry, fat_fd);
203c194: 7f ff b3 90 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203c198: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c19c: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203c1a0: 32 bf ff 9b bne,a 203c00c <msdos_eval4make+0xd4> <== NOT EXECUTED
203c1a4: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
goto err;
rtems_semaphore_release(fs_info->vol_sema);
203c1a8: 7f ff 45 6b call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c1ac: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return (*pathloc->ops->evalformake_h)(&path[i-token_len],
203c1b0: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
203c1b4: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
203c1b8: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
203c1bc: 90 24 80 08 sub %l2, %o0, %o0 <== NOT EXECUTED
203c1c0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203c1c4: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
203c1c8: 9f c0 40 00 call %g1 <== NOT EXECUTED
203c1cc: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
203c1d0: 81 c7 e0 08 ret <== NOT EXECUTED
203c1d4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rc = -1;
goto error;
}
}
fat_fd = pathloc->node_access;
203c1d8: ee 06 40 00 ld [ %i1 ], %l7 <== NOT EXECUTED
if (fat_fd->fat_file_type != FAT_DIRECTORY)
203c1dc: c2 05 e0 10 ld [ %l7 + 0x10 ], %g1 <== NOT EXECUTED
203c1e0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203c1e4: 12 80 00 10 bne 203c224 <msdos_eval4make+0x2ec> <== NOT EXECUTED
203c1e8: 01 00 00 00 nop <== NOT EXECUTED
{
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
fat_file_fd_t *fat_fd = loc->node_access;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
loc->handlers = fs_info->directory_handlers;
203c1ec: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
goto error;
}
msdos_set_handlers(pathloc);
rtems_semaphore_release(fs_info->vol_sema);
203c1f0: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
{
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
fat_file_fd_t *fat_fd = loc->node_access;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
loc->handlers = fs_info->directory_handlers;
203c1f4: c2 00 60 34 ld [ %g1 + 0x34 ], %g1 <== NOT EXECUTED
203c1f8: c2 00 60 90 ld [ %g1 + 0x90 ], %g1 <== NOT EXECUTED
goto error;
}
msdos_set_handlers(pathloc);
rtems_semaphore_release(fs_info->vol_sema);
203c1fc: 7f ff 45 56 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c200: c2 26 60 08 st %g1, [ %i1 + 8 ] <== NOT EXECUTED
return RC_OK;
203c204: 81 c7 e0 08 ret <== NOT EXECUTED
203c208: 81 e8 00 00 restore <== NOT EXECUTED
bool done = false;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c20c: 40 00 38 9d call 204a480 <__errno> <== NOT EXECUTED
203c210: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c214: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c218: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c21c: 81 c7 e0 08 ret <== NOT EXECUTED
203c220: 81 e8 00 00 restore <== NOT EXECUTED
fat_fd = pathloc->node_access;
if (fat_fd->fat_file_type != FAT_DIRECTORY)
{
errno = ENOTDIR;
203c224: 40 00 38 97 call 204a480 <__errno> <== NOT EXECUTED
203c228: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203c22c: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED
rc = -1;
goto error;
203c230: 10 bf ff 73 b 203bffc <msdos_eval4make+0xc4> <== NOT EXECUTED
203c234: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
0203bc8c <msdos_eval_path>:
const char *pathname,
size_t pathnamelen,
int flags,
rtems_filesystem_location_info_t *pathloc
)
{
203bc8c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203bc90: c2 06 e0 10 ld [ %i3 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = NULL;
rtems_filesystem_location_info_t newloc;
int i = 0;
int token_len = 0;
203bc94: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_filesystem_location_info_t *pathloc
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203bc98: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
int i = 0;
int token_len = 0;
msdos_token_types_t type = MSDOS_CURRENT_DIR;
const char *token;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203bc9c: 92 10 20 00 clr %o1 <== NOT EXECUTED
203bca0: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203bca4: 94 10 20 00 clr %o2 <== NOT EXECUTED
203bca8: 7f ff 46 64 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203bcac: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203bcb0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bcb4: 12 80 00 93 bne 203bf00 <msdos_eval_path+0x274> <== NOT EXECUTED
203bcb8: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
if (!pathloc->node_access)
203bcbc: d0 06 c0 00 ld [ %i3 ], %o0 <== NOT EXECUTED
203bcc0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bcc4: 02 80 00 65 be 203be58 <msdos_eval_path+0x1cc> <== NOT EXECUTED
203bcc8: 01 00 00 00 nop <== NOT EXECUTED
goto err;
}
fat_fd = pathloc->node_access;
rc = fat_file_reopen(fat_fd);
203bccc: 7f ff b1 df call 2028448 <fat_file_reopen> <== NOT EXECUTED
203bcd0: 01 00 00 00 nop <== NOT EXECUTED
if (rc != RC_OK)
203bcd4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203bcd8: 12 80 00 31 bne 203bd9c <msdos_eval_path+0x110> <== NOT EXECUTED
203bcdc: ba 10 00 18 mov %i0, %i5 <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203bce0: 2b 00 81 c3 sethi %hi(0x2070c00), %l5 <== NOT EXECUTED
}
fat_fd = pathloc->node_access;
rc = fat_file_reopen(fat_fd);
if (rc != RC_OK)
203bce4: a4 10 20 00 clr %l2 <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203bce8: aa 15 62 24 or %l5, 0x224, %l5 <== NOT EXECUTED
203bcec: a8 07 bf f8 add %fp, -8, %l4 <== NOT EXECUTED
203bcf0: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
if (rc != RC_OK)
goto err;
while ((type != MSDOS_NO_MORE_PATH) && (type != MSDOS_INVALID_TOKEN))
{
type = msdos_get_token(&pathname[i], pathnamelen, &token, &token_len);
203bcf4: 90 04 40 12 add %l1, %l2, %o0 <== NOT EXECUTED
203bcf8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203bcfc: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
203bd00: 40 00 07 92 call 203db48 <msdos_get_token> <== NOT EXECUTED
203bd04: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
pathnamelen -= token_len;
203bd08: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
if (rc != RC_OK)
goto err;
while ((type != MSDOS_NO_MORE_PATH) && (type != MSDOS_INVALID_TOKEN))
{
type = msdos_get_token(&pathname[i], pathnamelen, &token, &token_len);
203bd0c: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
pathnamelen -= token_len;
i += token_len;
fat_fd = pathloc->node_access;
switch (type)
203bd10: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
goto err;
while ((type != MSDOS_NO_MORE_PATH) && (type != MSDOS_INVALID_TOKEN))
{
type = msdos_get_token(&pathname[i], pathnamelen, &token, &token_len);
pathnamelen -= token_len;
203bd14: b2 26 40 0a sub %i1, %o2, %i1 <== NOT EXECUTED
i += token_len;
203bd18: a4 04 80 0a add %l2, %o2, %l2 <== NOT EXECUTED
fat_fd = pathloc->node_access;
switch (type)
203bd1c: 02 80 00 25 be 203bdb0 <msdos_eval_path+0x124> <== NOT EXECUTED
203bd20: ee 06 c0 00 ld [ %i3 ], %l7 <== NOT EXECUTED
203bd24: 80 a2 20 04 cmp %o0, 4 <== NOT EXECUTED
203bd28: 02 80 00 16 be 203bd80 <msdos_eval_path+0xf4> <== NOT EXECUTED
203bd2c: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
203bd30: 02 80 00 33 be 203bdfc <msdos_eval_path+0x170> <== NOT EXECUTED
203bd34: 82 1a 20 04 xor %o0, 4, %g1 <== NOT EXECUTED
break;
case MSDOS_INVALID_TOKEN:
errno = ENAMETOOLONG;
rc = -1;
goto error;
203bd38: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
203bd3c: 82 40 20 00 addx %g0, 0, %g1 <== NOT EXECUTED
rc = fat_file_reopen(fat_fd);
if (rc != RC_OK)
goto err;
while ((type != MSDOS_NO_MORE_PATH) && (type != MSDOS_INVALID_TOKEN))
203bd40: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203bd44: 02 80 00 04 be 203bd54 <msdos_eval_path+0xc8> <== NOT EXECUTED
203bd48: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203bd4c: 12 bf ff eb bne 203bcf8 <msdos_eval_path+0x6c> <== NOT EXECUTED
203bd50: 90 04 40 12 add %l1, %l2, %o0 <== NOT EXECUTED
msdos_set_handlers(rtems_filesystem_location_info_t *loc)
{
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
fat_file_fd_t *fat_fd = loc->node_access;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
203bd54: c4 05 e0 10 ld [ %l7 + 0x10 ], %g2 <== NOT EXECUTED
* None
*/
static void
msdos_set_handlers(rtems_filesystem_location_info_t *loc)
{
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
203bd58: c2 06 e0 10 ld [ %i3 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
203bd5c: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
203bd60: 02 80 00 73 be 203bf2c <msdos_eval_path+0x2a0> <== NOT EXECUTED
203bd64: c2 00 60 34 ld [ %g1 + 0x34 ], %g1 <== NOT EXECUTED
loc->handlers = fs_info->directory_handlers;
else
loc->handlers = fs_info->file_handlers;
203bd68: c2 00 60 94 ld [ %g1 + 0x94 ], %g1 <== NOT EXECUTED
203bd6c: c2 26 e0 08 st %g1, [ %i3 + 8 ] <== NOT EXECUTED
*/
fat_fd = pathloc->node_access;
msdos_set_handlers(pathloc);
rtems_semaphore_release(fs_info->vol_sema);
203bd70: 7f ff 46 79 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203bd74: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return RC_OK;
203bd78: 81 c7 e0 08 ret <== NOT EXECUTED
203bd7c: 81 e8 00 00 restore <== NOT EXECUTED
case MSDOS_NO_MORE_PATH:
case MSDOS_CURRENT_DIR:
break;
case MSDOS_INVALID_TOKEN:
errno = ENAMETOOLONG;
203bd80: 40 00 39 c0 call 204a480 <__errno> <== NOT EXECUTED
203bd84: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203bd88: 82 10 20 5b mov 0x5b, %g1 <== NOT EXECUTED
203bd8c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return RC_OK;
error:
fat_file_close(pathloc->mt_entry, fat_fd);
203bd90: d0 06 e0 10 ld [ %i3 + 0x10 ], %o0 <== NOT EXECUTED
203bd94: 7f ff b4 90 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203bd98: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
err:
rtems_semaphore_release(fs_info->vol_sema);
203bd9c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203bda0: 7f ff 46 6d call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203bda4: b0 10 00 1d mov %i5, %i0 <== NOT EXECUTED
return rc;
}
203bda8: 81 c7 e0 08 ret <== NOT EXECUTED
203bdac: 81 e8 00 00 restore <== NOT EXECUTED
case MSDOS_NAME:
/*
* Only a directory can be decended into.
*/
if (fat_fd->fat_file_type != FAT_DIRECTORY)
203bdb0: c2 05 e0 10 ld [ %l7 + 0x10 ], %g1 <== NOT EXECUTED
203bdb4: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203bdb8: 12 80 00 58 bne 203bf18 <msdos_eval_path+0x28c> <== NOT EXECUTED
203bdbc: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
/*
* Otherwise find the token name in the present location and
* set the node access to the point we have found.
*/
rc = msdos_find_name(pathloc, token, token_len);
203bdc0: 40 00 09 21 call 203e244 <msdos_find_name> <== NOT EXECUTED
203bdc4: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203bdc8: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203bdcc: 02 bf ff cb be 203bcf8 <msdos_eval_path+0x6c> <== NOT EXECUTED
203bdd0: 90 04 40 12 add %l1, %l2, %o0 <== NOT EXECUTED
{
if (rc == MSDOS_NAME_NOT_FOUND_ERR)
203bdd4: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
203bdd8: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203bddc: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203bde0: 32 bf ff ed bne,a 203bd94 <msdos_eval_path+0x108> <== NOT EXECUTED
203bde4: d0 06 e0 10 ld [ %i3 + 0x10 ], %o0 <== NOT EXECUTED
{
errno = ENOENT;
203bde8: 40 00 39 a6 call 204a480 <__errno> <== NOT EXECUTED
203bdec: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203bdf0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
203bdf4: 10 bf ff e7 b 203bd90 <msdos_eval_path+0x104> <== NOT EXECUTED
203bdf8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
{
case MSDOS_UP_DIR:
/*
* Only a directory can be decended into.
*/
if (fat_fd->fat_file_type != FAT_DIRECTORY)
203bdfc: c2 05 e0 10 ld [ %l7 + 0x10 ], %g1 <== NOT EXECUTED
203be00: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203be04: 12 80 00 45 bne 203bf18 <msdos_eval_path+0x28c> <== NOT EXECUTED
203be08: 01 00 00 00 nop <== NOT EXECUTED
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
pathloc->mt_entry->mt_fs_root.node_access)
203be0c: c2 06 e0 10 ld [ %i3 + 0x10 ], %g1 <== NOT EXECUTED
}
/*
* Am I at the root of this mounted filesystem?
*/
if (pathloc->node_access ==
203be10: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 <== NOT EXECUTED
203be14: 80 a5 c0 02 cmp %l7, %g2 <== NOT EXECUTED
203be18: 02 80 00 19 be 203be7c <msdos_eval_path+0x1f0> <== NOT EXECUTED
203be1c: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
flags, pathloc);
}
}
else
{
rc = msdos_find_name(pathloc, token, token_len);
203be20: 40 00 09 09 call 203e244 <msdos_find_name> <== NOT EXECUTED
203be24: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203be28: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203be2c: 02 bf ff b3 be 203bcf8 <msdos_eval_path+0x6c> <== NOT EXECUTED
203be30: 90 04 40 12 add %l1, %l2, %o0 <== NOT EXECUTED
{
if (rc == MSDOS_NAME_NOT_FOUND_ERR)
203be34: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
203be38: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203be3c: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203be40: 32 bf ff d5 bne,a 203bd94 <msdos_eval_path+0x108> <== NOT EXECUTED
203be44: d0 06 e0 10 ld [ %i3 + 0x10 ], %o0 <== NOT EXECUTED
{
errno = ENOENT;
203be48: 40 00 39 8e call 204a480 <__errno> <== NOT EXECUTED
203be4c: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203be50: 10 bf ff d0 b 203bd90 <msdos_eval_path+0x104> <== NOT EXECUTED
203be54: ec 22 00 00 st %l6, [ %o0 ] <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
if (!pathloc->node_access)
{
errno = ENOENT;
203be58: 40 00 39 8a call 204a480 <__errno> <== NOT EXECUTED
203be5c: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203be60: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
203be64: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
error:
fat_file_close(pathloc->mt_entry, fat_fd);
err:
rtems_semaphore_release(fs_info->vol_sema);
203be68: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203be6c: 7f ff 46 3a call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203be70: b0 10 00 1d mov %i5, %i0 <== NOT EXECUTED
return rc;
}
203be74: 81 c7 e0 08 ret <== NOT EXECUTED
203be78: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Am I at the root of all filesystems?
* XXX: MSDOS is not supposed to be base fs.
*/
if (pathloc->node_access ==
rtems_filesystem_root.node_access)
203be7c: c4 05 40 00 ld [ %l5 ], %g2 <== NOT EXECUTED
203be80: c4 00 a0 18 ld [ %g2 + 0x18 ], %g2 <== NOT EXECUTED
203be84: 80 a5 c0 02 cmp %l7, %g2 <== NOT EXECUTED
203be88: 02 bf ff 9c be 203bcf8 <msdos_eval_path+0x6c> <== NOT EXECUTED
203be8c: 90 04 40 12 add %l1, %l2, %o0 <== NOT EXECUTED
{
break; /* Throw out the .. in this case */
}
else
{
newloc = pathloc->mt_entry->mt_point_node;
203be90: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
203be94: d0 00 60 18 ld [ %g1 + 0x18 ], %o0 <== NOT EXECUTED
203be98: c8 00 60 14 ld [ %g1 + 0x14 ], %g4 <== NOT EXECUTED
203be9c: c6 00 60 10 ld [ %g1 + 0x10 ], %g3 <== NOT EXECUTED
203bea0: c2 00 60 0c ld [ %g1 + 0xc ], %g1 <== NOT EXECUTED
*pathloc = newloc;
203bea4: c8 26 e0 0c st %g4, [ %i3 + 0xc ] <== NOT EXECUTED
203bea8: c6 26 e0 08 st %g3, [ %i3 + 8 ] <== NOT EXECUTED
203beac: c2 26 e0 04 st %g1, [ %i3 + 4 ] <== NOT EXECUTED
203beb0: c4 26 c0 00 st %g2, [ %i3 ] <== NOT EXECUTED
203beb4: d0 26 e0 10 st %o0, [ %i3 + 0x10 ] <== NOT EXECUTED
rc = fat_file_close(pathloc->mt_entry, fat_fd);
203beb8: 7f ff b4 47 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203bebc: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203bec0: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
203bec4: 32 bf ff b7 bne,a 203bda0 <msdos_eval_path+0x114> <== NOT EXECUTED
203bec8: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
goto err;
rtems_semaphore_release(fs_info->vol_sema);
203becc: 7f ff 46 22 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203bed0: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)(&(pathname[i-token_len]),
203bed4: c2 06 e0 0c ld [ %i3 + 0xc ], %g1 <== NOT EXECUTED
203bed8: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
203bedc: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
203bee0: 92 06 40 02 add %i1, %g2, %o1 <== NOT EXECUTED
203bee4: 84 24 80 02 sub %l2, %g2, %g2 <== NOT EXECUTED
203bee8: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
203beec: 90 04 40 02 add %l1, %g2, %o0 <== NOT EXECUTED
203bef0: 9f c0 40 00 call %g1 <== NOT EXECUTED
203bef4: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
203bef8: 81 c7 e0 08 ret <== NOT EXECUTED
203befc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
const char *token;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203bf00: 40 00 39 60 call 204a480 <__errno> <== NOT EXECUTED
203bf04: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203bf08: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203bf0c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203bf10: 81 c7 e0 08 ret <== NOT EXECUTED
203bf14: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Only a directory can be decended into.
*/
if (fat_fd->fat_file_type != FAT_DIRECTORY)
{
errno = ENOTSUP;
203bf18: 40 00 39 5a call 204a480 <__errno> <== NOT EXECUTED
203bf1c: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203bf20: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
rc = -1;
goto error;
203bf24: 10 bf ff 9b b 203bd90 <msdos_eval_path+0x104> <== NOT EXECUTED
203bf28: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
{
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
fat_file_fd_t *fat_fd = loc->node_access;
if (fat_fd->fat_file_type == FAT_DIRECTORY)
loc->handlers = fs_info->directory_handlers;
203bf2c: c2 00 60 90 ld [ %g1 + 0x90 ], %g1 <== NOT EXECUTED
203bf30: 10 bf ff 90 b 203bd70 <msdos_eval_path+0xe4> <== NOT EXECUTED
203bf34: c2 26 e0 08 st %g1, [ %i3 + 8 ] <== NOT EXECUTED
0203c240 <msdos_file_chmod>:
int
msdos_file_chmod(rtems_filesystem_location_info_t *pathloc,
mode_t mode)
{
return RC_OK;
}
203c240: 81 c3 e0 08 retl <== NOT EXECUTED
203c244: 90 10 20 00 clr %o0 <== NOT EXECUTED
0203c79c <msdos_file_close>:
* RC_OK, if file closed successfully, or -1 if error occured (errno set
* appropriately)
*/
int
msdos_file_close(rtems_libio_t *iop)
{
203c79c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c7a0: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c7a4: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
int
msdos_file_close(rtems_libio_t *iop)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c7a8: e4 00 60 34 ld [ %g1 + 0x34 ], %l2 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c7ac: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c7b0: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
203c7b4: 94 10 20 00 clr %o2 <== NOT EXECUTED
203c7b8: 7f ff 43 a0 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c7bc: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c7c0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c7c4: 12 80 00 24 bne 203c854 <msdos_file_close+0xb8> <== NOT EXECUTED
203c7c8: 01 00 00 00 nop <== NOT EXECUTED
/*
* if fat-file descriptor is not marked as "removed", synchronize
* size, first cluster number, write time and date fields of the file
*/
if (!FAT_FILE_IS_REMOVED(fat_fd))
203c7cc: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1 <== NOT EXECUTED
203c7d0: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
203c7d4: 32 80 00 15 bne,a 203c828 <msdos_file_close+0x8c> <== NOT EXECUTED
203c7d8: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
{
rc = msdos_set_first_cluster_num(iop->pathinfo.mt_entry, fat_fd);
203c7dc: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c7e0: 40 00 03 d6 call 203d738 <msdos_set_first_cluster_num> <== NOT EXECUTED
203c7e4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c7e8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c7ec: 12 80 00 16 bne 203c844 <msdos_file_close+0xa8> <== NOT EXECUTED
203c7f0: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
rc = msdos_set_file_size(iop->pathinfo.mt_entry, fat_fd);
203c7f4: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c7f8: 40 00 03 a6 call 203d690 <msdos_set_file_size> <== NOT EXECUTED
203c7fc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c800: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c804: 12 80 00 10 bne 203c844 <msdos_file_close+0xa8> <== NOT EXECUTED
203c808: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
rc = msdos_set_dir_wrt_time_and_date(iop->pathinfo.mt_entry, fat_fd);
203c80c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c810: 40 00 04 74 call 203d9e0 <msdos_set_dir_wrt_time_and_date><== NOT EXECUTED
203c814: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c818: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c81c: 12 80 00 0a bne 203c844 <msdos_file_close+0xa8> <== NOT EXECUTED
203c820: 01 00 00 00 nop <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
}
rc = fat_file_close(iop->pathinfo.mt_entry, fat_fd);
203c824: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c828: 7f ff b1 eb call 2028fd4 <fat_file_close> <== NOT EXECUTED
203c82c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203c830: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c834: 7f ff 43 c8 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c838: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
203c83c: 81 c7 e0 08 ret <== NOT EXECUTED
203c840: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = msdos_set_dir_wrt_time_and_date(iop->pathinfo.mt_entry, fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c844: 7f ff 43 c4 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c848: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c84c: 81 c7 e0 08 ret <== NOT EXECUTED
203c850: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c854: 40 00 37 0b call 204a480 <__errno> <== NOT EXECUTED
203c858: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c85c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c860: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c864: 81 c7 e0 08 ret <== NOT EXECUTED
203c868: 81 e8 00 00 restore <== NOT EXECUTED
0203c370 <msdos_file_datasync>:
* RETURNS:
* RC_OK on success, or -1 if error occured (errno set appropriately)
*/
int
msdos_file_datasync(rtems_libio_t *iop)
{
203c370: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c374: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
int
msdos_file_datasync(rtems_libio_t *iop)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
203c378: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c37c: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c380: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c384: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c388: 7f ff 44 ac call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c38c: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c390: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c394: 12 80 00 0a bne 203c3bc <msdos_file_datasync+0x4c> <== NOT EXECUTED
203c398: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
/* synchronize file data */
rc = fat_file_datasync(iop->pathinfo.mt_entry, fat_fd);
203c39c: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c3a0: 7f ff b0 93 call 20285ec <fat_file_datasync> <== NOT EXECUTED
203c3a4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c3a8: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c3ac: 7f ff 44 ea call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c3b0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
}
203c3b4: 81 c7 e0 08 ret <== NOT EXECUTED
203c3b8: 81 e8 00 00 restore <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c3bc: 40 00 38 31 call 204a480 <__errno> <== NOT EXECUTED
203c3c0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c3c4: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c3c8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c3cc: 81 c7 e0 08 ret <== NOT EXECUTED
203c3d0: 81 e8 00 00 restore <== NOT EXECUTED
0203c4b0 <msdos_file_ftruncate>:
* RETURNS:
* RC_OK on success, or -1 if error occured (errno set appropriately).
*/
int
msdos_file_ftruncate(rtems_libio_t *iop, rtems_off64_t length)
{
203c4b0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c4b4: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c4b8: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
int
msdos_file_ftruncate(rtems_libio_t *iop, rtems_off64_t length)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c4bc: e4 00 60 34 ld [ %g1 + 0x34 ], %l2 <== NOT EXECUTED
* RETURNS:
* RC_OK on success, or -1 if error occured (errno set appropriately).
*/
int
msdos_file_ftruncate(rtems_libio_t *iop, rtems_off64_t length)
{
203c4c0: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
fat_file_fd_t *fat_fd = iop->file_info;
if (length >= fat_fd->fat_file_size)
203c4c4: 82 10 20 00 clr %g1 <== NOT EXECUTED
203c4c8: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
203c4cc: 14 80 00 09 bg 203c4f0 <msdos_file_ftruncate+0x40> <== NOT EXECUTED
203c4d0: c4 04 60 18 ld [ %l1 + 0x18 ], %g2 <== NOT EXECUTED
203c4d4: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
203c4d8: 02 80 00 04 be 203c4e8 <msdos_file_ftruncate+0x38> <== NOT EXECUTED
203c4dc: 80 a0 80 1a cmp %g2, %i2 <== NOT EXECUTED
203c4e0: 81 c7 e0 08 ret <== NOT EXECUTED
203c4e4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
203c4e8: 08 bf ff fe bleu 203c4e0 <msdos_file_ftruncate+0x30> <== NOT EXECUTED
203c4ec: 01 00 00 00 nop <== NOT EXECUTED
return RC_OK;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c4f0: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
203c4f4: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c4f8: 7f ff 44 50 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c4fc: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c500: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c504: 12 80 00 1b bne 203c570 <msdos_file_ftruncate+0xc0> <== NOT EXECUTED
203c508: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_truncate(iop->pathinfo.mt_entry, fat_fd, length);
203c50c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c510: 7f ff b0 cc call 2028840 <fat_file_truncate> <== NOT EXECUTED
203c514: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (rc != RC_OK)
203c518: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c51c: 12 80 00 11 bne 203c560 <msdos_file_ftruncate+0xb0> <== NOT EXECUTED
203c520: 80 a6 00 19 cmp %i0, %i1 <== NOT EXECUTED
/*
* fat_file_truncate do nothing if new length >= fat-file size, so update
* file size only if length < fat-file size
*/
if (length < fat_fd->fat_file_size)
203c524: 04 80 00 09 ble 203c548 <msdos_file_ftruncate+0x98> <== NOT EXECUTED
203c528: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 <== NOT EXECUTED
iop->size = fat_fd->fat_file_size = length;
203c52c: f4 24 20 0c st %i2, [ %l0 + 0xc ] <== NOT EXECUTED
203c530: f4 24 60 18 st %i2, [ %l1 + 0x18 ] <== NOT EXECUTED
203c534: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c538: 7f ff 44 87 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c53c: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
return RC_OK;
}
203c540: 81 c7 e0 08 ret <== NOT EXECUTED
203c544: 81 e8 00 00 restore <== NOT EXECUTED
/*
* fat_file_truncate do nothing if new length >= fat-file size, so update
* file size only if length < fat-file size
*/
if (length < fat_fd->fat_file_size)
203c548: 12 bf ff fc bne 203c538 <msdos_file_ftruncate+0x88> <== NOT EXECUTED
203c54c: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203c550: 08 bf ff fa bleu 203c538 <msdos_file_ftruncate+0x88> <== NOT EXECUTED
203c554: 01 00 00 00 nop <== NOT EXECUTED
iop->size = fat_fd->fat_file_size = length;
203c558: 10 bf ff f6 b 203c530 <msdos_file_ftruncate+0x80> <== NOT EXECUTED
203c55c: f4 24 20 0c st %i2, [ %l0 + 0xc ] <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_truncate(iop->pathinfo.mt_entry, fat_fd, length);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c560: 7f ff 44 7d call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c564: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c568: 81 c7 e0 08 ret <== NOT EXECUTED
203c56c: 81 e8 00 00 restore <== NOT EXECUTED
return RC_OK;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c570: 40 00 37 c4 call 204a480 <__errno> <== NOT EXECUTED
203c574: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c578: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c57c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c580: 81 c7 e0 08 ret <== NOT EXECUTED
203c584: 81 e8 00 00 restore <== NOT EXECUTED
0203c238 <msdos_file_ioctl>:
msdos_file_ioctl(rtems_libio_t *iop,uint32_t command, void *buffer)
{
int rc = RC_OK;
return rc;
}
203c238: 81 c3 e0 08 retl <== NOT EXECUTED
203c23c: 90 10 20 00 clr %o0 <== NOT EXECUTED
0203c588 <msdos_file_lseek>:
* new offset on success, or -1 if error occured (errno set
* appropriately).
*/
rtems_off64_t
msdos_file_lseek(rtems_libio_t *iop, rtems_off64_t offset, int whence)
{
203c588: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c58c: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
uint32_t real_size = 0;
203c590: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_off64_t
msdos_file_lseek(rtems_libio_t *iop, rtems_off64_t offset, int whence)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c594: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c598: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
uint32_t real_size = 0;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c59c: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
203c5a0: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c5a4: 7f ff 44 25 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c5a8: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c5ac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c5b0: 12 80 00 20 bne 203c630 <msdos_file_lseek+0xa8> <== NOT EXECUTED
203c5b4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_extend(iop->pathinfo.mt_entry, fat_fd, iop->offset,
203c5b8: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c5bc: d4 06 20 14 ld [ %i0 + 0x14 ], %o2 <== NOT EXECUTED
203c5c0: 7f ff b0 e2 call 2028948 <fat_file_extend> <== NOT EXECUTED
203c5c4: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
&real_size);
if (rc != RC_OK)
203c5c8: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
203c5cc: 12 80 00 12 bne 203c614 <msdos_file_lseek+0x8c> <== NOT EXECUTED
203c5d0: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
if (real_size > fat_fd->fat_file_size)
203c5d4: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
203c5d8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
203c5dc: 2a 80 00 0a bcs,a 203c604 <msdos_file_lseek+0x7c> <== NOT EXECUTED
203c5e0: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
fat_fd->fat_file_size = iop->offset = real_size;
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
203c5e4: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
}
if (real_size > fat_fd->fat_file_size)
fat_fd->fat_file_size = iop->offset = real_size;
iop->size = fat_fd->fat_file_size;
203c5e8: c2 26 20 0c st %g1, [ %i0 + 0xc ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c5ec: 7f ff 44 5a call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c5f0: c0 26 20 08 clr [ %i0 + 8 ] <== NOT EXECUTED
return iop->offset;
203c5f4: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
}
203c5f8: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
203c5fc: 81 c7 e0 08 ret <== NOT EXECUTED
203c600: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
if (real_size > fat_fd->fat_file_size)
fat_fd->fat_file_size = iop->offset = real_size;
203c604: c4 24 20 18 st %g2, [ %l0 + 0x18 ] <== NOT EXECUTED
203c608: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
203c60c: 10 bf ff f6 b 203c5e4 <msdos_file_lseek+0x5c> <== NOT EXECUTED
203c610: c4 26 20 14 st %g2, [ %i0 + 0x14 ] <== NOT EXECUTED
rc = fat_file_extend(iop->pathinfo.mt_entry, fat_fd, iop->offset,
&real_size);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c614: 7f ff 44 50 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c618: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c61c: 86 10 00 12 mov %l2, %g3 <== NOT EXECUTED
203c620: 85 3c a0 1f sra %l2, 0x1f, %g2 <== NOT EXECUTED
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
return iop->offset;
}
203c624: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
203c628: 81 c7 e0 08 ret <== NOT EXECUTED
203c62c: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
uint32_t real_size = 0;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c630: 40 00 37 94 call 204a480 <__errno> <== NOT EXECUTED
203c634: 01 00 00 00 nop <== NOT EXECUTED
203c638: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
203c63c: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
203c640: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c644: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
203c648: 10 bf ff ec b 203c5f8 <msdos_file_lseek+0x70> <== NOT EXECUTED
203c64c: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
0203c86c <msdos_file_open>:
* and errno set appropriately
*/
int
msdos_file_open(rtems_libio_t *iop, const char *pathname, uint32_t flag,
uint32_t mode)
{
203c86c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c870: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c874: e4 06 20 3c ld [ %i0 + 0x3c ], %l2 <== NOT EXECUTED
msdos_file_open(rtems_libio_t *iop, const char *pathname, uint32_t flag,
uint32_t mode)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c878: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c87c: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c880: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
203c884: 94 10 20 00 clr %o2 <== NOT EXECUTED
203c888: 7f ff 43 6c call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c88c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c890: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c894: 12 80 00 1d bne 203c908 <msdos_file_open+0x9c> <== NOT EXECUTED
203c898: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_reopen(fat_fd);
203c89c: 7f ff ae eb call 2028448 <fat_file_reopen> <== NOT EXECUTED
203c8a0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203c8a4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c8a8: 12 80 00 14 bne 203c8f8 <msdos_file_open+0x8c> <== NOT EXECUTED
203c8ac: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
if (iop->flags & LIBIO_FLAGS_APPEND)
203c8b0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
203c8b4: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED
203c8b8: 12 80 00 08 bne 203c8d8 <msdos_file_open+0x6c> <== NOT EXECUTED
203c8bc: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 <== NOT EXECUTED
iop->offset = fat_fd->fat_file_size;
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
203c8c0: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
}
if (iop->flags & LIBIO_FLAGS_APPEND)
iop->offset = fat_fd->fat_file_size;
iop->size = fat_fd->fat_file_size;
203c8c4: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c8c8: 7f ff 43 a3 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c8cc: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
return RC_OK;
}
203c8d0: 81 c7 e0 08 ret <== NOT EXECUTED
203c8d4: 81 e8 00 00 restore <== NOT EXECUTED
if (iop->flags & LIBIO_FLAGS_APPEND)
iop->offset = fat_fd->fat_file_size;
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
203c8d8: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
if (iop->flags & LIBIO_FLAGS_APPEND)
iop->offset = fat_fd->fat_file_size;
203c8dc: c0 24 20 10 clr [ %l0 + 0x10 ] <== NOT EXECUTED
203c8e0: c2 24 20 14 st %g1, [ %l0 + 0x14 ] <== NOT EXECUTED
iop->size = fat_fd->fat_file_size;
203c8e4: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c8e8: 7f ff 43 9b call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c8ec: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
return RC_OK;
}
203c8f0: 81 c7 e0 08 ret <== NOT EXECUTED
203c8f4: 81 e8 00 00 restore <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_reopen(fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c8f8: 7f ff 43 97 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c8fc: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c900: 81 c7 e0 08 ret <== NOT EXECUTED
203c904: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c908: 40 00 36 de call 204a480 <__errno> <== NOT EXECUTED
203c90c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c910: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c914: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c918: 81 c7 e0 08 ret <== NOT EXECUTED
203c91c: 81 e8 00 00 restore <== NOT EXECUTED
0203c730 <msdos_file_read>:
* the number of bytes read on success, or -1 if error occured (errno set
* appropriately)
*/
ssize_t
msdos_file_read(rtems_libio_t *iop, void *buffer, size_t count)
{
203c730: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
ssize_t ret = 0;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c734: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c738: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
ssize_t
msdos_file_read(rtems_libio_t *iop, void *buffer, size_t count)
{
ssize_t ret = 0;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c73c: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c740: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c744: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c748: 7f ff 43 bc call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c74c: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c750: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c754: 12 80 00 0c bne 203c784 <msdos_file_read+0x54> <== NOT EXECUTED
203c758: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
ret = fat_file_read(iop->pathinfo.mt_entry, fat_fd, iop->offset, count,
203c75c: d4 06 20 14 ld [ %i0 + 0x14 ], %o2 <== NOT EXECUTED
203c760: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c764: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
203c768: 7f ff b1 90 call 2028da8 <fat_file_read> <== NOT EXECUTED
203c76c: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
203c770: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
buffer);
rtems_semaphore_release(fs_info->vol_sema);
203c774: 7f ff 43 f8 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c778: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return ret;
}
203c77c: 81 c7 e0 08 ret <== NOT EXECUTED
203c780: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c784: 40 00 37 3f call 204a480 <__errno> <== NOT EXECUTED
203c788: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c78c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c790: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c794: 81 c7 e0 08 ret <== NOT EXECUTED
203c798: 81 e8 00 00 restore <== NOT EXECUTED
0203c2e8 <msdos_file_rmnod>:
* RC_OK on success, or -1 if error occured (errno set appropriately)
*/
int
msdos_file_rmnod(rtems_filesystem_location_info_t *parent_pathloc,
rtems_filesystem_location_info_t *pathloc)
{
203c2e8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203c2ec: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = pathloc->node_access;
203c2f0: e2 06 40 00 ld [ %i1 ], %l1 <== NOT EXECUTED
msdos_file_rmnod(rtems_filesystem_location_info_t *parent_pathloc,
rtems_filesystem_location_info_t *pathloc)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203c2f4: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
fat_file_fd_t *fat_fd = pathloc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c2f8: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c2fc: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c300: 7f ff 44 ce call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c304: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c308: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c30c: 12 80 00 13 bne 203c358 <msdos_file_rmnod+0x70> <== NOT EXECUTED
203c310: 92 04 60 20 add %l1, 0x20, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
/* mark file removed */
rc = msdos_set_first_char4file_name(pathloc->mt_entry,
203c314: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
203c318: 40 00 05 40 call 203d818 <msdos_set_first_char4file_name> <== NOT EXECUTED
203c31c: 94 10 20 e5 mov 0xe5, %o2 <== NOT EXECUTED
&fat_fd->dir_pos,
MSDOS_THIS_DIR_ENTRY_EMPTY);
if (rc != RC_OK)
203c320: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c324: 12 80 00 09 bne 203c348 <msdos_file_rmnod+0x60> <== NOT EXECUTED
203c328: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
fat_file_mark_removed(pathloc->mt_entry, fat_fd);
203c32c: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
203c330: 7f ff b0 fa call 2028718 <fat_file_mark_removed> <== NOT EXECUTED
203c334: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c338: 7f ff 45 07 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c33c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return RC_OK;
}
203c340: 81 c7 e0 08 ret <== NOT EXECUTED
203c344: 81 e8 00 00 restore <== NOT EXECUTED
rc = msdos_set_first_char4file_name(pathloc->mt_entry,
&fat_fd->dir_pos,
MSDOS_THIS_DIR_ENTRY_EMPTY);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c348: 7f ff 45 03 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c34c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c350: 81 c7 e0 08 ret <== NOT EXECUTED
203c354: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = pathloc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c358: 40 00 38 4a call 204a480 <__errno> <== NOT EXECUTED
203c35c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c360: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c364: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c368: 81 c7 e0 08 ret <== NOT EXECUTED
203c36c: 81 e8 00 00 restore <== NOT EXECUTED
0203c248 <msdos_file_stat>:
int
msdos_file_stat(
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
203c248: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
203c24c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
203c250: e2 06 00 00 ld [ %i0 ], %l1 <== NOT EXECUTED
rtems_filesystem_location_info_t *loc,
struct stat *buf
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = loc->mt_entry->fs_info;
203c254: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c258: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c25c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
203c260: 7f ff 44 f6 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c264: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c268: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c26c: 12 80 00 19 bne 203c2d0 <msdos_file_stat+0x88> <== NOT EXECUTED
203c270: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
203c274: c2 04 60 0c ld [ %l1 + 0xc ], %g1 <== NOT EXECUTED
buf->st_mode = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
203c278: c4 14 00 00 lduh [ %l0 ], %g2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
203c27c: c2 26 60 08 st %g1, [ %i1 + 8 ] <== NOT EXECUTED
buf->st_mode = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;
203c280: 03 00 00 20 sethi %hi(0x8000), %g1 <== NOT EXECUTED
203c284: 82 10 61 ff or %g1, 0x1ff, %g1 ! 81ff <PROM_START+0x81ff> <== NOT EXECUTED
203c288: c2 26 60 0c st %g1, [ %i1 + 0xc ] <== NOT EXECUTED
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
203c28c: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 <== NOT EXECUTED
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
203c290: c4 26 60 40 st %g2, [ %i1 + 0x40 ] <== NOT EXECUTED
buf->st_dev = fs_info->fat.vol.dev;
buf->st_ino = fat_fd->ino;
buf->st_mode = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
203c294: 85 30 60 09 srl %g1, 9, %g2 <== NOT EXECUTED
203c298: c4 26 60 44 st %g2, [ %i1 + 0x44 ] <== NOT EXECUTED
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
203c29c: c8 04 60 40 ld [ %l1 + 0x40 ], %g4 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
203c2a0: c4 1c 20 58 ldd [ %l0 + 0x58 ], %g2 <== NOT EXECUTED
buf->st_mode = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
buf->st_size = fat_fd->fat_file_size;
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
203c2a4: c8 26 60 30 st %g4, [ %i1 + 0x30 ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c2a8: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
buf->st_dev = fs_info->fat.vol.dev;
203c2ac: c4 3e 40 00 std %g2, [ %i1 ] <== NOT EXECUTED
buf->st_ino = fat_fd->ino;
buf->st_mode = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;
buf->st_rdev = 0ll;
203c2b0: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
203c2b4: c0 26 60 1c clr [ %i1 + 0x1c ] <== NOT EXECUTED
buf->st_size = fat_fd->fat_file_size;
203c2b8: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
203c2bc: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;
buf->st_blksize = fs_info->fat.vol.bps;
buf->st_mtime = fat_fd->mtime;
rtems_semaphore_release(fs_info->vol_sema);
203c2c0: 7f ff 45 25 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c2c4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
}
203c2c8: 81 c7 e0 08 ret <== NOT EXECUTED
203c2cc: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = loc->node_access;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c2d0: 40 00 38 6c call 204a480 <__errno> <== NOT EXECUTED
203c2d4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c2d8: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c2dc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c2e0: 81 c7 e0 08 ret <== NOT EXECUTED
203c2e4: 81 e8 00 00 restore <== NOT EXECUTED
0203c3d4 <msdos_file_sync>:
* RETURNS:
* RC_OK on success, or -1 if error occured (errno set appropriately)
*/
int
msdos_file_sync(rtems_libio_t *iop)
{
203c3d4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c3d8: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
int
msdos_file_sync(rtems_libio_t *iop)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
fat_file_fd_t *fat_fd = iop->file_info;
203c3dc: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c3e0: e4 00 60 34 ld [ %g1 + 0x34 ], %l2 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c3e4: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c3e8: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
203c3ec: 94 10 20 00 clr %o2 <== NOT EXECUTED
203c3f0: 7f ff 44 92 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c3f4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c3f8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c3fc: 12 80 00 27 bne 203c498 <msdos_file_sync+0xc4> <== NOT EXECUTED
203c400: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
/* synchronize file data */
rc = fat_file_datasync(iop->pathinfo.mt_entry, fat_fd);
203c404: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c408: 7f ff b0 79 call 20285ec <fat_file_datasync> <== NOT EXECUTED
203c40c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c410: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c414: 12 80 00 1d bne 203c488 <msdos_file_sync+0xb4> <== NOT EXECUTED
203c418: 01 00 00 00 nop <== NOT EXECUTED
/*
* if fat-file descriptor is not marked "removed" - synchronize file
* metadata
*/
if (!FAT_FILE_IS_REMOVED(fat_fd))
203c41c: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1 <== NOT EXECUTED
203c420: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
203c424: 32 80 00 15 bne,a 203c478 <msdos_file_sync+0xa4> <== NOT EXECUTED
203c428: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
{
rc = msdos_set_first_cluster_num(iop->pathinfo.mt_entry, fat_fd);
203c42c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c430: 40 00 04 c2 call 203d738 <msdos_set_first_cluster_num> <== NOT EXECUTED
203c434: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c438: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c43c: 12 80 00 13 bne 203c488 <msdos_file_sync+0xb4> <== NOT EXECUTED
203c440: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
rc = msdos_set_file_size(iop->pathinfo.mt_entry, fat_fd);
203c444: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c448: 40 00 04 92 call 203d690 <msdos_set_file_size> <== NOT EXECUTED
203c44c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c450: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c454: 12 80 00 0d bne 203c488 <msdos_file_sync+0xb4> <== NOT EXECUTED
203c458: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
rc = msdos_set_dir_wrt_time_and_date(iop->pathinfo.mt_entry, fat_fd);
203c45c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
203c460: 40 00 05 60 call 203d9e0 <msdos_set_dir_wrt_time_and_date><== NOT EXECUTED
203c464: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203c468: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c46c: 12 80 00 07 bne 203c488 <msdos_file_sync+0xb4> <== NOT EXECUTED
203c470: 01 00 00 00 nop <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
return rc;
}
}
rtems_semaphore_release(fs_info->vol_sema);
203c474: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
203c478: 7f ff 44 b7 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c47c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RC_OK;
}
203c480: 81 c7 e0 08 ret <== NOT EXECUTED
203c484: 81 e8 00 00 restore <== NOT EXECUTED
return rc;
}
rc = msdos_set_dir_wrt_time_and_date(iop->pathinfo.mt_entry, fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
203c488: 7f ff 44 b3 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c48c: d0 04 a0 98 ld [ %l2 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
203c490: 81 c7 e0 08 ret <== NOT EXECUTED
203c494: 81 e8 00 00 restore <== NOT EXECUTED
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c498: 40 00 37 fa call 204a480 <__errno> <== NOT EXECUTED
203c49c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c4a0: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c4a4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c4a8: 81 c7 e0 08 ret <== NOT EXECUTED
203c4ac: 81 e8 00 00 restore <== NOT EXECUTED
0203c650 <msdos_file_write>:
* the number of bytes written on success, or -1 if error occured
* and errno set appropriately
*/
ssize_t
msdos_file_write(rtems_libio_t *iop,const void *buffer, size_t count)
{
203c650: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
ssize_t ret = 0;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c654: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
203c658: e4 06 20 3c ld [ %i0 + 0x3c ], %l2 <== NOT EXECUTED
ssize_t
msdos_file_write(rtems_libio_t *iop,const void *buffer, size_t count)
{
ssize_t ret = 0;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = iop->pathinfo.mt_entry->fs_info;
203c65c: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c660: 92 10 20 00 clr %o1 <== NOT EXECUTED
203c664: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
203c668: 94 10 20 00 clr %o2 <== NOT EXECUTED
203c66c: 7f ff 43 f3 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c670: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c674: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c678: 12 80 00 23 bne 203c704 <msdos_file_write+0xb4> <== NOT EXECUTED
203c67c: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
ret = fat_file_write(iop->pathinfo.mt_entry, fat_fd, iop->offset, count,
203c680: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
203c684: d4 06 20 14 ld [ %i0 + 0x14 ], %o2 <== NOT EXECUTED
203c688: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
203c68c: 7f ff b1 2b call 2028b38 <fat_file_write> <== NOT EXECUTED
203c690: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
buffer);
if (ret < 0)
203c694: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203c698: 06 80 00 21 bl 203c71c <msdos_file_write+0xcc> <== NOT EXECUTED
203c69c: 85 3e 20 1f sra %i0, 0x1f, %g2 <== NOT EXECUTED
/*
* update file size in both fat-file descriptor and file control block if
* file was extended
*/
if (iop->offset + ret > fat_fd->fat_file_size)
203c6a0: d8 1c 20 10 ldd [ %l0 + 0x10 ], %o4 <== NOT EXECUTED
203c6a4: 86 86 00 0d addcc %i0, %o5, %g3 <== NOT EXECUTED
203c6a8: 84 40 80 0c addx %g2, %o4, %g2 <== NOT EXECUTED
203c6ac: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203c6b0: 04 80 00 0a ble 203c6d8 <msdos_file_write+0x88> <== NOT EXECUTED
203c6b4: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 <== NOT EXECUTED
fat_fd->fat_file_size = iop->offset + ret;
203c6b8: 82 06 00 0d add %i0, %o5, %g1 <== NOT EXECUTED
203c6bc: c2 24 a0 18 st %g1, [ %l2 + 0x18 ] <== NOT EXECUTED
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
203c6c0: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
* file was extended
*/
if (iop->offset + ret > fat_fd->fat_file_size)
fat_fd->fat_file_size = iop->offset + ret;
iop->size = fat_fd->fat_file_size;
203c6c4: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c6c8: 7f ff 44 23 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c6cc: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
return ret;
}
203c6d0: 81 c7 e0 08 ret <== NOT EXECUTED
203c6d4: 81 e8 00 00 restore <== NOT EXECUTED
/*
* update file size in both fat-file descriptor and file control block if
* file was extended
*/
if (iop->offset + ret > fat_fd->fat_file_size)
203c6d8: 32 bf ff fb bne,a 203c6c4 <msdos_file_write+0x74> <== NOT EXECUTED
203c6dc: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
203c6e0: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED
203c6e4: 38 bf ff f6 bgu,a 203c6bc <msdos_file_write+0x6c> <== NOT EXECUTED
203c6e8: 82 06 00 0d add %i0, %o5, %g1 <== NOT EXECUTED
fat_fd->fat_file_size = iop->offset + ret;
iop->size = fat_fd->fat_file_size;
rtems_semaphore_release(fs_info->vol_sema);
203c6ec: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
* file was extended
*/
if (iop->offset + ret > fat_fd->fat_file_size)
fat_fd->fat_file_size = iop->offset + ret;
iop->size = fat_fd->fat_file_size;
203c6f0: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c6f4: 7f ff 44 18 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c6f8: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
return ret;
}
203c6fc: 81 c7 e0 08 ret <== NOT EXECUTED
203c700: 81 e8 00 00 restore <== NOT EXECUTED
fat_file_fd_t *fat_fd = iop->file_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c704: 40 00 37 5f call 204a480 <__errno> <== NOT EXECUTED
203c708: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c70c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c710: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c714: 81 c7 e0 08 ret <== NOT EXECUTED
203c718: 81 e8 00 00 restore <== NOT EXECUTED
ret = fat_file_write(iop->pathinfo.mt_entry, fat_fd, iop->offset, count,
buffer);
if (ret < 0)
{
rtems_semaphore_release(fs_info->vol_sema);
203c71c: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
203c720: 7f ff 44 0d call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c724: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return -1;
203c728: 81 c7 e0 08 ret <== NOT EXECUTED
203c72c: 81 e8 00 00 restore <== NOT EXECUTED
0204886c <msdos_filename_unix2dos>:
* Convert a unix filename to a DOS filename. Return -1 if wrong name is
* supplied.
*/
int
msdos_filename_unix2dos(const char *un, int unlen, char *dn)
{
204886c: 82 10 20 00 clr %g1 <== NOT EXECUTED
/*
* Fill the dos filename string with blanks. These are DOS's pad
* characters.
*/
for (i = 0; i <= 10; i++)
dn[i] = ' ';
2048870: 84 10 20 20 mov 0x20, %g2 <== NOT EXECUTED
2048874: c4 2a 80 01 stb %g2, [ %o2 + %g1 ] <== NOT EXECUTED
/*
* Fill the dos filename string with blanks. These are DOS's pad
* characters.
*/
for (i = 0; i <= 10; i++)
2048878: 82 00 60 01 inc %g1 <== NOT EXECUTED
204887c: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
2048880: 32 bf ff fe bne,a 2048878 <msdos_filename_unix2dos+0xc> <== NOT EXECUTED
2048884: c4 2a 80 01 stb %g2, [ %o2 + %g1 ] <== NOT EXECUTED
/*
* The filenames "." and ".." are handled specially, since they
* don't follow dos filename rules.
*/
if (un[0] == '.' && unlen == 1) {
2048888: c4 4a 00 00 ldsb [ %o0 ], %g2 <== NOT EXECUTED
204888c: 84 18 a0 2e xor %g2, 0x2e, %g2 <== NOT EXECUTED
2048890: 80 a0 00 02 cmp %g0, %g2 <== NOT EXECUTED
2048894: 84 60 3f ff subx %g0, -1, %g2 <== NOT EXECUTED
2048898: 80 a2 60 01 cmp %o1, 1 <== NOT EXECUTED
204889c: 02 80 00 61 be 2048a20 <msdos_filename_unix2dos+0x1b4> <== NOT EXECUTED
20488a0: c2 0a 00 00 ldub [ %o0 ], %g1 <== NOT EXECUTED
dn[0] = '.';
return 0;
}
if (un[0] == '.' && un[1] == '.' && unlen == 2) {
20488a4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20488a8: 32 80 00 65 bne,a 2048a3c <msdos_filename_unix2dos+0x1d0><== NOT EXECUTED
20488ac: c6 4a 20 01 ldsb [ %o0 + 1 ], %g3 <== NOT EXECUTED
}
/*
* Remove any dots from the start of a file name.
*/
while (unlen && (*un == '.')) {
20488b0: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
20488b4: 02 80 00 21 be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
20488b8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20488bc: 32 80 00 26 bne,a 2048954 <msdos_filename_unix2dos+0xe8> <== NOT EXECUTED
20488c0: 92 82 7f ff addcc %o1, -1, %o1 <== NOT EXECUTED
* Copy the unix filename into the dos filename string upto the end
* of string, a '.', or 8 characters. Whichever happens first stops
* us. This forms the name portion of the dos filename. Fold to
* upper case.
*/
for (i = 0; i <= 7 && unlen && (c = *un) && c != '.'; i++) {
20488c4: 84 88 60 ff andcc %g1, 0xff, %g2 <== NOT EXECUTED
20488c8: 02 80 00 27 be 2048964 <msdos_filename_unix2dos+0xf8> <== NOT EXECUTED
20488cc: 80 a0 a0 2e cmp %g2, 0x2e <== NOT EXECUTED
20488d0: 02 80 00 25 be 2048964 <msdos_filename_unix2dos+0xf8> <== NOT EXECUTED
20488d4: 09 00 81 bd sethi %hi(0x206f400), %g4 <== NOT EXECUTED
if (msdos_map[c] == 0)
20488d8: 88 11 20 a0 or %g4, 0xa0, %g4 ! 206f4a0 <msdos_map> <== NOT EXECUTED
20488dc: c6 09 00 02 ldub [ %g4 + %g2 ], %g3 <== NOT EXECUTED
20488e0: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20488e4: 12 80 00 10 bne 2048924 <msdos_filename_unix2dos+0xb8> <== NOT EXECUTED
20488e8: 84 10 20 00 clr %g2 <== NOT EXECUTED
/*
* Strip any further characters up to a '.' or the end of the
* string.
*/
while (unlen && (c = *un)) {
20488ec: 10 80 00 1f b 2048968 <msdos_filename_unix2dos+0xfc> <== NOT EXECUTED
20488f0: 82 88 60 ff andcc %g1, 0xff, %g1 <== NOT EXECUTED
* Copy the unix filename into the dos filename string upto the end
* of string, a '.', or 8 characters. Whichever happens first stops
* us. This forms the name portion of the dos filename. Fold to
* upper case.
*/
for (i = 0; i <= 7 && unlen && (c = *un) && c != '.'; i++) {
20488f4: 80 a0 a0 07 cmp %g2, 7 <== NOT EXECUTED
20488f8: 14 80 00 1b bg 2048964 <msdos_filename_unix2dos+0xf8> <== NOT EXECUTED
20488fc: c2 0a 00 00 ldub [ %o0 ], %g1 <== NOT EXECUTED
2048900: 86 88 60 ff andcc %g1, 0xff, %g3 <== NOT EXECUTED
2048904: 02 80 00 18 be 2048964 <msdos_filename_unix2dos+0xf8> <== NOT EXECUTED
2048908: 80 a0 e0 2e cmp %g3, 0x2e <== NOT EXECUTED
204890c: 22 80 00 17 be,a 2048968 <msdos_filename_unix2dos+0xfc> <== NOT EXECUTED
2048910: 82 88 60 ff andcc %g1, 0xff, %g1 <== NOT EXECUTED
if (msdos_map[c] == 0)
2048914: c6 09 00 03 ldub [ %g4 + %g3 ], %g3 <== NOT EXECUTED
2048918: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
204891c: 22 80 00 13 be,a 2048968 <msdos_filename_unix2dos+0xfc> <== NOT EXECUTED
2048920: 82 88 60 ff andcc %g1, 0xff, %g1 <== NOT EXECUTED
break;
dn[i] = msdos_map[c];
2048924: c6 2a 80 02 stb %g3, [ %o2 + %g2 ] <== NOT EXECUTED
un++;
2048928: 90 02 20 01 inc %o0 <== NOT EXECUTED
* Copy the unix filename into the dos filename string upto the end
* of string, a '.', or 8 characters. Whichever happens first stops
* us. This forms the name portion of the dos filename. Fold to
* upper case.
*/
for (i = 0; i <= 7 && unlen && (c = *un) && c != '.'; i++) {
204892c: 92 82 7f ff addcc %o1, -1, %o1 <== NOT EXECUTED
2048930: 12 bf ff f1 bne 20488f4 <msdos_filename_unix2dos+0x88> <== NOT EXECUTED
2048934: 84 00 a0 01 inc %g2 <== NOT EXECUTED
dn[i] = msdos_map[c];
un++;
unlen--;
}
return 0;
}
2048938: 81 c3 e0 08 retl <== NOT EXECUTED
204893c: 90 10 20 00 clr %o0 <== NOT EXECUTED
}
/*
* Remove any dots from the start of a file name.
*/
while (unlen && (*un == '.')) {
2048940: c4 4a 00 00 ldsb [ %o0 ], %g2 <== NOT EXECUTED
2048944: 80 a0 a0 2e cmp %g2, 0x2e <== NOT EXECUTED
2048948: 12 bf ff df bne 20488c4 <msdos_filename_unix2dos+0x58> <== NOT EXECUTED
204894c: c2 0a 00 00 ldub [ %o0 ], %g1 <== NOT EXECUTED
2048950: 92 82 7f ff addcc %o1, -1, %o1 <== NOT EXECUTED
2048954: 12 bf ff fb bne 2048940 <msdos_filename_unix2dos+0xd4> <== NOT EXECUTED
2048958: 90 02 20 01 inc %o0 <== NOT EXECUTED
dn[i] = msdos_map[c];
un++;
unlen--;
}
return 0;
}
204895c: 81 c3 e0 08 retl <== NOT EXECUTED
2048960: 90 10 20 00 clr %o0 <== NOT EXECUTED
/*
* Strip any further characters up to a '.' or the end of the
* string.
*/
while (unlen && (c = *un)) {
2048964: 82 88 60 ff andcc %g1, 0xff, %g1 <== NOT EXECUTED
2048968: 02 bf ff f4 be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
204896c: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
un++;
2048970: 90 02 20 01 inc %o0 <== NOT EXECUTED
unlen--;
/* Make sure we've skipped over the dot before stopping. */
if (c == '.')
2048974: 02 80 00 0c be 20489a4 <msdos_filename_unix2dos+0x138> <== NOT EXECUTED
2048978: 92 02 7f ff add %o1, -1, %o1 <== NOT EXECUTED
/*
* Strip any further characters up to a '.' or the end of the
* string.
*/
while (unlen && (c = *un)) {
204897c: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
2048980: 02 bf ff ee be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
2048984: 01 00 00 00 nop <== NOT EXECUTED
2048988: c2 0a 00 00 ldub [ %o0 ], %g1 <== NOT EXECUTED
204898c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2048990: 02 bf ff ea be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
2048994: 92 02 7f ff add %o1, -1, %o1 <== NOT EXECUTED
un++;
unlen--;
/* Make sure we've skipped over the dot before stopping. */
if (c == '.')
2048998: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
204899c: 12 bf ff f8 bne 204897c <msdos_filename_unix2dos+0x110> <== NOT EXECUTED
20489a0: 90 02 20 01 inc %o0 <== NOT EXECUTED
/*
* Copy in the extension part of the name, if any. Force to upper
* case. Note that the extension is allowed to contain '.'s.
* Filenames in this form are probably inaccessable under dos.
*/
for (i = 8; i <= 10 && unlen && (c = *un); i++) {
20489a4: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
20489a8: 02 bf ff e4 be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
20489ac: 01 00 00 00 nop <== NOT EXECUTED
20489b0: c2 0a 00 00 ldub [ %o0 ], %g1 <== NOT EXECUTED
20489b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20489b8: 02 bf ff e0 be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
20489bc: 09 00 81 bd sethi %hi(0x206f400), %g4 <== NOT EXECUTED
if (msdos_map[c] == 0)
20489c0: 88 11 20 a0 or %g4, 0xa0, %g4 ! 206f4a0 <msdos_map> <== NOT EXECUTED
20489c4: c4 09 00 01 ldub [ %g4 + %g1 ], %g2 <== NOT EXECUTED
20489c8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20489cc: 12 80 00 0e bne 2048a04 <msdos_filename_unix2dos+0x198> <== NOT EXECUTED
20489d0: 82 10 20 08 mov 8, %g1 <== NOT EXECUTED
20489d4: 30 bf ff d9 b,a 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
/*
* Copy in the extension part of the name, if any. Force to upper
* case. Note that the extension is allowed to contain '.'s.
* Filenames in this form are probably inaccessable under dos.
*/
for (i = 8; i <= 10 && unlen && (c = *un); i++) {
20489d8: 80 a0 60 0a cmp %g1, 0xa <== NOT EXECUTED
20489dc: 14 bf ff d7 bg 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
20489e0: 01 00 00 00 nop <== NOT EXECUTED
20489e4: c4 08 bf f8 ldub [ %g2 + -8 ], %g2 <== NOT EXECUTED
20489e8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20489ec: 02 bf ff d3 be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
20489f0: 01 00 00 00 nop <== NOT EXECUTED
if (msdos_map[c] == 0)
20489f4: c4 09 00 02 ldub [ %g4 + %g2 ], %g2 <== NOT EXECUTED
20489f8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20489fc: 02 bf ff cf be 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
2048a00: 01 00 00 00 nop <== NOT EXECUTED
break;
dn[i] = msdos_map[c];
2048a04: c4 2a 80 01 stb %g2, [ %o2 + %g1 ] <== NOT EXECUTED
/*
* Copy in the extension part of the name, if any. Force to upper
* case. Note that the extension is allowed to contain '.'s.
* Filenames in this form are probably inaccessable under dos.
*/
for (i = 8; i <= 10 && unlen && (c = *un); i++) {
2048a08: 92 82 7f ff addcc %o1, -1, %o1 <== NOT EXECUTED
2048a0c: 82 00 60 01 inc %g1 <== NOT EXECUTED
2048a10: 12 bf ff f2 bne 20489d8 <msdos_filename_unix2dos+0x16c> <== NOT EXECUTED
2048a14: 84 02 00 01 add %o0, %g1, %g2 <== NOT EXECUTED
dn[i] = msdos_map[c];
un++;
unlen--;
}
return 0;
}
2048a18: 81 c3 e0 08 retl <== NOT EXECUTED
2048a1c: 90 10 20 00 clr %o0 <== NOT EXECUTED
/*
* The filenames "." and ".." are handled specially, since they
* don't follow dos filename rules.
*/
if (un[0] == '.' && unlen == 1) {
2048a20: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2048a24: 02 bf ff a1 be 20488a8 <msdos_filename_unix2dos+0x3c> <== NOT EXECUTED
2048a28: 01 00 00 00 nop <== NOT EXECUTED
dn[0] = '.';
2048a2c: 82 10 20 2e mov 0x2e, %g1 ! 2e <PROM_START+0x2e> <== NOT EXECUTED
dn[i] = msdos_map[c];
un++;
unlen--;
}
return 0;
}
2048a30: 90 10 20 00 clr %o0 <== NOT EXECUTED
2048a34: 81 c3 e0 08 retl <== NOT EXECUTED
2048a38: c2 2a 80 00 stb %g1, [ %o2 ] <== NOT EXECUTED
*/
if (un[0] == '.' && unlen == 1) {
dn[0] = '.';
return 0;
}
if (un[0] == '.' && un[1] == '.' && unlen == 2) {
2048a3c: 80 a0 e0 2e cmp %g3, 0x2e <== NOT EXECUTED
2048a40: 12 bf ff 9d bne 20488b4 <msdos_filename_unix2dos+0x48> <== NOT EXECUTED
2048a44: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
2048a48: 80 a2 60 02 cmp %o1, 2 <== NOT EXECUTED
2048a4c: 12 bf ff 9a bne 20488b4 <msdos_filename_unix2dos+0x48> <== NOT EXECUTED
2048a50: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
dn[0] = '.';
dn[1] = '.';
2048a54: c6 2a a0 01 stb %g3, [ %o2 + 1 ] <== NOT EXECUTED
return 0;
2048a58: 10 bf ff b8 b 2048938 <msdos_filename_unix2dos+0xcc> <== NOT EXECUTED
2048a5c: c6 2a 80 00 stb %g3, [ %o2 ] <== NOT EXECUTED
0203e244 <msdos_find_name>:
msdos_find_name(
rtems_filesystem_location_info_t *parent_loc,
const char *name,
int name_len
)
{
203e244: 9d e3 bf 60 save %sp, -160, %sp <== NOT EXECUTED
int rc = RC_OK;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
203e248: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
fat_dir_pos_t dir_pos;
unsigned short time_val = 0;
unsigned short date = 0;
char node_entry[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];
memset(node_entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203e24c: a4 07 bf c8 add %fp, -56, %l2 <== NOT EXECUTED
const char *name,
int name_len
)
{
int rc = RC_OK;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
203e250: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
unsigned short date = 0;
char node_entry[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];
memset(node_entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
name_type = msdos_long_to_short (name,
203e254: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203e258: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
203e25c: 96 10 20 0b mov 0xb, %o3 <== NOT EXECUTED
int name_len
)
{
int rc = RC_OK;
msdos_fs_info_t *fs_info = parent_loc->mt_entry->fs_info;
fat_file_fd_t *fat_fd = NULL;
203e260: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
fat_dir_pos_t dir_pos;
unsigned short time_val = 0;
unsigned short date = 0;
char node_entry[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];
memset(node_entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203e264: c0 27 bf c8 clr [ %fp + -56 ] <== NOT EXECUTED
203e268: c0 27 bf cc clr [ %fp + -52 ] <== NOT EXECUTED
203e26c: c0 24 a0 08 clr [ %l2 + 8 ] <== NOT EXECUTED
203e270: c0 24 a0 0c clr [ %l2 + 0xc ] <== NOT EXECUTED
203e274: c0 24 a0 10 clr [ %l2 + 0x10 ] <== NOT EXECUTED
203e278: c0 24 a0 14 clr [ %l2 + 0x14 ] <== NOT EXECUTED
203e27c: c0 24 a0 18 clr [ %l2 + 0x18 ] <== NOT EXECUTED
203e280: c0 24 a0 1c clr [ %l2 + 0x1c ] <== NOT EXECUTED
name_type = msdos_long_to_short (name,
203e284: 7f ff fe 6d call 203dc38 <msdos_long_to_short> <== NOT EXECUTED
203e288: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
msdos_find_name(
rtems_filesystem_location_info_t *parent_loc,
const char *name,
int name_len
)
{
203e28c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
unsigned short date = 0;
char node_entry[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];
memset(node_entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
name_type = msdos_long_to_short (name,
203e290: 98 10 00 08 mov %o0, %o4 <== NOT EXECUTED
/*
* find the node which correspondes to the name in the directory pointed by
* 'parent_loc'
*/
rc = msdos_get_name_node(parent_loc, false, name, name_len, name_type,
203e294: e4 23 a0 5c st %l2, [ %sp + 0x5c ] <== NOT EXECUTED
203e298: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203e29c: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
203e2a0: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
203e2a4: a6 07 bf ec add %fp, -20, %l3 <== NOT EXECUTED
203e2a8: 92 10 20 00 clr %o1 <== NOT EXECUTED
203e2ac: 7f ff ff a2 call 203e134 <msdos_get_name_node> <== NOT EXECUTED
203e2b0: 9a 10 00 13 mov %l3, %o5 <== NOT EXECUTED
&dir_pos, node_entry);
if (rc != RC_OK)
203e2b4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e2b8: 12 80 00 20 bne 203e338 <msdos_find_name+0xf4> <== NOT EXECUTED
203e2bc: c2 0f bf d3 ldub [ %fp + -45 ], %g1 <== NOT EXECUTED
return rc;
if (((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_VOLUME_ID) ||
203e2c0: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
203e2c4: 12 80 00 1f bne 203e340 <msdos_find_name+0xfc> <== NOT EXECUTED
203e2c8: 82 08 60 3f and %g1, 0x3f, %g1 <== NOT EXECUTED
203e2cc: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED
203e2d0: 02 80 00 1c be 203e340 <msdos_find_name+0xfc> <== NOT EXECUTED
203e2d4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
((*MSDOS_DIR_ATTR(node_entry) & MSDOS_ATTR_LFN_MASK) == MSDOS_ATTR_LFN))
return MSDOS_NAME_NOT_FOUND_ERR;
/* open fat-file corresponded to the found node */
rc = fat_file_open(parent_loc->mt_entry, &dir_pos, &fat_fd);
203e2d8: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203e2dc: 7f ff ab 70 call 202909c <fat_file_open> <== NOT EXECUTED
203e2e0: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (rc != RC_OK)
203e2e4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e2e8: 12 80 00 14 bne 203e338 <msdos_find_name+0xf4> <== NOT EXECUTED
203e2ec: e6 07 bf fc ld [ %fp + -4 ], %l3 <== NOT EXECUTED
return rc;
fat_fd->dir_pos = dir_pos;
203e2f0: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
* size and first cluster num to the disk after each write operation
* (even if one byte is written - that is TOO slow) because
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
203e2f4: f4 04 e0 08 ld [ %l3 + 8 ], %i2 <== NOT EXECUTED
/* open fat-file corresponded to the found node */
rc = fat_file_open(parent_loc->mt_entry, &dir_pos, &fat_fd);
if (rc != RC_OK)
return rc;
fat_fd->dir_pos = dir_pos;
203e2f8: c2 24 e0 20 st %g1, [ %l3 + 0x20 ] <== NOT EXECUTED
203e2fc: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
* size and first cluster num to the disk after each write operation
* (even if one byte is written - that is TOO slow) because
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
203e300: 80 a6 a0 01 cmp %i2, 1 <== NOT EXECUTED
/* open fat-file corresponded to the found node */
rc = fat_file_open(parent_loc->mt_entry, &dir_pos, &fat_fd);
if (rc != RC_OK)
return rc;
fat_fd->dir_pos = dir_pos;
203e304: c2 24 e0 24 st %g1, [ %l3 + 0x24 ] <== NOT EXECUTED
203e308: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
203e30c: c2 24 e0 28 st %g1, [ %l3 + 0x28 ] <== NOT EXECUTED
203e310: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
* size and first cluster num to the disk after each write operation
* (even if one byte is written - that is TOO slow) because
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
203e314: 02 80 00 0f be 203e350 <msdos_find_name+0x10c> <== NOT EXECUTED
203e318: c2 24 e0 2c st %g1, [ %l3 + 0x2c ] <== NOT EXECUTED
fat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
}
}
/* close fat-file corresponded to the node we searched in */
rc = fat_file_close(parent_loc->mt_entry, parent_loc->node_access);
203e31c: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203e320: 7f ff ab 2d call 2028fd4 <fat_file_close> <== NOT EXECUTED
203e324: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
if (rc != RC_OK)
203e328: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e32c: 12 80 00 49 bne 203e450 <msdos_find_name+0x20c> <== NOT EXECUTED
203e330: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
fat_file_close(parent_loc->mt_entry, fat_fd);
return rc;
}
/* update node_info_ptr field */
parent_loc->node_access = fat_fd;
203e334: c2 24 00 00 st %g1, [ %l0 ] <== NOT EXECUTED
return rc;
203e338: 81 c7 e0 08 ret <== NOT EXECUTED
203e33c: 81 e8 00 00 restore <== NOT EXECUTED
203e340: 31 00 00 1f sethi %hi(0x7c00), %i0 <== NOT EXECUTED
203e344: b0 16 21 01 or %i0, 0x101, %i0 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
}
203e348: 81 c7 e0 08 ret <== NOT EXECUTED
203e34c: 81 e8 00 00 restore <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e350: da 14 a0 1a lduh [ %l2 + 0x1a ], %o5 <== NOT EXECUTED
203e354: c8 14 a0 14 lduh [ %l2 + 0x14 ], %g4 <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
203e358: d4 14 a0 16 lduh [ %l2 + 0x16 ], %o2 <== NOT EXECUTED
date = *MSDOS_DIR_WRITE_DATE(node_entry);
203e35c: c6 14 a0 18 lduh [ %l2 + 0x18 ], %g3 <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e360: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203e364: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
203e368: 97 31 20 18 srl %g4, 0x18, %o3 <== NOT EXECUTED
203e36c: 99 33 60 18 srl %o5, 0x18, %o4 <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
date = *MSDOS_DIR_WRITE_DATE(node_entry);
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
203e370: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203e374: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
203e378: 85 30 e0 18 srl %g3, 0x18, %g2 <== NOT EXECUTED
203e37c: 93 32 a0 18 srl %o2, 0x18, %o1 <== NOT EXECUTED
203e380: 87 30 e0 08 srl %g3, 8, %g3 <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e384: 89 31 20 08 srl %g4, 8, %g4 <== NOT EXECUTED
203e388: 9b 33 60 08 srl %o5, 8, %o5 <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
date = *MSDOS_DIR_WRITE_DATE(node_entry);
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
203e38c: 95 32 a0 08 srl %o2, 8, %o2 <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e390: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
203e394: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
date = *MSDOS_DIR_WRITE_DATE(node_entry);
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
203e398: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e39c: 88 09 00 01 and %g4, %g1, %g4 <== NOT EXECUTED
203e3a0: 9a 0b 40 01 and %o5, %g1, %o5 <== NOT EXECUTED
203e3a4: 88 11 00 0b or %g4, %o3, %g4 <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
date = *MSDOS_DIR_WRITE_DATE(node_entry);
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
203e3a8: 82 08 c0 01 and %g3, %g1, %g1 <== NOT EXECUTED
* otherwise real values of these fields stored in fat-file descriptor
* may be accidentally rewritten with wrong values stored on the disk
*/
if (fat_fd->links_num == 1)
{
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);
203e3ac: 9a 13 40 0c or %o5, %o4, %o5 <== NOT EXECUTED
203e3b0: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203e3b4: 88 11 00 0d or %g4, %o5, %g4 <== NOT EXECUTED
time_val = *MSDOS_DIR_WRITE_TIME(node_entry);
date = *MSDOS_DIR_WRITE_DATE(node_entry);
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
203e3b8: 90 10 40 02 or %g1, %g2, %o0 <== NOT EXECUTED
203e3bc: 92 12 80 09 or %o2, %o1, %o1 <== NOT EXECUTED
203e3c0: 40 00 28 d2 call 2048708 <msdos_date_dos2unix> <== NOT EXECUTED
203e3c4: c8 24 e0 1c st %g4, [ %l3 + 0x1c ] <== NOT EXECUTED
203e3c8: d0 24 e0 40 st %o0, [ %l3 + 0x40 ] <== NOT EXECUTED
if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)
203e3cc: c2 0f bf d3 ldub [ %fp + -45 ], %g1 <== NOT EXECUTED
203e3d0: 80 88 60 10 btst 0x10, %g1 <== NOT EXECUTED
203e3d4: 12 80 00 27 bne 203e470 <msdos_find_name+0x22c> <== NOT EXECUTED
203e3d8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
}
}
else
{
fat_fd->fat_file_size = CF_LE_L(*MSDOS_DIR_FILE_SIZE(node_entry));
203e3dc: c4 04 a0 1c ld [ %l2 + 0x1c ], %g2 <== NOT EXECUTED
203e3e0: 87 30 a0 10 srl %g2, 0x10, %g3 <== NOT EXECUTED
203e3e4: 9b 28 a0 18 sll %g2, 0x18, %o5 <== NOT EXECUTED
203e3e8: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
203e3ec: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
203e3f0: 88 13 40 04 or %o5, %g4, %g4 <== NOT EXECUTED
203e3f4: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
203e3f8: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
203e3fc: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
203e400: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
203e404: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
203e408: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
203e40c: c4 20 60 18 st %g2, [ %g1 + 0x18 ] <== NOT EXECUTED
fat_fd->fat_file_type = FAT_FILE;
203e410: 84 10 20 05 mov 5, %g2 <== NOT EXECUTED
203e414: c4 20 60 10 st %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_FILE_SIZE;
203e418: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
203e41c: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
}
/* these data is not actual for zero-length fat-file */
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
203e420: c6 00 60 1c ld [ %g1 + 0x1c ], %g3 <== NOT EXECUTED
if ((fat_fd->fat_file_size != 0) &&
203e424: c4 00 60 18 ld [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
fat_fd->fat_file_type = FAT_FILE;
fat_fd->size_limit = MSDOS_MAX_FILE_SIZE;
}
/* these data is not actual for zero-length fat-file */
fat_fd->map.file_cln = 0;
203e428: c0 20 60 34 clr [ %g1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln;
if ((fat_fd->fat_file_size != 0) &&
203e42c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203e430: 02 80 00 0d be 203e464 <msdos_find_name+0x220> <== NOT EXECUTED
203e434: c6 20 60 38 st %g3, [ %g1 + 0x38 ] <== NOT EXECUTED
(fat_fd->fat_file_size <= fs_info->fat.vol.bpc))
203e438: c8 14 60 06 lduh [ %l1 + 6 ], %g4 <== NOT EXECUTED
203e43c: 80 a0 80 04 cmp %g2, %g4 <== NOT EXECUTED
203e440: 18 80 00 0a bgu 203e468 <msdos_find_name+0x224> <== NOT EXECUTED
203e444: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
/* these data is not actual for zero-length fat-file */
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
if ((fat_fd->fat_file_size != 0) &&
203e448: 10 bf ff b5 b 203e31c <msdos_find_name+0xd8> <== NOT EXECUTED
203e44c: c6 20 60 3c st %g3, [ %g1 + 0x3c ] <== NOT EXECUTED
/* close fat-file corresponded to the node we searched in */
rc = fat_file_close(parent_loc->mt_entry, parent_loc->node_access);
if (rc != RC_OK)
{
fat_file_close(parent_loc->mt_entry, fat_fd);
203e450: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
203e454: 7f ff aa e0 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203e458: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
return rc;
203e45c: 81 c7 e0 08 ret <== NOT EXECUTED
203e460: 81 e8 00 00 restore <== NOT EXECUTED
{
fat_fd->map.last_cln = fat_fd->cln;
}
else
{
fat_fd->map.last_cln = FAT_UNDEFINED_VALUE;
203e464: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
203e468: 10 bf ff ad b 203e31c <msdos_find_name+0xd8> <== NOT EXECUTED
203e46c: c4 20 60 3c st %g2, [ %g1 + 0x3c ] <== NOT EXECUTED
if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)
{
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
rc = fat_file_size(parent_loc->mt_entry, fat_fd);
203e470: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)
{
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203e474: 05 00 08 00 sethi %hi(0x200000), %g2 <== NOT EXECUTED
fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)
{
fat_fd->fat_file_type = FAT_DIRECTORY;
203e478: f4 20 60 10 st %i2, [ %g1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
rc = fat_file_size(parent_loc->mt_entry, fat_fd);
203e47c: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
203e480: 7f ff a7 f8 call 2028460 <fat_file_size> <== NOT EXECUTED
203e484: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
if (rc != RC_OK)
203e488: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e48c: 12 bf ff f1 bne 203e450 <msdos_find_name+0x20c> <== NOT EXECUTED
203e490: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_FILE_SIZE;
}
/* these data is not actual for zero-length fat-file */
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
203e494: 10 bf ff e4 b 203e424 <msdos_find_name+0x1e0> <== NOT EXECUTED
203e498: c6 00 60 1c ld [ %g1 + 0x1c ], %g3 <== NOT EXECUTED
0203cb60 <msdos_find_name_in_fat_file>:
int name_len,
msdos_name_type_t name_type,
fat_dir_pos_t *dir_pos,
char *name_dir_entry
)
{
203cb60: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
203cb64: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED
203cb68: f0 27 a0 44 st %i0, [ %fp + 0x44 ] <== NOT EXECUTED
203cb6c: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
203cb70: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
203cb74: 82 10 00 1d mov %i5, %g1 <== NOT EXECUTED
uint32_t empty_space_count = 0;
bool empty_space_found = false;
uint32_t entries_per_block;
bool read_cluster = false;
assert(name_len > 0);
203cb78: 80 a7 20 00 cmp %i4, 0 <== NOT EXECUTED
203cb7c: 04 80 02 5e ble 203d4f4 <msdos_find_name_in_fat_file+0x994><== NOT EXECUTED
203cb80: f2 06 20 34 ld [ %i0 + 0x34 ], %i1 <== NOT EXECUTED
static inline void
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
203cb84: c4 07 a0 5c ld [ %fp + 0x5c ], %g2 <== NOT EXECUTED
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203cb88: c6 07 a0 5c ld [ %fp + 0x5c ], %g3 <== NOT EXECUTED
static inline void
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
203cb8c: c0 20 80 00 clr [ %g2 ] <== NOT EXECUTED
dir_pos->sname.ofs = 0;
203cb90: c0 20 a0 04 clr [ %g2 + 4 ] <== NOT EXECUTED
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203cb94: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203cb98: c4 20 e0 0c st %g2, [ %g3 + 0xc ] <== NOT EXECUTED
* is short still check for possible long entries with the short name.
*
* In PR1491 we need to have a LFN for a short file name entry. To
* test this make this test always fail, ie add "0 &&".
*/
if (create_node && (name_type == MSDOS_NAME_SHORT))
203cb9c: aa 8e a0 ff andcc %i2, 0xff, %l5 <== NOT EXECUTED
203cba0: 02 80 00 05 be 203cbb4 <msdos_find_name_in_fat_file+0x54> <== NOT EXECUTED
203cba4: c4 20 e0 08 st %g2, [ %g3 + 8 ] <== NOT EXECUTED
203cba8: 80 a7 60 01 cmp %i5, 1 <== NOT EXECUTED
203cbac: 02 80 00 09 be 203cbd0 <msdos_find_name_in_fat_file+0x70> <== NOT EXECUTED
203cbb0: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
lfn_entries = 0;
else
lfn_entries =
203cbb4: c8 07 a0 54 ld [ %fp + 0x54 ], %g4 <== NOT EXECUTED
203cbb8: c2 27 bf dc st %g1, [ %fp + -36 ] <== NOT EXECUTED
203cbbc: 90 01 20 0c add %g4, 0xc, %o0 <== NOT EXECUTED
203cbc0: 40 00 97 73 call 206298c <.div> <== NOT EXECUTED
203cbc4: 92 10 20 0d mov 0xd, %o1 <== NOT EXECUTED
203cbc8: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
203cbcc: d0 27 bf e8 st %o0, [ %fp + -24 ] <== NOT EXECUTED
((name_len - 1) + MSDOS_LFN_LEN_PER_ENTRY) / MSDOS_LFN_LEN_PER_ENTRY;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203cbd0: c6 07 a0 48 ld [ %fp + 0x48 ], %g3 <== NOT EXECUTED
203cbd4: c4 00 e0 20 ld [ %g3 + 0x20 ], %g2 <== NOT EXECUTED
203cbd8: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
203cbdc: 22 80 01 24 be,a 203d06c <msdos_find_name_in_fat_file+0x50c><== NOT EXECUTED
203cbe0: c4 00 e0 24 ld [ %g3 + 0x24 ], %g2 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
bts2rd = fat_fd->fat_file_size;
else
bts2rd = fs_info->fat.vol.bpc;
203cbe4: e6 16 60 06 lduh [ %i1 + 6 ], %l3 <== NOT EXECUTED
/*
* Remainder is not empty so is this entry empty ?
*/
empty_space_count++;
if (empty_space_count == (lfn_entries + 1))
203cbe8: c8 07 bf e8 ld [ %fp + -24 ], %g4 <== NOT EXECUTED
assert(name_len > 0);
fat_dir_pos_init(dir_pos);
lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;
203cbec: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
203cbf0: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
203cbf4: a0 10 00 19 mov %i1, %l0 <== NOT EXECUTED
203cbf8: c4 27 bf f4 st %g2, [ %fp + -12 ] <== NOT EXECUTED
203cbfc: c4 27 bf f8 st %g2, [ %fp + -8 ] <== NOT EXECUTED
203cc00: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
203cc04: b4 10 20 00 clr %i2 <== NOT EXECUTED
203cc08: a4 10 20 00 clr %l2 <== NOT EXECUTED
203cc0c: ac 10 20 00 clr %l6 <== NOT EXECUTED
203cc10: b8 10 20 00 clr %i4 <== NOT EXECUTED
203cc14: b0 10 20 00 clr %i0 <== NOT EXECUTED
203cc18: ae 10 20 00 clr %l7 <== NOT EXECUTED
203cc1c: a8 10 20 00 clr %l4 <== NOT EXECUTED
203cc20: b6 10 20 00 clr %i3 <== NOT EXECUTED
/*
* Remainder is not empty so is this entry empty ?
*/
empty_space_count++;
if (empty_space_count == (lfn_entries + 1))
203cc24: a2 01 20 01 add %g4, 1, %l1 <== NOT EXECUTED
memcpy(name_dir_entry, entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
}
lfn_start.cln = FAT_FILE_SHORT_NAME;
203cc28: ba 10 3f ff mov -1, %i5 <== NOT EXECUTED
203cc2c: b2 10 00 01 mov %g1, %i1 <== NOT EXECUTED
/*
* Scan the directory seeing if the file is present. While
* doing this see if a suitable location can be found to
* create the entry if the name is not found.
*/
while ((ret = fat_file_read(mt_entry, fat_fd, (dir_offset * bts2rd),
203cc30: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203cc34: d2 07 a0 48 ld [ %fp + 0x48 ], %o1 <== NOT EXECUTED
203cc38: d4 07 bf ec ld [ %fp + -20 ], %o2 <== NOT EXECUTED
203cc3c: 7f ff b0 5b call 2028da8 <fat_file_read> <== NOT EXECUTED
203cc40: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203cc44: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203cc48: 02 80 01 4e be 203d180 <msdos_find_name_in_fat_file+0x620><== NOT EXECUTED
203cc4c: 80 a2 20 1f cmp %o0, 0x1f <== NOT EXECUTED
bool remainder_empty = false;
#if MSDOS_FIND_PRINT
printf ("MSFS:[2] dir_offset:%li\n", dir_offset);
#endif
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203cc50: 04 80 01 46 ble 203d168 <msdos_find_name_in_fat_file+0x608><== NOT EXECUTED
203cc54: 80 a2 00 13 cmp %o0, %l3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
assert(ret == bts2rd);
203cc58: 12 80 02 1d bne 203d4cc <msdos_find_name_in_fat_file+0x96c><== NOT EXECUTED
203cc5c: 84 10 20 00 clr %g2 <== NOT EXECUTED
203cc60: d8 04 20 9c ld [ %l0 + 0x9c ], %o4 <== NOT EXECUTED
203cc64: 82 10 00 0c mov %o4, %g1 <== NOT EXECUTED
* to here and write the long file name if this is the start of
* a series of empty entries. If empty_space_count is 0 then
* we are currently not inside an empty series of entries. It
* is a count of empty entries.
*/
if (empty_space_count == 0)
203cc68: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203cc6c: 12 80 00 04 bne 203cc7c <msdos_find_name_in_fat_file+0x11c><== NOT EXECUTED
203cc70: da 08 40 00 ldub [ %g1 ], %o5 <== NOT EXECUTED
203cc74: ac 10 00 02 mov %g2, %l6 <== NOT EXECUTED
203cc78: b8 10 00 1b mov %i3, %i4 <== NOT EXECUTED
{
empty_space_entry = dir_entry;
empty_space_offset = dir_offset;
}
if (remainder_empty)
203cc7c: 86 8b 60 ff andcc %o5, 0xff, %g3 <== NOT EXECUTED
203cc80: 02 80 00 cd be 203cfb4 <msdos_find_name_in_fat_file+0x454><== NOT EXECUTED
203cc84: 80 a0 e0 e5 cmp %g3, 0xe5 <== NOT EXECUTED
printf ("MSFS:[3.2] esf:%i esc%i\n", empty_space_found, empty_space_count);
#endif
}
break;
}
else if (entry_empty)
203cc88: 02 80 00 4e be 203cdc0 <msdos_find_name_in_fat_file+0x260><== NOT EXECUTED
203cc8c: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
* A valid entry so handle it.
*
* If empty space has not been found we need to start the
* count again.
*/
if (create_node && !empty_space_found)
203cc90: 02 80 00 07 be 203ccac <msdos_find_name_in_fat_file+0x14c><== NOT EXECUTED
203cc94: c8 08 60 0b ldub [ %g1 + 0xb ], %g4 <== NOT EXECUTED
203cc98: 80 8e a0 ff btst 0xff, %i2 <== NOT EXECUTED
203cc9c: 12 80 00 04 bne 203ccac <msdos_find_name_in_fat_file+0x14c><== NOT EXECUTED
203cca0: 01 00 00 00 nop <== NOT EXECUTED
203cca4: a4 10 20 00 clr %l2 ! 0 <PROM_START> <== NOT EXECUTED
203cca8: ac 10 20 00 clr %l6 <== NOT EXECUTED
/*
* Check the attribute to see if the entry is for a long
* file name.
*/
if ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==
203ccac: 88 09 20 3f and %g4, 0x3f, %g4 <== NOT EXECUTED
203ccb0: 80 a1 20 0f cmp %g4, 0xf <== NOT EXECUTED
203ccb4: 02 80 00 6a be 203ce5c <msdos_find_name_in_fat_file+0x2fc><== NOT EXECUTED
203ccb8: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
* If a LFN has been found and it matched check the
* entries have all been found and the checksum is
* correct. If this is the case return the short file
* name entry.
*/
if (lfn_matched)
203ccbc: 02 80 00 51 be 203ce00 <msdos_find_name_in_fat_file+0x2a0><== NOT EXECUTED
203ccc0: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
203ccc4: 86 10 20 00 clr %g3 <== NOT EXECUTED
203ccc8: 88 10 20 00 clr %g4 <== NOT EXECUTED
203cccc: 10 80 00 07 b 203cce8 <msdos_find_name_in_fat_file+0x188> <== NOT EXECUTED
203ccd0: 96 10 20 00 clr %o3 <== NOT EXECUTED
uint8_t cs = 0;
uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(entry);
int i;
for (i = 0; i < MSDOS_SHORT_NAME_LEN; i++, p++)
cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
203ccd4: da 08 40 03 ldub [ %g1 + %g3 ], %o5 <== NOT EXECUTED
203ccd8: 96 0a e0 ff and %o3, 0xff, %o3 <== NOT EXECUTED
203ccdc: 88 0a e0 01 and %o3, 1, %g4 <== NOT EXECUTED
203cce0: 88 20 00 04 neg %g4 <== NOT EXECUTED
203cce4: 88 09 20 80 and %g4, 0x80, %g4 <== NOT EXECUTED
203cce8: 88 03 40 04 add %o5, %g4, %g4 <== NOT EXECUTED
203ccec: 97 32 e0 01 srl %o3, 1, %o3 <== NOT EXECUTED
{
uint8_t cs = 0;
uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(entry);
int i;
for (i = 0; i < MSDOS_SHORT_NAME_LEN; i++, p++)
203ccf0: 86 00 e0 01 inc %g3 <== NOT EXECUTED
203ccf4: 80 a0 e0 0b cmp %g3, 0xb <== NOT EXECUTED
203ccf8: 12 bf ff f7 bne 203ccd4 <msdos_find_name_in_fat_file+0x174><== NOT EXECUTED
203ccfc: 96 01 00 0b add %g4, %o3, %o3 <== NOT EXECUTED
cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
if (lfn_entry || (lfn_checksum != cs))
203cd00: 96 0a e0 ff and %o3, 0xff, %o3 <== NOT EXECUTED
203cd04: 86 0d e0 ff and %l7, 0xff, %g3 <== NOT EXECUTED
203cd08: 80 a0 c0 0b cmp %g3, %o3 <== NOT EXECUTED
203cd0c: 12 80 00 3d bne 203ce00 <msdos_find_name_in_fat_file+0x2a0><== NOT EXECUTED
203cd10: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
203cd14: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203cd18: 12 80 00 3a bne 203ce00 <msdos_find_name_in_fat_file+0x2a0><== NOT EXECUTED
203cd1c: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
#endif
/*
* We get the entry we looked for - fill the position
* structure and the 32 bytes of the short entry
*/
int rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203cd20: d6 07 bf ec ld [ %fp + -20 ], %o3 <== NOT EXECUTED
203cd24: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203cd28: d2 07 a0 48 ld [ %fp + 0x48 ], %o1 <== NOT EXECUTED
203cd2c: d8 07 a0 5c ld [ %fp + 0x5c ], %o4 <== NOT EXECUTED
203cd30: a0 10 00 01 mov %g1, %l0 <== NOT EXECUTED
203cd34: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
203cd38: 7f ff ae 8d call 202876c <fat_file_ioctl> <== NOT EXECUTED
203cd3c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
dir_offset * bts2rd,
&dir_pos->sname.cln);
if (rc != RC_OK)
203cd40: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203cd44: 12 80 00 1b bne 203cdb0 <msdos_find_name_in_fat_file+0x250><== NOT EXECUTED
203cd48: c8 07 a0 5c ld [ %fp + 0x5c ], %g4 <== NOT EXECUTED
return rc;
dir_pos->sname.ofs = dir_entry;
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
203cd4c: d2 07 bf f4 ld [ %fp + -12 ], %o1 <== NOT EXECUTED
dir_offset * bts2rd,
&dir_pos->sname.cln);
if (rc != RC_OK)
return rc;
dir_pos->sname.ofs = dir_entry;
203cd50: e2 21 20 04 st %l1, [ %g4 + 4 ] <== NOT EXECUTED
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
203cd54: 80 a2 7f ff cmp %o1, -1 <== NOT EXECUTED
203cd58: 02 80 00 0d be 203cd8c <msdos_find_name_in_fat_file+0x22c><== NOT EXECUTED
203cd5c: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
{
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203cd60: 7f ff 17 8b call 2002b8c <.umul> <== NOT EXECUTED
203cd64: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
203cd68: d2 07 a0 48 ld [ %fp + 0x48 ], %o1 <== NOT EXECUTED
203cd6c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
203cd70: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203cd74: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203cd78: 7f ff ae 7d call 202876c <fat_file_ioctl> <== NOT EXECUTED
203cd7c: 98 07 bf f4 add %fp, -12, %o4 <== NOT EXECUTED
lfn_start.cln * bts2rd,
&lfn_start.cln);
if (rc != RC_OK)
203cd80: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203cd84: 12 80 00 0b bne 203cdb0 <msdos_find_name_in_fat_file+0x250><== NOT EXECUTED
203cd88: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
203cd8c: c4 07 a0 5c ld [ %fp + 0x5c ], %g2 <== NOT EXECUTED
dir_pos->lname.ofs = lfn_start.ofs;
memcpy(name_dir_entry, entry,
203cd90: d0 07 a0 60 ld [ %fp + 0x60 ], %o0 <== NOT EXECUTED
&lfn_start.cln);
if (rc != RC_OK)
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
203cd94: c2 20 a0 08 st %g1, [ %g2 + 8 ] <== NOT EXECUTED
dir_pos->lname.ofs = lfn_start.ofs;
203cd98: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
memcpy(name_dir_entry, entry,
203cd9c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
dir_pos->lname.ofs = lfn_start.ofs;
203cda0: c2 20 a0 0c st %g1, [ %g2 + 0xc ] <== NOT EXECUTED
memcpy(name_dir_entry, entry,
203cda4: 94 10 20 20 mov 0x20, %o2 <== NOT EXECUTED
203cda8: 40 00 43 02 call 204d9b0 <memcpy> <== NOT EXECUTED
203cdac: b0 10 20 00 clr %i0 <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
203cdb0: 81 c7 e0 08 ret <== NOT EXECUTED
203cdb4: 81 e8 00 00 restore <== NOT EXECUTED
empty_space_entry = 0;
read_cluster = true;
}
return 0;
}
203cdb8: 81 c7 e0 08 ret <== NOT EXECUTED
203cdbc: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
break;
}
else if (entry_empty)
{
if (create_node)
203cdc0: 22 80 00 07 be,a 203cddc <msdos_find_name_in_fat_file+0x27c><== NOT EXECUTED
203cdc4: 82 00 60 20 add %g1, 0x20, %g1 <== NOT EXECUTED
{
/*
* Remainder is not empty so is this entry empty ?
*/
empty_space_count++;
203cdc8: a4 04 a0 01 inc %l2 <== NOT EXECUTED
if (empty_space_count == (lfn_entries + 1))
203cdcc: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
203cdd0: 22 80 00 02 be,a 203cdd8 <msdos_find_name_in_fat_file+0x278><== NOT EXECUTED
203cdd4: b4 10 20 01 mov 1, %i2 <== NOT EXECUTED
memcpy(name_dir_entry, entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
}
lfn_start.cln = FAT_FILE_SHORT_NAME;
203cdd8: 82 00 60 20 add %g1, 0x20, %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
assert(ret == bts2rd);
/* have to look at the DIR_NAME as "raw" 8-bit data */
for (dir_entry = 0;
203cddc: 84 20 40 0c sub %g1, %o4, %g2 <== NOT EXECUTED
203cde0: 80 a4 c0 02 cmp %l3, %g2 <== NOT EXECUTED
203cde4: 18 bf ff a2 bgu 203cc6c <msdos_find_name_in_fat_file+0x10c><== NOT EXECUTED
203cde8: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203cdec: c6 07 bf ec ld [ %fp + -20 ], %g3 <== NOT EXECUTED
}
if (remainder_empty)
break;
dir_offset++;
203cdf0: b6 06 e0 01 inc %i3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
assert(ret == bts2rd);
/* have to look at the DIR_NAME as "raw" 8-bit data */
for (dir_entry = 0;
203cdf4: 86 00 c0 13 add %g3, %l3, %g3 <== NOT EXECUTED
203cdf8: 10 bf ff 8e b 203cc30 <msdos_find_name_in_fat_file+0xd0> <== NOT EXECUTED
203cdfc: c6 27 bf ec st %g3, [ %fp + -20 ] <== NOT EXECUTED
* short and they match then we have the entry. We will not
* match a long file name against a short file name because
* a long file name that generates a matching short file
* name is not a long file name.
*/
if (lfn_matched ||
203ce00: 02 80 00 05 be 203ce14 <msdos_find_name_in_fat_file+0x2b4><== NOT EXECUTED
203ce04: c6 07 bf f4 ld [ %fp + -12 ], %g3 <== NOT EXECUTED
memcpy(name_dir_entry, entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
}
lfn_start.cln = FAT_FILE_SHORT_NAME;
203ce08: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
203ce0c: 10 bf ff f3 b 203cdd8 <msdos_find_name_in_fat_file+0x278> <== NOT EXECUTED
203ce10: a8 10 20 00 clr %l4 <== NOT EXECUTED
* short and they match then we have the entry. We will not
* match a long file name against a short file name because
* a long file name that generates a matching short file
* name is not a long file name.
*/
if (lfn_matched ||
203ce14: 80 a0 ff ff cmp %g3, -1 <== NOT EXECUTED
203ce18: 32 bf ff fd bne,a 203ce0c <msdos_find_name_in_fat_file+0x2ac><== NOT EXECUTED
203ce1c: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
((name_type == MSDOS_NAME_SHORT) &&
(lfn_start.cln == FAT_FILE_SHORT_NAME) &&
(memcmp(MSDOS_DIR_NAME(entry),
203ce20: d2 07 a0 60 ld [ %fp + 0x60 ], %o1 <== NOT EXECUTED
203ce24: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
203ce28: c2 27 bf dc st %g1, [ %fp + -36 ] <== NOT EXECUTED
203ce2c: c4 27 bf e0 st %g2, [ %fp + -32 ] <== NOT EXECUTED
203ce30: d8 27 bf e4 st %o4, [ %fp + -28 ] <== NOT EXECUTED
203ce34: 40 00 42 ae call 204d8ec <memcmp> <== NOT EXECUTED
203ce38: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
* short and they match then we have the entry. We will not
* match a long file name against a short file name because
* a long file name that generates a matching short file
* name is not a long file name.
*/
if (lfn_matched ||
203ce3c: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
203ce40: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ce44: c4 07 bf e0 ld [ %fp + -32 ], %g2 <== NOT EXECUTED
203ce48: 02 bf ff b6 be 203cd20 <msdos_find_name_in_fat_file+0x1c0><== NOT EXECUTED
203ce4c: d8 07 bf e4 ld [ %fp + -28 ], %o4 <== NOT EXECUTED
memcpy(name_dir_entry, entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
}
lfn_start.cln = FAT_FILE_SHORT_NAME;
203ce50: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
203ce54: 10 bf ff e1 b 203cdd8 <msdos_find_name_in_fat_file+0x278> <== NOT EXECUTED
203ce58: a8 10 20 00 clr %l4 <== NOT EXECUTED
#endif
/*
* If we are not already processing a LFN see if this is
* the first entry of a LFN ?
*/
if (lfn_start.cln == FAT_FILE_SHORT_NAME)
203ce5c: da 07 bf f4 ld [ %fp + -12 ], %o5 <== NOT EXECUTED
203ce60: 80 a3 7f ff cmp %o5, -1 <== NOT EXECUTED
203ce64: 02 80 00 42 be 203cf6c <msdos_find_name_in_fat_file+0x40c><== NOT EXECUTED
203ce68: 88 10 00 17 mov %l7, %g4 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These
* could be orphaned entries depending on the history
* of the disk.
*/
if ((lfn_entry != (*MSDOS_DIR_ENTRY_TYPE(entry) &
203ce6c: 86 08 e0 3f and %g3, 0x3f, %g3 <== NOT EXECUTED
203ce70: 80 a0 c0 18 cmp %g3, %i0 <== NOT EXECUTED
203ce74: 22 80 00 05 be,a 203ce88 <msdos_find_name_in_fat_file+0x328><== NOT EXECUTED
203ce78: ee 08 60 0d ldub [ %g1 + 0xd ], %l7 <== NOT EXECUTED
(lfn_checksum != *MSDOS_DIR_LFN_CHECKSUM(entry)))
{
#if MSDOS_FIND_PRINT
printf ("MSFS:[4.4] no match\n");
#endif
lfn_start.cln = FAT_FILE_SHORT_NAME;
203ce7c: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
continue;
203ce80: 10 bf ff d6 b 203cdd8 <msdos_find_name_in_fat_file+0x278> <== NOT EXECUTED
203ce84: ae 10 00 04 mov %g4, %l7 <== NOT EXECUTED
* If the entry number or the check sum do not match
* forget this series of long directory entries. These
* could be orphaned entries depending on the history
* of the disk.
*/
if ((lfn_entry != (*MSDOS_DIR_ENTRY_TYPE(entry) &
203ce88: 84 09 20 ff and %g4, 0xff, %g2 <== NOT EXECUTED
203ce8c: 9a 0d e0 ff and %l7, 0xff, %o5 <== NOT EXECUTED
203ce90: 80 a3 40 02 cmp %o5, %g2 <== NOT EXECUTED
203ce94: 32 bf ff fb bne,a 203ce80 <msdos_find_name_in_fat_file+0x320><== NOT EXECUTED
203ce98: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
#endif
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
203ce9c: b0 06 3f ff add %i0, -1, %i0 <== NOT EXECUTED
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203cea0: 89 2e 20 04 sll %i0, 4, %g4 <== NOT EXECUTED
203cea4: 85 2e 20 02 sll %i0, 2, %g2 <== NOT EXECUTED
203cea8: 84 21 00 02 sub %g4, %g2, %g2 <== NOT EXECUTED
((o + i) != name_len))
lfn_start.cln = FAT_FILE_SHORT_NAME;
break;
}
if (((o + i) >= name_len) || (*p != name[o + i]))
203ceac: c8 07 a0 50 ld [ %fp + 0x50 ], %g4 <== NOT EXECUTED
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203ceb0: 92 00 80 18 add %g2, %i0, %o1 <== NOT EXECUTED
203ceb4: 9a 00 60 01 add %g1, 1, %o5 <== NOT EXECUTED
((o + i) != name_len))
lfn_start.cln = FAT_FILE_SHORT_NAME;
break;
}
if (((o + i) >= name_len) || (*p != name[o + i]))
203ceb8: 90 01 00 09 add %g4, %o1, %o0 <== NOT EXECUTED
{
#if MSDOS_FIND_PRINT > 1
printf ("MSFS:[6] o:%i i:%i *p:%c(%02x) name[o + i]:%c(%02x)\n",
o, i, *p, *p, name[o + i], name[o + i]);
#endif
if (*p == '\0')
203cebc: c8 4b 40 00 ldsb [ %o5 ], %g4 <== NOT EXECUTED
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203cec0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203cec4: 84 10 20 00 clr %g2 <== NOT EXECUTED
{
#if MSDOS_FIND_PRINT > 1
printf ("MSFS:[6] o:%i i:%i *p:%c(%02x) name[o + i]:%c(%02x)\n",
o, i, *p, *p, name[o + i], name[o + i]);
#endif
if (*p == '\0')
203cec8: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
203cecc: 02 80 00 16 be 203cf24 <msdos_find_name_in_fat_file+0x3c4><== NOT EXECUTED
203ced0: de 07 a0 54 ld [ %fp + 0x54 ], %o7 <== NOT EXECUTED
((o + i) != name_len))
lfn_start.cln = FAT_FILE_SHORT_NAME;
break;
}
if (((o + i) >= name_len) || (*p != name[o + i]))
203ced4: 94 00 80 09 add %g2, %o1, %o2 <== NOT EXECUTED
203ced8: 80 a3 c0 0a cmp %o7, %o2 <== NOT EXECUTED
203cedc: 24 80 00 1c ble,a 203cf4c <msdos_find_name_in_fat_file+0x3ec><== NOT EXECUTED
203cee0: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
203cee4: d4 4a 00 02 ldsb [ %o0 + %g2 ], %o2 <== NOT EXECUTED
203cee8: 80 a1 00 0a cmp %g4, %o2 <== NOT EXECUTED
203ceec: 12 80 00 17 bne 203cf48 <msdos_find_name_in_fat_file+0x3e8><== NOT EXECUTED
203cef0: 80 a0 a0 04 cmp %g2, 4 <== NOT EXECUTED
{
lfn_start.cln = FAT_FILE_SHORT_NAME;
break;
}
switch (i)
203cef4: 02 80 00 28 be 203cf94 <msdos_find_name_in_fat_file+0x434><== NOT EXECUTED
203cef8: 80 a0 a0 0a cmp %g2, 0xa <== NOT EXECUTED
203cefc: 02 80 00 2a be 203cfa4 <msdos_find_name_in_fat_file+0x444><== NOT EXECUTED
203cf00: 80 a2 e0 0c cmp %o3, 0xc <== NOT EXECUTED
p = entry + 1;
#if MSDOS_FIND_PRINT
printf ("MSFS:[5] lfne:%i\n", lfn_entry);
#endif
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
203cf04: 14 80 00 12 bg 203cf4c <msdos_find_name_in_fat_file+0x3ec><== NOT EXECUTED
203cf08: 84 00 a0 01 inc %g2 <== NOT EXECUTED
break;
case 10:
p += 4;
break;
default:
p += 2;
203cf0c: 9a 03 60 02 add %o5, 2, %o5 <== NOT EXECUTED
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203cf10: 96 02 e0 01 inc %o3 <== NOT EXECUTED
{
#if MSDOS_FIND_PRINT > 1
printf ("MSFS:[6] o:%i i:%i *p:%c(%02x) name[o + i]:%c(%02x)\n",
o, i, *p, *p, name[o + i], name[o + i]);
#endif
if (*p == '\0')
203cf14: c8 4b 40 00 ldsb [ %o5 ], %g4 <== NOT EXECUTED
203cf18: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
203cf1c: 12 bf ff ef bne 203ced8 <msdos_find_name_in_fat_file+0x378><== NOT EXECUTED
203cf20: 94 00 80 09 add %g2, %o1, %o2 <== NOT EXECUTED
/*
* If this is the first entry, ie the last part of the
* long file name and the length does not match then
* the file names do not match.
*/
if (((lfn_entry + 1) == lfn_entries) &&
203cf24: c8 07 bf e8 ld [ %fp + -24 ], %g4 <== NOT EXECUTED
203cf28: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED
203cf2c: 12 80 00 09 bne 203cf50 <msdos_find_name_in_fat_file+0x3f0><== NOT EXECUTED
203cf30: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203cf34: c6 07 a0 54 ld [ %fp + 0x54 ], %g3 <== NOT EXECUTED
203cf38: 84 00 80 09 add %g2, %o1, %g2 <== NOT EXECUTED
203cf3c: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
203cf40: 02 80 00 04 be 203cf50 <msdos_find_name_in_fat_file+0x3f0><== NOT EXECUTED
203cf44: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
break;
}
if (((o + i) >= name_len) || (*p != name[o + i]))
{
lfn_start.cln = FAT_FILE_SHORT_NAME;
203cf48: fa 27 bf f4 st %i5, [ %fp + -12 ] <== NOT EXECUTED
p += 2;
break;
}
}
lfn_matched = ((lfn_entry == 0) &&
203cf4c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203cf50: 12 bf ff a2 bne 203cdd8 <msdos_find_name_in_fat_file+0x278><== NOT EXECUTED
203cf54: a8 10 20 00 clr %l4 <== NOT EXECUTED
* RC_OK on success, or error code if error occured (errno set
* appropriately)
*
*/
#define MSDOS_FIND_PRINT 0
int msdos_find_name_in_fat_file(
203cf58: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
203cf5c: 84 38 00 02 xnor %g0, %g2, %g2 <== NOT EXECUTED
203cf60: 80 a0 00 02 cmp %g0, %g2 <== NOT EXECUTED
203cf64: 10 bf ff 9d b 203cdd8 <msdos_find_name_in_fat_file+0x278> <== NOT EXECUTED
203cf68: a8 40 20 00 addx %g0, 0, %l4 <== NOT EXECUTED
/*
* The first entry must have the last long entry
* flag set.
*/
if ((*MSDOS_DIR_ENTRY_TYPE(entry) &
203cf6c: 80 88 e0 40 btst 0x40, %g3 <== NOT EXECUTED
203cf70: 02 bf ff 9a be 203cdd8 <msdos_find_name_in_fat_file+0x278><== NOT EXECUTED
203cf74: a8 10 20 00 clr %l4 <== NOT EXECUTED
* entry match the number we expect for this
* file name. Note we do not know the number of
* characters in the entry so this is check further
* on when the characters are checked.
*/
if (lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
203cf78: c8 07 bf e8 ld [ %fp + -24 ], %g4 <== NOT EXECUTED
203cf7c: 86 08 e0 3f and %g3, 0x3f, %g3 <== NOT EXECUTED
203cf80: 80 a0 c0 04 cmp %g3, %g4 <== NOT EXECUTED
203cf84: 22 80 00 34 be,a 203d054 <msdos_find_name_in_fat_file+0x4f4><== NOT EXECUTED
203cf88: c4 27 bf f8 st %g2, [ %fp + -8 ] <== NOT EXECUTED
memcpy(name_dir_entry, entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
}
lfn_start.cln = FAT_FILE_SHORT_NAME;
203cf8c: 10 bf ff 94 b 203cddc <msdos_find_name_in_fat_file+0x27c> <== NOT EXECUTED
203cf90: 82 00 60 20 add %g1, 0x20, %g1 <== NOT EXECUTED
}
switch (i)
{
case 4:
p += 5;
203cf94: 9a 03 60 05 add %o5, 5, %o5 <== NOT EXECUTED
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203cf98: 84 00 a0 01 inc %g2 <== NOT EXECUTED
203cf9c: 10 bf ff de b 203cf14 <msdos_find_name_in_fat_file+0x3b4> <== NOT EXECUTED
203cfa0: 96 02 e0 01 inc %o3 <== NOT EXECUTED
{
case 4:
p += 5;
break;
case 10:
p += 4;
203cfa4: 9a 03 60 04 add %o5, 4, %o5 <== NOT EXECUTED
lfn_start.cln = FAT_FILE_SHORT_NAME;
continue;
}
lfn_entry--;
o = lfn_entry * MSDOS_LFN_LEN_PER_ENTRY;
203cfa8: 84 00 a0 01 inc %g2 <== NOT EXECUTED
203cfac: 10 bf ff da b 203cf14 <msdos_find_name_in_fat_file+0x3b4> <== NOT EXECUTED
203cfb0: 96 02 e0 01 inc %o3 <== NOT EXECUTED
203cfb4: 82 10 00 19 mov %i1, %g1 <== NOT EXECUTED
#endif
/*
* If just looking and there is no more entries in the
* directory - return name-not-found
*/
if (!create_node)
203cfb8: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
203cfbc: 02 80 00 75 be 203d190 <msdos_find_name_in_fat_file+0x630><== NOT EXECUTED
203cfc0: b2 10 00 10 mov %l0, %i1 <== NOT EXECUTED
* Lets go and write the directory entries. If we have not found
* any available space add the remaining number of entries to any that
* we may have already found that are just before this entry. If more
* are needed FAT_EOF is returned by the read and we extend the file.
*/
if (!empty_space_found)
203cfc4: 80 8e a0 ff btst 0xff, %i2 <== NOT EXECUTED
203cfc8: 12 80 00 07 bne 203cfe4 <msdos_find_name_in_fat_file+0x484><== NOT EXECUTED
203cfcc: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
{
empty_space_count +=
203cfd0: a3 30 a0 05 srl %g2, 5, %l1 <== NOT EXECUTED
entries_per_block - (dir_entry / MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203cfd4: 85 34 e0 05 srl %l3, 5, %g2 <== NOT EXECUTED
203cfd8: a4 04 80 02 add %l2, %g2, %l2 <== NOT EXECUTED
* we may have already found that are just before this entry. If more
* are needed FAT_EOF is returned by the read and we extend the file.
*/
if (!empty_space_found)
{
empty_space_count +=
203cfdc: a4 24 80 11 sub %l2, %l1, %l2 <== NOT EXECUTED
* data to place in each long file name entry. First set the short
* file name to the slot of the SFN entry. This will mean no clashes
* in this directory.
*/
lfn_checksum = 0;
if (name_type == MSDOS_NAME_LONG)
203cfe0: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
203cfe4: 02 80 01 10 be 203d424 <msdos_find_name_in_fat_file+0x8c4><== NOT EXECUTED
203cfe8: c2 07 bf e8 ld [ %fp + -24 ], %g1 <== NOT EXECUTED
int slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + lfn_entries + 1;
msdos_short_name_hex(MSDOS_DIR_NAME(name_dir_entry), slot);
}
if (lfn_entries)
203cfec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203cff0: 02 80 00 12 be 203d038 <msdos_find_name_in_fat_file+0x4d8><== NOT EXECUTED
203cff4: a8 10 20 00 clr %l4 <== NOT EXECUTED
203cff8: 84 10 20 00 clr %g2 <== NOT EXECUTED
203cffc: 82 10 20 00 clr %g1 <== NOT EXECUTED
203d000: a8 10 20 00 clr %l4 <== NOT EXECUTED
203d004: 10 80 00 06 b 203d01c <msdos_find_name_in_fat_file+0x4bc> <== NOT EXECUTED
203d008: c8 07 a0 60 ld [ %fp + 0x60 ], %g4 <== NOT EXECUTED
{
uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(name_dir_entry);
int i;
for (i = 0; i < 11; i++, p++)
lfn_checksum =
203d00c: a8 0d 20 ff and %l4, 0xff, %l4 <== NOT EXECUTED
203d010: 82 0d 20 01 and %l4, 1, %g1 <== NOT EXECUTED
203d014: 82 20 00 01 neg %g1 <== NOT EXECUTED
203d018: 82 08 60 80 and %g1, 0x80, %g1 <== NOT EXECUTED
203d01c: c6 09 00 02 ldub [ %g4 + %g2 ], %g3 <== NOT EXECUTED
203d020: a9 35 20 01 srl %l4, 1, %l4 <== NOT EXECUTED
203d024: 82 00 40 03 add %g1, %g3, %g1 <== NOT EXECUTED
if (lfn_entries)
{
uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(name_dir_entry);
int i;
for (i = 0; i < 11; i++, p++)
203d028: 84 00 a0 01 inc %g2 <== NOT EXECUTED
203d02c: 80 a0 a0 0b cmp %g2, 0xb <== NOT EXECUTED
203d030: 12 bf ff f7 bne 203d00c <msdos_find_name_in_fat_file+0x4ac><== NOT EXECUTED
203d034: a8 00 40 14 add %g1, %l4, %l4 <== NOT EXECUTED
* empty_space_count is a count of empty entries in the currently
* read cluster so if 0 there is no space. Note, dir_offset will
* be at the next cluster so we can just make empty_space_offset
* that value.
*/
if (empty_space_count == 0)
203d038: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203d03c: 12 80 00 15 bne 203d090 <msdos_find_name_in_fat_file+0x530><== NOT EXECUTED
203d040: 80 a7 00 1b cmp %i4, %i3 <== NOT EXECUTED
203d044: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
203d048: ac 10 20 00 clr %l6 <== NOT EXECUTED
}
/*
* Have we read past the empty block ? If so go back and read it again.
*/
if (dir_offset != empty_space_offset)
203d04c: 10 80 00 13 b 203d098 <msdos_find_name_in_fat_file+0x538> <== NOT EXECUTED
203d050: b8 10 00 1b mov %i3, %i4 <== NOT EXECUTED
continue;
/*
* Get the checksum of the short entry.
*/
lfn_start.cln = dir_offset;
203d054: f6 27 bf f4 st %i3, [ %fp + -12 ] <== NOT EXECUTED
lfn_start.ofs = dir_entry;
lfn_entry = lfn_entries;
lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);
203d058: f0 07 bf e8 ld [ %fp + -24 ], %i0 <== NOT EXECUTED
203d05c: c8 08 60 0d ldub [ %g1 + 0xd ], %g4 <== NOT EXECUTED
203d060: c6 08 40 00 ldub [ %g1 ], %g3 <== NOT EXECUTED
203d064: 10 bf ff 82 b 203ce6c <msdos_find_name_in_fat_file+0x30c> <== NOT EXECUTED
203d068: a8 10 20 00 clr %l4 <== NOT EXECUTED
lfn_entries = 0;
else
lfn_entries =
((name_len - 1) + MSDOS_LFN_LEN_PER_ENTRY) / MSDOS_LFN_LEN_PER_ENTRY;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203d06c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203d070: 32 bf fe de bne,a 203cbe8 <msdos_find_name_in_fat_file+0x88><== NOT EXECUTED
203d074: e6 16 60 06 lduh [ %i1 + 6 ], %l3 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
203d078: c4 0e 60 0a ldub [ %i1 + 0xa ], %g2 <== NOT EXECUTED
203d07c: 80 88 a0 03 btst 3, %g2 <== NOT EXECUTED
203d080: 22 bf fe da be,a 203cbe8 <msdos_find_name_in_fat_file+0x88><== NOT EXECUTED
203d084: e6 16 60 06 lduh [ %i1 + 6 ], %l3 <== NOT EXECUTED
lfn_entries = 0;
else
lfn_entries =
((name_len - 1) + MSDOS_LFN_LEN_PER_ENTRY) / MSDOS_LFN_LEN_PER_ENTRY;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203d088: 10 bf fe d8 b 203cbe8 <msdos_find_name_in_fat_file+0x88> <== NOT EXECUTED
203d08c: e6 00 e0 18 ld [ %g3 + 0x18 ], %l3 <== NOT EXECUTED
}
/*
* Have we read past the empty block ? If so go back and read it again.
*/
if (dir_offset != empty_space_offset)
203d090: 02 80 01 21 be 203d514 <msdos_find_name_in_fat_file+0x9b4><== NOT EXECUTED
203d094: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
#endif
/*
* The one more is the short entry.
*/
while (lfn_entry < (lfn_entries + 1))
203d098: c4 07 bf e8 ld [ %fp + -24 ], %g2 <== NOT EXECUTED
203d09c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203d0a0: 06 bf ff 46 bl 203cdb8 <msdos_find_name_in_fat_file+0x258><== NOT EXECUTED
203d0a4: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
{
/* get current cluster number */
int rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d0a8: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
read_cluster = true;
/*
* Handle the entry writes.
*/
lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;
203d0ac: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
203d0b0: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
{
/* get current cluster number */
int rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d0b4: 7f ff 16 b6 call 2002b8c <.umul> <== NOT EXECUTED
203d0b8: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
length, lfn_entry);
#endif
/*
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
203d0bc: c6 07 bf e8 ld [ %fp + -24 ], %g3 <== NOT EXECUTED
dir_pos->sname.ofs = dir_entry;
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
{
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d0c0: f0 07 a0 48 ld [ %fp + 0x48 ], %i0 <== NOT EXECUTED
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
{
/* get current cluster number */
int rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d0c4: b6 10 20 00 clr %i3 <== NOT EXECUTED
203d0c8: ba 10 00 08 mov %o0, %i5 <== NOT EXECUTED
length, lfn_entry);
#endif
/*
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
203d0cc: ae 00 e0 01 add %g3, 1, %l7 <== NOT EXECUTED
*/
while (lfn_entry < (lfn_entries + 1))
{
int length = 0;
if (read_cluster)
203d0d0: 80 8c 20 ff btst 0xff, %l0 <== NOT EXECUTED
203d0d4: 02 80 00 34 be 203d1a4 <msdos_find_name_in_fat_file+0x644><== NOT EXECUTED
203d0d8: b4 10 00 1d mov %i5, %i2 <== NOT EXECUTED
{
uint32_t new_length;
#if MSDOS_FIND_PRINT
printf ("MSFS:[9.1] eso:%li\n", empty_space_offset);
#endif
ret = fat_file_read(mt_entry, fat_fd,
203d0dc: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
203d0e0: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203d0e4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203d0e8: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
203d0ec: 7f ff af 2f call 2028da8 <fat_file_read> <== NOT EXECUTED
203d0f0: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
(empty_space_offset * bts2rd), bts2rd,
fs_info->cl_buf);
if (ret != bts2rd)
203d0f4: 80 a2 00 13 cmp %o0, %l3 <== NOT EXECUTED
203d0f8: 02 80 00 2a be 203d1a0 <msdos_find_name_in_fat_file+0x640><== NOT EXECUTED
203d0fc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
{
if (ret != FAT_EOF)
203d100: 12 80 00 1a bne 203d168 <msdos_find_name_in_fat_file+0x608><== NOT EXECUTED
203d104: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
#if MSDOS_FIND_PRINT
printf ("MSFS:[9.2] extending file:%li\n", empty_space_offset);
#endif
ret = fat_file_extend (mt_entry, fat_fd, empty_space_offset * bts2rd,
203d108: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203d10c: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
203d110: 7f ff ae 0e call 2028948 <fat_file_extend> <== NOT EXECUTED
203d114: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
&new_length);
if (ret != RC_OK)
203d118: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d11c: 12 80 00 f4 bne 203d4ec <msdos_find_name_in_fat_file+0x98c><== NOT EXECUTED
203d120: f4 07 bf fc ld [ %fp + -4 ], %i2 <== NOT EXECUTED
return ret;
#if MSDOS_FIND_PRINT
printf ("MSFS:[9.3] extended: %d <-> %d\n", new_length, empty_space_offset * bts2rd);
#endif
if (new_length != (empty_space_offset * bts2rd))
203d124: 80 a6 80 1d cmp %i2, %i5 <== NOT EXECUTED
203d128: 12 80 00 10 bne 203d168 <msdos_find_name_in_fat_file+0x608><== NOT EXECUTED
203d12c: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
memset(fs_info->cl_buf, 0, bts2rd);
203d130: d0 06 60 9c ld [ %i1 + 0x9c ], %o0 <== NOT EXECUTED
203d134: 40 00 42 b2 call 204dbfc <memset> <== NOT EXECUTED
203d138: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
ret = fat_file_write(mt_entry, fat_fd,
203d13c: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203d140: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
203d144: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203d148: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
203d14c: 7f ff ae 7b call 2028b38 <fat_file_write> <== NOT EXECUTED
203d150: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
empty_space_offset * bts2rd,
bts2rd, fs_info->cl_buf);
#if MSDOS_FIND_PRINT
printf ("MSFS:[9.4] clear write: %d\n", ret);
#endif
if (ret == -1)
203d154: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
203d158: 02 80 00 db be 203d4c4 <msdos_find_name_in_fat_file+0x964><== NOT EXECUTED
203d15c: 80 a2 00 13 cmp %o0, %l3 <== NOT EXECUTED
return ret;
else if (ret != bts2rd)
203d160: 02 80 00 12 be 203d1a8 <msdos_find_name_in_fat_file+0x648><== NOT EXECUTED
203d164: 80 a4 c0 16 cmp %l3, %l6 <== NOT EXECUTED
(empty_space_offset * bts2rd) + empty_space_entry,
length, fs_info->cl_buf + empty_space_entry);
if (ret == -1)
return ret;
else if (ret != length)
rtems_set_errno_and_return_minus_one(EIO);
203d168: 40 00 34 c6 call 204a480 <__errno> <== NOT EXECUTED
203d16c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203d170: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203d174: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203d178: 81 c7 e0 08 ret <== NOT EXECUTED
203d17c: 81 e8 00 00 restore <== NOT EXECUTED
203d180: 82 10 00 19 mov %i1, %g1 <== NOT EXECUTED
}
/*
* If we are not to create the entry return a not found error.
*/
if (!create_node)
203d184: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
203d188: 12 bf ff 96 bne 203cfe0 <msdos_find_name_in_fat_file+0x480><== NOT EXECUTED
203d18c: b2 10 00 10 mov %l0, %i1 <== NOT EXECUTED
if (ret == -1)
return ret;
else if (ret != length)
rtems_set_errno_and_return_minus_one(EIO);
empty_space_offset++;
203d190: 31 00 00 1f sethi %hi(0x7c00), %i0 <== NOT EXECUTED
203d194: b0 16 21 01 or %i0, 0x101, %i0 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203d198: 81 c7 e0 08 ret <== NOT EXECUTED
203d19c: 81 e8 00 00 restore <== NOT EXECUTED
#if MSDOS_FIND_PRINT
printf ("MSFS:[9.4] clear write: %d\n", ret);
#endif
if (ret == -1)
return ret;
else if (ret != bts2rd)
203d1a0: b4 10 00 1d mov %i5, %i2 <== NOT EXECUTED
#if MSDOS_FIND_PRINT
printf ("MSFS:[10] eso:%li\n", empty_space_offset);
#endif
for (dir_entry = empty_space_entry;
203d1a4: 80 a4 c0 16 cmp %l3, %l6 <== NOT EXECUTED
203d1a8: 08 80 00 9b bleu 203d414 <msdos_find_name_in_fat_file+0x8b4><== NOT EXECUTED
203d1ac: a2 10 00 16 mov %l6, %l1 <== NOT EXECUTED
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + dir_entry;
203d1b0: e0 06 60 9c ld [ %i1 + 0x9c ], %l0 <== NOT EXECUTED
char* p;
const char* n;
int i;
length += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
lfn_entry++;
203d1b4: a4 06 e0 01 add %i3, 1, %l2 <== NOT EXECUTED
for (dir_entry = empty_space_entry;
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + dir_entry;
203d1b8: a0 04 00 16 add %l0, %l6, %l0 <== NOT EXECUTED
length, lfn_entry);
#endif
/*
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
203d1bc: 80 a5 c0 12 cmp %l7, %l2 <== NOT EXECUTED
203d1c0: 02 80 00 50 be 203d300 <msdos_find_name_in_fat_file+0x7a0><== NOT EXECUTED
203d1c4: aa 10 20 20 mov 0x20, %l5 <== NOT EXECUTED
dir_pos->lname.ofs = lfn_start.ofs;
/* write new node entry */
memcpy (entry, (uint8_t *) name_dir_entry,
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
break;
203d1c8: c6 07 bf e8 ld [ %fp + -24 ], %g3 <== NOT EXECUTED
203d1cc: c8 07 a0 50 ld [ %fp + 0x50 ], %g4 <== NOT EXECUTED
203d1d0: 82 38 00 1b xnor %g0, %i3, %g1 <== NOT EXECUTED
203d1d4: a2 10 00 16 mov %l6, %l1 <== NOT EXECUTED
203d1d8: 82 00 40 03 add %g1, %g3, %g1 <== NOT EXECUTED
203d1dc: f0 27 bf ec st %i0, [ %fp + -20 ] <== NOT EXECUTED
203d1e0: 85 28 60 02 sll %g1, 2, %g2 <== NOT EXECUTED
203d1e4: 87 28 60 04 sll %g1, 4, %g3 <== NOT EXECUTED
203d1e8: b0 10 00 16 mov %l6, %i0 <== NOT EXECUTED
203d1ec: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
203d1f0: ac 10 00 13 mov %l3, %l6 <== NOT EXECUTED
203d1f4: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
203d1f8: b6 25 c0 12 sub %l7, %l2, %i3 <== NOT EXECUTED
203d1fc: 82 01 00 01 add %g4, %g1, %g1 <== NOT EXECUTED
203d200: aa 10 20 20 mov 0x20, %l5 <== NOT EXECUTED
203d204: a6 10 00 01 mov %g1, %l3 <== NOT EXECUTED
* This is a long file name and we need to write
* a long file name entry. See if this is the
* first entry written and if so remember the
* the location of the long file name.
*/
if (lfn_start.cln == FAT_FILE_SHORT_NAME)
203d208: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
203d20c: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
203d210: 22 80 00 72 be,a 203d3d8 <msdos_find_name_in_fat_file+0x878><== NOT EXECUTED
203d214: f8 27 bf f4 st %i4, [ %fp + -12 ] <== NOT EXECUTED
}
/*
* Clear the entry before loading the data.
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203d218: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203d21c: 92 10 20 00 clr %o1 <== NOT EXECUTED
203d220: 40 00 42 77 call 204dbfc <memset> <== NOT EXECUTED
203d224: 94 10 20 20 mov 0x20, %o2 <== NOT EXECUTED
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d228: 82 10 00 13 mov %l3, %g1 <== NOT EXECUTED
/*
* Clear the entry before loading the data.
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
203d22c: e8 2c 20 0d stb %l4, [ %l0 + 0xd ] <== NOT EXECUTED
p = entry + 1;
n = name + (lfn_entries - lfn_entry) * MSDOS_LFN_LEN_PER_ENTRY;
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
203d230: da 08 40 00 ldub [ %g1 ], %o5 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d234: 86 04 20 01 add %l0, 1, %g3 <== NOT EXECUTED
n = name + (lfn_entries - lfn_entry) * MSDOS_LFN_LEN_PER_ENTRY;
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
203d238: da 28 c0 00 stb %o5, [ %g3 ] <== NOT EXECUTED
if (*n != 0)
203d23c: da 48 40 00 ldsb [ %g1 ], %o5 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d240: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
if (*n != 0)
n++;
203d244: 80 a0 00 0d cmp %g0, %o5 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d248: 88 00 bf ff add %g2, -1, %g4 <== NOT EXECUTED
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
if (*n != 0)
n++;
203d24c: 82 40 00 01 addx %g0, %g1, %g1 <== NOT EXECUTED
switch (i)
203d250: 80 a1 20 04 cmp %g4, 4 <== NOT EXECUTED
203d254: 22 80 00 12 be,a 203d29c <msdos_find_name_in_fat_file+0x73c><== NOT EXECUTED
203d258: 86 00 e0 05 add %g3, 5, %g3 <== NOT EXECUTED
203d25c: 80 a1 20 0a cmp %g4, 0xa <== NOT EXECUTED
203d260: 02 80 00 11 be 203d2a4 <msdos_find_name_in_fat_file+0x744><== NOT EXECUTED
203d264: 80 a0 a0 0c cmp %g2, 0xc <== NOT EXECUTED
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
n = name + (lfn_entries - lfn_entry) * MSDOS_LFN_LEN_PER_ENTRY;
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
203d268: 14 80 00 12 bg 203d2b0 <msdos_find_name_in_fat_file+0x750><== NOT EXECUTED
203d26c: 86 00 e0 02 add %g3, 2, %g3 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d270: 84 00 a0 01 inc %g2 <== NOT EXECUTED
n = name + (lfn_entries - lfn_entry) * MSDOS_LFN_LEN_PER_ENTRY;
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
203d274: da 08 40 00 ldub [ %g1 ], %o5 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d278: 88 00 bf ff add %g2, -1, %g4 <== NOT EXECUTED
n = name + (lfn_entries - lfn_entry) * MSDOS_LFN_LEN_PER_ENTRY;
for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; i++)
{
*p = *n;
203d27c: da 28 c0 00 stb %o5, [ %g3 ] <== NOT EXECUTED
if (*n != 0)
203d280: da 48 40 00 ldsb [ %g1 ], %o5 <== NOT EXECUTED
n++;
203d284: 80 a0 00 0d cmp %g0, %o5 <== NOT EXECUTED
203d288: 82 40 00 01 addx %g0, %g1, %g1 <== NOT EXECUTED
switch (i)
203d28c: 80 a1 20 04 cmp %g4, 4 <== NOT EXECUTED
203d290: 12 bf ff f4 bne 203d260 <msdos_find_name_in_fat_file+0x700><== NOT EXECUTED
203d294: 80 a1 20 0a cmp %g4, 0xa <== NOT EXECUTED
{
case 4:
p += 5;
203d298: 86 00 e0 05 add %g3, 5, %g3 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d29c: 10 bf ff f6 b 203d274 <msdos_find_name_in_fat_file+0x714> <== NOT EXECUTED
203d2a0: 84 00 a0 01 inc %g2 <== NOT EXECUTED
{
case 4:
p += 5;
break;
case 10:
p += 4;
203d2a4: 86 00 e0 04 add %g3, 4, %g3 <== NOT EXECUTED
*/
memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
*MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;
p = entry + 1;
203d2a8: 10 bf ff f3 b 203d274 <msdos_find_name_in_fat_file+0x714> <== NOT EXECUTED
203d2ac: 84 00 a0 01 inc %g2 <== NOT EXECUTED
break;
}
}
*MSDOS_DIR_ENTRY_TYPE(entry) = (lfn_entries - lfn_entry) + 1;
if (lfn_entry == 1)
203d2b0: 80 a4 a0 01 cmp %l2, 1 <== NOT EXECUTED
203d2b4: 02 80 00 4b be 203d3e0 <msdos_find_name_in_fat_file+0x880><== NOT EXECUTED
203d2b8: f6 2c 00 00 stb %i3, [ %l0 ] <== NOT EXECUTED
*MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
*MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;
203d2bc: c2 0c 20 0b ldub [ %l0 + 0xb ], %g1 <== NOT EXECUTED
printf ("MSFS:[10] eso:%li\n", empty_space_offset);
#endif
for (dir_entry = empty_space_entry;
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203d2c0: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
}
*MSDOS_DIR_ENTRY_TYPE(entry) = (lfn_entries - lfn_entry) + 1;
if (lfn_entry == 1)
*MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
*MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;
203d2c4: 82 10 60 0f or %g1, 0xf, %g1 <== NOT EXECUTED
#if MSDOS_FIND_PRINT
printf ("MSFS:[10] eso:%li\n", empty_space_offset);
#endif
for (dir_entry = empty_space_entry;
203d2c8: 80 a5 80 11 cmp %l6, %l1 <== NOT EXECUTED
203d2cc: 08 80 00 4d bleu 203d400 <msdos_find_name_in_fat_file+0x8a0><== NOT EXECUTED
203d2d0: c2 2c 20 0b stb %g1, [ %l0 + 0xb ] <== NOT EXECUTED
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + dir_entry;
203d2d4: e0 06 60 9c ld [ %i1 + 0x9c ], %l0 <== NOT EXECUTED
char* p;
const char* n;
int i;
length += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
lfn_entry++;
203d2d8: a4 04 a0 01 inc %l2 <== NOT EXECUTED
for (dir_entry = empty_space_entry;
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + dir_entry;
203d2dc: a0 04 00 11 add %l0, %l1, %l0 <== NOT EXECUTED
char* p;
const char* n;
int i;
length += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
203d2e0: aa 05 60 20 add %l5, 0x20, %l5 <== NOT EXECUTED
lfn_entry++;
203d2e4: a6 04 ff f3 add %l3, -13, %l3 <== NOT EXECUTED
length, lfn_entry);
#endif
/*
* Time to write the short file name entry.
*/
if (lfn_entry == (lfn_entries + 1))
203d2e8: 80 a4 80 17 cmp %l2, %l7 <== NOT EXECUTED
203d2ec: 12 bf ff c7 bne 203d208 <msdos_find_name_in_fat_file+0x6a8><== NOT EXECUTED
203d2f0: b6 06 ff ff add %i3, -1, %i3 <== NOT EXECUTED
203d2f4: a6 10 00 16 mov %l6, %l3 <== NOT EXECUTED
203d2f8: ac 10 00 18 mov %i0, %l6 <== NOT EXECUTED
203d2fc: f0 07 bf ec ld [ %fp + -20 ], %i0 <== NOT EXECUTED
{
/* get current cluster number */
int rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d300: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203d304: d8 07 a0 5c ld [ %fp + 0x5c ], %o4 <== NOT EXECUTED
203d308: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203d30c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203d310: 7f ff ad 17 call 202876c <fat_file_ioctl> <== NOT EXECUTED
203d314: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
empty_space_offset * bts2rd,
&dir_pos->sname.cln);
if (rc != RC_OK)
203d318: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d31c: 12 80 00 74 bne 203d4ec <msdos_find_name_in_fat_file+0x98c><== NOT EXECUTED
203d320: c8 07 a0 5c ld [ %fp + 0x5c ], %g4 <== NOT EXECUTED
return rc;
dir_pos->sname.ofs = dir_entry;
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
203d324: d2 07 bf f4 ld [ %fp + -12 ], %o1 <== NOT EXECUTED
empty_space_offset * bts2rd,
&dir_pos->sname.cln);
if (rc != RC_OK)
return rc;
dir_pos->sname.ofs = dir_entry;
203d328: e2 21 20 04 st %l1, [ %g4 + 4 ] <== NOT EXECUTED
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
203d32c: 80 a2 7f ff cmp %o1, -1 <== NOT EXECUTED
203d330: 02 80 00 0d be 203d364 <msdos_find_name_in_fat_file+0x804><== NOT EXECUTED
203d334: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
{
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
203d338: 7f ff 16 15 call 2002b8c <.umul> <== NOT EXECUTED
203d33c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
203d340: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
203d344: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203d348: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203d34c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203d350: 7f ff ad 07 call 202876c <fat_file_ioctl> <== NOT EXECUTED
203d354: 98 07 bf f4 add %fp, -12, %o4 <== NOT EXECUTED
lfn_start.cln * bts2rd,
&lfn_start.cln);
if (rc != RC_OK)
203d358: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d35c: 12 80 00 64 bne 203d4ec <msdos_find_name_in_fat_file+0x98c><== NOT EXECUTED
203d360: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
203d364: c4 07 a0 5c ld [ %fp + 0x5c ], %g2 <== NOT EXECUTED
dir_pos->lname.ofs = lfn_start.ofs;
/* write new node entry */
memcpy (entry, (uint8_t *) name_dir_entry,
203d368: d2 07 a0 60 ld [ %fp + 0x60 ], %o1 <== NOT EXECUTED
&lfn_start.cln);
if (rc != RC_OK)
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
203d36c: c2 20 a0 08 st %g1, [ %g2 + 8 ] <== NOT EXECUTED
dir_pos->lname.ofs = lfn_start.ofs;
203d370: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
/* write new node entry */
memcpy (entry, (uint8_t *) name_dir_entry,
203d374: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
}
dir_pos->lname.cln = lfn_start.cln;
dir_pos->lname.ofs = lfn_start.ofs;
203d378: c2 20 a0 0c st %g1, [ %g2 + 0xc ] <== NOT EXECUTED
/* write new node entry */
memcpy (entry, (uint8_t *) name_dir_entry,
203d37c: 40 00 41 8d call 204d9b0 <memcpy> <== NOT EXECUTED
203d380: 94 10 20 20 mov 0x20, %o2 <== NOT EXECUTED
203d384: a4 10 00 17 mov %l7, %l2 <== NOT EXECUTED
203d388: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
if (lfn_entry == 1)
*MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
*MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;
}
ret = fat_file_write(mt_entry, fat_fd,
203d38c: d8 06 60 9c ld [ %i1 + 0x9c ], %o4 <== NOT EXECUTED
203d390: d0 07 a0 44 ld [ %fp + 0x44 ], %o0 <== NOT EXECUTED
203d394: 94 06 80 16 add %i2, %l6, %o2 <== NOT EXECUTED
203d398: 98 03 00 16 add %o4, %l6, %o4 <== NOT EXECUTED
203d39c: 7f ff ad e7 call 2028b38 <fat_file_write> <== NOT EXECUTED
203d3a0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
(empty_space_offset * bts2rd) + empty_space_entry,
length, fs_info->cl_buf + empty_space_entry);
if (ret == -1)
203d3a4: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
203d3a8: 02 80 00 47 be 203d4c4 <msdos_find_name_in_fat_file+0x964><== NOT EXECUTED
203d3ac: 80 a5 40 08 cmp %l5, %o0 <== NOT EXECUTED
return ret;
else if (ret != length)
203d3b0: 12 bf ff 6e bne 203d168 <msdos_find_name_in_fat_file+0x608><== NOT EXECUTED
203d3b4: c2 07 bf e8 ld [ %fp + -24 ], %g1 <== NOT EXECUTED
#endif
/*
* The one more is the short entry.
*/
while (lfn_entry < (lfn_entries + 1))
203d3b8: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
203d3bc: 06 bf fe 7f bl 203cdb8 <msdos_find_name_in_fat_file+0x258><== NOT EXECUTED
203d3c0: ba 07 40 13 add %i5, %l3, %i5 <== NOT EXECUTED
if (ret == -1)
return ret;
else if (ret != length)
rtems_set_errno_and_return_minus_one(EIO);
empty_space_offset++;
203d3c4: b8 07 20 01 inc %i4 <== NOT EXECUTED
203d3c8: b6 10 00 12 mov %l2, %i3 <== NOT EXECUTED
203d3cc: ac 10 20 00 clr %l6 <== NOT EXECUTED
203d3d0: 10 bf ff 40 b 203d0d0 <msdos_find_name_in_fat_file+0x570> <== NOT EXECUTED
203d3d4: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
* the location of the long file name.
*/
if (lfn_start.cln == FAT_FILE_SHORT_NAME)
{
lfn_start.cln = empty_space_offset;
lfn_start.ofs = dir_entry;
203d3d8: 10 bf ff 90 b 203d218 <msdos_find_name_in_fat_file+0x6b8> <== NOT EXECUTED
203d3dc: e2 27 bf f8 st %l1, [ %fp + -8 ] <== NOT EXECUTED
}
}
*MSDOS_DIR_ENTRY_TYPE(entry) = (lfn_entries - lfn_entry) + 1;
if (lfn_entry == 1)
*MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
203d3e0: 82 16 e0 40 or %i3, 0x40, %g1 <== NOT EXECUTED
203d3e4: c2 2c 00 00 stb %g1, [ %l0 ] <== NOT EXECUTED
*MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;
203d3e8: c2 0c 20 0b ldub [ %l0 + 0xb ], %g1 <== NOT EXECUTED
printf ("MSFS:[10] eso:%li\n", empty_space_offset);
#endif
for (dir_entry = empty_space_entry;
dir_entry < bts2rd;
dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203d3ec: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
}
*MSDOS_DIR_ENTRY_TYPE(entry) = (lfn_entries - lfn_entry) + 1;
if (lfn_entry == 1)
*MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
*MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;
203d3f0: 82 10 60 0f or %g1, 0xf, %g1 <== NOT EXECUTED
#if MSDOS_FIND_PRINT
printf ("MSFS:[10] eso:%li\n", empty_space_offset);
#endif
for (dir_entry = empty_space_entry;
203d3f4: 80 a5 80 11 cmp %l6, %l1 <== NOT EXECUTED
203d3f8: 18 bf ff b7 bgu 203d2d4 <msdos_find_name_in_fat_file+0x774><== NOT EXECUTED
203d3fc: c2 2c 20 0b stb %g1, [ %l0 + 0xb ] <== NOT EXECUTED
203d400: a6 10 00 16 mov %l6, %l3 <== NOT EXECUTED
203d404: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
203d408: ac 10 00 18 mov %i0, %l6 <== NOT EXECUTED
203d40c: 10 bf ff e0 b 203d38c <msdos_find_name_in_fat_file+0x82c> <== NOT EXECUTED
203d410: f0 07 bf ec ld [ %fp + -20 ], %i0 <== NOT EXECUTED
203d414: a4 10 00 1b mov %i3, %l2 <== NOT EXECUTED
203d418: 96 10 20 00 clr %o3 <== NOT EXECUTED
203d41c: 10 bf ff dc b 203d38c <msdos_find_name_in_fat_file+0x82c> <== NOT EXECUTED
203d420: aa 10 20 00 clr %l5 <== NOT EXECUTED
*/
lfn_checksum = 0;
if (name_type == MSDOS_NAME_LONG)
{
int slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + lfn_entries + 1;
203d424: c8 07 bf e8 ld [ %fp + -24 ], %g4 <== NOT EXECUTED
203d428: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
203d42c: a0 01 20 01 add %g4, 1, %l0 <== NOT EXECUTED
203d430: 7f ff 15 d7 call 2002b8c <.umul> <== NOT EXECUTED
203d434: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
static const char* hex = "0123456789ABCDEF";
char* c = MSDOS_DIR_NAME(sfn);
int i;
for (i = 0; i < 3; i++, c++)
if ((*c == ' ') || (*c == '.'))
*c = '~';
203d438: c8 07 a0 60 ld [ %fp + 0x60 ], %g4 <== NOT EXECUTED
*/
lfn_checksum = 0;
if (name_type == MSDOS_NAME_LONG)
{
int slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + lfn_entries + 1;
203d43c: 82 02 00 16 add %o0, %l6, %g1 <== NOT EXECUTED
203d440: 83 30 60 05 srl %g1, 5, %g1 <== NOT EXECUTED
static const char* hex = "0123456789ABCDEF";
char* c = MSDOS_DIR_NAME(sfn);
int i;
for (i = 0; i < 3; i++, c++)
if ((*c == ' ') || (*c == '.'))
*c = '~';
203d444: 86 10 20 7e mov 0x7e, %g3 <== NOT EXECUTED
*/
lfn_checksum = 0;
if (name_type == MSDOS_NAME_LONG)
{
int slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + lfn_entries + 1;
203d448: a0 04 00 01 add %l0, %g1, %l0 <== NOT EXECUTED
203d44c: 82 10 20 00 clr %g1 <== NOT EXECUTED
{
static const char* hex = "0123456789ABCDEF";
char* c = MSDOS_DIR_NAME(sfn);
int i;
for (i = 0; i < 3; i++, c++)
if ((*c == ' ') || (*c == '.'))
203d450: c4 49 00 01 ldsb [ %g4 + %g1 ], %g2 <== NOT EXECUTED
203d454: 80 a0 a0 2e cmp %g2, 0x2e <== NOT EXECUTED
203d458: 22 80 00 05 be,a 203d46c <msdos_find_name_in_fat_file+0x90c><== NOT EXECUTED
203d45c: c6 29 00 01 stb %g3, [ %g4 + %g1 ] <== NOT EXECUTED
203d460: 80 a0 a0 20 cmp %g2, 0x20 <== NOT EXECUTED
203d464: 22 80 00 02 be,a 203d46c <msdos_find_name_in_fat_file+0x90c><== NOT EXECUTED
203d468: c6 29 00 01 stb %g3, [ %g4 + %g1 ] <== NOT EXECUTED
msdos_short_name_hex(char* sfn, int num)
{
static const char* hex = "0123456789ABCDEF";
char* c = MSDOS_DIR_NAME(sfn);
int i;
for (i = 0; i < 3; i++, c++)
203d46c: 82 00 60 01 inc %g1 <== NOT EXECUTED
203d470: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED
203d474: 32 bf ff f8 bne,a 203d454 <msdos_find_name_in_fat_file+0x8f4><== NOT EXECUTED
203d478: c4 49 00 01 ldsb [ %g4 + %g1 ], %g2 <== NOT EXECUTED
if ((*c == ' ') || (*c == '.'))
*c = '~';
*c++ = '~';
203d47c: c4 07 a0 60 ld [ %fp + 0x60 ], %g2 <== NOT EXECUTED
203d480: 03 00 81 b8 sethi %hi(0x206e000), %g1 <== NOT EXECUTED
203d484: c6 00 63 dc ld [ %g1 + 0x3dc ], %g3 ! 206e3dc <hex.7100> <== NOT EXECUTED
203d488: 82 10 20 7e mov 0x7e, %g1 <== NOT EXECUTED
203d48c: c2 28 a0 03 stb %g1, [ %g2 + 3 ] <== NOT EXECUTED
203d490: c8 07 a0 60 ld [ %fp + 0x60 ], %g4 <== NOT EXECUTED
203d494: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
203d498: 84 01 20 04 add %g4, 4, %g2 <== NOT EXECUTED
for (i = 0; i < 4; i++, c++)
*c = hex[(num >> ((3 - i) * 4)) & 0xf];
203d49c: 89 3c 00 01 sra %l0, %g1, %g4 <== NOT EXECUTED
203d4a0: 88 09 20 0f and %g4, 0xf, %g4 <== NOT EXECUTED
203d4a4: c8 08 c0 04 ldub [ %g3 + %g4 ], %g4 <== NOT EXECUTED
int i;
for (i = 0; i < 3; i++, c++)
if ((*c == ' ') || (*c == '.'))
*c = '~';
*c++ = '~';
for (i = 0; i < 4; i++, c++)
203d4a8: 82 00 7f fc add %g1, -4, %g1 <== NOT EXECUTED
*c = hex[(num >> ((3 - i) * 4)) & 0xf];
203d4ac: c8 28 80 00 stb %g4, [ %g2 ] <== NOT EXECUTED
int i;
for (i = 0; i < 3; i++, c++)
if ((*c == ' ') || (*c == '.'))
*c = '~';
*c++ = '~';
for (i = 0; i < 4; i++, c++)
203d4b0: 80 a0 7f fc cmp %g1, -4 <== NOT EXECUTED
203d4b4: 12 bf ff fa bne 203d49c <msdos_find_name_in_fat_file+0x93c><== NOT EXECUTED
203d4b8: 84 00 a0 01 inc %g2 <== NOT EXECUTED
int slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + lfn_entries + 1;
msdos_short_name_hex(MSDOS_DIR_NAME(name_dir_entry), slot);
}
if (lfn_entries)
203d4bc: 10 bf fe cc b 203cfec <msdos_find_name_in_fat_file+0x48c> <== NOT EXECUTED
203d4c0: c2 07 bf e8 ld [ %fp + -24 ], %g1 <== NOT EXECUTED
if (ret == -1)
return ret;
else if (ret != length)
rtems_set_errno_and_return_minus_one(EIO);
empty_space_offset++;
203d4c4: 81 c7 e0 08 ret <== NOT EXECUTED
203d4c8: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
#endif
if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
rtems_set_errno_and_return_minus_one(EIO);
assert(ret == bts2rd);
203d4cc: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203d4d0: 15 00 81 b8 sethi %hi(0x206e000), %o2 <== NOT EXECUTED
203d4d4: 17 00 81 b8 sethi %hi(0x206e000), %o3 <== NOT EXECUTED
203d4d8: 90 12 22 90 or %o0, 0x290, %o0 <== NOT EXECUTED
203d4dc: 94 12 a3 c0 or %o2, 0x3c0, %o2 <== NOT EXECUTED
203d4e0: 96 12 e2 e8 or %o3, 0x2e8, %o3 <== NOT EXECUTED
203d4e4: 7f ff bb 9b call 202c350 <__assert_func> <== NOT EXECUTED
203d4e8: 92 10 24 49 mov 0x449, %o1 <== NOT EXECUTED
if (lfn_start.cln != FAT_FILE_SHORT_NAME)
{
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM,
lfn_start.cln * bts2rd,
&lfn_start.cln);
if (rc != RC_OK)
203d4ec: 81 c7 e0 08 ret <== NOT EXECUTED
203d4f0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
uint32_t empty_space_count = 0;
bool empty_space_found = false;
uint32_t entries_per_block;
bool read_cluster = false;
assert(name_len > 0);
203d4f4: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203d4f8: 15 00 81 b8 sethi %hi(0x206e000), %o2 <== NOT EXECUTED
203d4fc: 17 00 81 b8 sethi %hi(0x206e000), %o3 <== NOT EXECUTED
203d500: 90 12 22 90 or %o0, 0x290, %o0 <== NOT EXECUTED
203d504: 94 12 a3 c0 or %o2, 0x3c0, %o2 <== NOT EXECUTED
203d508: 96 12 e2 f8 or %o3, 0x2f8, %o3 <== NOT EXECUTED
203d50c: 7f ff bb 91 call 202c350 <__assert_func> <== NOT EXECUTED
203d510: 92 10 24 19 mov 0x419, %o1 <== NOT EXECUTED
}
/*
* Have we read past the empty block ? If so go back and read it again.
*/
if (dir_offset != empty_space_offset)
203d514: a0 10 20 00 clr %l0 <== NOT EXECUTED
203d518: 10 bf fe e0 b 203d098 <msdos_find_name_in_fat_file+0x538> <== NOT EXECUTED
203d51c: b8 10 00 1b mov %i3, %i4 <== NOT EXECUTED
0203c9d4 <msdos_find_node_by_cluster_num_in_fat_file>:
fat_file_fd_t *fat_fd,
uint32_t cl4find,
fat_dir_pos_t *dir_pos,
char *dir_entry
)
{
203c9d4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t bts2rd = 0;
uint32_t i = 0, j = 0;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203c9d8: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
203c9dc: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
203c9e0: 02 80 00 36 be 203cab8 <msdos_find_node_by_cluster_num_in_fat_file+0xe4><== NOT EXECUTED
203c9e4: e8 06 20 34 ld [ %i0 + 0x34 ], %l4 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
bts2rd = fat_fd->fat_file_size;
else
bts2rd = fs_info->fat.vol.bpc;
203c9e8: e6 15 20 06 lduh [ %l4 + 6 ], %l3 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t bts2rd = 0;
uint32_t i = 0, j = 0;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203c9ec: d8 05 20 9c ld [ %l4 + 0x9c ], %o4 <== NOT EXECUTED
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
MSDOS_THIS_DIR_ENTRY_EMPTY)
continue;
/* if get a non-empty entry - compare clusters num */
if (MSDOS_EXTRACT_CLUSTER_NUM(entry) == cl4find)
203c9f0: 25 00 00 3f sethi %hi(0xfc00), %l2 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t bts2rd = 0;
uint32_t i = 0, j = 0;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203c9f4: aa 10 20 00 clr %l5 <== NOT EXECUTED
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
MSDOS_THIS_DIR_ENTRY_EMPTY)
continue;
/* if get a non-empty entry - compare clusters num */
if (MSDOS_EXTRACT_CLUSTER_NUM(entry) == cl4find)
203c9f8: a4 14 a3 ff or %l2, 0x3ff, %l2 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
bts2rd = fat_fd->fat_file_size;
else
bts2rd = fs_info->fat.vol.bpc;
while ((ret = fat_file_read(mt_entry, fat_fd, j * bts2rd, bts2rd,
203c9fc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203ca00: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203ca04: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
203ca08: 7f ff b0 e8 call 2028da8 <fat_file_read> <== NOT EXECUTED
203ca0c: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203ca10: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ca14: 02 80 00 25 be 203caa8 <msdos_find_node_by_cluster_num_in_fat_file+0xd4><== NOT EXECUTED
203ca18: 80 a2 20 1f cmp %o0, 0x1f <== NOT EXECUTED
fs_info->cl_buf)) != FAT_EOF)
{
if ( ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE )
203ca1c: 04 80 00 42 ble 203cb24 <msdos_find_node_by_cluster_num_in_fat_file+0x150><== NOT EXECUTED
203ca20: 80 a2 00 13 cmp %o0, %l3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
assert(ret == bts2rd);
203ca24: 12 80 00 46 bne 203cb3c <msdos_find_node_by_cluster_num_in_fat_file+0x168><== NOT EXECUTED
203ca28: a2 10 20 00 clr %l1 <== NOT EXECUTED
203ca2c: d8 05 20 9c ld [ %l4 + 0x9c ], %o4 <== NOT EXECUTED
203ca30: a0 10 00 0c mov %o4, %l0 <== NOT EXECUTED
for (i = 0; i < bts2rd; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
{
char* entry = (char*) fs_info->cl_buf + i;
/* if this and all rest entries are empty - return not-found */
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
203ca34: c2 0c 00 00 ldub [ %l0 ], %g1 <== NOT EXECUTED
203ca38: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203ca3c: 02 80 00 1b be 203caa8 <msdos_find_node_by_cluster_num_in_fat_file+0xd4><== NOT EXECUTED
203ca40: 80 a0 60 e5 cmp %g1, 0xe5 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY)
return MSDOS_NAME_NOT_FOUND_ERR;
/* if this entry is empty - skip it */
if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==
203ca44: 22 80 00 14 be,a 203ca94 <msdos_find_node_by_cluster_num_in_fat_file+0xc0><== NOT EXECUTED
203ca48: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
MSDOS_THIS_DIR_ENTRY_EMPTY)
continue;
/* if get a non-empty entry - compare clusters num */
if (MSDOS_EXTRACT_CLUSTER_NUM(entry) == cl4find)
203ca4c: c2 14 20 1a lduh [ %l0 + 0x1a ], %g1 <== NOT EXECUTED
203ca50: c4 14 20 14 lduh [ %l0 + 0x14 ], %g2 <== NOT EXECUTED
203ca54: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
203ca58: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
203ca5c: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
203ca60: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
203ca64: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203ca68: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
203ca6c: 82 08 40 12 and %g1, %l2, %g1 <== NOT EXECUTED
203ca70: 84 08 80 12 and %g2, %l2, %g2 <== NOT EXECUTED
203ca74: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
203ca78: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
203ca7c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
203ca80: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
203ca84: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203ca88: 22 80 00 16 be,a 203cae0 <msdos_find_node_by_cluster_num_in_fat_file+0x10c><== NOT EXECUTED
203ca8c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ( ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE )
rtems_set_errno_and_return_minus_one( EIO );
assert(ret == bts2rd);
for (i = 0; i < bts2rd; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
203ca90: a2 04 60 20 add %l1, 0x20, %l1 <== NOT EXECUTED
203ca94: 80 a4 c0 11 cmp %l3, %l1 <== NOT EXECUTED
203ca98: 18 bf ff e7 bgu 203ca34 <msdos_find_node_by_cluster_num_in_fat_file+0x60><== NOT EXECUTED
203ca9c: a0 04 20 20 add %l0, 0x20, %l0 <== NOT EXECUTED
203caa0: 10 bf ff d7 b 203c9fc <msdos_find_node_by_cluster_num_in_fat_file+0x28><== NOT EXECUTED
203caa4: aa 05 40 13 add %l5, %l3, %l5 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
bts2rd = fat_fd->fat_file_size;
else
bts2rd = fs_info->fat.vol.bpc;
while ((ret = fat_file_read(mt_entry, fat_fd, j * bts2rd, bts2rd,
203caa8: 31 00 00 1f sethi %hi(0x7c00), %i0 <== NOT EXECUTED
203caac: b0 16 21 01 or %i0, 0x101, %i0 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
}
}
j++;
}
return MSDOS_NAME_NOT_FOUND_ERR;
}
203cab0: 81 c7 e0 08 ret <== NOT EXECUTED
203cab4: 81 e8 00 00 restore <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t bts2rd = 0;
uint32_t i = 0, j = 0;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203cab8: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
203cabc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203cac0: 32 bf ff cb bne,a 203c9ec <msdos_find_node_by_cluster_num_in_fat_file+0x18><== NOT EXECUTED
203cac4: e6 15 20 06 lduh [ %l4 + 6 ], %l3 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
203cac8: c2 0d 20 0a ldub [ %l4 + 0xa ], %g1 <== NOT EXECUTED
203cacc: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
203cad0: 22 bf ff c7 be,a 203c9ec <msdos_find_node_by_cluster_num_in_fat_file+0x18><== NOT EXECUTED
203cad4: e6 15 20 06 lduh [ %l4 + 6 ], %l3 <== NOT EXECUTED
ssize_t ret = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t bts2rd = 0;
uint32_t i = 0, j = 0;
if (FAT_FD_OF_ROOT_DIR(fat_fd) &&
203cad8: 10 bf ff c5 b 203c9ec <msdos_find_node_by_cluster_num_in_fat_file+0x18><== NOT EXECUTED
203cadc: e6 06 60 18 ld [ %i1 + 0x18 ], %l3 <== NOT EXECUTED
/* if get a non-empty entry - compare clusters num */
if (MSDOS_EXTRACT_CLUSTER_NUM(entry) == cl4find)
{
/* on success fill aux structure and copy all 32 bytes */
rc = fat_file_ioctl(mt_entry, fat_fd, F_CLU_NUM, j * bts2rd,
203cae0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203cae4: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
203cae8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203caec: 7f ff af 20 call 202876c <fat_file_ioctl> <== NOT EXECUTED
203caf0: 98 10 00 1b mov %i3, %o4 <== NOT EXECUTED
&dir_pos->sname.cln);
if (rc != RC_OK)
203caf4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203caf8: 12 bf ff ee bne 203cab0 <msdos_find_node_by_cluster_num_in_fat_file+0xdc><== NOT EXECUTED
203cafc: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
return rc;
dir_pos->sname.ofs = i;
203cb00: e2 26 e0 04 st %l1, [ %i3 + 4 ] <== NOT EXECUTED
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
memcpy(dir_entry, entry,
203cb04: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
203cb08: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
dir_pos->sname.ofs = i;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203cb0c: c2 26 e0 0c st %g1, [ %i3 + 0xc ] <== NOT EXECUTED
&dir_pos->sname.cln);
if (rc != RC_OK)
return rc;
dir_pos->sname.ofs = i;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203cb10: c2 26 e0 08 st %g1, [ %i3 + 8 ] <== NOT EXECUTED
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
memcpy(dir_entry, entry,
203cb14: 40 00 43 a7 call 204d9b0 <memcpy> <== NOT EXECUTED
203cb18: 94 10 20 20 mov 0x20, %o2 <== NOT EXECUTED
MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
return RC_OK;
203cb1c: 81 c7 e0 08 ret <== NOT EXECUTED
203cb20: 81 e8 00 00 restore <== NOT EXECUTED
while ((ret = fat_file_read(mt_entry, fat_fd, j * bts2rd, bts2rd,
fs_info->cl_buf)) != FAT_EOF)
{
if ( ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE )
rtems_set_errno_and_return_minus_one( EIO );
203cb24: 40 00 36 57 call 204a480 <__errno> <== NOT EXECUTED
203cb28: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203cb2c: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203cb30: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203cb34: 81 c7 e0 08 ret <== NOT EXECUTED
203cb38: 81 e8 00 00 restore <== NOT EXECUTED
assert(ret == bts2rd);
203cb3c: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203cb40: 15 00 81 b8 sethi %hi(0x206e000), %o2 <== NOT EXECUTED
203cb44: 17 00 81 b8 sethi %hi(0x206e000), %o3 <== NOT EXECUTED
203cb48: 90 12 22 90 or %o0, 0x290, %o0 <== NOT EXECUTED
203cb4c: 94 12 a3 90 or %o2, 0x390, %o2 <== NOT EXECUTED
203cb50: 96 12 e2 e8 or %o3, 0x2e8, %o3 <== NOT EXECUTED
203cb54: 7f ff bd ff call 202c350 <__assert_func> <== NOT EXECUTED
203cb58: 92 10 26 95 mov 0x695, %o1 <== NOT EXECUTED
02022030 <msdos_format>:
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
2022030: 9d e3 bc e0 save %sp, -800, %sp <== NOT EXECUTED
int ret_val = 0;
int fd = -1;
int i;
msdos_format_param_t fmt_params;
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_INFO,
2022034: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2022038: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
202203c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022040: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2022044: 7f ff ff 5b call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022048: 94 12 a3 78 or %o2, 0x378, %o2 ! 2069778 <rtems_rtc_shell_usage+0xe18><== NOT EXECUTED
"formating: %s\n", devname);
/*
* sanity check on device
*/
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
202204c: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
2022050: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022054: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2022058: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
202205c: 7f ff ff 55 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022060: 94 12 a3 88 or %o2, 0x388, %o2 ! 2069788 <rtems_rtc_shell_usage+0xe28><== NOT EXECUTED
"stat check: %s\n", devname);
if (ret_val == 0) {
rc = stat(devname, &stat_buf);
2022064: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
2022068: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
* sanity check on device
*/
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"stat check: %s\n", devname);
if (ret_val == 0) {
rc = stat(devname, &stat_buf);
202206c: 7f ff a0 cd call 200a3a0 <stat> <== NOT EXECUTED
2022070: 92 07 bf a8 add %fp, -88, %o1 <== NOT EXECUTED
ret_val = rc;
}
/* rtems feature: no block devices, all are character devices */
if ((ret_val == 0) &&
2022074: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022078: 12 80 00 0e bne 20220b0 <msdos_format+0x80> <== NOT EXECUTED
202207c: a4 10 20 00 clr %l2 <== NOT EXECUTED
(!S_ISBLK(stat_buf.st_mode))) {
2022080: c4 07 bf b4 ld [ %fp + -76 ], %g2 <== NOT EXECUTED
2022084: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2022088: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
202208c: 03 00 00 18 sethi %hi(0x6000), %g1 <== NOT EXECUTED
2022090: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2022094: 02 80 00 17 be 20220f0 <msdos_format+0xc0> <== NOT EXECUTED
2022098: 01 00 00 00 nop <== NOT EXECUTED
errno = ENOTTY;
202209c: 40 00 a0 f9 call 204a480 <__errno> <== NOT EXECUTED
20220a0: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
20220a4: 82 10 20 19 mov 0x19, %g1 <== NOT EXECUTED
20220a8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20220ac: a4 10 20 00 clr %l2 <== NOT EXECUTED
/* check that device is registered as block device and lock it */
if (ret_val == 0) {
dd = rtems_disk_obtain(stat_buf.st_rdev);
if (dd == NULL) {
errno = ENOTTY;
20220b0: a2 10 3f ff mov -1, %l1 <== NOT EXECUTED
0xe5);
}
/*
* create master boot record
*/
if (ret_val == 0) {
20220b4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
20220b8: 02 80 00 73 be 2022284 <msdos_format+0x254> <== NOT EXECUTED
20220bc: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
/*
* cleanup:
* sync and unlock disk
* free any data structures (not needed now)
*/
if (fd != -1) {
20220c0: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
20220c4: 02 80 00 05 be 20220d8 <msdos_format+0xa8> <== NOT EXECUTED
20220c8: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
close(fd);
20220cc: 7f ff 98 b9 call 20083b0 <close> <== NOT EXECUTED
20220d0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
}
if (dd != NULL) {
20220d4: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
20220d8: 02 80 00 04 be 20220e8 <msdos_format+0xb8> <== NOT EXECUTED
20220dc: 01 00 00 00 nop <== NOT EXECUTED
rtems_disk_release(dd);
20220e0: 7f ff 94 d7 call 200743c <rtems_disk_release> <== NOT EXECUTED
20220e4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
}
return ret_val;
}
20220e8: 81 c7 e0 08 ret <== NOT EXECUTED
20220ec: 81 e8 00 00 restore <== NOT EXECUTED
ret_val = -1;
}
/* check that device is registered as block device and lock it */
if (ret_val == 0) {
dd = rtems_disk_obtain(stat_buf.st_rdev);
20220f0: 7f ff 94 e8 call 2007490 <rtems_disk_obtain> <== NOT EXECUTED
20220f4: d0 1f bf c0 ldd [ %fp + -64 ], %o0 <== NOT EXECUTED
if (dd == NULL) {
20220f8: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20220fc: 02 80 03 5c be 2022e6c <msdos_format+0xe3c> <== NOT EXECUTED
2022100: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
/*
* open device for writing
*/
if (ret_val == 0) {
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022104: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022108: 15 00 81 a6 sethi %hi(0x2069800), %o2 <== NOT EXECUTED
202210c: 7f ff ff 29 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022110: 94 12 a0 50 or %o2, 0x50, %o2 ! 2069850 <rtems_rtc_shell_usage+0xef0><== NOT EXECUTED
"open device\n");
fd = open(devname, O_RDWR);
2022114: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2022118: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
202211c: 7f ff 9e 7b call 2009b08 <open> <== NOT EXECUTED
2022120: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
if (fd == -1)
2022124: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
2022128: 02 bf ff e2 be 20220b0 <msdos_format+0x80> <== NOT EXECUTED
202212c: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
uint32_t fatdata_sect_cnt;
uint32_t onebit;
uint32_t sectors_per_cluster_adj = 0;
uint64_t total_size = 0;
memset(fmt_params,0,sizeof(*fmt_params));
2022130: a0 07 bf 58 add %fp, -168, %l0 <== NOT EXECUTED
2022134: c0 27 bf 58 clr [ %fp + -168 ] <== NOT EXECUTED
2022138: c0 27 bf 5c clr [ %fp + -164 ] <== NOT EXECUTED
202213c: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
2022140: c0 24 20 0c clr [ %l0 + 0xc ] <== NOT EXECUTED
2022144: c0 24 20 10 clr [ %l0 + 0x10 ] <== NOT EXECUTED
2022148: c0 24 20 14 clr [ %l0 + 0x14 ] <== NOT EXECUTED
202214c: c0 24 20 18 clr [ %l0 + 0x18 ] <== NOT EXECUTED
2022150: c0 24 20 1c clr [ %l0 + 0x1c ] <== NOT EXECUTED
2022154: c0 24 20 20 clr [ %l0 + 0x20 ] <== NOT EXECUTED
2022158: c0 24 20 24 clr [ %l0 + 0x24 ] <== NOT EXECUTED
202215c: c0 24 20 28 clr [ %l0 + 0x28 ] <== NOT EXECUTED
2022160: c0 24 20 2c clr [ %l0 + 0x2c ] <== NOT EXECUTED
2022164: c0 24 20 30 clr [ %l0 + 0x30 ] <== NOT EXECUTED
2022168: c0 24 20 34 clr [ %l0 + 0x34 ] <== NOT EXECUTED
202216c: c0 24 20 38 clr [ %l0 + 0x38 ] <== NOT EXECUTED
2022170: c0 24 20 3c clr [ %l0 + 0x3c ] <== NOT EXECUTED
2022174: c0 24 20 40 clr [ %l0 + 0x40 ] <== NOT EXECUTED
2022178: c0 24 20 44 clr [ %l0 + 0x44 ] <== NOT EXECUTED
202217c: c0 24 20 48 clr [ %l0 + 0x48 ] <== NOT EXECUTED
2022180: c0 24 20 4c clr [ %l0 + 0x4c ] <== NOT EXECUTED
/*
* this one is fixed in this implementation.
* At least one thing we don't have to magically guess...
*/
if (ret_val == 0) {
fmt_params->bytes_per_sector = dd->block_size;
2022184: e6 04 a0 20 ld [ %l2 + 0x20 ], %l3 <== NOT EXECUTED
fmt_params->totl_sector_cnt = dd->size;
total_size = dd->block_size * dd->size;
2022188: a8 10 20 00 clr %l4 <== NOT EXECUTED
/*
* this one is fixed in this implementation.
* At least one thing we don't have to magically guess...
*/
if (ret_val == 0) {
fmt_params->bytes_per_sector = dd->block_size;
202218c: e6 27 bf 58 st %l3, [ %fp + -168 ] <== NOT EXECUTED
fmt_params->totl_sector_cnt = dd->size;
2022190: f0 04 a0 1c ld [ %l2 + 0x1c ], %i0 <== NOT EXECUTED
total_size = dd->block_size * dd->size;
2022194: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
* this one is fixed in this implementation.
* At least one thing we don't have to magically guess...
*/
if (ret_val == 0) {
fmt_params->bytes_per_sector = dd->block_size;
fmt_params->totl_sector_cnt = dd->size;
2022198: f0 27 bf 5c st %i0, [ %fp + -164 ] <== NOT EXECUTED
total_size = dd->block_size * dd->size;
202219c: 7f ff 82 7c call 2002b8c <.umul> <== NOT EXECUTED
20221a0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
20221a4: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
* At least one thing we don't have to magically guess...
*/
if (ret_val == 0) {
fmt_params->bytes_per_sector = dd->block_size;
fmt_params->totl_sector_cnt = dd->size;
total_size = dd->block_size * dd->size;
20221a8: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
20221ac: d0 23 a0 5c st %o0, [ %sp + 0x5c ] <== NOT EXECUTED
20221b0: 98 10 00 18 mov %i0, %o4 <== NOT EXECUTED
20221b4: e8 3f bd 50 std %l4, [ %fp + -688 ] <== NOT EXECUTED
20221b8: 9a 10 20 00 clr %o5 <== NOT EXECUTED
20221bc: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
20221c0: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
20221c4: 15 00 81 a6 sethi %hi(0x2069800), %o2 <== NOT EXECUTED
20221c8: 7f ff fe fa call 2021db0 <msdos_format_printf> <== NOT EXECUTED
20221cc: 94 12 a0 60 or %o2, 0x60, %o2 ! 2069860 <rtems_rtc_shell_usage+0xf00><== NOT EXECUTED
}
/*
* determine number of FATs
*/
if (ret_val == 0) {
if ((rqdata == NULL) ||
20221d0: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20221d4: 02 80 02 5d be 2022b48 <msdos_format+0xb18> <== NOT EXECUTED
20221d8: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
(rqdata->fat_num == 0)) {
20221dc: d6 06 60 0c ld [ %i1 + 0xc ], %o3 <== NOT EXECUTED
}
/*
* determine number of FATs
*/
if (ret_val == 0) {
if ((rqdata == NULL) ||
20221e0: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
20221e4: 02 80 01 26 be 202267c <msdos_format+0x64c> <== NOT EXECUTED
20221e8: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
(rqdata->fat_num == 0)) {
fmt_params->fat_num = 2;
}
else if (rqdata->fat_num <= 6) {
20221ec: 80 a2 e0 06 cmp %o3, 6 <== NOT EXECUTED
20221f0: 38 80 02 51 bgu,a 2022b34 <msdos_format+0xb04> <== NOT EXECUTED
20221f4: a8 10 20 16 mov 0x16, %l4 <== NOT EXECUTED
fmt_params->fat_num = rqdata->fat_num;
20221f8: d6 2f bf 88 stb %o3, [ %fp + -120 ] <== NOT EXECUTED
ret_val = EINVAL;
}
}
if (ret_val == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
20221fc: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022200: 96 0a e0 ff and %o3, 0xff, %o3 <== NOT EXECUTED
2022204: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2022208: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
202220c: 7f ff fe e9 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022210: 94 12 a3 98 or %o2, 0x398, %o2 ! 2069798 <rtems_rtc_shell_usage+0xe38><== NOT EXECUTED
/*
* determine FAT type and sectors per cluster
* depends on
*/
if (ret_val == 0) {
fmt_params->sectors_per_cluster = 1;
2022214: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2022218: c2 27 bf 64 st %g1, [ %fp + -156 ] <== NOT EXECUTED
if ((rqdata != NULL) &&
202221c: c2 0e 60 14 ldub [ %i1 + 0x14 ], %g1 <== NOT EXECUTED
2022220: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2022224: 02 80 01 20 be 20226a4 <msdos_format+0x674> <== NOT EXECUTED
2022228: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
(rqdata->fattype == MSDOS_FMT_FAT12)) {
fmt_params->fattype = FAT_FAT12;
}
else if ((rqdata != NULL) &&
202222c: 02 80 01 1e be 20226a4 <msdos_format+0x674> <== NOT EXECUTED
2022230: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED
(rqdata->fattype == MSDOS_FMT_FAT16)) {
fmt_params->fattype = FAT_FAT16;
}
else if ((rqdata != NULL) &&
2022234: 02 80 01 1b be 20226a0 <msdos_format+0x670> <== NOT EXECUTED
2022238: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
(rqdata->fattype == MSDOS_FMT_FAT32)) {
fmt_params->fattype = FAT_FAT32;
}
else if ((rqdata != NULL) &&
202223c: 12 80 02 58 bne 2022b9c <msdos_format+0xb6c> <== NOT EXECUTED
2022240: c2 07 bf 5c ld [ %fp + -164 ], %g1 <== NOT EXECUTED
/*
* limiting values for disk size, fat type, sectors per cluster
* NOTE: maximum sect_per_clust is arbitrarily choosen with values that
* are a compromise concerning capacity and efficency
*/
if (fmt_params->totl_sector_cnt
2022244: 05 00 00 1f sethi %hi(0x7c00), %g2 <== NOT EXECUTED
2022248: 84 10 a3 a7 or %g2, 0x3a7, %g2 ! 7fa7 <PROM_START+0x7fa7> <== NOT EXECUTED
202224c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2022250: 18 80 02 b5 bgu 2022d24 <msdos_format+0xcf4> <== NOT EXECUTED
2022254: 05 00 07 ff sethi %hi(0x1ffc00), %g2 <== NOT EXECUTED
< ((uint32_t)FAT_FAT12_MAX_CLN)*8) {
fmt_params->fattype = FAT_FAT12;
2022258: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
202225c: c2 2f bf 8a stb %g1, [ %fp + -118 ] <== NOT EXECUTED
/* start trying with small clusters */
fmt_params->sectors_per_cluster = 2;
2022260: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
2022264: c2 27 bf 64 st %g1, [ %fp + -156 ] <== NOT EXECUTED
}
}
/*
* try to use user requested cluster size
*/
if ((rqdata != NULL) &&
2022268: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
202226c: 12 80 01 10 bne 20226ac <msdos_format+0x67c> <== NOT EXECUTED
2022270: a8 10 20 00 clr %l4 <== NOT EXECUTED
2022274: c4 07 bf 64 ld [ %fp + -156 ], %g2 <== NOT EXECUTED
2022278: a8 10 00 19 mov %i1, %l4 <== NOT EXECUTED
202227c: 10 80 01 12 b 20226c4 <msdos_format+0x694> <== NOT EXECUTED
2022280: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
*/
if (ret_val == 0) {
/*
* Read the current MBR to obtain the partition table.
*/
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022284: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2022288: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
202228c: 7f ff fe c9 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022290: 94 12 a3 e0 or %o2, 0x3e0, %o2 ! 20697e0 <rtems_rtc_shell_usage+0xe80><== NOT EXECUTED
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
int ret_val = 0;
if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {
2022294: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
/*
* Read the current MBR to obtain the partition table.
*/
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"read MRB sector\n");
ret_val = msdos_format_read_sec(fd,
2022298: e0 07 bf 58 ld [ %fp + -168 ], %l0 <== NOT EXECUTED
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
int ret_val = 0;
if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {
202229c: 92 10 20 00 clr %o1 <== NOT EXECUTED
20222a0: 94 10 20 00 clr %o2 <== NOT EXECUTED
20222a4: 40 00 2d cd call 202d9d8 <lseek> <== NOT EXECUTED
20222a8: 96 10 20 00 clr %o3 <== NOT EXECUTED
20222ac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20222b0: 06 80 00 f1 bl 2022674 <msdos_format+0x644> <== NOT EXECUTED
20222b4: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
ret_val = -1;
}
if (ret_val == 0) {
if (0 > read(fd,buffer,sector_size)) {
20222b8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20222bc: a0 07 bd 58 add %fp, -680, %l0 <== NOT EXECUTED
20222c0: 7f ff 9f 06 call 2009ed8 <read> <== NOT EXECUTED
20222c4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20222c8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20222cc: 06 80 00 ea bl 2022674 <msdos_format+0x644> <== NOT EXECUTED
20222d0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
ret_val = msdos_format_read_sec(fd,
0,
fmt_params.bytes_per_sector,
tmp_sec);
if (ret_val == 0) {
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
20222d4: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
20222d8: 15 00 81 a6 sethi %hi(0x2069800), %o2 <== NOT EXECUTED
20222dc: 7f ff fe b5 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
20222e0: 94 12 a0 98 or %o2, 0x98, %o2 ! 2069898 <rtems_rtc_shell_usage+0xf38><== NOT EXECUTED
{
uint32_t total_sectors_num16 = 0;
uint32_t total_sectors_num32 = 0;
/* store total sector count in either 16 or 32 bit field in mbr */
if (fmt_params->totl_sector_cnt < 0x10000) {
20222e4: ec 07 bf 5c ld [ %fp + -164 ], %l6 <== NOT EXECUTED
20222e8: 29 00 00 3f sethi %hi(0xfc00), %l4 <== NOT EXECUTED
20222ec: a8 15 23 ff or %l4, 0x3ff, %l4 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
20222f0: 80 a5 80 14 cmp %l6, %l4 <== NOT EXECUTED
20222f4: 08 80 02 1e bleu 2022b6c <msdos_format+0xb3c> <== NOT EXECUTED
20222f8: af 35 a0 08 srl %l6, 8, %l7 <== NOT EXECUTED
if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {
ret_val = -1;
}
if (ret_val == 0) {
if (0 > read(fd,buffer,sector_size)) {
20222fc: a8 0d 80 14 and %l6, %l4, %l4 <== NOT EXECUTED
2022300: b1 35 a0 18 srl %l6, 0x18, %i0 <== NOT EXECUTED
2022304: a6 10 00 16 mov %l6, %l3 <== NOT EXECUTED
2022308: ab 35 a0 10 srl %l6, 0x10, %l5 <== NOT EXECUTED
202230c: a9 35 20 08 srl %l4, 8, %l4 <== NOT EXECUTED
2022310: ae 10 20 00 clr %l7 <== NOT EXECUTED
2022314: ac 10 20 00 clr %l6 <== NOT EXECUTED
* finally we are there: let's fill in the values into the MBR
* but first clear the MRB leaving the partition table.
*/
#define RTEMS_IDE_PARTITION_TABLE_OFFSET 0x1be
#define RTEMS_IDE_PARTITION_TABLE_SIZE (4 * 16)
memset(mbr,0,RTEMS_IDE_PARTITION_TABLE_OFFSET);
2022318: 92 10 20 00 clr %o1 <== NOT EXECUTED
202231c: 94 10 21 be mov 0x1be, %o2 <== NOT EXECUTED
2022320: 40 00 ae 37 call 204dbfc <memset> <== NOT EXECUTED
2022324: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* with 0xEB,....
*/
/*
* fill OEMName
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
2022328: 90 07 bd 5b add %fp, -677, %o0 <== NOT EXECUTED
* but first clear the MRB leaving the partition table.
*/
#define RTEMS_IDE_PARTITION_TABLE_OFFSET 0x1be
#define RTEMS_IDE_PARTITION_TABLE_SIZE (4 * 16)
memset(mbr,0,RTEMS_IDE_PARTITION_TABLE_OFFSET);
memset(mbr + RTEMS_IDE_PARTITION_TABLE_OFFSET + RTEMS_IDE_PARTITION_TABLE_SIZE,
202232c: c0 37 bf 56 clrh [ %fp + -170 ] <== NOT EXECUTED
* with 0xEB,....
*/
/*
* fill OEMName
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
2022330: 92 07 bf 8b add %fp, -117, %o1 <== NOT EXECUTED
2022334: 40 00 ad 9f call 204d9b0 <memcpy> <== NOT EXECUTED
2022338: 94 10 20 08 mov 8, %o2 <== NOT EXECUTED
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
202233c: da 07 bf 64 ld [ %fp + -156 ], %o5 <== NOT EXECUTED
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
2022340: c4 07 bf 60 ld [ %fp + -160 ], %g2 <== NOT EXECUTED
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
2022344: c2 07 bf 70 ld [ %fp + -144 ], %g1 <== NOT EXECUTED
* fill OEMName
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
2022348: c6 07 bf 58 ld [ %fp + -168 ], %g3 <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
202234c: c8 0f bf 8a ldub [ %fp + -118 ], %g4 <== NOT EXECUTED
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
2022350: da 2c 20 0d stb %o5, [ %l0 + 0xd ] <== NOT EXECUTED
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
2022354: ec 2c 20 13 stb %l6, [ %l0 + 0x13 ] <== NOT EXECUTED
2022358: ee 2c 20 14 stb %l7, [ %l0 + 0x14 ] <== NOT EXECUTED
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
202235c: da 0f bf 89 ldub [ %fp + -119 ], %o5 <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
2022360: c2 2c 20 11 stb %g1, [ %l0 + 0x11 ] <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
2022364: da 2c 20 15 stb %o5, [ %l0 + 0x15 ] <== NOT EXECUTED
* fill OEMName
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
2022368: 9b 30 e0 08 srl %g3, 8, %o5 <== NOT EXECUTED
202236c: da 2c 20 0c stb %o5, [ %l0 + 0xc ] <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
2022370: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
2022374: da 2c 20 0f stb %o5, [ %l0 + 0xf ] <== NOT EXECUTED
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
2022378: 9b 30 60 08 srl %g1, 8, %o5 <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
202237c: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
2022380: c2 2c 20 18 stb %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
2022384: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
2022388: c4 2c 20 0e stb %g2, [ %l0 + 0xe ] <== NOT EXECUTED
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
202238c: c2 2c 20 1a stb %g1, [ %l0 + 0x1a ] <== NOT EXECUTED
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
2022390: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
2022394: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
2022398: e6 2c 20 20 stb %l3, [ %l0 + 0x20 ] <== NOT EXECUTED
202239c: e8 2c 20 21 stb %l4, [ %l0 + 0x21 ] <== NOT EXECUTED
20223a0: ea 2c 20 22 stb %l5, [ %l0 + 0x22 ] <== NOT EXECUTED
20223a4: f0 2c 20 23 stb %i0, [ %l0 + 0x23 ] <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
20223a8: da 2c 20 12 stb %o5, [ %l0 + 0x12 ] <== NOT EXECUTED
* fill OEMName
*/
memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),
fmt_params->OEMName,
FAT_BR_OEMNAME_SIZE);
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
20223ac: c6 2c 20 0b stb %g3, [ %l0 + 0xb ] <== NOT EXECUTED
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
FAT_SET_BR_FILES_PER_ROOT_DIR(mbr , fmt_params->files_per_root_dir);
FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);
FAT_SET_BR_MEDIA(mbr , fmt_params->media_code);
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
20223b0: c0 2c 20 19 clrb [ %l0 + 0x19 ] <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
20223b4: c0 2c 20 1b clrb [ %l0 + 0x1b ] <== NOT EXECUTED
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
20223b8: c0 2c 20 1d clrb [ %l0 + 0x1d ] <== NOT EXECUTED
20223bc: c0 2c 20 1e clrb [ %l0 + 0x1e ] <== NOT EXECUTED
20223c0: c0 2c 20 1f clrb [ %l0 + 0x1f ] <== NOT EXECUTED
FAT_SET_BR_BYTES_PER_SECTOR(mbr , fmt_params->bytes_per_sector);
FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);
/* number of FATs on medium */
FAT_SET_BR_FAT_NUM(mbr , 2); /* standard/recommended value */
20223c4: c4 2c 20 10 stb %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_TRACK(mbr , 255); /* only needed for INT13... */
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
20223c8: 80 a1 20 04 cmp %g4, 4 <== NOT EXECUTED
20223cc: 02 80 02 5f be 2022d48 <msdos_format+0xd18> <== NOT EXECUTED
20223d0: c2 2c 20 1c stb %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
20223d4: c2 07 bf a4 ld [ %fp + -92 ], %g1 <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
20223d8: c4 07 bf 68 ld [ %fp + -152 ], %g2 <== NOT EXECUTED
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
20223dc: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
20223e0: c4 2c 20 16 stb %g2, [ %l0 + 0x16 ] <== NOT EXECUTED
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
20223e4: c6 2c 20 2a stb %g3, [ %l0 + 0x2a ] <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
20223e8: 87 30 a0 08 srl %g2, 8, %g3 <== NOT EXECUTED
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
20223ec: 85 30 60 10 srl %g1, 0x10, %g2 <== NOT EXECUTED
20223f0: c4 2c 20 29 stb %g2, [ %l0 + 0x29 ] <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
20223f4: 84 10 20 29 mov 0x29, %g2 <== NOT EXECUTED
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
20223f8: c2 2c 20 27 stb %g1, [ %l0 + 0x27 ] <== NOT EXECUTED
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
20223fc: c4 2c 20 26 stb %g2, [ %l0 + 0x26 ] <== NOT EXECUTED
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
2022400: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
2022404: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
2022408: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
202240c: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
memcpy(FAT_GET_ADDR_BR_VOLLAB(mbr),
2022410: 92 07 bf 94 add %fp, -108, %o1 <== NOT EXECUTED
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
2022414: c2 2c 20 28 stb %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
FAT_SET_BR_NUMBER_OF_HEADS(mbr , 6); /* only needed for INT13... */
FAT_SET_BR_HIDDEN_SECTORS(mbr , 1); /* only needed for INT13... */
FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);
if (fmt_params->fattype != FAT_FAT32) {
FAT_SET_BR_SECTORS_PER_FAT(mbr ,fmt_params->sectors_per_fat);
2022418: c6 2c 20 17 stb %g3, [ %l0 + 0x17 ] <== NOT EXECUTED
FAT_SET_BR_DRVNUM(mbr , 0); /* only needed for INT13... */
202241c: c0 2c 20 24 clrb [ %l0 + 0x24 ] <== NOT EXECUTED
FAT_SET_BR_RSVD1(mbr , 0); /* fill with zero */
2022420: c0 2c 20 25 clrb [ %l0 + 0x25 ] <== NOT EXECUTED
FAT_SET_BR_BOOTSIG(mbr , FAT_BR_BOOTSIG_VAL);
FAT_SET_BR_VOLID(mbr , fmt_params->vol_id); /* volume id */
memcpy(FAT_GET_ADDR_BR_VOLLAB(mbr),
2022424: 90 07 bd 83 add %fp, -637, %o0 <== NOT EXECUTED
2022428: 40 00 ad 62 call 204d9b0 <memcpy> <== NOT EXECUTED
202242c: 94 10 20 0b mov 0xb, %o2 <== NOT EXECUTED
fmt_params->VolLabel,
FAT_BR_VOLLAB_SIZE);
memcpy(FAT_GET_ADDR_BR_FILSYSTYPE(mbr),
2022430: c2 0f bf 8a ldub [ %fp + -118 ], %g1 <== NOT EXECUTED
2022434: 13 00 81 a6 sethi %hi(0x2069800), %o1 <== NOT EXECUTED
2022438: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
202243c: 02 80 00 04 be 202244c <msdos_format+0x41c> <== NOT EXECUTED
2022440: 92 12 60 08 or %o1, 8, %o1 <== NOT EXECUTED
2022444: 13 00 81 a5 sethi %hi(0x2069400), %o1 <== NOT EXECUTED
2022448: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 20697f8 <rtems_rtc_shell_usage+0xe98><== NOT EXECUTED
202244c: 90 07 bd 8e add %fp, -626, %o0 <== NOT EXECUTED
2022450: 40 00 ad 58 call 204d9b0 <memcpy> <== NOT EXECUTED
2022454: 94 10 20 08 mov 8, %o2 <== NOT EXECUTED
FAT_BR_FILSYSTYPE_SIZE);
}
/*
* add boot record signature
*/
FAT_SET_BR_SIGNATURE(mbr, FAT_BR_SIGNATURE_VAL);
2022458: 82 10 20 55 mov 0x55, %g1 <== NOT EXECUTED
202245c: c2 2c 21 fe stb %g1, [ %l0 + 0x1fe ] <== NOT EXECUTED
2022460: 82 10 3f aa mov -86, %g1 <== NOT EXECUTED
2022464: c2 2c 21 ff stb %g1, [ %l0 + 0x1ff ] <== NOT EXECUTED
/*
* add jump to boot loader at start of sector
*/
FAT_SET_VAL8(mbr,0,0xeb);
2022468: 82 10 3f eb mov -21, %g1 <== NOT EXECUTED
202246c: c2 2c 00 00 stb %g1, [ %l0 ] <== NOT EXECUTED
FAT_SET_VAL8(mbr,1,0x3c);
2022470: 82 10 20 3c mov 0x3c, %g1 <== NOT EXECUTED
2022474: c2 2c 20 01 stb %g1, [ %l0 + 1 ] <== NOT EXECUTED
FAT_SET_VAL8(mbr,2,0x90);
2022478: 82 10 3f 90 mov -112, %g1 <== NOT EXECUTED
/*
* write master boot record to disk
* also write copy of MBR to disk
*/
if (ret_val == 0) {
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
202247c: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
/*
* add jump to boot loader at start of sector
*/
FAT_SET_VAL8(mbr,0,0xeb);
FAT_SET_VAL8(mbr,1,0x3c);
FAT_SET_VAL8(mbr,2,0x90);
2022480: c2 2c 20 02 stb %g1, [ %l0 + 2 ] <== NOT EXECUTED
/*
* write master boot record to disk
* also write copy of MBR to disk
*/
if (ret_val == 0) {
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022484: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022488: 15 00 81 a6 sethi %hi(0x2069800), %o2 <== NOT EXECUTED
202248c: 7f ff fe 49 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022490: 94 12 a0 18 or %o2, 0x18, %o2 ! 2069818 <rtems_rtc_shell_usage+0xeb8><== NOT EXECUTED
"write MRB sector\n");
ret_val = msdos_format_write_sec(fd,
2022494: d4 07 bf 58 ld [ %fp + -168 ], %o2 <== NOT EXECUTED
2022498: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202249c: 92 10 20 00 clr %o1 <== NOT EXECUTED
20224a0: 7f ff fe 59 call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
20224a4: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
0,
fmt_params.bytes_per_sector,
tmp_sec);
}
if ((ret_val == 0) &&
20224a8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20224ac: 12 bf ff 05 bne 20220c0 <msdos_format+0x90> <== NOT EXECUTED
20224b0: c2 07 bf 80 ld [ %fp + -128 ], %g1 <== NOT EXECUTED
20224b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20224b8: 12 80 01 e6 bne 2022c50 <msdos_format+0xc20> <== NOT EXECUTED
20224bc: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
}
}
/*
* for FAT32: initialize info sector on disk
*/
if ((ret_val == 0) &&
20224c0: c2 07 bf 84 ld [ %fp + -124 ], %g1 <== NOT EXECUTED
20224c4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20224c8: 12 80 01 ba bne 2022bb0 <msdos_format+0xb80> <== NOT EXECUTED
20224cc: 92 10 20 00 clr %o1 <== NOT EXECUTED
/*
* write FAT as all empty
* -> write all FAT sectors as zero
*/
if (ret_val == 0) {
ret_val = msdos_format_fill_sectors
20224d0: d2 07 bf 68 ld [ %fp + -152 ], %o1 <== NOT EXECUTED
20224d4: 7f ff 81 ae call 2002b8c <.umul> <== NOT EXECUTED
20224d8: d0 0f bf 88 ldub [ %fp + -120 ], %o0 <== NOT EXECUTED
20224dc: d4 07 bf 60 ld [ %fp + -160 ], %o2 <== NOT EXECUTED
20224e0: d8 07 bf 58 ld [ %fp + -168 ], %o4 <== NOT EXECUTED
20224e4: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20224e8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20224ec: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
20224f0: 7f ff fe 60 call 2021e70 <msdos_format_fill_sectors> <== NOT EXECUTED
20224f4: 9a 10 20 00 clr %o5 <== NOT EXECUTED
}
/*
* clear/init root directory
* -> write all directory sectors as 0x00
*/
if (ret_val == 0) {
20224f8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20224fc: 12 bf fe f1 bne 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022500: d4 1f bf 78 ldd [ %fp + -136 ], %o2 <== NOT EXECUTED
ret_val = msdos_format_fill_sectors
2022504: d8 07 bf 58 ld [ %fp + -168 ], %o4 <== NOT EXECUTED
2022508: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
202250c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2022510: 7f ff fe 58 call 2021e70 <msdos_format_fill_sectors> <== NOT EXECUTED
2022514: 9a 10 20 00 clr %o5 <== NOT EXECUTED
0x00);
}
/*
* write volume label to first entry of directory
*/
if ((ret_val == 0) && fmt_params.VolLabel_present) {
2022518: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
202251c: 12 bf fe e9 bne 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022520: c2 0f bf a0 ldub [ %fp + -96 ], %g1 <== NOT EXECUTED
2022524: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2022528: 02 bf fe e7 be 20220c4 <msdos_format+0x94> <== NOT EXECUTED
202252c: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
memset(tmp_sec,0,sizeof(tmp_sec));
2022530: 92 10 20 00 clr %o1 <== NOT EXECUTED
2022534: 94 10 22 00 mov 0x200, %o2 <== NOT EXECUTED
2022538: 40 00 ad b1 call 204dbfc <memset> <== NOT EXECUTED
202253c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
memcpy(MSDOS_DIR_NAME(tmp_sec),fmt_params.VolLabel,MSDOS_SHORT_NAME_LEN);
2022540: 84 07 bf 94 add %fp, -108, %g2 <== NOT EXECUTED
2022544: c2 08 a0 0a ldub [ %g2 + 0xa ], %g1 <== NOT EXECUTED
2022548: c6 00 a0 04 ld [ %g2 + 4 ], %g3 <== NOT EXECUTED
202254c: c4 10 a0 08 lduh [ %g2 + 8 ], %g2 <== NOT EXECUTED
2022550: c8 07 bf 94 ld [ %fp + -108 ], %g4 <== NOT EXECUTED
*MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;
ret_val = msdos_format_write_sec
2022554: d2 07 bf 78 ld [ %fp + -136 ], %o1 <== NOT EXECUTED
2022558: d4 07 bf 58 ld [ %fp + -168 ], %o2 <== NOT EXECUTED
/*
* write volume label to first entry of directory
*/
if ((ret_val == 0) && fmt_params.VolLabel_present) {
memset(tmp_sec,0,sizeof(tmp_sec));
memcpy(MSDOS_DIR_NAME(tmp_sec),fmt_params.VolLabel,MSDOS_SHORT_NAME_LEN);
202255c: c2 2c 20 0a stb %g1, [ %l0 + 0xa ] <== NOT EXECUTED
2022560: c6 24 20 04 st %g3, [ %l0 + 4 ] <== NOT EXECUTED
2022564: c4 34 20 08 sth %g2, [ %l0 + 8 ] <== NOT EXECUTED
*MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;
2022568: 82 10 20 08 mov 8, %g1 <== NOT EXECUTED
/*
* write volume label to first entry of directory
*/
if ((ret_val == 0) && fmt_params.VolLabel_present) {
memset(tmp_sec,0,sizeof(tmp_sec));
memcpy(MSDOS_DIR_NAME(tmp_sec),fmt_params.VolLabel,MSDOS_SHORT_NAME_LEN);
202256c: c8 27 bd 58 st %g4, [ %fp + -680 ] <== NOT EXECUTED
*MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;
2022570: c2 2f bd 63 stb %g1, [ %fp + -669 ] <== NOT EXECUTED
ret_val = msdos_format_write_sec
2022574: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2022578: 7f ff fe 23 call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
202257c: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
/*
* write FAT entry 0 as (0xffffff00|Media_type)EOC,
* write FAT entry 1 as EOC
* allocate directory in a FAT32 FS
*/
if ((ret_val == 0) && fmt_params.VolLabel_present){
2022580: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022584: 12 bf fe cf bne 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022588: c2 0f bf a0 ldub [ %fp + -96 ], %g1 <== NOT EXECUTED
202258c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2022590: 02 bf fe cc be 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022594: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
/*
* empty sector: all clusters are free/do not link further on
*/
memset(tmp_sec,0,sizeof(tmp_sec));
2022598: 92 10 20 00 clr %o1 <== NOT EXECUTED
202259c: 40 00 ad 98 call 204dbfc <memset> <== NOT EXECUTED
20225a0: 94 10 22 00 mov 0x200, %o2 <== NOT EXECUTED
switch(fmt_params.fattype) {
20225a4: c2 0f bf 8a ldub [ %fp + -118 ], %g1 <== NOT EXECUTED
20225a8: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
20225ac: 02 80 01 d2 be 2022cf4 <msdos_format+0xcc4> <== NOT EXECUTED
20225b0: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED
20225b4: 02 80 01 be be 2022cac <msdos_format+0xc7c> <== NOT EXECUTED
20225b8: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
20225bc: 02 80 01 b3 be 2022c88 <msdos_format+0xc58> <== NOT EXECUTED
20225c0: c2 0f bf 89 ldub [ %fp + -119 ], %g1 <== NOT EXECUTED
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
break;
default:
ret_val = -1;
errno = EINVAL;
20225c4: 40 00 9f af call 204a480 <__errno> <== NOT EXECUTED
20225c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20225cc: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20225d0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
if (fmt_params.fattype == FAT_FAT32) {
20225d4: c2 0f bf 8a ldub [ %fp + -118 ], %g1 <== NOT EXECUTED
20225d8: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED
20225dc: 12 bf fe ba bne 20220c4 <msdos_format+0x94> <== NOT EXECUTED
20225e0: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
/*
* only first valid cluster (cluster number 2) belongs
* to root directory, and is end of chain
* mark this in every copy of the FAT
*/
FAT_SET_VAL32(tmp_sec,8,FAT_FAT32_EOC);
20225e4: c2 0f bf 88 ldub [ %fp + -120 ], %g1 <== NOT EXECUTED
20225e8: 80 a0 00 18 cmp %g0, %i0 <== NOT EXECUTED
20225ec: 84 60 3f ff subx %g0, -1, %g2 <== NOT EXECUTED
20225f0: 82 20 00 01 neg %g1 <== NOT EXECUTED
20225f4: 83 30 60 1f srl %g1, 0x1f, %g1 <== NOT EXECUTED
20225f8: 82 08 80 01 and %g2, %g1, %g1 <== NOT EXECUTED
20225fc: 84 10 3f ff mov -1, %g2 <== NOT EXECUTED
2022600: c4 2c 20 0a stb %g2, [ %l0 + 0xa ] <== NOT EXECUTED
2022604: c4 2c 20 09 stb %g2, [ %l0 + 9 ] <== NOT EXECUTED
2022608: 84 10 3f f8 mov -8, %g2 <== NOT EXECUTED
202260c: c4 2c 20 08 stb %g2, [ %l0 + 8 ] <== NOT EXECUTED
2022610: 84 10 20 0f mov 0xf, %g2 <== NOT EXECUTED
2022614: c4 2f bd 63 stb %g2, [ %fp + -669 ] <== NOT EXECUTED
}
for (i = 0;
2022618: 80 88 60 ff btst 0xff, %g1 <== NOT EXECUTED
202261c: 02 bf fe a9 be 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022620: d0 07 bf 68 ld [ %fp + -152 ], %o0 <== NOT EXECUTED
2022624: 10 80 00 05 b 2022638 <msdos_format+0x608> <== NOT EXECUTED
2022628: a8 10 20 00 clr %l4 <== NOT EXECUTED
202262c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2022630: 12 bf fe a4 bne 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022634: d0 07 bf 68 ld [ %fp + -152 ], %o0 <== NOT EXECUTED
(i < fmt_params.fat_num) && (ret_val == 0);
i++) {
ret_val = msdos_format_write_sec
2022638: 7f ff 81 55 call 2002b8c <.umul> <== NOT EXECUTED
202263c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2022640: d2 07 bf 60 ld [ %fp + -160 ], %o1 <== NOT EXECUTED
2022644: d4 07 bf 58 ld [ %fp + -168 ], %o2 <== NOT EXECUTED
2022648: 92 02 00 09 add %o0, %o1, %o1 <== NOT EXECUTED
202264c: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2022650: 7f ff fd ed call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
2022654: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
* to root directory, and is end of chain
* mark this in every copy of the FAT
*/
FAT_SET_VAL32(tmp_sec,8,FAT_FAT32_EOC);
}
for (i = 0;
2022658: c2 0f bf 88 ldub [ %fp + -120 ], %g1 <== NOT EXECUTED
(i < fmt_params.fat_num) && (ret_val == 0);
i++) {
202265c: a8 05 20 01 inc %l4 <== NOT EXECUTED
* to root directory, and is end of chain
* mark this in every copy of the FAT
*/
FAT_SET_VAL32(tmp_sec,8,FAT_FAT32_EOC);
}
for (i = 0;
2022660: 80 a0 40 14 cmp %g1, %l4 <== NOT EXECUTED
2022664: 14 bf ff f2 bg 202262c <msdos_format+0x5fc> <== NOT EXECUTED
2022668: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
/*
* cleanup:
* sync and unlock disk
* free any data structures (not needed now)
*/
if (fd != -1) {
202266c: 10 bf fe 96 b 20220c4 <msdos_format+0x94> <== NOT EXECUTED
2022670: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {
ret_val = -1;
}
if (ret_val == 0) {
if (0 > read(fd,buffer,sector_size)) {
2022674: 10 bf fe 93 b 20220c0 <msdos_format+0x90> <== NOT EXECUTED
2022678: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
* determine number of FATs
*/
if (ret_val == 0) {
if ((rqdata == NULL) ||
(rqdata->fat_num == 0)) {
fmt_params->fat_num = 2;
202267c: c2 2f bf 88 stb %g1, [ %fp + -120 ] <== NOT EXECUTED
ret_val = EINVAL;
}
}
if (ret_val == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022680: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2022684: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2022688: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
202268c: 7f ff fd c9 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022690: 94 12 a3 98 or %o2, 0x398, %o2 <== NOT EXECUTED
/*
* determine FAT type and sectors per cluster
* depends on
*/
if (ret_val == 0) {
fmt_params->sectors_per_cluster = 1;
2022694: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2022698: 10 bf fe e1 b 202221c <msdos_format+0x1ec> <== NOT EXECUTED
202269c: c2 27 bf 64 st %g1, [ %fp + -156 ] <== NOT EXECUTED
(rqdata->fattype == MSDOS_FMT_FAT16)) {
fmt_params->fattype = FAT_FAT16;
}
else if ((rqdata != NULL) &&
(rqdata->fattype == MSDOS_FMT_FAT32)) {
fmt_params->fattype = FAT_FAT32;
20226a0: 82 10 20 04 mov 4, %g1 <== NOT EXECUTED
20226a4: c2 2f bf 8a stb %g1, [ %fp + -118 ] <== NOT EXECUTED
20226a8: a8 10 20 00 clr %l4 <== NOT EXECUTED
}
/*
* try to use user requested cluster size
*/
if ((rqdata != NULL) &&
(rqdata->sectors_per_cluster > 0)) {
20226ac: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
}
}
/*
* try to use user requested cluster size
*/
if ((rqdata != NULL) &&
20226b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20226b4: 12 80 00 04 bne 20226c4 <msdos_format+0x694> <== NOT EXECUTED
20226b8: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
20226bc: c4 07 bf 64 ld [ %fp + -156 ], %g2 <== NOT EXECUTED
20226c0: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
*/
for (onebit = 128;onebit >= 1;onebit = onebit>>1) {
if (fmt_params->sectors_per_cluster >= onebit) {
fmt_params->sectors_per_cluster = onebit;
if (fmt_params->sectors_per_cluster
<= 32768L/fmt_params->bytes_per_sector) {
20226c4: a6 10 20 80 mov 0x80, %l3 <== NOT EXECUTED
20226c8: ec 07 bf 58 ld [ %fp + -168 ], %l6 <== NOT EXECUTED
* must be power of 2
* must be smaller than or equal to 128
* sectors_per_cluster*bytes_per_sector must not be bigger than 32K
*/
for (onebit = 128;onebit >= 1;onebit = onebit>>1) {
if (fmt_params->sectors_per_cluster >= onebit) {
20226cc: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
20226d0: 08 80 00 0a bleu 20226f8 <msdos_format+0x6c8> <== NOT EXECUTED
20226d4: aa 10 20 00 clr %l5 <== NOT EXECUTED
20226d8: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
* check sectors per cluster.
* must be power of 2
* must be smaller than or equal to 128
* sectors_per_cluster*bytes_per_sector must not be bigger than 32K
*/
for (onebit = 128;onebit >= 1;onebit = onebit>>1) {
20226dc: aa 05 60 01 inc %l5 <== NOT EXECUTED
20226e0: 80 a5 60 08 cmp %l5, 8 <== NOT EXECUTED
20226e4: 02 80 01 fe be 2022edc <msdos_format+0xeac> <== NOT EXECUTED
20226e8: a7 34 e0 01 srl %l3, 1, %l3 <== NOT EXECUTED
if (fmt_params->sectors_per_cluster >= onebit) {
20226ec: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
20226f0: 18 bf ff fa bgu 20226d8 <msdos_format+0x6a8> <== NOT EXECUTED
20226f4: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
fmt_params->sectors_per_cluster = onebit;
if (fmt_params->sectors_per_cluster
20226f8: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
20226fc: 40 01 00 a2 call 2062984 <.udiv> <== NOT EXECUTED
2022700: 11 00 00 20 sethi %hi(0x8000), %o0 <== NOT EXECUTED
2022704: 80 a2 00 13 cmp %o0, %l3 <== NOT EXECUTED
2022708: 3a 80 00 04 bcc,a 2022718 <msdos_format+0x6e8> <== NOT EXECUTED
202270c: e6 27 bf 64 st %l3, [ %fp + -156 ] <== NOT EXECUTED
2022710: 10 bf ff f3 b 20226dc <msdos_format+0x6ac> <== NOT EXECUTED
2022714: 82 10 00 13 mov %l3, %g1 <== NOT EXECUTED
}
}
}
}
if (ret_val == 0) {
2022718: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
202271c: 12 80 01 06 bne 2022b34 <msdos_format+0xb04> <== NOT EXECUTED
2022720: d6 07 bf 64 ld [ %fp + -156 ], %o3 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022724: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022728: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
202272c: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2022730: 7f ff fd a0 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022734: 94 12 a3 b0 or %o2, 0x3b0, %o2 ! 20697b0 <rtems_rtc_shell_usage+0xe50><== NOT EXECUTED
"sectors per cluster: %d\n", fmt_params->sectors_per_cluster);
if (fmt_params->fattype == FAT_FAT32) {
2022738: fa 0f bf 8a ldub [ %fp + -118 ], %i5 <== NOT EXECUTED
202273c: 80 a7 60 04 cmp %i5, 4 <== NOT EXECUTED
2022740: 02 80 01 c1 be 2022e44 <msdos_format+0xe14> <== NOT EXECUTED
2022744: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
/* recommended: for FAT12/FAT16, always set reserved sector count to 1 */
fmt_params->rsvd_sector_cnt = 1;
/* recommended: for FAT16, set files per root directory to 512 */
/* for FAT12/FAT16, set files per root directory */
/* must fill up an even count of sectors */
if ((rqdata != NULL) &&
2022748: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
202274c: 02 80 01 0d be 2022b80 <msdos_format+0xb50> <== NOT EXECUTED
2022750: c2 27 bf 60 st %g1, [ %fp + -160 ] <== NOT EXECUTED
(rqdata->files_per_root_dir > 0)) {
2022754: e6 06 60 10 ld [ %i1 + 0x10 ], %l3 <== NOT EXECUTED
/* recommended: for FAT12/FAT16, always set reserved sector count to 1 */
fmt_params->rsvd_sector_cnt = 1;
/* recommended: for FAT16, set files per root directory to 512 */
/* for FAT12/FAT16, set files per root directory */
/* must fill up an even count of sectors */
if ((rqdata != NULL) &&
2022758: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
202275c: 02 80 01 09 be 2022b80 <msdos_format+0xb50> <== NOT EXECUTED
2022760: a6 04 ff ff add %l3, -1, %l3 <== NOT EXECUTED
}
else {
fmt_params->files_per_root_dir = 64;
}
}
fmt_params->files_per_root_dir = (fmt_params->files_per_root_dir +
2022764: ee 07 bf 58 ld [ %fp + -168 ], %l7 <== NOT EXECUTED
2022768: 93 2d e0 01 sll %l7, 1, %o1 <== NOT EXECUTED
202276c: 93 32 60 05 srl %o1, 5, %o1 <== NOT EXECUTED
2022770: a6 04 c0 09 add %l3, %o1, %l3 <== NOT EXECUTED
(2*fmt_params->bytes_per_sector/
FAT_DIRENTRY_SIZE-1));
fmt_params->files_per_root_dir -= (fmt_params->files_per_root_dir %
2022774: 40 01 01 30 call 2062c34 <.urem> <== NOT EXECUTED
2022778: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
202277c: 90 24 c0 08 sub %l3, %o0, %o0 <== NOT EXECUTED
2022780: d0 27 bf 70 st %o0, [ %fp + -144 ] <== NOT EXECUTED
2022784: 91 2a 20 05 sll %o0, 5, %o0 <== NOT EXECUTED
(2*fmt_params->bytes_per_sector
/FAT_DIRENTRY_SIZE));
}
fmt_params->root_dir_sectors =
(((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)
2022788: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
202278c: b6 05 ff ff add %l7, -1, %i3 <== NOT EXECUTED
2022790: 40 01 00 7d call 2062984 <.udiv> <== NOT EXECUTED
2022794: 90 06 c0 08 add %i3, %o0, %o0 <== NOT EXECUTED
+ fmt_params->bytes_per_sector - 1)
/ fmt_params->bytes_per_sector);
}
if (ret_val == 0) {
fatdata_sect_cnt = (fmt_params->totl_sector_cnt -
2022798: c2 07 bf 5c ld [ %fp + -164 ], %g1 <== NOT EXECUTED
202279c: e6 07 bf 60 ld [ %fp + -160 ], %l3 <== NOT EXECUTED
ret_val = msdos_format_eval_sectors_per_cluster
(fmt_params->fattype,
fmt_params->bytes_per_sector,
fatdata_sect_cnt,
fmt_params->fat_num,
20227a0: f0 0f bf 88 ldub [ %fp + -120 ], %i0 <== NOT EXECUTED
/*
* check values to get legal arrangement of FAT type and cluster count
*/
ret_val = msdos_format_eval_sectors_per_cluster
20227a4: ea 07 bf 64 ld [ %fp + -156 ], %l5 <== NOT EXECUTED
(((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)
+ fmt_params->bytes_per_sector - 1)
/ fmt_params->bytes_per_sector);
}
if (ret_val == 0) {
fatdata_sect_cnt = (fmt_params->totl_sector_cnt -
20227a8: 82 20 40 13 sub %g1, %l3, %g1 <== NOT EXECUTED
20227ac: 82 20 40 08 sub %g1, %o0, %g1 <== NOT EXECUTED
FAT_DIRENTRY_SIZE-1));
fmt_params->files_per_root_dir -= (fmt_params->files_per_root_dir %
(2*fmt_params->bytes_per_sector
/FAT_DIRENTRY_SIZE));
}
fmt_params->root_dir_sectors =
20227b0: d0 27 bf 74 st %o0, [ %fp + -140 ] <== NOT EXECUTED
(((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)
+ fmt_params->bytes_per_sector - 1)
/ fmt_params->bytes_per_sector);
}
if (ret_val == 0) {
fatdata_sect_cnt = (fmt_params->totl_sector_cnt -
20227b4: c2 27 bd 4c st %g1, [ %fp + -692 ] <== NOT EXECUTED
uint32_t sectors_per_fat;
uint32_t data_cluster_cnt;
/*
* ensure, that maximum cluster size (32KByte) is not exceeded
*/
while (MS_BYTES_PER_CLUSTER_LIMIT / bytes_per_sector < sectors_per_cluster) {
20227b8: 11 00 00 20 sethi %hi(0x8000), %o0 <== NOT EXECUTED
20227bc: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
20227c0: 40 01 00 71 call 2062984 <.udiv> <== NOT EXECUTED
20227c4: ba 0f 60 ff and %i5, 0xff, %i5 <== NOT EXECUTED
20227c8: 80 a5 40 08 cmp %l5, %o0 <== NOT EXECUTED
20227cc: 08 80 00 07 bleu 20227e8 <msdos_format+0x7b8> <== NOT EXECUTED
20227d0: b4 0e 20 ff and %i0, 0xff, %i2 <== NOT EXECUTED
sectors_per_cluster /= 2;
20227d4: ab 35 60 01 srl %l5, 1, %l5 <== NOT EXECUTED
uint32_t sectors_per_fat;
uint32_t data_cluster_cnt;
/*
* ensure, that maximum cluster size (32KByte) is not exceeded
*/
while (MS_BYTES_PER_CLUSTER_LIMIT / bytes_per_sector < sectors_per_cluster) {
20227d8: 80 a5 40 08 cmp %l5, %o0 <== NOT EXECUTED
20227dc: 38 bf ff ff bgu,a 20227d8 <msdos_format+0x7a8> <== NOT EXECUTED
20227e0: ab 35 60 01 srl %l5, 1, %l5 <== NOT EXECUTED
20227e4: b4 0e 20 ff and %i0, 0xff, %i2 <== NOT EXECUTED
finished = true;
}
/*
* when maximum cluster size is exceeded, we have invalid data, abort...
*/
if ((sectors_per_cluster * bytes_per_sector)
20227e8: 39 00 00 20 sethi %hi(0x8000), %i4 <== NOT EXECUTED
* compute number of data clusters for current data:
* - compute cluster count for data AND fat
* - compute storage size for FAT
* - subtract from total cluster count
*/
fatdata_cluster_cnt = fatdata_sec_cnt/sectors_per_cluster;
20227ec: d0 07 bd 4c ld [ %fp + -692 ], %o0 <== NOT EXECUTED
20227f0: 40 01 00 65 call 2062984 <.udiv> <== NOT EXECUTED
20227f4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
if (fattype == FAT_FAT12) {
20227f8: 80 a7 60 01 cmp %i5, 1 <== NOT EXECUTED
20227fc: 02 80 00 92 be 2022a44 <msdos_format+0xa14> <== NOT EXECUTED
2022800: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
fat_capacity = fatdata_cluster_cnt * 3 / 2;
}
else if (fattype == FAT_FAT16) {
2022804: 80 a7 60 02 cmp %i5, 2 <== NOT EXECUTED
2022808: 02 80 00 ce be 2022b40 <msdos_format+0xb10> <== NOT EXECUTED
202280c: 91 2a 20 02 sll %o0, 2, %o0 <== NOT EXECUTED
}
else { /* FAT32 */
fat_capacity = fatdata_cluster_cnt * 4;
}
sectors_per_fat = ((fat_capacity
2022810: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2022814: 40 01 00 5c call 2062984 <.udiv> <== NOT EXECUTED
2022818: 90 06 c0 08 add %i3, %o0, %o0 <== NOT EXECUTED
+ (sectors_per_cluster - 1))
/ sectors_per_cluster));
/*
* data cluster count too big? then make sectors bigger
*/
if (((fattype == FAT_FAT12) && (data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
202281c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2022820: 7f ff 80 db call 2002b8c <.umul> <== NOT EXECUTED
2022824: d0 27 bd 48 st %o0, [ %fp + -696 ] <== NOT EXECUTED
2022828: 82 05 7f ff add %l5, -1, %g1 <== NOT EXECUTED
202282c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2022830: 40 01 00 55 call 2062984 <.udiv> <== NOT EXECUTED
2022834: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
2022838: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
202283c: 90 25 80 08 sub %l6, %o0, %o0 <== NOT EXECUTED
2022840: 82 10 63 f5 or %g1, 0x3f5, %g1 <== NOT EXECUTED
2022844: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
2022848: 18 80 00 29 bgu 20228ec <msdos_format+0x8bc> <== NOT EXECUTED
202284c: 80 a7 60 02 cmp %i5, 2 <== NOT EXECUTED
finished = true;
}
/*
* when maximum cluster size is exceeded, we have invalid data, abort...
*/
if ((sectors_per_cluster * bytes_per_sector)
2022850: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2022854: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2022858: 7f ff 80 cd call 2002b8c <.umul> <== NOT EXECUTED
202285c: ac 10 20 01 mov 1, %l6 <== NOT EXECUTED
2022860: 80 a2 00 1c cmp %o0, %i4 <== NOT EXECUTED
2022864: 08 80 00 2c bleu 2022914 <msdos_format+0x8e4> <== NOT EXECUTED
2022868: 80 8d a0 ff btst 0xff, %l6 <== NOT EXECUTED
finished = true;
}
} while (!finished);
if (ret_val != 0) {
rtems_set_errno_and_return_minus_one(ret_val);
202286c: 40 00 9f 05 call 204a480 <__errno> <== NOT EXECUTED
2022870: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
2022874: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2022878: e6 07 bf 60 ld [ %fp + -160 ], %l3 <== NOT EXECUTED
202287c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2022880: f0 0f bf 88 ldub [ %fp + -120 ], %i0 <== NOT EXECUTED
fatdata_sect_cnt,
fmt_params->fat_num,
fmt_params->sectors_per_cluster,
§ors_per_cluster_adj,
&(fmt_params->sectors_per_fat));
fmt_params->sectors_per_cluster = sectors_per_cluster_adj;
2022884: c0 27 bf 64 clr [ %fp + -156 ] <== NOT EXECUTED
}
/*
* determine location and size of root directory
* for formatting
*/
if (fmt_params->root_dir_sectors > 0) {
2022888: ea 07 bf 74 ld [ %fp + -140 ], %l5 <== NOT EXECUTED
202288c: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
2022890: 02 80 00 a2 be 2022b18 <msdos_format+0xae8> <== NOT EXECUTED
2022894: d2 07 bf 68 ld [ %fp + -152 ], %o1 <== NOT EXECUTED
fmt_params->root_dir_start_sec =
2022898: 7f ff 80 bd call 2002b8c <.umul> <== NOT EXECUTED
202289c: 90 0e 20 ff and %i0, 0xff, %o0 <== NOT EXECUTED
fmt_params->rsvd_sector_cnt
+ (fmt_params-> fat_num*fmt_params->sectors_per_fat);
fmt_params->root_dir_fmt_sec_cnt = fmt_params->root_dir_sectors;
20228a0: ea 27 bf 7c st %l5, [ %fp + -132 ] <== NOT EXECUTED
/*
* determine location and size of root directory
* for formatting
*/
if (fmt_params->root_dir_sectors > 0) {
fmt_params->root_dir_start_sec =
20228a4: 90 02 00 13 add %o0, %l3, %o0 <== NOT EXECUTED
20228a8: d0 27 bf 78 st %o0, [ %fp + -136 ] <== NOT EXECUTED
fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
}
/*
* determine usable OEMName
*/
if (ret_val == 0) {
20228ac: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
20228b0: 12 80 00 52 bne 20229f8 <msdos_format+0x9c8> <== NOT EXECUTED
20228b4: 07 00 81 a5 sethi %hi(0x2069400), %g3 <== NOT EXECUTED
const char *from;
char *to = fmt_params->OEMName;
int cnt;
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
20228b8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20228bc: 02 80 00 06 be 20228d4 <msdos_format+0x8a4> <== NOT EXECUTED
20228c0: 86 10 e3 d0 or %g3, 0x3d0, %g3 <== NOT EXECUTED
(rqdata->OEMName != NULL)) {
20228c4: c6 06 40 00 ld [ %i1 ], %g3 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->OEMName;
int cnt;
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
20228c8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20228cc: 22 80 01 6f be,a 2022e88 <msdos_format+0xe58> <== NOT EXECUTED
20228d0: 07 00 81 a5 sethi %hi(0x2069400), %g3 <== NOT EXECUTED
20228d4: 03 00 81 c5 sethi %hi(0x2071400), %g1 <== NOT EXECUTED
}
/*=========================================================================*\
| Function: |
\*-------------------------------------------------------------------------*/
int msdos_format
20228d8: 98 07 bf 94 add %fp, -108, %o4 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->OEMName;
int cnt;
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
20228dc: c8 00 61 fc ld [ %g1 + 0x1fc ], %g4 <== NOT EXECUTED
/*
* non-printable character in given name, so keep stuck
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
20228e0: 96 10 20 20 mov 0x20, %o3 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->OEMName;
int cnt;
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
20228e4: 10 80 00 2a b 202298c <msdos_format+0x95c> <== NOT EXECUTED
20228e8: 82 07 bf 8c add %fp, -116, %g1 <== NOT EXECUTED
+ (sectors_per_cluster - 1))
/ sectors_per_cluster));
/*
* data cluster count too big? then make sectors bigger
*/
if (((fattype == FAT_FAT12) && (data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
20228ec: 12 bf ff da bne 2022854 <msdos_format+0x824> <== NOT EXECUTED
20228f0: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
((fattype == FAT_FAT16) && (data_cluster_cnt > FAT_FAT16_MAX_CLN))) {
sectors_per_cluster *= 2;
20228f4: ab 2d 60 01 sll %l5, 1, %l5 <== NOT EXECUTED
20228f8: ac 10 20 00 clr %l6 <== NOT EXECUTED
finished = true;
}
/*
* when maximum cluster size is exceeded, we have invalid data, abort...
*/
if ((sectors_per_cluster * bytes_per_sector)
20228fc: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2022900: 7f ff 80 a3 call 2002b8c <.umul> <== NOT EXECUTED
2022904: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2022908: 80 a2 00 1c cmp %o0, %i4 <== NOT EXECUTED
202290c: 18 bf ff d8 bgu 202286c <msdos_format+0x83c> <== NOT EXECUTED
2022910: 80 8d a0 ff btst 0xff, %l6 <== NOT EXECUTED
> MS_BYTES_PER_CLUSTER_LIMIT) {
ret_val = EINVAL;
finished = true;
}
} while (!finished);
2022914: 02 bf ff b7 be 20227f0 <msdos_format+0x7c0> <== NOT EXECUTED
2022918: d0 07 bd 4c ld [ %fp + -692 ], %o0 <== NOT EXECUTED
if (ret_val != 0) {
rtems_set_errno_and_return_minus_one(ret_val);
}
else {
*sectors_per_cluster_adj = sectors_per_cluster;
*sectors_per_fat_ptr = sectors_per_fat;
202291c: c2 07 bd 48 ld [ %fp + -696 ], %g1 <== NOT EXECUTED
fatdata_sect_cnt,
fmt_params->fat_num,
fmt_params->sectors_per_cluster,
§ors_per_cluster_adj,
&(fmt_params->sectors_per_fat));
fmt_params->sectors_per_cluster = sectors_per_cluster_adj;
2022920: ea 27 bf 64 st %l5, [ %fp + -156 ] <== NOT EXECUTED
/*
* determine media code
*/
if (ret_val == 0) {
if ((rqdata != NULL) &&
2022924: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2022928: 02 80 01 6f be 2022ee4 <msdos_format+0xeb4> <== NOT EXECUTED
202292c: c2 27 bf 68 st %g1, [ %fp + -152 ] <== NOT EXECUTED
2022930: ea 0e 60 15 ldub [ %i1 + 0x15 ], %l5 <== NOT EXECUTED
2022934: 92 8d 60 ff andcc %l5, 0xff, %o1 <== NOT EXECUTED
2022938: 02 80 01 6c be 2022ee8 <msdos_format+0xeb8> <== NOT EXECUTED
202293c: 82 10 3f f8 mov -8, %g1 <== NOT EXECUTED
(rqdata->media != 0)) {
const char valid_media_codes[] =
{0xF0,0xF8,0xF9,0xFA,0xFB,0xFC,0xFD,0xFE,0xFF};
2022940: 03 00 81 a6 sethi %hi(0x2069800), %g1 <== NOT EXECUTED
2022944: c4 18 60 b0 ldd [ %g1 + 0xb0 ], %g2 ! 20698b0 <C.13.7373> <== NOT EXECUTED
2022948: 82 10 60 b0 or %g1, 0xb0, %g1 <== NOT EXECUTED
202294c: c2 08 60 08 ldub [ %g1 + 8 ], %g1 <== NOT EXECUTED
2022950: c4 3f bf f0 std %g2, [ %fp + -16 ] <== NOT EXECUTED
2022954: c2 2f bf f8 stb %g1, [ %fp + -8 ] <== NOT EXECUTED
if (NULL==memchr(valid_media_codes,
2022958: 90 07 bf f0 add %fp, -16, %o0 <== NOT EXECUTED
202295c: 40 00 ab a2 call 204d7e4 <memchr> <== NOT EXECUTED
2022960: 94 10 20 09 mov 9, %o2 <== NOT EXECUTED
2022964: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2022968: 02 80 01 62 be 2022ef0 <msdos_format+0xec0> <== NOT EXECUTED
202296c: 01 00 00 00 nop <== NOT EXECUTED
sizeof(valid_media_codes))) {
ret_val = -1;
errno = EINVAL;
}
else {
fmt_params->media_code = rqdata->media;
2022970: 10 bf ff c6 b 2022888 <msdos_format+0x858> <== NOT EXECUTED
2022974: ea 2f bf 89 stb %l5, [ %fp + -119 ] <== NOT EXECUTED
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
}
*to = '\0';
2022978: c0 28 40 00 clrb [ %g1 ] <== NOT EXECUTED
202297c: 82 00 60 01 inc %g1 <== NOT EXECUTED
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
(rqdata->OEMName != NULL)) {
from = rqdata->OEMName;
}
for (cnt = 0;
2022980: 80 a0 40 0c cmp %g1, %o4 <== NOT EXECUTED
2022984: 02 80 00 0f be 20229c0 <msdos_format+0x990> <== NOT EXECUTED
2022988: 86 00 e0 01 inc %g3 <== NOT EXECUTED
cnt < (sizeof(fmt_params->OEMName)-1);
cnt++) {
if (isprint((unsigned char)*from)) {
202298c: c4 08 c0 00 ldub [ %g3 ], %g2 <== NOT EXECUTED
2022990: 9a 08 a0 ff and %g2, 0xff, %o5 <== NOT EXECUTED
2022994: 9a 01 00 0d add %g4, %o5, %o5 <== NOT EXECUTED
2022998: da 4b 60 01 ldsb [ %o5 + 1 ], %o5 <== NOT EXECUTED
202299c: 80 8b 60 97 btst 0x97, %o5 <== NOT EXECUTED
20229a0: 32 bf ff f6 bne,a 2022978 <msdos_format+0x948> <== NOT EXECUTED
20229a4: c4 28 7f ff stb %g2, [ %g1 + -1 ] <== NOT EXECUTED
/*
* non-printable character in given name, so keep stuck
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
20229a8: d6 28 7f ff stb %o3, [ %g1 + -1 ] <== NOT EXECUTED
}
*to = '\0';
20229ac: c0 28 40 00 clrb [ %g1 ] <== NOT EXECUTED
20229b0: 82 00 60 01 inc %g1 <== NOT EXECUTED
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
(rqdata->OEMName != NULL)) {
from = rqdata->OEMName;
}
for (cnt = 0;
20229b4: 80 a0 40 0c cmp %g1, %o4 <== NOT EXECUTED
20229b8: 32 bf ff f6 bne,a 2022990 <msdos_format+0x960> <== NOT EXECUTED
20229bc: c4 08 c0 00 ldub [ %g3 ], %g2 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->VolLabel;
int cnt;
from = ""; /* default: make "from" point to empty string */
if ((rqdata != NULL) &&
20229c0: 07 00 81 a5 sethi %hi(0x2069400), %g3 <== NOT EXECUTED
20229c4: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20229c8: 02 80 00 08 be 20229e8 <msdos_format+0x9b8> <== NOT EXECUTED
20229cc: 86 10 e3 d8 or %g3, 0x3d8, %g3 <== NOT EXECUTED
(rqdata->VolLabel != NULL)) {
20229d0: c6 06 60 04 ld [ %i1 + 4 ], %g3 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->VolLabel;
int cnt;
from = ""; /* default: make "from" point to empty string */
if ((rqdata != NULL) &&
20229d4: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20229d8: 22 80 01 2a be,a 2022e80 <msdos_format+0xe50> <== NOT EXECUTED
20229dc: 07 00 81 a5 sethi %hi(0x2069400), %g3 <== NOT EXECUTED
(rqdata->VolLabel != NULL)) {
from = rqdata->VolLabel;
fmt_params->VolLabel_present = true;
20229e0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20229e4: c2 2f bf a0 stb %g1, [ %fp + -96 ] <== NOT EXECUTED
}
/*=========================================================================*\
| Function: |
\*-------------------------------------------------------------------------*/
int msdos_format
20229e8: a0 04 20 48 add %l0, 0x48, %l0 <== NOT EXECUTED
int cnt;
from = ""; /* default: make "from" point to empty string */
if ((rqdata != NULL) &&
(rqdata->VolLabel != NULL)) {
from = rqdata->VolLabel;
fmt_params->VolLabel_present = true;
20229ec: 82 07 bf 95 add %fp, -107, %g1 <== NOT EXECUTED
/*
* non-printable character in given name, so keep stuck
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
20229f0: 10 80 00 31 b 2022ab4 <msdos_format+0xa84> <== NOT EXECUTED
20229f4: 98 10 20 20 mov 0x20, %o4 <== NOT EXECUTED
}
/*
* Phuuu.... That's it.
*/
if (ret_val != 0) {
rtems_set_errno_and_return_minus_one(ret_val);
20229f8: 40 00 9e a2 call 204a480 <__errno> <== NOT EXECUTED
20229fc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2022a00: e8 22 00 00 st %l4, [ %o0 ] <== NOT EXECUTED
2022a04: 82 10 20 00 clr %g1 <== NOT EXECUTED
ret_val = msdos_format_determine_fmt_params(dd,rqdata,&fmt_params);
}
/*
* if requested, write whole disk/partition with 0xe5
*/
if ((ret_val == 0) &&
2022a08: 80 88 60 ff btst 0xff, %g1 <== NOT EXECUTED
2022a0c: 02 bf fd ab be 20220b8 <msdos_format+0x88> <== NOT EXECUTED
2022a10: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
(rqdata != NULL) &&
!(rqdata->quick_format)) {
2022a14: c2 0e 60 16 ldub [ %i1 + 0x16 ], %g1 <== NOT EXECUTED
2022a18: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2022a1c: 12 bf fe 1a bne 2022284 <msdos_format+0x254> <== NOT EXECUTED
2022a20: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
ret_val = msdos_format_fill_sectors
2022a24: d6 07 bf 5c ld [ %fp + -164 ], %o3 <== NOT EXECUTED
2022a28: d8 07 bf 58 ld [ %fp + -168 ], %o4 <== NOT EXECUTED
2022a2c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2022a30: 94 10 20 00 clr %o2 <== NOT EXECUTED
2022a34: 7f ff fd 0f call 2021e70 <msdos_format_fill_sectors> <== NOT EXECUTED
2022a38: 9a 10 3f e5 mov -27, %o5 <== NOT EXECUTED
2022a3c: 10 bf fd 9e b 20220b4 <msdos_format+0x84> <== NOT EXECUTED
2022a40: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
}
else { /* FAT32 */
fat_capacity = fatdata_cluster_cnt * 4;
}
sectors_per_fat = ((fat_capacity
2022a44: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2022a48: 91 2a 20 01 sll %o0, 1, %o0 <== NOT EXECUTED
2022a4c: 90 02 00 16 add %o0, %l6, %o0 <== NOT EXECUTED
2022a50: 91 32 20 01 srl %o0, 1, %o0 <== NOT EXECUTED
2022a54: 40 00 ff cc call 2062984 <.udiv> <== NOT EXECUTED
2022a58: 90 06 c0 08 add %i3, %o0, %o0 <== NOT EXECUTED
+ (sectors_per_cluster - 1))
/ sectors_per_cluster));
/*
* data cluster count too big? then make sectors bigger
*/
if (((fattype == FAT_FAT12) && (data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
2022a5c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2022a60: 7f ff 80 4b call 2002b8c <.umul> <== NOT EXECUTED
2022a64: d0 27 bd 48 st %o0, [ %fp + -696 ] <== NOT EXECUTED
2022a68: 82 05 7f ff add %l5, -1, %g1 <== NOT EXECUTED
2022a6c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2022a70: 40 00 ff c5 call 2062984 <.udiv> <== NOT EXECUTED
2022a74: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
2022a78: 90 25 80 08 sub %l6, %o0, %o0 <== NOT EXECUTED
2022a7c: 80 a2 2f f5 cmp %o0, 0xff5 <== NOT EXECUTED
2022a80: 18 80 00 03 bgu 2022a8c <msdos_format+0xa5c> <== NOT EXECUTED
2022a84: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2022a88: 82 10 20 00 clr %g1 <== NOT EXECUTED
2022a8c: 80 88 60 ff btst 0xff, %g1 <== NOT EXECUTED
2022a90: 02 bf ff 70 be 2022850 <msdos_format+0x820> <== NOT EXECUTED
2022a94: ac 10 20 00 clr %l6 <== NOT EXECUTED
((fattype == FAT_FAT16) && (data_cluster_cnt > FAT_FAT16_MAX_CLN))) {
sectors_per_cluster *= 2;
2022a98: 10 bf ff 99 b 20228fc <msdos_format+0x8cc> <== NOT EXECUTED
2022a9c: ab 2d 60 01 sll %l5, 1, %l5 <== NOT EXECUTED
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
}
*to = '\0';
2022aa0: c0 28 40 00 clrb [ %g1 ] <== NOT EXECUTED
2022aa4: 82 00 60 01 inc %g1 <== NOT EXECUTED
if ((rqdata != NULL) &&
(rqdata->VolLabel != NULL)) {
from = rqdata->VolLabel;
fmt_params->VolLabel_present = true;
}
for (cnt = 0;
2022aa8: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2022aac: 02 80 00 0f be 2022ae8 <msdos_format+0xab8> <== NOT EXECUTED
2022ab0: 86 00 e0 01 inc %g3 <== NOT EXECUTED
cnt < (sizeof(fmt_params->VolLabel)-1);
cnt++) {
if (isprint((unsigned char)*from)) {
2022ab4: c4 08 c0 00 ldub [ %g3 ], %g2 <== NOT EXECUTED
2022ab8: 9a 08 a0 ff and %g2, 0xff, %o5 <== NOT EXECUTED
2022abc: 9a 01 00 0d add %g4, %o5, %o5 <== NOT EXECUTED
2022ac0: da 4b 60 01 ldsb [ %o5 + 1 ], %o5 <== NOT EXECUTED
2022ac4: 80 8b 60 97 btst 0x97, %o5 <== NOT EXECUTED
2022ac8: 32 bf ff f6 bne,a 2022aa0 <msdos_format+0xa70> <== NOT EXECUTED
2022acc: c4 28 7f ff stb %g2, [ %g1 + -1 ] <== NOT EXECUTED
/*
* non-printable character in given name, so keep stuck
* at that character and replace all following characters
* with a ' '
*/
*to++=' ';
2022ad0: d8 28 7f ff stb %o4, [ %g1 + -1 ] <== NOT EXECUTED
}
*to = '\0';
2022ad4: c0 28 40 00 clrb [ %g1 ] <== NOT EXECUTED
2022ad8: 82 00 60 01 inc %g1 <== NOT EXECUTED
if ((rqdata != NULL) &&
(rqdata->VolLabel != NULL)) {
from = rqdata->VolLabel;
fmt_params->VolLabel_present = true;
}
for (cnt = 0;
2022adc: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2022ae0: 32 bf ff f6 bne,a 2022ab8 <msdos_format+0xa88> <== NOT EXECUTED
2022ae4: c4 08 c0 00 ldub [ %g3 ], %g2 <== NOT EXECUTED
{
int ret_val = 0;
int rc;
struct timeval time_value;
rc = rtems_clock_get_tod_timeval(&time_value);
2022ae8: 7f ff a8 e1 call 200ce6c <rtems_clock_get_tod_timeval> <== NOT EXECUTED
2022aec: 90 07 bf f0 add %fp, -16, %o0 <== NOT EXECUTED
if (rc == RTEMS_SUCCESSFUL) {
2022af0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2022af4: 12 80 00 88 bne 2022d14 <msdos_format+0xce4> <== NOT EXECUTED
2022af8: 01 00 00 00 nop <== NOT EXECUTED
*volid_ptr = time_value.tv_sec + time_value.tv_sec;
2022afc: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
2022b00: 83 28 60 01 sll %g1, 1, %g1 <== NOT EXECUTED
2022b04: c2 27 bf a4 st %g1, [ %fp + -92 ] <== NOT EXECUTED
int ret_val = 0;
int rc;
struct timeval time_value;
rc = rtems_clock_get_tod_timeval(&time_value);
if (rc == RTEMS_SUCCESSFUL) {
2022b08: 80 a0 00 19 cmp %g0, %i1 <== NOT EXECUTED
2022b0c: b0 10 20 00 clr %i0 <== NOT EXECUTED
2022b10: 10 bf ff be b 2022a08 <msdos_format+0x9d8> <== NOT EXECUTED
2022b14: 82 40 20 00 addx %g0, 0, %g1 <== NOT EXECUTED
}
else {
/*
* for FAT32: root directory is in cluster 2
*/
fmt_params->root_dir_start_sec =
2022b18: 7f ff 80 1d call 2002b8c <.umul> <== NOT EXECUTED
2022b1c: 90 0e 20 ff and %i0, 0xff, %o0 <== NOT EXECUTED
fmt_params->rsvd_sector_cnt
+ (fmt_params-> fat_num*fmt_params->sectors_per_fat);
fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
2022b20: c2 07 bf 64 ld [ %fp + -156 ], %g1 <== NOT EXECUTED
}
else {
/*
* for FAT32: root directory is in cluster 2
*/
fmt_params->root_dir_start_sec =
2022b24: 90 02 00 13 add %o0, %l3, %o0 <== NOT EXECUTED
fmt_params->rsvd_sector_cnt
+ (fmt_params-> fat_num*fmt_params->sectors_per_fat);
fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
2022b28: c2 27 bf 7c st %g1, [ %fp + -132 ] <== NOT EXECUTED
}
else {
/*
* for FAT32: root directory is in cluster 2
*/
fmt_params->root_dir_start_sec =
2022b2c: 10 bf ff 60 b 20228ac <msdos_format+0x87c> <== NOT EXECUTED
2022b30: d0 27 bf 78 st %o0, [ %fp + -136 ] <== NOT EXECUTED
2022b34: e6 07 bf 60 ld [ %fp + -160 ], %l3 <== NOT EXECUTED
2022b38: 10 bf ff 54 b 2022888 <msdos_format+0x858> <== NOT EXECUTED
2022b3c: f0 0f bf 88 ldub [ %fp + -120 ], %i0 <== NOT EXECUTED
fatdata_cluster_cnt = fatdata_sec_cnt/sectors_per_cluster;
if (fattype == FAT_FAT12) {
fat_capacity = fatdata_cluster_cnt * 3 / 2;
}
else if (fattype == FAT_FAT16) {
fat_capacity = fatdata_cluster_cnt * 2;
2022b40: 10 bf ff 34 b 2022810 <msdos_format+0x7e0> <== NOT EXECUTED
2022b44: 91 2d a0 01 sll %l6, 1, %o0 <== NOT EXECUTED
ret_val = EINVAL;
}
}
if (ret_val == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022b48: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
* determine number of FATs
*/
if (ret_val == 0) {
if ((rqdata == NULL) ||
(rqdata->fat_num == 0)) {
fmt_params->fat_num = 2;
2022b4c: c2 2f bf 88 stb %g1, [ %fp + -120 ] <== NOT EXECUTED
ret_val = EINVAL;
}
}
if (ret_val == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022b50: 94 12 a3 98 or %o2, 0x398, %o2 <== NOT EXECUTED
2022b54: 90 10 20 00 clr %o0 <== NOT EXECUTED
2022b58: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2022b5c: 7f ff fc 95 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022b60: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
/*
* limiting values for disk size, fat type, sectors per cluster
* NOTE: maximum sect_per_clust is arbitrarily choosen with values that
* are a compromise concerning capacity and efficency
*/
if (fmt_params->totl_sector_cnt
2022b64: 10 bf fd b8 b 2022244 <msdos_format+0x214> <== NOT EXECUTED
2022b68: c2 07 bf 5c ld [ %fp + -164 ], %g1 <== NOT EXECUTED
{
uint32_t total_sectors_num16 = 0;
uint32_t total_sectors_num32 = 0;
/* store total sector count in either 16 or 32 bit field in mbr */
if (fmt_params->totl_sector_cnt < 0x10000) {
2022b6c: b0 10 20 00 clr %i0 <== NOT EXECUTED
2022b70: aa 10 20 00 clr %l5 <== NOT EXECUTED
2022b74: a8 10 20 00 clr %l4 <== NOT EXECUTED
2022b78: 10 bf fd e8 b 2022318 <msdos_format+0x2e8> <== NOT EXECUTED
2022b7c: a6 10 20 00 clr %l3 <== NOT EXECUTED
(rqdata->files_per_root_dir > 0)) {
fmt_params->files_per_root_dir = rqdata->files_per_root_dir;
}
else {
if (fmt_params->fattype == FAT_FAT16) {
fmt_params->files_per_root_dir = 512;
2022b80: 82 1f 60 02 xor %i5, 2, %g1 <== NOT EXECUTED
2022b84: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2022b88: a6 40 20 00 addx %g0, 0, %l3 <== NOT EXECUTED
2022b8c: a6 20 00 13 neg %l3 <== NOT EXECUTED
2022b90: a6 0c fe 40 and %l3, -448, %l3 <== NOT EXECUTED
2022b94: 10 bf fe f4 b 2022764 <msdos_format+0x734> <== NOT EXECUTED
2022b98: a6 04 e1 ff add %l3, 0x1ff, %l3 <== NOT EXECUTED
fmt_params->fattype = FAT_FAT32;
}
else if ((rqdata != NULL) &&
(rqdata->fattype != MSDOS_FMT_FATANY)) {
ret_val = -1;
errno = EINVAL;
2022b9c: 40 00 9e 39 call 204a480 <__errno> <== NOT EXECUTED
2022ba0: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
2022ba4: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2022ba8: 10 bf fe c1 b 20226ac <msdos_format+0x67c> <== NOT EXECUTED
2022bac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
\*=========================================================================*/
{
/*
* clear fsinfo sector data
*/
memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);
2022bb0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2022bb4: 40 00 ac 12 call 204dbfc <memset> <== NOT EXECUTED
2022bb8: 94 10 22 00 mov 0x200, %o2 <== NOT EXECUTED
FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
/*
* write "empty" values for free cluster count and next cluster number
*/
FAT_SET_FSINFO_FREE_CLUSTER_COUNT(fsinfo+FAT_FSI_INFO,
2022bbc: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
}
/*
* write fsinfo sector
*/
if ((ret_val == 0) &&
(fmt_params.fsinfo_sec != 0)) {
2022bc0: d2 07 bf 84 ld [ %fp + -124 ], %o1 <== NOT EXECUTED
/*
* write "empty" values for free cluster count and next cluster number
*/
FAT_SET_FSINFO_FREE_CLUSTER_COUNT(fsinfo+FAT_FSI_INFO,
0xffffffff);
FAT_SET_FSINFO_NEXT_FREE_CLUSTER (fsinfo+FAT_FSI_INFO,
2022bc4: c2 2c 21 ef stb %g1, [ %l0 + 0x1ef ] <== NOT EXECUTED
FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
/*
* write "empty" values for free cluster count and next cluster number
*/
FAT_SET_FSINFO_FREE_CLUSTER_COUNT(fsinfo+FAT_FSI_INFO,
2022bc8: c2 2c 21 e8 stb %g1, [ %l0 + 0x1e8 ] <== NOT EXECUTED
2022bcc: c2 2c 21 e9 stb %g1, [ %l0 + 0x1e9 ] <== NOT EXECUTED
2022bd0: c2 2c 21 ea stb %g1, [ %l0 + 0x1ea ] <== NOT EXECUTED
2022bd4: c2 2c 21 eb stb %g1, [ %l0 + 0x1eb ] <== NOT EXECUTED
0xffffffff);
FAT_SET_FSINFO_NEXT_FREE_CLUSTER (fsinfo+FAT_FSI_INFO,
2022bd8: c2 2c 21 ec stb %g1, [ %l0 + 0x1ec ] <== NOT EXECUTED
2022bdc: c2 2c 21 ed stb %g1, [ %l0 + 0x1ed ] <== NOT EXECUTED
2022be0: c2 2c 21 ee stb %g1, [ %l0 + 0x1ee ] <== NOT EXECUTED
*/
memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);
/*
* write LEADSIG, STRUCTSIG, TRAILSIG
*/
FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
2022be4: 82 10 20 52 mov 0x52, %g1 <== NOT EXECUTED
2022be8: c2 2c 20 01 stb %g1, [ %l0 + 1 ] <== NOT EXECUTED
2022bec: c2 2c 00 00 stb %g1, [ %l0 ] <== NOT EXECUTED
2022bf0: 82 10 20 61 mov 0x61, %g1 <== NOT EXECUTED
FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
2022bf4: c2 2c 21 e7 stb %g1, [ %l0 + 0x1e7 ] <== NOT EXECUTED
*/
memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);
/*
* write LEADSIG, STRUCTSIG, TRAILSIG
*/
FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
2022bf8: c2 2c 20 02 stb %g1, [ %l0 + 2 ] <== NOT EXECUTED
2022bfc: 82 10 20 41 mov 0x41, %g1 <== NOT EXECUTED
FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
2022c00: c2 2c 21 e6 stb %g1, [ %l0 + 0x1e6 ] <== NOT EXECUTED
*/
memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);
/*
* write LEADSIG, STRUCTSIG, TRAILSIG
*/
FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
2022c04: c2 2c 20 03 stb %g1, [ %l0 + 3 ] <== NOT EXECUTED
FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
2022c08: 82 10 20 72 mov 0x72, %g1 <== NOT EXECUTED
2022c0c: c2 2c 21 e5 stb %g1, [ %l0 + 0x1e5 ] <== NOT EXECUTED
2022c10: c2 2c 21 e4 stb %g1, [ %l0 + 0x1e4 ] <== NOT EXECUTED
FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
2022c14: 82 10 20 55 mov 0x55, %g1 <== NOT EXECUTED
2022c18: c2 2c 21 fe stb %g1, [ %l0 + 0x1fe ] <== NOT EXECUTED
2022c1c: 82 10 3f aa mov -86, %g1 <== NOT EXECUTED
ret_val = msdos_format_gen_fsinfo(tmp_sec);
}
/*
* write fsinfo sector
*/
if ((ret_val == 0) &&
2022c20: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
2022c24: 02 bf fe 2b be 20224d0 <msdos_format+0x4a0> <== NOT EXECUTED
2022c28: c2 2c 21 ff stb %g1, [ %l0 + 0x1ff ] <== NOT EXECUTED
(fmt_params.fsinfo_sec != 0)) {
ret_val = msdos_format_write_sec(fd,
2022c2c: d4 07 bf 58 ld [ %fp + -168 ], %o2 <== NOT EXECUTED
2022c30: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2022c34: 7f ff fc 74 call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
2022c38: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
}
/*
* write FAT as all empty
* -> write all FAT sectors as zero
*/
if (ret_val == 0) {
2022c3c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022c40: 12 bf fd 21 bne 20220c4 <msdos_format+0x94> <== NOT EXECUTED
2022c44: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
ret_val = msdos_format_fill_sectors
2022c48: 10 bf fe 23 b 20224d4 <msdos_format+0x4a4> <== NOT EXECUTED
2022c4c: d2 07 bf 68 ld [ %fp + -152 ], %o1 <== NOT EXECUTED
if ((ret_val == 0) &&
(fmt_params.mbr_copy_sec != 0)) {
/*
* write copy of MBR
*/
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2022c50: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2022c54: 15 00 81 a6 sethi %hi(0x2069800), %o2 <== NOT EXECUTED
2022c58: 7f ff fc 56 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022c5c: 94 12 a0 30 or %o2, 0x30, %o2 ! 2069830 <rtems_rtc_shell_usage+0xed0><== NOT EXECUTED
"write back up MRB sector\n");
ret_val = msdos_format_write_sec(fd,
2022c60: d2 07 bf 80 ld [ %fp + -128 ], %o1 <== NOT EXECUTED
2022c64: d4 07 bf 58 ld [ %fp + -168 ], %o2 <== NOT EXECUTED
2022c68: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2022c6c: 7f ff fc 66 call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
2022c70: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
}
}
/*
* for FAT32: initialize info sector on disk
*/
if ((ret_val == 0) &&
2022c74: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022c78: 02 bf fe 13 be 20224c4 <msdos_format+0x494> <== NOT EXECUTED
2022c7c: c2 07 bf 84 ld [ %fp + -124 ], %g1 <== NOT EXECUTED
/*
* cleanup:
* sync and unlock disk
* free any data structures (not needed now)
*/
if (fd != -1) {
2022c80: 10 bf fd 11 b 20220c4 <msdos_format+0x94> <== NOT EXECUTED
2022c84: 80 a4 7f ff cmp %l1, -1 <== NOT EXECUTED
memset(tmp_sec,0,sizeof(tmp_sec));
switch(fmt_params.fattype) {
case FAT_FAT12:
/* LSBits of FAT entry 0: media_type */
FAT_SET_VAL8(tmp_sec,0,(fmt_params.media_code));
2022c88: c2 2c 00 00 stb %g1, [ %l0 ] <== NOT EXECUTED
/* MSBits of FAT entry 0:0xf, LSBits of FAT entry 1: LSB of EOC */
FAT_SET_VAL8(tmp_sec,1,(0x0f | (FAT_FAT12_EOC << 4)));
2022c8c: 82 10 3f 8f mov -113, %g1 <== NOT EXECUTED
2022c90: c2 2c 20 01 stb %g1, [ %l0 + 1 ] <== NOT EXECUTED
/* MSBits of FAT entry 1: MSBits of EOC */
FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));
2022c94: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
2022c98: c2 2c 20 02 stb %g1, [ %l0 + 2 ] <== NOT EXECUTED
+ (sectors_per_cluster - 1))
/ sectors_per_cluster));
/*
* data cluster count too big? then make sectors bigger
*/
if (((fattype == FAT_FAT12) && (data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
2022c9c: c2 0f bf 88 ldub [ %fp + -120 ], %g1 <== NOT EXECUTED
2022ca0: 82 20 00 01 neg %g1 <== NOT EXECUTED
2022ca4: 10 bf fe 5d b 2022618 <msdos_format+0x5e8> <== NOT EXECUTED
2022ca8: 83 30 60 1f srl %g1, 0x1f, %g1 <== NOT EXECUTED
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
break;
case FAT_FAT32:
/* FAT entry 0: 0xffffff00|media_type */
FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);
2022cac: c4 0f bf 89 ldub [ %fp + -119 ], %g2 <== NOT EXECUTED
2022cb0: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
2022cb4: c2 2c 20 06 stb %g1, [ %l0 + 6 ] <== NOT EXECUTED
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
break;
case FAT_FAT32:
/* FAT entry 0: 0xffffff00|media_type */
FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);
2022cb8: c2 2c 20 02 stb %g1, [ %l0 + 2 ] <== NOT EXECUTED
2022cbc: c2 2c 20 03 stb %g1, [ %l0 + 3 ] <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
2022cc0: c2 2c 20 05 stb %g1, [ %l0 + 5 ] <== NOT EXECUTED
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
break;
case FAT_FAT32:
/* FAT entry 0: 0xffffff00|media_type */
FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);
2022cc4: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
2022cc8: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
2022ccc: 84 10 bf 00 or %g2, -256, %g2 <== NOT EXECUTED
2022cd0: c4 2c 00 00 stb %g2, [ %l0 ] <== NOT EXECUTED
2022cd4: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
2022cd8: 82 10 3f f8 mov -8, %g1 <== NOT EXECUTED
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
break;
case FAT_FAT32:
/* FAT entry 0: 0xffffff00|media_type */
FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);
2022cdc: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
2022ce0: c2 2c 20 04 stb %g1, [ %l0 + 4 ] <== NOT EXECUTED
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
break;
case FAT_FAT32:
/* FAT entry 0: 0xffffff00|media_type */
FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);
2022ce4: c4 2c 20 01 stb %g2, [ %l0 + 1 ] <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);
2022ce8: 82 10 20 0f mov 0xf, %g1 <== NOT EXECUTED
2022cec: 10 bf fe 3e b 20225e4 <msdos_format+0x5b4> <== NOT EXECUTED
2022cf0: c2 2c 20 07 stb %g1, [ %l0 + 7 ] <== NOT EXECUTED
FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));
break;
case FAT_FAT16:
/* FAT entry 0: 0xff00|media_type */
FAT_SET_VAL16(tmp_sec,0,0xff00|fmt_params.media_code);
2022cf4: c4 0f bf 89 ldub [ %fp + -119 ], %g2 <== NOT EXECUTED
2022cf8: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
2022cfc: c4 2c 00 00 stb %g2, [ %l0 ] <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
2022d00: c2 2c 20 03 stb %g1, [ %l0 + 3 ] <== NOT EXECUTED
FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));
break;
case FAT_FAT16:
/* FAT entry 0: 0xff00|media_type */
FAT_SET_VAL16(tmp_sec,0,0xff00|fmt_params.media_code);
2022d04: c2 2c 20 01 stb %g1, [ %l0 + 1 ] <== NOT EXECUTED
/* FAT entry 1: EOC */
FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);
2022d08: 82 10 3f f8 mov -8, %g1 <== NOT EXECUTED
break;
2022d0c: 10 bf ff e4 b 2022c9c <msdos_format+0xc6c> <== NOT EXECUTED
2022d10: c2 2c 20 02 stb %g1, [ %l0 + 2 ] <== NOT EXECUTED
rc = rtems_clock_get_tod_timeval(&time_value);
if (rc == RTEMS_SUCCESSFUL) {
*volid_ptr = time_value.tv_sec + time_value.tv_sec;
}
else {
*volid_ptr = rand();
2022d14: 40 00 b2 e9 call 204f8b8 <rand> <== NOT EXECUTED
2022d18: 01 00 00 00 nop <== NOT EXECUTED
2022d1c: 10 bf ff 7b b 2022b08 <msdos_format+0xad8> <== NOT EXECUTED
2022d20: d0 27 bf a4 st %o0, [ %fp + -92 ] <== NOT EXECUTED
< ((uint32_t)FAT_FAT12_MAX_CLN)*8) {
fmt_params->fattype = FAT_FAT12;
/* start trying with small clusters */
fmt_params->sectors_per_cluster = 2;
}
else if (fmt_params->totl_sector_cnt
2022d24: 84 10 a2 9f or %g2, 0x29f, %g2 <== NOT EXECUTED
2022d28: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2022d2c: 18 80 00 59 bgu 2022e90 <msdos_format+0xe60> <== NOT EXECUTED
2022d30: 07 10 00 00 sethi %hi(0x40000000), %g3 <== NOT EXECUTED
< ((uint32_t)FAT_FAT16_MAX_CLN)*32) {
fmt_params->fattype = FAT_FAT16;
2022d34: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
2022d38: c2 2f bf 8a stb %g1, [ %fp + -118 ] <== NOT EXECUTED
/* start trying with small clusters */
fmt_params->sectors_per_cluster = 2;
2022d3c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
2022d40: 10 bf fd 4a b 2022268 <msdos_format+0x238> <== NOT EXECUTED
2022d44: c2 27 bf 64 st %g1, [ %fp + -156 ] <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022d48: c6 07 bf 68 ld [ %fp + -152 ], %g3 <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
2022d4c: c8 07 bf 80 ld [ %fp + -128 ], %g4 <== NOT EXECUTED
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
2022d50: c4 2c 20 2c stb %g2, [ %l0 + 0x2c ] <== NOT EXECUTED
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
2022d54: c2 2c 20 30 stb %g1, [ %l0 + 0x30 ] <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022d58: c6 2c 20 24 stb %g3, [ %l0 + 0x24 ] <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
2022d5c: c8 2c 20 32 stb %g4, [ %l0 + 0x32 ] <== NOT EXECUTED
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
FAT_SET_BR_EXT_FLAGS(mbr , 0);
2022d60: c0 2c 20 28 clrb [ %l0 + 0x28 ] <== NOT EXECUTED
2022d64: c0 2c 20 29 clrb [ %l0 + 0x29 ] <== NOT EXECUTED
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
2022d68: c0 2c 20 2a clrb [ %l0 + 0x2a ] <== NOT EXECUTED
2022d6c: c0 2c 20 2b clrb [ %l0 + 0x2b ] <== NOT EXECUTED
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
2022d70: c0 2c 20 2d clrb [ %l0 + 0x2d ] <== NOT EXECUTED
2022d74: c0 2c 20 2e clrb [ %l0 + 0x2e ] <== NOT EXECUTED
2022d78: c0 2c 20 2f clrb [ %l0 + 0x2f ] <== NOT EXECUTED
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
2022d7c: c0 2c 20 31 clrb [ %l0 + 0x31 ] <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022d80: 83 30 e0 18 srl %g3, 0x18, %g1 <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
2022d84: 89 31 20 08 srl %g4, 8, %g4 <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022d88: c2 2c 20 27 stb %g1, [ %l0 + 0x27 ] <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
2022d8c: c8 2c 20 33 stb %g4, [ %l0 + 0x33 ] <== NOT EXECUTED
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
2022d90: c0 27 bd 8c clr [ %fp + -628 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
2022d94: c0 2c 20 40 clrb [ %l0 + 0x40 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
2022d98: c0 2c 20 41 clrb [ %l0 + 0x41 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
2022d9c: c0 2c 20 43 clrb [ %l0 + 0x43 ] <== NOT EXECUTED
2022da0: c0 2c 20 44 clrb [ %l0 + 0x44 ] <== NOT EXECUTED
2022da4: c0 2c 20 45 clrb [ %l0 + 0x45 ] <== NOT EXECUTED
2022da8: c0 2c 20 46 clrb [ %l0 + 0x46 ] <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
2022dac: 84 07 bd 8c add %fp, -628, %g2 <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
2022db0: 82 07 bd 9f add %fp, -609, %g1 <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
2022db4: c0 20 a0 08 clr [ %g2 + 8 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
2022db8: c0 28 60 01 clrb [ %g1 + 1 ] <== NOT EXECUTED
2022dbc: c0 28 60 02 clrb [ %g1 + 2 ] <== NOT EXECUTED
2022dc0: c0 28 60 03 clrb [ %g1 + 3 ] <== NOT EXECUTED
2022dc4: c0 28 60 04 clrb [ %g1 + 4 ] <== NOT EXECUTED
FAT_SET_BR_EXT_FLAGS(mbr , 0);
FAT_SET_BR_FSVER(mbr , 0); /* FAT32 Version:0.0 */
FAT_SET_BR_FAT32_ROOT_CLUSTER(mbr , 2); /* put root dir to cluster 2 */
FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo to rsrvd sec 1*/
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
2022dc8: c0 20 a0 04 clr [ %g2 + 4 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
2022dcc: c0 2f bd 9f clrb [ %fp + -609 ] <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022dd0: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
2022dd4: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
2022dd8: 84 08 c0 02 and %g3, %g2, %g2 <== NOT EXECUTED
2022ddc: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
2022de0: c4 2c 20 25 stb %g2, [ %l0 + 0x25 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
2022de4: 84 10 20 29 mov 0x29, %g2 <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022de8: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
2022dec: c4 2c 20 42 stb %g2, [ %l0 + 0x42 ] <== NOT EXECUTED
? "FAT12 "
: "FAT16 ",
FAT_BR_FILSYSTYPE_SIZE);
}
else {
FAT_SET_BR_SECTORS_PER_FAT32(mbr ,fmt_params->sectors_per_fat);
2022df0: c6 2c 20 26 stb %g3, [ %l0 + 0x26 ] <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
memcpy(FAT_GET_ADDR_BR_FAT32_FILSYSTYPE(mbr),
2022df4: 05 00 00 11 sethi %hi(0x4400), %g2 <== NOT EXECUTED
2022df8: 84 10 a2 41 or %g2, 0x241, %g2 ! 4641 <PROM_START+0x4641> <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
2022dfc: c0 28 60 05 clrb [ %g1 + 5 ] <== NOT EXECUTED
memcpy(FAT_GET_ADDR_BR_FAT32_FILSYSTYPE(mbr),
2022e00: c4 37 bd aa sth %g2, [ %fp + -598 ] <== NOT EXECUTED
2022e04: 05 00 00 15 sethi %hi(0x5400), %g2 <== NOT EXECUTED
2022e08: 84 10 a0 33 or %g2, 0x33, %g2 ! 5433 <PROM_START+0x5433> <== NOT EXECUTED
FAT_SET_BR_FAT32_DRVNUM(mbr , 0); /* only needed for INT13... */
FAT_SET_BR_FAT32_RSVD1(mbr , 0); /* fill with zero */
FAT_SET_BR_FAT32_BOOTSIG(mbr ,FAT_BR_FAT32_BOOTSIG_VAL);
FAT_SET_BR_FAT32_VOLID(mbr , 0); /* not set */
memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr) ,0,FAT_BR_VOLLAB_SIZE);
2022e0c: c0 28 60 0a clrb [ %g1 + 0xa ] <== NOT EXECUTED
2022e10: c0 28 60 06 clrb [ %g1 + 6 ] <== NOT EXECUTED
2022e14: c0 28 60 07 clrb [ %g1 + 7 ] <== NOT EXECUTED
2022e18: c0 28 60 08 clrb [ %g1 + 8 ] <== NOT EXECUTED
2022e1c: c0 28 60 09 clrb [ %g1 + 9 ] <== NOT EXECUTED
memcpy(FAT_GET_ADDR_BR_FAT32_FILSYSTYPE(mbr),
2022e20: 82 07 bd aa add %fp, -598, %g1 <== NOT EXECUTED
2022e24: c4 30 60 02 sth %g2, [ %g1 + 2 ] <== NOT EXECUTED
2022e28: 05 00 00 0c sethi %hi(0x3000), %g2 <== NOT EXECUTED
2022e2c: 84 10 a2 20 or %g2, 0x220, %g2 ! 3220 <PROM_START+0x3220> <== NOT EXECUTED
2022e30: c4 30 60 04 sth %g2, [ %g1 + 4 ] <== NOT EXECUTED
2022e34: 05 00 00 08 sethi %hi(0x2000), %g2 <== NOT EXECUTED
2022e38: 84 10 a0 20 or %g2, 0x20, %g2 ! 2020 <PROM_START+0x2020> <== NOT EXECUTED
2022e3c: 10 bf fd 87 b 2022458 <msdos_format+0x428> <== NOT EXECUTED
2022e40: c4 30 60 06 sth %g2, [ %g1 + 6 ] <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"sectors per cluster: %d\n", fmt_params->sectors_per_cluster);
if (fmt_params->fattype == FAT_FAT32) {
/* recommended: for FAT32, always set reserved sector count to 32 */
fmt_params->rsvd_sector_cnt = 32;
2022e44: 82 10 20 20 mov 0x20, %g1 <== NOT EXECUTED
2022e48: c2 27 bf 60 st %g1, [ %fp + -160 ] <== NOT EXECUTED
/* for FAT32, always set files per root directory 0 */
fmt_params->files_per_root_dir = 0;
/* location of copy of MBR */
fmt_params->mbr_copy_sec = 6;
2022e4c: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED
if (fmt_params->fattype == FAT_FAT32) {
/* recommended: for FAT32, always set reserved sector count to 32 */
fmt_params->rsvd_sector_cnt = 32;
/* for FAT32, always set files per root directory 0 */
fmt_params->files_per_root_dir = 0;
2022e50: c0 27 bf 70 clr [ %fp + -144 ] <== NOT EXECUTED
/* location of copy of MBR */
fmt_params->mbr_copy_sec = 6;
2022e54: c2 27 bf 80 st %g1, [ %fp + -128 ] <== NOT EXECUTED
/* location of fsinfo sector */
fmt_params->fsinfo_sec = 1;
2022e58: 90 10 20 00 clr %o0 <== NOT EXECUTED
2022e5c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2022e60: ee 07 bf 58 ld [ %fp + -168 ], %l7 <== NOT EXECUTED
2022e64: 10 bf fe 49 b 2022788 <msdos_format+0x758> <== NOT EXECUTED
2022e68: c2 27 bf 84 st %g1, [ %fp + -124 ] <== NOT EXECUTED
/* check that device is registered as block device and lock it */
if (ret_val == 0) {
dd = rtems_disk_obtain(stat_buf.st_rdev);
if (dd == NULL) {
errno = ENOTTY;
2022e6c: 40 00 9d 85 call 204a480 <__errno> <== NOT EXECUTED
2022e70: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2022e74: 82 10 20 19 mov 0x19, %g1 <== NOT EXECUTED
2022e78: 10 bf fc 8e b 20220b0 <msdos_format+0x80> <== NOT EXECUTED
2022e7c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->VolLabel;
int cnt;
from = ""; /* default: make "from" point to empty string */
if ((rqdata != NULL) &&
2022e80: 10 bf fe da b 20229e8 <msdos_format+0x9b8> <== NOT EXECUTED
2022e84: 86 10 e3 d8 or %g3, 0x3d8, %g3 <== NOT EXECUTED
if (ret_val == 0) {
const char *from;
char *to = fmt_params->OEMName;
int cnt;
from = "RTEMS"; /* default: make "from" point to OS Name */
if ((rqdata != NULL) &&
2022e88: 10 bf fe 93 b 20228d4 <msdos_format+0x8a4> <== NOT EXECUTED
2022e8c: 86 10 e3 d0 or %g3, 0x3d0, %g3 <== NOT EXECUTED
/* start trying with small clusters */
fmt_params->sectors_per_cluster = 2;
}
else {
#define ONE_GB (1024L * 1024L * 1024L)
uint32_t gigs = (total_size + ONE_GB) / ONE_GB;
2022e90: aa 85 40 03 addcc %l5, %g3, %l5 <== NOT EXECUTED
2022e94: 83 35 60 1e srl %l5, 0x1e, %g1 <== NOT EXECUTED
2022e98: 84 10 20 00 clr %g2 <== NOT EXECUTED
int b;
fmt_params->fattype = FAT_FAT32;
/* scale with the size of disk... */
for (b = 31; b > 0; b--)
if ((gigs & (1 << b)) != 0)
2022e9c: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
/* start trying with small clusters */
fmt_params->sectors_per_cluster = 2;
}
else {
#define ONE_GB (1024L * 1024L * 1024L)
uint32_t gigs = (total_size + ONE_GB) / ONE_GB;
2022ea0: a8 45 00 02 addx %l4, %g2, %l4 <== NOT EXECUTED
2022ea4: 89 2d 20 02 sll %l4, 2, %g4 <== NOT EXECUTED
2022ea8: 88 11 00 01 or %g4, %g1, %g4 <== NOT EXECUTED
2022eac: 10 80 00 04 b 2022ebc <msdos_format+0xe8c> <== NOT EXECUTED
2022eb0: 82 10 20 1f mov 0x1f, %g1 <== NOT EXECUTED
int b;
fmt_params->fattype = FAT_FAT32;
/* scale with the size of disk... */
for (b = 31; b > 0; b--)
2022eb4: 02 80 00 06 be 2022ecc <msdos_format+0xe9c> <== NOT EXECUTED
2022eb8: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
if ((gigs & (1 << b)) != 0)
2022ebc: 85 28 c0 01 sll %g3, %g1, %g2 <== NOT EXECUTED
2022ec0: 80 88 80 04 btst %g2, %g4 <== NOT EXECUTED
2022ec4: 02 bf ff fc be 2022eb4 <msdos_format+0xe84> <== NOT EXECUTED
2022ec8: 82 80 7f ff addcc %g1, -1, %g1 <== NOT EXECUTED
}
else {
#define ONE_GB (1024L * 1024L * 1024L)
uint32_t gigs = (total_size + ONE_GB) / ONE_GB;
int b;
fmt_params->fattype = FAT_FAT32;
2022ecc: 82 10 20 04 mov 4, %g1 <== NOT EXECUTED
/* scale with the size of disk... */
for (b = 31; b > 0; b--)
if ((gigs & (1 << b)) != 0)
break;
fmt_params->sectors_per_cluster = 1 << b;
2022ed0: c4 27 bf 64 st %g2, [ %fp + -156 ] <== NOT EXECUTED
}
else {
#define ONE_GB (1024L * 1024L * 1024L)
uint32_t gigs = (total_size + ONE_GB) / ONE_GB;
int b;
fmt_params->fattype = FAT_FAT32;
2022ed4: 10 bf fc e5 b 2022268 <msdos_format+0x238> <== NOT EXECUTED
2022ed8: c2 2f bf 8a stb %g1, [ %fp + -118 ] <== NOT EXECUTED
* check sectors per cluster.
* must be power of 2
* must be smaller than or equal to 128
* sectors_per_cluster*bytes_per_sector must not be bigger than 32K
*/
for (onebit = 128;onebit >= 1;onebit = onebit>>1) {
2022edc: 10 bf fe 0f b 2022718 <msdos_format+0x6e8> <== NOT EXECUTED
2022ee0: c2 27 bf 64 st %g1, [ %fp + -156 ] <== NOT EXECUTED
else {
fmt_params->media_code = rqdata->media;
}
}
else {
fmt_params->media_code = FAT_BR_MEDIA_FIXED;
2022ee4: 82 10 3f f8 mov -8, %g1 <== NOT EXECUTED
2022ee8: 10 bf fe 68 b 2022888 <msdos_format+0x858> <== NOT EXECUTED
2022eec: c2 2f bf 89 stb %g1, [ %fp + -119 ] <== NOT EXECUTED
{0xF0,0xF8,0xF9,0xFA,0xFB,0xFC,0xFD,0xFE,0xFF};
if (NULL==memchr(valid_media_codes,
rqdata->media,
sizeof(valid_media_codes))) {
ret_val = -1;
errno = EINVAL;
2022ef0: 40 00 9d 64 call 204a480 <__errno> <== NOT EXECUTED
2022ef4: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
2022ef8: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2022efc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2022f00: e6 07 bf 60 ld [ %fp + -160 ], %l3 <== NOT EXECUTED
2022f04: 10 bf fe 61 b 2022888 <msdos_format+0x858> <== NOT EXECUTED
2022f08: f0 0f bf 88 ldub [ %fp + -120 ], %i0 <== NOT EXECUTED
02021e70 <msdos_format_fill_sectors>:
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
2021e70: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* allocate and fill buffer
*/
if (ret_val == 0) {
fill_buffer = malloc(sector_size);
2021e74: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
2021e78: 7f ff 9c 7a call 2009060 <malloc> <== NOT EXECUTED
2021e7c: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
if (fill_buffer == NULL) {
2021e80: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2021e84: 02 80 00 4a be 2021fac <msdos_format_fill_sectors+0x13c> <== NOT EXECUTED
2021e88: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
errno = ENOMEM;
ret_val = -1;
}
else {
memset(fill_buffer,fill_byte,sector_size);
2021e8c: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
2021e90: 40 00 af 5b call 204dbfc <memset> <== NOT EXECUTED
2021e94: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
}
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2021e98: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2021e9c: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2021ea0: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2021ea4: 7f ff ff c3 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021ea8: 94 12 a3 38 or %o2, 0x338, %o2 ! 2069738 <rtems_rtc_shell_usage+0xdd8><== NOT EXECUTED
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021eac: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2021eb0: 02 80 00 59 be 2022014 <msdos_format_fill_sectors+0x1a4> <== NOT EXECUTED
2021eb4: 83 2e e0 04 sll %i3, 4, %g1 <== NOT EXECUTED
2021eb8: a7 2e e0 02 sll %i3, 2, %l3 <== NOT EXECUTED
(sector_cnt > 0)) {
int percent = (sector_cnt * 100) / total_sectors;
if (percent != last_percent) {
if ((percent & 1) == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
2021ebc: 2b 00 81 a5 sethi %hi(0x2069400), %l5 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021ec0: a6 04 c0 01 add %l3, %g1, %l3 <== NOT EXECUTED
(sector_cnt > 0)) {
int percent = (sector_cnt * 100) / total_sectors;
if (percent != last_percent) {
if ((percent & 1) == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
2021ec4: aa 15 63 50 or %l5, 0x350, %l5 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021ec8: 83 2c e0 02 sll %l3, 2, %g1 <== NOT EXECUTED
2021ecc: a8 10 00 1b mov %i3, %l4 <== NOT EXECUTED
2021ed0: a6 04 c0 01 add %l3, %g1, %l3 <== NOT EXECUTED
2021ed4: 10 80 00 11 b 2021f18 <msdos_format_fill_sectors+0xa8> <== NOT EXECUTED
2021ed8: ac 10 3f ff mov -1, %l6 <== NOT EXECUTED
if (percent != last_percent) {
if ((percent & 1) == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
2021edc: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2021ee0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2021ee4: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2021ee8: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2021eec: 7f ff ff c6 call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
2021ef0: a8 05 3f ff add %l4, -1, %l4 <== NOT EXECUTED
start_sector++;
2021ef4: b4 06 a0 01 inc %i2 <== NOT EXECUTED
if (percent != last_percent) {
if ((percent & 1) == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
2021ef8: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021efc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
start_sector++;
sector_cnt--;
2021f00: a6 04 ff 9c add %l3, -100, %l3 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021f04: 12 80 00 1e bne 2021f7c <msdos_format_fill_sectors+0x10c> <== NOT EXECUTED
2021f08: ac 10 00 12 mov %l2, %l6 <== NOT EXECUTED
2021f0c: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
2021f10: 02 80 00 1c be 2021f80 <msdos_format_fill_sectors+0x110> <== NOT EXECUTED
2021f14: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
(sector_cnt > 0)) {
int percent = (sector_cnt * 100) / total_sectors;
2021f18: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2021f1c: 40 01 02 9a call 2062984 <.udiv> <== NOT EXECUTED
2021f20: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (percent != last_percent) {
2021f24: 80 a2 00 16 cmp %o0, %l6 <== NOT EXECUTED
2021f28: 02 bf ff ed be 2021edc <msdos_format_fill_sectors+0x6c> <== NOT EXECUTED
2021f2c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
if ((percent & 1) == 0)
2021f30: 80 8a 20 01 btst 1, %o0 <== NOT EXECUTED
2021f34: 12 bf ff eb bne 2021ee0 <msdos_format_fill_sectors+0x70> <== NOT EXECUTED
2021f38: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
2021f3c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2021f40: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2021f44: 7f ff ff 9b call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021f48: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
2021f4c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2021f50: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2021f54: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2021f58: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2021f5c: 7f ff ff aa call 2021e04 <msdos_format_write_sec> <== NOT EXECUTED
2021f60: a8 05 3f ff add %l4, -1, %l4 <== NOT EXECUTED
start_sector++;
2021f64: b4 06 a0 01 inc %i2 <== NOT EXECUTED
if (percent != last_percent) {
if ((percent & 1) == 0)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
2021f68: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021f6c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
last_percent = percent;
}
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
start_sector++;
sector_cnt--;
2021f70: a6 04 ff 9c add %l3, -100, %l3 <== NOT EXECUTED
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
"Filling : ");
/*
* write to consecutive sectors
*/
while ((ret_val == 0) &&
2021f74: 02 bf ff e6 be 2021f0c <msdos_format_fill_sectors+0x9c> <== NOT EXECUTED
2021f78: ac 10 00 12 mov %l2, %l6 <== NOT EXECUTED
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
start_sector++;
sector_cnt--;
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "\n");
2021f7c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2021f80: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2021f84: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2021f88: 7f ff ff 8a call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021f8c: 94 12 a3 48 or %o2, 0x348, %o2 ! 2069748 <rtems_rtc_shell_usage+0xde8><== NOT EXECUTED
if (ret_val)
2021f90: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2021f94: 12 80 00 16 bne 2021fec <msdos_format_fill_sectors+0x17c> <== NOT EXECUTED
2021f98: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
/*
* cleanup
*/
if (fill_buffer != NULL) {
free(fill_buffer);
2021f9c: 7f ff 9a 50 call 20088dc <free> <== NOT EXECUTED
2021fa0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
fill_buffer = NULL;
}
return ret_val;
}
2021fa4: 81 c7 e0 08 ret <== NOT EXECUTED
2021fa8: 81 e8 00 00 restore <== NOT EXECUTED
* allocate and fill buffer
*/
if (ret_val == 0) {
fill_buffer = malloc(sector_size);
if (fill_buffer == NULL) {
errno = ENOMEM;
2021fac: 40 00 a1 35 call 204a480 <__errno> <== NOT EXECUTED
2021fb0: 01 00 00 00 nop <== NOT EXECUTED
2021fb4: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
else {
memset(fill_buffer,fill_byte,sector_size);
}
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2021fb8: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
* allocate and fill buffer
*/
if (ret_val == 0) {
fill_buffer = malloc(sector_size);
if (fill_buffer == NULL) {
errno = ENOMEM;
2021fbc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
else {
memset(fill_buffer,fill_byte,sector_size);
}
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
2021fc0: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2021fc4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2021fc8: 7f ff ff 7a call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021fcc: 94 12 a3 38 or %o2, 0x338, %o2 <== NOT EXECUTED
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
start_sector++;
sector_cnt--;
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "\n");
2021fd0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2021fd4: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2021fd8: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2021fdc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2021fe0: 7f ff ff 74 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021fe4: 94 12 a3 48 or %o2, 0x348, %o2 <== NOT EXECUTED
if (ret_val)
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_INFO,
2021fe8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2021fec: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
2021ff0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2021ff4: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2021ff8: 7f ff ff 6e call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2021ffc: 94 12 a3 58 or %o2, 0x358, %o2 ! 2069758 <rtems_rtc_shell_usage+0xdf8><== NOT EXECUTED
"filling error on sector: %d\n", start_sector);
/*
* cleanup
*/
if (fill_buffer != NULL) {
2022000: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
2022004: 12 bf ff e6 bne 2021f9c <msdos_format_fill_sectors+0x12c> <== NOT EXECUTED
2022008: 01 00 00 00 nop <== NOT EXECUTED
free(fill_buffer);
fill_buffer = NULL;
}
return ret_val;
}
202200c: 81 c7 e0 08 ret <== NOT EXECUTED
2022010: 81 e8 00 00 restore <== NOT EXECUTED
ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
start_sector++;
sector_cnt--;
}
msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "\n");
2022014: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2022018: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
202201c: 15 00 81 a5 sethi %hi(0x2069400), %o2 <== NOT EXECUTED
2022020: b0 10 20 00 clr %i0 <== NOT EXECUTED
2022024: 7f ff ff 63 call 2021db0 <msdos_format_printf> <== NOT EXECUTED
2022028: 94 12 a3 48 or %o2, 0x348, %o2 <== NOT EXECUTED
202202c: 30 bf ff dc b,a 2021f9c <msdos_format_fill_sectors+0x12c><== NOT EXECUTED
02021db0 <msdos_format_printf>:
*/
static void
msdos_format_printf (const msdos_format_request_param_t *rqdata,
int info_level,
const char *format, ...)
{
2021db0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
va_list args;
va_start (args, format);
2021db4: 94 07 a0 50 add %fp, 0x50, %o2 <== NOT EXECUTED
2021db8: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
2021dbc: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
2021dc0: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
if (rqdata != NULL && rqdata->info_level >= info_level)
2021dc4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2021dc8: 02 80 00 0d be 2021dfc <msdos_format_printf+0x4c> <== NOT EXECUTED
2021dcc: d4 27 bf fc st %o2, [ %fp + -4 ] <== NOT EXECUTED
2021dd0: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
2021dd4: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
2021dd8: 06 80 00 09 bl 2021dfc <msdos_format_printf+0x4c> <== NOT EXECUTED
2021ddc: 21 00 81 c5 sethi %hi(0x2071400), %l0 <== NOT EXECUTED
{
vfprintf (stdout, format, args);
2021de0: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 ! 2071608 <_impure_ptr><== NOT EXECUTED
2021de4: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2021de8: 40 00 de 07 call 2059604 <vfprintf> <== NOT EXECUTED
2021dec: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
fflush (stdout);
2021df0: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 <== NOT EXECUTED
2021df4: 40 00 a2 ad call 204a8a8 <fflush> <== NOT EXECUTED
2021df8: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
2021dfc: 81 c7 e0 08 ret <== NOT EXECUTED
2021e00: 81 e8 00 00 restore <== NOT EXECUTED
02021e04 <msdos_format_write_sec>:
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
2021e04: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int ret_val = 0;
if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {
2021e08: 94 10 20 00 clr %o2 <== NOT EXECUTED
2021e0c: 96 10 00 19 mov %i1, %o3 <== NOT EXECUTED
2021e10: 90 10 20 00 clr %o0 <== NOT EXECUTED
2021e14: 40 01 04 34 call 2062ee4 <__muldi3> <== NOT EXECUTED
2021e18: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2021e1c: 84 10 00 08 mov %o0, %g2 <== NOT EXECUTED
2021e20: 86 10 00 09 mov %o1, %g3 <== NOT EXECUTED
2021e24: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2021e28: 92 10 00 02 mov %g2, %o1 <== NOT EXECUTED
2021e2c: 94 10 00 03 mov %g3, %o2 <== NOT EXECUTED
2021e30: 40 00 2e ea call 202d9d8 <lseek> <== NOT EXECUTED
2021e34: 96 10 20 00 clr %o3 <== NOT EXECUTED
2021e38: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2021e3c: 06 80 00 0b bl 2021e68 <msdos_format_write_sec+0x64> <== NOT EXECUTED
2021e40: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
ret_val = -1;
}
if (ret_val == 0) {
if (0 > write(fd,buffer,sector_size)) {
2021e44: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2021e48: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2021e4c: 7f ff ab 65 call 200cbe0 <write> <== NOT EXECUTED
2021e50: b0 10 20 00 clr %i0 <== NOT EXECUTED
2021e54: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2021e58: 06 80 00 04 bl 2021e68 <msdos_format_write_sec+0x64> <== NOT EXECUTED
2021e5c: 01 00 00 00 nop <== NOT EXECUTED
ret_val = -1;
}
}
return ret_val;
}
2021e60: 81 c7 e0 08 ret <== NOT EXECUTED
2021e64: 81 e8 00 00 restore <== NOT EXECUTED
2021e68: 81 c7 e0 08 ret <== NOT EXECUTED
2021e6c: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0203c920 <msdos_free_node_info>:
* RC_OK on success, or -1 code if error occured
*
*/
int
msdos_free_node_info(rtems_filesystem_location_info_t *pathloc)
{
203c920: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203c924: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c928: 92 10 20 00 clr %o1 <== NOT EXECUTED
int
msdos_free_node_info(rtems_filesystem_location_info_t *pathloc)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
203c92c: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
203c930: 94 10 20 00 clr %o2 <== NOT EXECUTED
203c934: 7f ff 43 41 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
203c938: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
203c93c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c940: 12 80 00 0a bne 203c968 <msdos_free_node_info+0x48> <== NOT EXECUTED
203c944: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
rc = fat_file_close(pathloc->mt_entry, pathloc->node_access);
203c948: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
203c94c: 7f ff b1 a2 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203c950: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
203c954: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
203c958: 7f ff 43 7f call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
203c95c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
203c960: 81 c7 e0 08 ret <== NOT EXECUTED
203c964: 81 e8 00 00 restore <== NOT EXECUTED
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
203c968: 40 00 36 c6 call 204a480 <__errno> <== NOT EXECUTED
203c96c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
203c970: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
203c974: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
203c978: 81 c7 e0 08 ret <== NOT EXECUTED
203c97c: 81 e8 00 00 restore <== NOT EXECUTED
0203de6c <msdos_get_dotdot_dir_info_cluster_num_and_offset>:
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
fat_dir_pos_t *dir_pos,
char *dir_entry
)
{
203de6c: 9d e3 bf 50 save %sp, -176, %sp <== NOT EXECUTED
int rc = RC_OK;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203de70: e4 06 20 34 ld [ %i0 + 0x34 ], %l2 <== NOT EXECUTED
uint32_t cl4find = 0;
/*
* open fat-file corresponded to ".."
*/
rc = fat_file_open(mt_entry, dir_pos, &fat_fd);
203de74: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_filesystem_mount_table_entry_t *mt_entry,
uint32_t cln,
fat_dir_pos_t *dir_pos,
char *dir_entry
)
{
203de78: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc = RC_OK;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
fat_file_fd_t *fat_fd = NULL;
203de7c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
uint32_t cl4find = 0;
/*
* open fat-file corresponded to ".."
*/
rc = fat_file_open(mt_entry, dir_pos, &fat_fd);
203de80: a2 07 bf fc add %fp, -4, %l1 <== NOT EXECUTED
203de84: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203de88: 7f ff ac 85 call 202909c <fat_file_open> <== NOT EXECUTED
203de8c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc != RC_OK)
203de90: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203de94: 12 80 00 a4 bne 203e124 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2b8><== NOT EXECUTED
203de98: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
fat_fd->cln = cln;
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203de9c: 05 00 08 00 sethi %hi(0x200000), %g2 <== NOT EXECUTED
rc = fat_file_open(mt_entry, dir_pos, &fat_fd);
if (rc != RC_OK)
return rc;
fat_fd->cln = cln;
fat_fd->fat_file_type = FAT_DIRECTORY;
203dea0: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
203dea4: f2 20 60 38 st %i1, [ %g1 + 0x38 ] <== NOT EXECUTED
*/
rc = fat_file_open(mt_entry, dir_pos, &fat_fd);
if (rc != RC_OK)
return rc;
fat_fd->cln = cln;
203dea8: f2 20 60 1c st %i1, [ %g1 + 0x1c ] <== NOT EXECUTED
fat_fd->fat_file_type = FAT_DIRECTORY;
203deac: e8 20 60 10 st %l4, [ %g1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
fat_fd->map.file_cln = 0;
203deb0: c0 20 60 34 clr [ %g1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln;
rc = fat_file_size(mt_entry, fat_fd);
203deb4: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
if (rc != RC_OK)
return rc;
fat_fd->cln = cln;
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203deb8: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
rc = fat_file_size(mt_entry, fat_fd);
203debc: 7f ff a9 69 call 2028460 <fat_file_size> <== NOT EXECUTED
203dec0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203dec4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203dec8: 12 80 00 94 bne 203e118 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
203decc: a6 07 bf d8 add %fp, -40, %l3 <== NOT EXECUTED
return rc;
}
/* find "." node in opened directory */
memset(dot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
msdos_long_to_short(".", 1, dot_node, MSDOS_SHORT_NAME_LEN);
203ded0: 31 00 81 b8 sethi %hi(0x206e000), %i0 <== NOT EXECUTED
203ded4: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
203ded8: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
203dedc: 96 10 20 0b mov 0xb, %o3 <== NOT EXECUTED
203dee0: 90 16 23 48 or %i0, 0x348, %o0 <== NOT EXECUTED
fat_file_close(mt_entry, fat_fd);
return rc;
}
/* find "." node in opened directory */
memset(dot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203dee4: c0 27 bf d8 clr [ %fp + -40 ] <== NOT EXECUTED
203dee8: c0 27 bf dc clr [ %fp + -36 ] <== NOT EXECUTED
203deec: c0 24 e0 08 clr [ %l3 + 8 ] <== NOT EXECUTED
203def0: c0 24 e0 0c clr [ %l3 + 0xc ] <== NOT EXECUTED
203def4: c0 24 e0 10 clr [ %l3 + 0x10 ] <== NOT EXECUTED
203def8: c0 24 e0 14 clr [ %l3 + 0x14 ] <== NOT EXECUTED
203defc: c0 24 e0 18 clr [ %l3 + 0x18 ] <== NOT EXECUTED
msdos_long_to_short(".", 1, dot_node, MSDOS_SHORT_NAME_LEN);
203df00: 7f ff ff 4e call 203dc38 <msdos_long_to_short> <== NOT EXECUTED
203df04: c0 24 e0 1c clr [ %l3 + 0x1c ] <== NOT EXECUTED
rc = msdos_find_name_in_fat_file(mt_entry, fat_fd, false, ".", 1,
203df08: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
203df0c: 96 16 23 48 or %i0, 0x348, %o3 <== NOT EXECUTED
203df10: f4 23 a0 5c st %i2, [ %sp + 0x5c ] <== NOT EXECUTED
203df14: e6 23 a0 60 st %l3, [ %sp + 0x60 ] <== NOT EXECUTED
203df18: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203df1c: 94 10 20 00 clr %o2 <== NOT EXECUTED
203df20: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
203df24: 7f ff fb 0f call 203cb60 <msdos_find_name_in_fat_file> <== NOT EXECUTED
203df28: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
MSDOS_NAME_SHORT, dir_pos, dot_node);
if (rc != RC_OK)
203df2c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203df30: 12 80 00 7a bne 203e118 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
203df34: 2b 00 81 b8 sethi %hi(0x206e000), %l5 <== NOT EXECUTED
fat_file_close(mt_entry, fat_fd);
return rc;
}
/* find ".." node in opened directory */
memset(dotdot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203df38: b0 07 bf b8 add %fp, -72, %i0 <== NOT EXECUTED
msdos_long_to_short("..", 2, dotdot_node, MSDOS_SHORT_NAME_LEN);
203df3c: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
fat_file_close(mt_entry, fat_fd);
return rc;
}
/* find ".." node in opened directory */
memset(dotdot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203df40: c0 26 20 08 clr [ %i0 + 8 ] <== NOT EXECUTED
203df44: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED
203df48: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
203df4c: c0 26 20 14 clr [ %i0 + 0x14 ] <== NOT EXECUTED
203df50: c0 26 20 18 clr [ %i0 + 0x18 ] <== NOT EXECUTED
203df54: c0 26 20 1c clr [ %i0 + 0x1c ] <== NOT EXECUTED
msdos_long_to_short("..", 2, dotdot_node, MSDOS_SHORT_NAME_LEN);
203df58: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
203df5c: 96 10 20 0b mov 0xb, %o3 <== NOT EXECUTED
fat_file_close(mt_entry, fat_fd);
return rc;
}
/* find ".." node in opened directory */
memset(dotdot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
203df60: c0 27 bf b8 clr [ %fp + -72 ] <== NOT EXECUTED
203df64: c0 27 bf bc clr [ %fp + -68 ] <== NOT EXECUTED
msdos_long_to_short("..", 2, dotdot_node, MSDOS_SHORT_NAME_LEN);
203df68: 7f ff ff 34 call 203dc38 <msdos_long_to_short> <== NOT EXECUTED
203df6c: 90 15 63 50 or %l5, 0x350, %o0 <== NOT EXECUTED
rc = msdos_find_name_in_fat_file(mt_entry, fat_fd, false, "..", 2,
203df70: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
203df74: f0 23 a0 60 st %i0, [ %sp + 0x60 ] <== NOT EXECUTED
203df78: f4 23 a0 5c st %i2, [ %sp + 0x5c ] <== NOT EXECUTED
203df7c: 96 15 63 50 or %l5, 0x350, %o3 <== NOT EXECUTED
203df80: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203df84: 94 10 20 00 clr %o2 <== NOT EXECUTED
203df88: 98 10 20 02 mov 2, %o4 <== NOT EXECUTED
203df8c: 7f ff fa f5 call 203cb60 <msdos_find_name_in_fat_file> <== NOT EXECUTED
203df90: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
MSDOS_NAME_SHORT, dir_pos,
dotdot_node);
if (rc != RC_OK)
203df94: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203df98: 12 80 00 60 bne 203e118 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
203df9c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
fat_file_close(mt_entry, fat_fd);
return rc;
}
cl4find = MSDOS_EXTRACT_CLUSTER_NUM(dot_node);
203dfa0: ea 14 e0 14 lduh [ %l3 + 0x14 ], %l5 <== NOT EXECUTED
/* close fat-file corresponded to ".." directory */
rc = fat_file_close(mt_entry, fat_fd);
203dfa4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203dfa8: 7f ff ac 0b call 2028fd4 <fat_file_close> <== NOT EXECUTED
203dfac: e6 14 e0 1a lduh [ %l3 + 0x1a ], %l3 <== NOT EXECUTED
if ( rc != RC_OK )
203dfb0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203dfb4: 12 80 00 5c bne 203e124 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2b8><== NOT EXECUTED
203dfb8: c2 17 bf cc lduh [ %fp + -52 ], %g1 <== NOT EXECUTED
return rc;
if ( (MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)
203dfbc: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
203dfc0: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
203dfc4: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
203dfc8: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
203dfcc: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203dfd0: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
203dfd4: 80 90 40 03 orcc %g1, %g3, %g0 <== NOT EXECUTED
203dfd8: 12 80 00 10 bne 203e018 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x1ac><== NOT EXECUTED
203dfdc: c2 17 bf d2 lduh [ %fp + -46 ], %g1 <== NOT EXECUTED
203dfe0: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
203dfe4: 87 30 60 08 srl %g1, 8, %g3 <== NOT EXECUTED
203dfe8: 80 88 c0 02 btst %g3, %g2 <== NOT EXECUTED
203dfec: 12 80 00 0c bne 203e01c <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x1b0><== NOT EXECUTED
203dff0: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
203dff4: 83 30 60 18 srl %g1, 0x18, %g1 <== NOT EXECUTED
203dff8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203dffc: 12 80 00 09 bne 203e020 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x1b4><== NOT EXECUTED
203e000: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203e004: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
/*
* we handle root dir for all FAT types in the same way with the
* ordinary directories ( through fat_file_* calls )
*/
fat_dir_pos_init(dir_pos);
dir_pos->sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
203e008: e8 26 80 00 st %l4, [ %i2 ] <== NOT EXECUTED
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
203e00c: c0 26 a0 04 clr [ %i2 + 4 ] <== NOT EXECUTED
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203e010: c2 26 a0 0c st %g1, [ %i2 + 0xc ] <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203e014: c2 26 a0 08 st %g1, [ %i2 + 8 ] <== NOT EXECUTED
}
/* open fat-file corresponded to second ".." */
rc = fat_file_open(mt_entry, dir_pos, &fat_fd);
203e018: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
203e01c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203e020: 7f ff ac 1f call 202909c <fat_file_open> <== NOT EXECUTED
203e024: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
if (rc != RC_OK)
203e028: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e02c: 12 80 00 3e bne 203e124 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2b8><== NOT EXECUTED
203e030: c6 17 bf cc lduh [ %fp + -52 ], %g3 <== NOT EXECUTED
return rc;
if ((MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)
203e034: c8 17 bf d2 lduh [ %fp + -46 ], %g4 <== NOT EXECUTED
203e038: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203e03c: 83 30 e0 18 srl %g3, 0x18, %g1 <== NOT EXECUTED
203e040: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203e044: 85 30 e0 08 srl %g3, 8, %g2 <== NOT EXECUTED
203e048: 9b 31 20 18 srl %g4, 0x18, %o5 <== NOT EXECUTED
203e04c: 07 00 00 3f sethi %hi(0xfc00), %g3 <== NOT EXECUTED
203e050: 86 10 e3 ff or %g3, 0x3ff, %g3 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
203e054: 84 08 80 03 and %g2, %g3, %g2 <== NOT EXECUTED
203e058: 84 10 80 01 or %g2, %g1, %g2 <== NOT EXECUTED
203e05c: 83 31 20 08 srl %g4, 8, %g1 <== NOT EXECUTED
203e060: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
203e064: 82 08 40 03 and %g1, %g3, %g1 <== NOT EXECUTED
203e068: 82 10 40 0d or %g1, %o5, %g1 <== NOT EXECUTED
203e06c: 84 90 80 01 orcc %g2, %g1, %g2 <== NOT EXECUTED
203e070: 12 80 00 2f bne 203e12c <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2c0><== NOT EXECUTED
203e074: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
fat_fd->cln = fs_info->fat.vol.rdir_cl;
203e078: c4 04 a0 38 ld [ %l2 + 0x38 ], %g2 <== NOT EXECUTED
203e07c: c4 20 60 1c st %g2, [ %g1 + 0x1c ] <== NOT EXECUTED
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
203e080: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 <== NOT EXECUTED
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node);
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
fat_fd->map.file_cln = 0;
203e084: c0 20 60 34 clr [ %g1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln;
203e088: c4 20 60 38 st %g2, [ %g1 + 0x38 ] <== NOT EXECUTED
if ((MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)
fat_fd->cln = fs_info->fat.vol.rdir_cl;
else
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node);
fat_fd->fat_file_type = FAT_DIRECTORY;
203e08c: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
203e090: c4 20 60 10 st %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203e094: 05 00 08 00 sethi %hi(0x200000), %g2 <== NOT EXECUTED
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
rc = fat_file_size(mt_entry, fat_fd);
203e098: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
fat_fd->cln = fs_info->fat.vol.rdir_cl;
else
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node);
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
203e09c: c4 20 60 14 st %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
fat_fd->map.file_cln = 0;
fat_fd->map.disk_cln = fat_fd->cln;
rc = fat_file_size(mt_entry, fat_fd);
203e0a0: 7f ff a8 f0 call 2028460 <fat_file_size> <== NOT EXECUTED
203e0a4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc != RC_OK)
203e0a8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e0ac: 12 80 00 1b bne 203e118 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
203e0b0: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
fat_file_close(mt_entry, fat_fd);
return rc;
}
/* in this directory find slot with specified cluster num */
rc = msdos_find_node_by_cluster_num_in_fat_file(mt_entry, fat_fd, cl4find,
203e0b4: ab 2d 60 10 sll %l5, 0x10, %l5 <== NOT EXECUTED
203e0b8: a7 2c e0 10 sll %l3, 0x10, %l3 <== NOT EXECUTED
203e0bc: 87 35 60 18 srl %l5, 0x18, %g3 <== NOT EXECUTED
203e0c0: 89 34 e0 18 srl %l3, 0x18, %g4 <== NOT EXECUTED
203e0c4: 85 34 e0 08 srl %l3, 8, %g2 <== NOT EXECUTED
203e0c8: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
203e0cc: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
203e0d0: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
203e0d4: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
203e0d8: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
203e0dc: 98 10 00 1b mov %i3, %o4 <== NOT EXECUTED
203e0e0: 95 35 60 08 srl %l5, 8, %o2 <== NOT EXECUTED
203e0e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203e0e8: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
203e0ec: 94 12 80 03 or %o2, %g3, %o2 <== NOT EXECUTED
203e0f0: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
203e0f4: 7f ff fa 38 call 203c9d4 <msdos_find_node_by_cluster_num_in_fat_file><== NOT EXECUTED
203e0f8: 94 12 80 02 or %o2, %g2, %o2 <== NOT EXECUTED
dir_pos, dir_entry);
if (rc != RC_OK)
203e0fc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e100: 12 80 00 06 bne 203e118 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
203e104: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
{
fat_file_close(mt_entry, fat_fd);
return rc;
}
rc = fat_file_close(mt_entry, fat_fd);
203e108: 7f ff ab b3 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203e10c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
}
203e110: 81 c7 e0 08 ret <== NOT EXECUTED
203e114: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
/* in this directory find slot with specified cluster num */
rc = msdos_find_node_by_cluster_num_in_fat_file(mt_entry, fat_fd, cl4find,
dir_pos, dir_entry);
if (rc != RC_OK)
{
fat_file_close(mt_entry, fat_fd);
203e118: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
203e11c: 7f ff ab ae call 2028fd4 <fat_file_close> <== NOT EXECUTED
203e120: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
203e124: 81 c7 e0 08 ret <== NOT EXECUTED
203e128: 81 e8 00 00 restore <== NOT EXECUTED
return rc;
if ((MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)
fat_fd->cln = fs_info->fat.vol.rdir_cl;
else
fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node);
203e12c: 10 bf ff d5 b 203e080 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x214><== NOT EXECUTED
203e130: c4 20 60 1c st %g2, [ %g1 + 0x1c ] <== NOT EXECUTED
0203e134 <msdos_get_name_node>:
int name_len,
msdos_name_type_t name_type,
fat_dir_pos_t *dir_pos,
char *name_dir_entry
)
{
203e134: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
fat_file_fd_t *fat_fd = parent_loc->node_access;
uint32_t dotdot_cln = 0;
/* find name in fat-file which corresponds to the directory */
rc = msdos_find_name_in_fat_file(parent_loc->mt_entry, fat_fd,
203e138: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
203e13c: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
int name_len,
msdos_name_type_t name_type,
fat_dir_pos_t *dir_pos,
char *name_dir_entry
)
{
203e140: e0 07 a0 5c ld [ %fp + 0x5c ], %l0 <== NOT EXECUTED
int rc = RC_OK;
fat_file_fd_t *fat_fd = parent_loc->node_access;
uint32_t dotdot_cln = 0;
/* find name in fat-file which corresponds to the directory */
rc = msdos_find_name_in_fat_file(parent_loc->mt_entry, fat_fd,
203e144: b2 0e 60 ff and %i1, 0xff, %i1 <== NOT EXECUTED
203e148: fa 23 a0 5c st %i5, [ %sp + 0x5c ] <== NOT EXECUTED
203e14c: e0 23 a0 60 st %l0, [ %sp + 0x60 ] <== NOT EXECUTED
203e150: 98 10 00 1b mov %i3, %o4 <== NOT EXECUTED
203e154: 9a 10 00 1c mov %i4, %o5 <== NOT EXECUTED
203e158: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
203e15c: 7f ff fa 81 call 203cb60 <msdos_find_name_in_fat_file> <== NOT EXECUTED
203e160: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
create_node, name, name_len, name_type,
dir_pos, name_dir_entry);
if ((rc != RC_OK) && (rc != MSDOS_NAME_NOT_FOUND_ERR))
203e164: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
203e168: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203e16c: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
203e170: 12 80 00 2b bne 203e21c <msdos_get_name_node+0xe8> <== NOT EXECUTED
203e174: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
return rc;
if (!create_node)
203e178: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
203e17c: 12 80 00 26 bne 203e214 <msdos_get_name_node+0xe0> <== NOT EXECUTED
203e180: 03 00 00 1f sethi %hi(0x7c00), %g1 <== NOT EXECUTED
{
/* if we search for valid name and name not found -> return */
if (rc == MSDOS_NAME_NOT_FOUND_ERR)
203e184: 82 10 61 01 or %g1, 0x101, %g1 ! 7d01 <PROM_START+0x7d01> <== NOT EXECUTED
203e188: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
203e18c: 02 80 00 22 be 203e214 <msdos_get_name_node+0xe0> <== NOT EXECUTED
203e190: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
* if we have deal with ".." - it is a special case :(((
*
* Really, we should return cluster num and offset not of ".." slot, but
* slot which correspondes to real directory name.
*/
if (rc == RC_OK)
203e194: 12 80 00 20 bne 203e214 <msdos_get_name_node+0xe0> <== NOT EXECUTED
203e198: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
{
if (strncmp(name, "..", 2) == 0)
203e19c: 13 00 81 b8 sethi %hi(0x206e000), %o1 <== NOT EXECUTED
203e1a0: 94 10 20 02 mov 2, %o2 <== NOT EXECUTED
203e1a4: 40 00 4c db call 2051510 <strncmp> <== NOT EXECUTED
203e1a8: 92 12 63 50 or %o1, 0x350, %o1 <== NOT EXECUTED
203e1ac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203e1b0: 12 80 00 19 bne 203e214 <msdos_get_name_node+0xe0> <== NOT EXECUTED
203e1b4: 01 00 00 00 nop <== NOT EXECUTED
{
dotdot_cln = MSDOS_EXTRACT_CLUSTER_NUM((name_dir_entry));
203e1b8: c4 14 20 14 lduh [ %l0 + 0x14 ], %g2 <== NOT EXECUTED
203e1bc: c6 14 20 1a lduh [ %l0 + 0x1a ], %g3 <== NOT EXECUTED
203e1c0: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
203e1c4: 83 30 a0 18 srl %g2, 0x18, %g1 <== NOT EXECUTED
203e1c8: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203e1cc: b3 30 a0 08 srl %g2, 8, %i1 <== NOT EXECUTED
203e1d0: 89 30 e0 18 srl %g3, 0x18, %g4 <== NOT EXECUTED
203e1d4: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
203e1d8: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
203e1dc: b2 0e 40 02 and %i1, %g2, %i1 <== NOT EXECUTED
203e1e0: b2 16 40 01 or %i1, %g1, %i1 <== NOT EXECUTED
203e1e4: 83 30 e0 08 srl %g3, 8, %g1 <== NOT EXECUTED
203e1e8: b3 2e 60 10 sll %i1, 0x10, %i1 <== NOT EXECUTED
203e1ec: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
203e1f0: 82 10 40 04 or %g1, %g4, %g1 <== NOT EXECUTED
/* are we right under root dir ? */
if (dotdot_cln == 0)
203e1f4: b2 96 40 01 orcc %i1, %g1, %i1 <== NOT EXECUTED
203e1f8: 12 80 00 0e bne 203e230 <msdos_get_name_node+0xfc> <== NOT EXECUTED
203e1fc: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
203e200: c0 27 60 04 clr [ %i5 + 4 ] <== NOT EXECUTED
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
203e204: c2 27 60 0c st %g1, [ %i5 + 0xc ] <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
203e208: c2 27 60 08 st %g1, [ %i5 + 8 ] <== NOT EXECUTED
/*
* we can relax about first_char field - it never should be
* used for root dir
*/
fat_dir_pos_init(dir_pos);
dir_pos->sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
203e20c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
203e210: c2 27 40 00 st %g1, [ %i5 ] <== NOT EXECUTED
}
}
}
}
return rc;
}
203e214: 81 c7 e0 08 ret <== NOT EXECUTED
203e218: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
/* find name in fat-file which corresponds to the directory */
rc = msdos_find_name_in_fat_file(parent_loc->mt_entry, fat_fd,
create_node, name, name_len, name_type,
dir_pos, name_dir_entry);
if ((rc != RC_OK) && (rc != MSDOS_NAME_NOT_FOUND_ERR))
203e21c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203e220: 02 bf ff d7 be 203e17c <msdos_get_name_node+0x48> <== NOT EXECUTED
203e224: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
}
}
}
}
return rc;
}
203e228: 81 c7 e0 08 ret <== NOT EXECUTED
203e22c: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
dir_pos->sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
}
else
{
rc =
msdos_get_dotdot_dir_info_cluster_num_and_offset(parent_loc->mt_entry,
203e230: f0 06 20 10 ld [ %i0 + 0x10 ], %i0 <== NOT EXECUTED
203e234: b4 10 00 1d mov %i5, %i2 <== NOT EXECUTED
203e238: 7f ff ff 0d call 203de6c <msdos_get_dotdot_dir_info_cluster_num_and_offset><== NOT EXECUTED
203e23c: 97 e8 00 10 restore %g0, %l0, %o3 <== NOT EXECUTED
0203db48 <msdos_get_token>:
msdos_token_types_t
msdos_get_token(const char *path,
int pathlen,
const char **ret_token,
int *ret_token_len)
{
203db48: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
msdos_token_types_t type = MSDOS_NAME;
int i = 0;
*ret_token = NULL;
203db4c: c0 26 80 00 clr [ %i2 ] <== NOT EXECUTED
*ret_token_len = 0;
203db50: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
msdos_token_types_t
msdos_get_token(const char *path,
int pathlen,
const char **ret_token,
int *ret_token_len)
{
203db54: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
int i = 0;
*ret_token = NULL;
*ret_token_len = 0;
if (pathlen == 0)
203db58: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
203db5c: a0 10 20 00 clr %l0 <== NOT EXECUTED
203db60: 12 80 00 0d bne 203db94 <msdos_get_token+0x4c> <== NOT EXECUTED
203db64: b0 10 20 00 clr %i0 <== NOT EXECUTED
203db68: 30 80 00 1d b,a 203dbdc <msdos_get_token+0x94> <== NOT EXECUTED
return MSDOS_NO_MORE_PATH;
/*
* Check for a separator.
*/
while (!msdos_is_separator(path[i]) && (i < pathlen))
203db6c: 16 80 00 10 bge 203dbac <msdos_get_token+0x64> <== NOT EXECUTED
203db70: 82 94 20 00 orcc %l0, 0, %g1 <== NOT EXECUTED
{
if ( !msdos_is_valid_name_char(path[i]) )
203db74: d0 4c 40 10 ldsb [ %l1 + %l0 ], %o0 <== NOT EXECUTED
203db78: 7f ff ff d8 call 203dad8 <msdos_is_valid_name_char> <== NOT EXECUTED
203db7c: a0 04 20 01 inc %l0 <== NOT EXECUTED
203db80: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203db84: 02 80 00 15 be 203dbd8 <msdos_get_token+0x90> <== NOT EXECUTED
203db88: 80 a4 21 04 cmp %l0, 0x104 <== NOT EXECUTED
return MSDOS_INVALID_TOKEN;
++i;
if ( i == MSDOS_NAME_MAX_LFN_WITH_DOT )
203db8c: 02 80 00 11 be 203dbd0 <msdos_get_token+0x88> <== NOT EXECUTED
203db90: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED
return MSDOS_NO_MORE_PATH;
/*
* Check for a separator.
*/
while (!msdos_is_separator(path[i]) && (i < pathlen))
203db94: 7f ff 32 78 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
203db98: d0 4c 40 10 ldsb [ %l1 + %l0 ], %o0 <== NOT EXECUTED
203db9c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203dba0: 02 bf ff f3 be 203db6c <msdos_get_token+0x24> <== NOT EXECUTED
203dba4: 80 a4 00 19 cmp %l0, %i1 <== NOT EXECUTED
*ret_token = path;
/*
* If it is just a separator then it is the current dir.
*/
if ( i == 0 )
203dba8: 82 94 20 00 orcc %l0, 0, %g1 <== NOT EXECUTED
203dbac: 12 80 00 0e bne 203dbe4 <msdos_get_token+0x9c> <== NOT EXECUTED
203dbb0: e2 26 80 00 st %l1, [ %i2 ] <== NOT EXECUTED
{
if ( (*path != '\0') && pathlen )
203dbb4: c4 4c 40 00 ldsb [ %l1 ], %g2 <== NOT EXECUTED
203dbb8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203dbbc: 02 80 00 04 be 203dbcc <msdos_get_token+0x84> <== NOT EXECUTED
203dbc0: b0 10 20 00 clr %i0 <== NOT EXECUTED
203dbc4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
203dbc8: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
}
/*
* Set the token and token_len to the token start and length.
*/
*ret_token_len = i;
203dbcc: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
203dbd0: 81 c7 e0 08 ret <== NOT EXECUTED
203dbd4: 81 e8 00 00 restore <== NOT EXECUTED
{
type = MSDOS_UP_DIR;
return type;
}
if ((i == 1) && ((*ret_token)[0] == '.'))
203dbd8: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED
return type;
}
}
return type;
}
203dbdc: 81 c7 e0 08 ret <== NOT EXECUTED
203dbe0: 81 e8 00 00 restore <== NOT EXECUTED
* If we copied something that was not a seperator see if
* it was a special name.
*/
if ( type == MSDOS_NAME )
{
if ((i == 2) && ((*ret_token)[0] == '.') && ((*ret_token)[1] == '.'))
203dbe4: 80 a4 20 02 cmp %l0, 2 <== NOT EXECUTED
203dbe8: 02 80 00 0b be 203dc14 <msdos_get_token+0xcc> <== NOT EXECUTED
203dbec: e0 26 c0 00 st %l0, [ %i3 ] <== NOT EXECUTED
{
type = MSDOS_UP_DIR;
return type;
}
if ((i == 1) && ((*ret_token)[0] == '.'))
203dbf0: 80 a4 20 01 cmp %l0, 1 <== NOT EXECUTED
203dbf4: 22 80 00 04 be,a 203dc04 <msdos_get_token+0xbc> <== NOT EXECUTED
203dbf8: c2 4c 40 00 ldsb [ %l1 ], %g1 <== NOT EXECUTED
203dbfc: 81 c7 e0 08 ret <== NOT EXECUTED
203dc00: 91 e8 20 03 restore %g0, 3, %o0 <== NOT EXECUTED
203dc04: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
203dc08: 12 bf ff fd bne 203dbfc <msdos_get_token+0xb4> <== NOT EXECUTED
203dc0c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
203dc10: 30 bf ff f3 b,a 203dbdc <msdos_get_token+0x94> <== NOT EXECUTED
* If we copied something that was not a seperator see if
* it was a special name.
*/
if ( type == MSDOS_NAME )
{
if ((i == 2) && ((*ret_token)[0] == '.') && ((*ret_token)[1] == '.'))
203dc14: c2 4c 40 00 ldsb [ %l1 ], %g1 <== NOT EXECUTED
203dc18: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
203dc1c: 12 bf ff f8 bne 203dbfc <msdos_get_token+0xb4> <== NOT EXECUTED
203dc20: 01 00 00 00 nop <== NOT EXECUTED
203dc24: c2 4c 60 01 ldsb [ %l1 + 1 ], %g1 <== NOT EXECUTED
203dc28: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
203dc2c: 12 bf ff f4 bne 203dbfc <msdos_get_token+0xb4> <== NOT EXECUTED
203dc30: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
203dc34: 30 bf ff ea b,a 203dbdc <msdos_get_token+0x94> <== NOT EXECUTED
02022f34 <msdos_initialize_support>:
rtems_filesystem_mount_table_entry_t *temp_mt_entry,
const rtems_filesystem_operations_table *op_table,
const rtems_filesystem_file_handlers_r *file_handlers,
const rtems_filesystem_file_handlers_r *directory_handlers
)
{
2022f34: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
msdos_fs_info_t *fs_info = NULL;
fat_file_fd_t *fat_fd = NULL;
fat_dir_pos_t root_pos;
uint32_t cl_buf_size;
fs_info = (msdos_fs_info_t *)calloc(1, sizeof(msdos_fs_info_t));
2022f38: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = NULL;
fat_file_fd_t *fat_fd = NULL;
2022f3c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
fat_dir_pos_t root_pos;
uint32_t cl_buf_size;
fs_info = (msdos_fs_info_t *)calloc(1, sizeof(msdos_fs_info_t));
2022f40: 92 10 20 a0 mov 0xa0, %o1 <== NOT EXECUTED
2022f44: 7f ff 94 c4 call 2008254 <calloc> <== NOT EXECUTED
2022f48: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
if (!fs_info)
2022f4c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2022f50: 02 80 00 55 be 20230a4 <msdos_initialize_support+0x170> <== NOT EXECUTED
2022f54: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
temp_mt_entry->fs_info = fs_info;
2022f58: d0 24 60 34 st %o0, [ %l1 + 0x34 ] <== NOT EXECUTED
rc = fat_init_volume_info(temp_mt_entry);
2022f5c: 40 00 1b 51 call 2029ca0 <fat_init_volume_info> <== NOT EXECUTED
2022f60: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc != RC_OK)
2022f64: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022f68: 12 80 00 37 bne 2023044 <msdos_initialize_support+0x110> <== NOT EXECUTED
2022f6c: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
{
free(fs_info);
return rc;
}
fs_info->file_handlers = file_handlers;
2022f70: f4 24 20 94 st %i2, [ %l0 + 0x94 ] <== NOT EXECUTED
fs_info->directory_handlers = directory_handlers;
2022f74: f6 24 20 90 st %i3, [ %l0 + 0x90 ] <== NOT EXECUTED
fat_dir_pos_init(
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
2022f78: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;
2022f7c: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
fat_dir_pos_t *dir_pos
)
{
dir_pos->sname.cln = 0;
dir_pos->sname.ofs = 0;
dir_pos->lname.cln = FAT_FILE_SHORT_NAME;
2022f80: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
/*
* open fat-file which correspondes to root directory
* (so inode number 0x00000010 is always used for root directory)
*/
fat_dir_pos_init(&root_pos);
root_pos.sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
2022f84: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
rc = fat_file_open(temp_mt_entry, &root_pos, &fat_fd);
2022f88: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
/*
* open fat-file which correspondes to root directory
* (so inode number 0x00000010 is always used for root directory)
*/
fat_dir_pos_init(&root_pos);
root_pos.sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
2022f8c: e4 27 bf ec st %l2, [ %fp + -20 ] <== NOT EXECUTED
rc = fat_file_open(temp_mt_entry, &root_pos, &fat_fd);
2022f90: 92 07 bf ec add %fp, -20, %o1 <== NOT EXECUTED
2022f94: 40 00 18 42 call 202909c <fat_file_open> <== NOT EXECUTED
2022f98: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (rc != RC_OK)
2022f9c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2022fa0: 12 80 00 2d bne 2023054 <msdos_initialize_support+0x120> <== NOT EXECUTED
2022fa4: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
return rc;
}
/* again: unfortunately "fat-file" is just almost fat file :( */
fat_fd->fat_file_type = FAT_DIRECTORY;
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
2022fa8: 03 00 08 00 sethi %hi(0x200000), %g1 <== NOT EXECUTED
2022fac: c2 22 60 14 st %g1, [ %o1 + 0x14 ] <== NOT EXECUTED
fat_fd->cln = fs_info->fat.vol.rdir_cl;
2022fb0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1 <== NOT EXECUTED
free(fs_info);
return rc;
}
/* again: unfortunately "fat-file" is just almost fat file :( */
fat_fd->fat_file_type = FAT_DIRECTORY;
2022fb4: e4 22 60 10 st %l2, [ %o1 + 0x10 ] <== NOT EXECUTED
fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;
fat_fd->cln = fs_info->fat.vol.rdir_cl;
2022fb8: c2 22 60 1c st %g1, [ %o1 + 0x1c ] <== NOT EXECUTED
fat_fd->map.file_cln = 0;
2022fbc: c0 22 60 34 clr [ %o1 + 0x34 ] <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln;
/* if we have FAT12/16 */
if ( fat_fd->cln == 0 )
2022fc0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2022fc4: 12 80 00 2a bne 202306c <msdos_initialize_support+0x138> <== NOT EXECUTED
2022fc8: c2 22 60 38 st %g1, [ %o1 + 0x38 ] <== NOT EXECUTED
{
fat_fd->fat_file_size = fs_info->fat.vol.rdir_size;
2022fcc: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
cl_buf_size = (fs_info->fat.vol.bpc > fs_info->fat.vol.rdir_size) ?
2022fd0: d0 14 20 06 lduh [ %l0 + 6 ], %o0 <== NOT EXECUTED
fat_fd->map.disk_cln = fat_fd->cln;
/* if we have FAT12/16 */
if ( fat_fd->cln == 0 )
{
fat_fd->fat_file_size = fs_info->fat.vol.rdir_size;
2022fd4: c2 22 60 18 st %g1, [ %o1 + 0x18 ] <== NOT EXECUTED
cl_buf_size = (fs_info->fat.vol.bpc > fs_info->fat.vol.rdir_size) ?
2022fd8: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
2022fdc: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
2022fe0: 2a 80 00 02 bcs,a 2022fe8 <msdos_initialize_support+0xb4><== NOT EXECUTED
2022fe4: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
return rc;
}
cl_buf_size = fs_info->fat.vol.bpc;
}
fs_info->cl_buf = (uint8_t *)calloc(cl_buf_size, sizeof(char));
2022fe8: 7f ff 94 9b call 2008254 <calloc> <== NOT EXECUTED
2022fec: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
if (fs_info->cl_buf == NULL)
2022ff0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2022ff4: 02 80 00 25 be 2023088 <msdos_initialize_support+0x154> <== NOT EXECUTED
2022ff8: d0 24 20 9c st %o0, [ %l0 + 0x9c ] <== NOT EXECUTED
fat_shutdown_drive(temp_mt_entry);
free(fs_info);
rtems_set_errno_and_return_minus_one(ENOMEM);
}
sc = rtems_semaphore_create(3,
2022ffc: 90 10 20 03 mov 3, %o0 <== NOT EXECUTED
2023000: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2023004: 94 10 20 10 mov 0x10, %o2 <== NOT EXECUTED
2023008: 96 10 20 00 clr %o3 <== NOT EXECUTED
202300c: 7f ff a8 d1 call 200d350 <rtems_semaphore_create> <== NOT EXECUTED
2023010: 98 04 20 98 add %l0, 0x98, %o4 <== NOT EXECUTED
1,
RTEMS_BINARY_SEMAPHORE | RTEMS_FIFO,
0,
&fs_info->vol_sema);
if (sc != RTEMS_SUCCESSFUL)
2023014: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023018: 12 80 00 29 bne 20230bc <msdos_initialize_support+0x188> <== NOT EXECUTED
202301c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
}
temp_mt_entry->mt_fs_root.node_access = fat_fd;
temp_mt_entry->mt_fs_root.handlers = directory_handlers;
temp_mt_entry->mt_fs_root.ops = op_table;
2023020: f2 24 60 28 st %i1, [ %l1 + 0x28 ] <== NOT EXECUTED
free(fs_info->cl_buf);
free(fs_info);
rtems_set_errno_and_return_minus_one( EIO );
}
temp_mt_entry->mt_fs_root.node_access = fat_fd;
2023024: c2 24 60 1c st %g1, [ %l1 + 0x1c ] <== NOT EXECUTED
temp_mt_entry->mt_fs_root.handlers = directory_handlers;
2023028: f6 24 60 24 st %i3, [ %l1 + 0x24 ] <== NOT EXECUTED
temp_mt_entry->mt_fs_root.ops = op_table;
return rc;
}
202302c: 81 c7 e0 08 ret <== NOT EXECUTED
2023030: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
else
{
rc = fat_file_size(temp_mt_entry, fat_fd);
if ( rc != RC_OK )
{
fat_file_close(temp_mt_entry, fat_fd);
2023034: 40 00 17 e8 call 2028fd4 <fat_file_close> <== NOT EXECUTED
2023038: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
fat_shutdown_drive(temp_mt_entry);
202303c: 40 00 1a 63 call 20299c8 <fat_shutdown_drive> <== NOT EXECUTED
2023040: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
free(fs_info);
2023044: 7f ff 96 26 call 20088dc <free> <== NOT EXECUTED
2023048: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
202304c: 81 c7 e0 08 ret <== NOT EXECUTED
2023050: 81 e8 00 00 restore <== NOT EXECUTED
fat_dir_pos_init(&root_pos);
root_pos.sname.cln = FAT_ROOTDIR_CLUSTER_NUM;
rc = fat_file_open(temp_mt_entry, &root_pos, &fat_fd);
if (rc != RC_OK)
{
fat_shutdown_drive(temp_mt_entry);
2023054: 40 00 1a 5d call 20299c8 <fat_shutdown_drive> <== NOT EXECUTED
2023058: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
free(fs_info);
202305c: 7f ff 96 20 call 20088dc <free> <== NOT EXECUTED
2023060: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
2023064: 81 c7 e0 08 ret <== NOT EXECUTED
2023068: 81 e8 00 00 restore <== NOT EXECUTED
fs_info->fat.vol.bpc :
fs_info->fat.vol.rdir_size;
}
else
{
rc = fat_file_size(temp_mt_entry, fat_fd);
202306c: 40 00 14 fd call 2028460 <fat_file_size> <== NOT EXECUTED
2023070: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
if ( rc != RC_OK )
2023074: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2023078: 12 bf ff ef bne 2023034 <msdos_initialize_support+0x100> <== NOT EXECUTED
202307c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
fat_file_close(temp_mt_entry, fat_fd);
fat_shutdown_drive(temp_mt_entry);
free(fs_info);
return rc;
}
cl_buf_size = fs_info->fat.vol.bpc;
2023080: 10 bf ff da b 2022fe8 <msdos_initialize_support+0xb4> <== NOT EXECUTED
2023084: d0 14 20 06 lduh [ %l0 + 6 ], %o0 <== NOT EXECUTED
}
fs_info->cl_buf = (uint8_t *)calloc(cl_buf_size, sizeof(char));
if (fs_info->cl_buf == NULL)
{
fat_file_close(temp_mt_entry, fat_fd);
2023088: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
202308c: 40 00 17 d2 call 2028fd4 <fat_file_close> <== NOT EXECUTED
2023090: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
fat_shutdown_drive(temp_mt_entry);
2023094: 40 00 1a 4d call 20299c8 <fat_shutdown_drive> <== NOT EXECUTED
2023098: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
free(fs_info);
202309c: 7f ff 96 10 call 20088dc <free> <== NOT EXECUTED
20230a0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
20230a4: 40 00 9c f7 call 204a480 <__errno> <== NOT EXECUTED
20230a8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20230ac: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
20230b0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20230b4: 81 c7 e0 08 ret <== NOT EXECUTED
20230b8: 81 e8 00 00 restore <== NOT EXECUTED
RTEMS_BINARY_SEMAPHORE | RTEMS_FIFO,
0,
&fs_info->vol_sema);
if (sc != RTEMS_SUCCESSFUL)
{
fat_file_close(temp_mt_entry, fat_fd);
20230bc: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
20230c0: 40 00 17 c5 call 2028fd4 <fat_file_close> <== NOT EXECUTED
20230c4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
fat_shutdown_drive(temp_mt_entry);
20230c8: 40 00 1a 40 call 20299c8 <fat_shutdown_drive> <== NOT EXECUTED
20230cc: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
free(fs_info->cl_buf);
20230d0: d0 04 20 9c ld [ %l0 + 0x9c ], %o0 <== NOT EXECUTED
20230d4: 7f ff 96 02 call 20088dc <free> <== NOT EXECUTED
20230d8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free(fs_info);
20230dc: 7f ff 96 00 call 20088dc <free> <== NOT EXECUTED
20230e0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EIO );
20230e4: 40 00 9c e7 call 204a480 <__errno> <== NOT EXECUTED
20230e8: 01 00 00 00 nop <== NOT EXECUTED
20230ec: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
20230f0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20230f4: 81 c7 e0 08 ret <== NOT EXECUTED
20230f8: 81 e8 00 00 restore <== NOT EXECUTED
0203dad8 <msdos_is_valid_name_char>:
* MSDOS_NAME_LONG - Valid in a long name only.
*
*/
static msdos_name_type_t
msdos_is_valid_name_char(const char ch)
{
203dad8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (strchr(" +,;=[]", ch) != NULL)
203dadc: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203dae0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203dae4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
203dae8: 90 12 23 28 or %o0, 0x328, %o0 <== NOT EXECUTED
203daec: 40 00 4b ad call 20509a0 <strchr> <== NOT EXECUTED
203daf0: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
203daf4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203daf8: 12 80 00 10 bne 203db38 <msdos_is_valid_name_char+0x60> <== NOT EXECUTED
203dafc: 80 a4 20 2e cmp %l0, 0x2e <== NOT EXECUTED
return MSDOS_NAME_LONG;
if ((ch == '.') || isalnum((unsigned char)ch) ||
203db00: 02 80 00 10 be 203db40 <msdos_is_valid_name_char+0x68> <== NOT EXECUTED
203db04: 03 00 81 c5 sethi %hi(0x2071400), %g1 <== NOT EXECUTED
203db08: c2 00 61 fc ld [ %g1 + 0x1fc ], %g1 ! 20715fc <__ctype_ptr__><== NOT EXECUTED
203db0c: a2 0c 20 ff and %l0, 0xff, %l1 <== NOT EXECUTED
203db10: a2 00 40 11 add %g1, %l1, %l1 <== NOT EXECUTED
203db14: c2 0c 60 01 ldub [ %l1 + 1 ], %g1 <== NOT EXECUTED
203db18: 80 88 60 07 btst 7, %g1 <== NOT EXECUTED
203db1c: 12 80 00 09 bne 203db40 <msdos_is_valid_name_char+0x68> <== NOT EXECUTED
203db20: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
(strchr("$%'-_@~`!(){}^#&", ch) != NULL))
203db24: 11 00 81 b8 sethi %hi(0x206e000), %o0 <== NOT EXECUTED
203db28: 40 00 4b 9e call 20509a0 <strchr> <== NOT EXECUTED
203db2c: 90 12 23 30 or %o0, 0x330, %o0 ! 206e330 <msdos_file_handlers+0xd8><== NOT EXECUTED
203db30: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
203db34: b0 40 20 00 addx %g0, 0, %i0 <== NOT EXECUTED
203db38: 81 c7 e0 08 ret <== NOT EXECUTED
203db3c: 81 e8 00 00 restore <== NOT EXECUTED
return MSDOS_NAME_SHORT;
return MSDOS_NAME_INVALID;
}
203db40: 81 c7 e0 08 ret <== NOT EXECUTED
203db44: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
0203dc38 <msdos_long_to_short>:
*
*/
#define MSDOS_L2S_PRINT 0
msdos_name_type_t
msdos_long_to_short(const char *lfn, int lfn_len, char* sfn, int sfn_len)
{
203dc38: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int i;
/*
* Fill with spaces. This is how a short directory entry is padded.
*/
memset (sfn, ' ', sfn_len);
203dc3c: 92 10 20 20 mov 0x20, %o1 <== NOT EXECUTED
203dc40: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
203dc44: 40 00 3f ee call 204dbfc <memset> <== NOT EXECUTED
203dc48: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
/*
* Handle '.' and '..' specially.
*/
if ((lfn[0] == '.') && (lfn_len == 1))
203dc4c: e2 0e 00 00 ldub [ %i0 ], %l1 <== NOT EXECUTED
203dc50: a7 2c 60 18 sll %l1, 0x18, %l3 <== NOT EXECUTED
203dc54: 83 3c e0 18 sra %l3, 0x18, %g1 <== NOT EXECUTED
203dc58: 82 18 60 2e xor %g1, 0x2e, %g1 <== NOT EXECUTED
203dc5c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
203dc60: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
203dc64: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
203dc68: 02 80 00 62 be 203ddf0 <msdos_long_to_short+0x1b8> <== NOT EXECUTED
203dc6c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
printf ("MSDOS_L2S: SHORT[1]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif
return MSDOS_NAME_SHORT;
}
if ((lfn[0] == '.') && (lfn[1] == '.') && (lfn_len == 2))
203dc70: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203dc74: 32 80 00 69 bne,a 203de18 <msdos_long_to_short+0x1e0> <== NOT EXECUTED
203dc78: c2 4c 20 01 ldsb [ %l0 + 1 ], %g1 <== NOT EXECUTED
}
/*
* Filenames with only blanks and dots are not allowed!
*/
for (i = 0; i < lfn_len; i++)
203dc7c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
203dc80: 04 80 00 0f ble 203dcbc <msdos_long_to_short+0x84> <== NOT EXECUTED
203dc84: 82 10 20 00 clr %g1 <== NOT EXECUTED
if ((lfn[i] != ' ') && (lfn[i] != '.'))
203dc88: 83 3c e0 18 sra %l3, 0x18, %g1 <== NOT EXECUTED
203dc8c: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
203dc90: 12 80 00 73 bne 203de5c <msdos_long_to_short+0x224> <== NOT EXECUTED
203dc94: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
203dc98: 10 80 00 05 b 203dcac <msdos_long_to_short+0x74> <== NOT EXECUTED
203dc9c: 82 10 20 00 clr %g1 <== NOT EXECUTED
203dca0: 80 a0 a0 2e cmp %g2, 0x2e <== NOT EXECUTED
203dca4: 12 80 00 59 bne 203de08 <msdos_long_to_short+0x1d0> <== NOT EXECUTED
203dca8: 80 a0 a0 20 cmp %g2, 0x20 <== NOT EXECUTED
}
/*
* Filenames with only blanks and dots are not allowed!
*/
for (i = 0; i < lfn_len; i++)
203dcac: 82 00 60 01 inc %g1 <== NOT EXECUTED
203dcb0: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
203dcb4: 34 bf ff fb bg,a 203dca0 <msdos_long_to_short+0x68> <== NOT EXECUTED
203dcb8: c4 4c 00 01 ldsb [ %l0 + %g1 ], %g2 <== NOT EXECUTED
if ((lfn[i] != ' ') && (lfn[i] != '.'))
break;
if (i == lfn_len)
203dcbc: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
203dcc0: 02 80 00 40 be 203ddc0 <msdos_long_to_short+0x188> <== NOT EXECUTED
203dcc4: b0 10 20 00 clr %i0 <== NOT EXECUTED
bool lowercase = false;
bool uppercase = false;
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
203dcc8: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
203dccc: 02 80 00 62 be 203de54 <msdos_long_to_short+0x21c> <== NOT EXECUTED
203dcd0: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
203dcd4: 04 80 00 60 ble 203de54 <msdos_long_to_short+0x21c> <== NOT EXECUTED
203dcd8: aa 10 20 00 clr %l5 <== NOT EXECUTED
203dcdc: ac 10 20 00 clr %l6 <== NOT EXECUTED
203dce0: a4 10 20 00 clr %l2 <== NOT EXECUTED
203dce4: 10 80 00 15 b 203dd38 <msdos_long_to_short+0x100> <== NOT EXECUTED
203dce8: a8 10 3f ff mov -1, %l4 <== NOT EXECUTED
if ((type == MSDOS_NAME_INVALID) || (type == MSDOS_NAME_LONG))
return type;
if (dot_at >= 0)
{
if (is_dot || ((count - dot_at) > 3))
203dcec: 12 80 00 30 bne 203ddac <msdos_long_to_short+0x174> <== NOT EXECUTED
203dcf0: 82 24 80 14 sub %l2, %l4, %g1 <== NOT EXECUTED
203dcf4: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED
203dcf8: 14 80 00 2e bg 203ddb0 <msdos_long_to_short+0x178> <== NOT EXECUTED
203dcfc: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
}
}
if (is_dot)
dot_at = count;
else if ((*name >= 'A') && (*name <= 'Z'))
203dd00: 82 04 7f bf add %l1, -65, %g1 <== NOT EXECUTED
203dd04: 82 08 60 ff and %g1, 0xff, %g1 <== NOT EXECUTED
203dd08: 80 a0 60 19 cmp %g1, 0x19 <== NOT EXECUTED
203dd0c: 18 80 00 2f bgu 203ddc8 <msdos_long_to_short+0x190> <== NOT EXECUTED
203dd10: a2 04 7f 9f add %l1, -97, %l1 <== NOT EXECUTED
203dd14: aa 10 20 01 mov 1, %l5 <== NOT EXECUTED
uppercase = true;
else if ((*name >= 'a') && (*name <= 'z'))
lowercase = true;
count++;
203dd18: a4 04 a0 01 inc %l2 <== NOT EXECUTED
bool lowercase = false;
bool uppercase = false;
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
203dd1c: 80 a6 40 12 cmp %i1, %l2 <== NOT EXECUTED
203dd20: 04 80 00 1e ble 203dd98 <msdos_long_to_short+0x160> <== NOT EXECUTED
203dd24: e2 0c 00 12 ldub [ %l0 + %l2 ], %l1 <== NOT EXECUTED
203dd28: a7 2c 60 18 sll %l1, 0x18, %l3 <== NOT EXECUTED
203dd2c: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
203dd30: 02 80 00 1b be 203dd9c <msdos_long_to_short+0x164> <== NOT EXECUTED
203dd34: 80 8d a0 ff btst 0xff, %l6 <== NOT EXECUTED
{
bool is_dot = *name == '.';
msdos_name_type_t type = msdos_is_valid_name_char(*name);
203dd38: a7 3c e0 18 sra %l3, 0x18, %l3 <== NOT EXECUTED
203dd3c: 7f ff ff 67 call 203dad8 <msdos_is_valid_name_char> <== NOT EXECUTED
203dd40: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
#if MSDOS_NAME_TYPE_PRINT
printf ("MSDOS_NAME_TYPE: c:%02x type:%d\n", *name, type);
#endif
if ((type == MSDOS_NAME_INVALID) || (type == MSDOS_NAME_LONG))
203dd44: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
203dd48: 02 80 00 3e be 203de40 <msdos_long_to_short+0x208> <== NOT EXECUTED
203dd4c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
203dd50: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203dd54: 02 80 00 3b be 203de40 <msdos_long_to_short+0x208> <== NOT EXECUTED
203dd58: a6 1c e0 2e xor %l3, 0x2e, %l3 <== NOT EXECUTED
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
{
bool is_dot = *name == '.';
203dd5c: 80 a0 00 13 cmp %g0, %l3 <== NOT EXECUTED
203dd60: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
#endif
if ((type == MSDOS_NAME_INVALID) || (type == MSDOS_NAME_LONG))
return type;
if (dot_at >= 0)
203dd64: 80 a5 3f ff cmp %l4, -1 <== NOT EXECUTED
203dd68: 12 bf ff e1 bne 203dcec <msdos_long_to_short+0xb4> <== NOT EXECUTED
203dd6c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
return MSDOS_NAME_LONG;
}
}
else
{
if (count == 8 && !is_dot)
203dd70: 80 a4 a0 08 cmp %l2, 8 <== NOT EXECUTED
203dd74: 02 80 00 1b be 203dde0 <msdos_long_to_short+0x1a8> <== NOT EXECUTED
203dd78: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
#endif
return MSDOS_NAME_LONG;
}
}
if (is_dot)
203dd7c: 22 bf ff e2 be,a 203dd04 <msdos_long_to_short+0xcc> <== NOT EXECUTED
203dd80: 82 04 7f bf add %l1, -65, %g1 <== NOT EXECUTED
dot_at = count;
else if ((*name >= 'A') && (*name <= 'Z'))
uppercase = true;
else if ((*name >= 'a') && (*name <= 'z'))
203dd84: a8 10 00 12 mov %l2, %l4 <== NOT EXECUTED
lowercase = true;
count++;
203dd88: a4 04 a0 01 inc %l2 <== NOT EXECUTED
bool lowercase = false;
bool uppercase = false;
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
203dd8c: 80 a6 40 12 cmp %i1, %l2 <== NOT EXECUTED
203dd90: 14 bf ff e6 bg 203dd28 <msdos_long_to_short+0xf0> <== NOT EXECUTED
203dd94: e2 0c 00 12 ldub [ %l0 + %l2 ], %l1 <== NOT EXECUTED
count++;
name++;
}
if (lowercase && uppercase)
203dd98: 80 8d a0 ff btst 0xff, %l6 <== NOT EXECUTED
203dd9c: 02 80 00 2e be 203de54 <msdos_long_to_short+0x21c> <== NOT EXECUTED
203dda0: 80 8d 60 ff btst 0xff, %l5 <== NOT EXECUTED
203dda4: 22 80 00 03 be,a 203ddb0 <msdos_long_to_short+0x178> <== NOT EXECUTED
203dda8: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
msdos_filename_unix2dos (lfn, lfn_len, sfn);
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: TYPE:%d lfn:'%s' SFN:'%s'\n", type, lfn, sfn);
#endif
return type;
203ddac: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
printf ("MSDOS_L2S: INVALID[2]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif
return MSDOS_NAME_INVALID;
}
msdos_filename_unix2dos (lfn, lfn_len, sfn);
203ddb0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ddb4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203ddb8: 40 00 2a ad call 204886c <msdos_filename_unix2dos> <== NOT EXECUTED
203ddbc: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: TYPE:%d lfn:'%s' SFN:'%s'\n", type, lfn, sfn);
#endif
return type;
}
203ddc0: 81 c7 e0 08 ret <== NOT EXECUTED
203ddc4: 81 e8 00 00 restore <== NOT EXECUTED
if (is_dot)
dot_at = count;
else if ((*name >= 'A') && (*name <= 'Z'))
uppercase = true;
else if ((*name >= 'a') && (*name <= 'z'))
203ddc8: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
203ddcc: 80 a4 60 19 cmp %l1, 0x19 <== NOT EXECUTED
203ddd0: 28 bf ff d2 bleu,a 203dd18 <msdos_long_to_short+0xe0> <== NOT EXECUTED
203ddd4: ac 10 20 01 mov 1, %l6 <== NOT EXECUTED
lowercase = true;
count++;
203ddd8: 10 bf ff d1 b 203dd1c <msdos_long_to_short+0xe4> <== NOT EXECUTED
203dddc: a4 04 a0 01 inc %l2 <== NOT EXECUTED
return MSDOS_NAME_LONG;
}
}
else
{
if (count == 8 && !is_dot)
203dde0: 22 bf ff f4 be,a 203ddb0 <msdos_long_to_short+0x178> <== NOT EXECUTED
203dde4: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
if (is_dot)
dot_at = count;
else if ((*name >= 'A') && (*name <= 'Z'))
uppercase = true;
else if ((*name >= 'a') && (*name <= 'z'))
203dde8: 10 bf ff e8 b 203dd88 <msdos_long_to_short+0x150> <== NOT EXECUTED
203ddec: a8 10 00 12 mov %l2, %l4 <== NOT EXECUTED
memset (sfn, ' ', sfn_len);
/*
* Handle '.' and '..' specially.
*/
if ((lfn[0] == '.') && (lfn_len == 1))
203ddf0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203ddf4: 02 bf ff a0 be 203dc74 <msdos_long_to_short+0x3c> <== NOT EXECUTED
203ddf8: 82 10 20 2e mov 0x2e, %g1 <== NOT EXECUTED
{
sfn[0] = '.';
203ddfc: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: SHORT[1]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif
return MSDOS_NAME_SHORT;
203de00: 81 c7 e0 08 ret <== NOT EXECUTED
203de04: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
/*
* Filenames with only blanks and dots are not allowed!
*/
for (i = 0; i < lfn_len; i++)
if ((lfn[i] != ' ') && (lfn[i] != '.'))
203de08: 22 bf ff aa be,a 203dcb0 <msdos_long_to_short+0x78> <== NOT EXECUTED
203de0c: 82 00 60 01 inc %g1 <== NOT EXECUTED
bool lowercase = false;
bool uppercase = false;
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
203de10: 10 bf ff af b 203dccc <msdos_long_to_short+0x94> <== NOT EXECUTED
203de14: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
printf ("MSDOS_L2S: SHORT[1]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif
return MSDOS_NAME_SHORT;
}
if ((lfn[0] == '.') && (lfn[1] == '.') && (lfn_len == 2))
203de18: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
203de1c: 12 bf ff 99 bne 203dc80 <msdos_long_to_short+0x48> <== NOT EXECUTED
203de20: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
203de24: 80 a6 60 02 cmp %i1, 2 <== NOT EXECUTED
203de28: 32 bf ff 96 bne,a 203dc80 <msdos_long_to_short+0x48> <== NOT EXECUTED
203de2c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
{
sfn[0] = sfn[1] = '.';
203de30: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
203de34: c2 2e a0 01 stb %g1, [ %i2 + 1 ] <== NOT EXECUTED
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: SHORT[2]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif
return MSDOS_NAME_SHORT;
203de38: 81 c7 e0 08 ret <== NOT EXECUTED
203de3c: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
* Is this a short name ?
*/
type = msdos_name_type (lfn, lfn_len);
if (type == MSDOS_NAME_INVALID)
203de40: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203de44: 12 bf ff dc bne 203ddb4 <msdos_long_to_short+0x17c> <== NOT EXECUTED
203de48: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: TYPE:%d lfn:'%s' SFN:'%s'\n", type, lfn, sfn);
#endif
return type;
}
203de4c: 81 c7 e0 08 ret <== NOT EXECUTED
203de50: 81 e8 00 00 restore <== NOT EXECUTED
msdos_filename_unix2dos (lfn, lfn_len, sfn);
#if MSDOS_L2S_PRINT
printf ("MSDOS_L2S: TYPE:%d lfn:'%s' SFN:'%s'\n", type, lfn, sfn);
#endif
return type;
203de54: 10 bf ff d7 b 203ddb0 <msdos_long_to_short+0x178> <== NOT EXECUTED
203de58: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
/*
* Filenames with only blanks and dots are not allowed!
*/
for (i = 0; i < lfn_len; i++)
if ((lfn[i] != ' ') && (lfn[i] != '.'))
203de5c: 22 bf ff 94 be,a 203dcac <msdos_long_to_short+0x74> <== NOT EXECUTED
203de60: 82 10 20 00 clr %g1 <== NOT EXECUTED
bool lowercase = false;
bool uppercase = false;
int dot_at = -1;
int count = 0;
while (*name && (count < name_len))
203de64: 10 bf ff 9a b 203dccc <msdos_long_to_short+0x94> <== NOT EXECUTED
203de68: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
020230fc <msdos_mknod>:
const char *name,
mode_t mode,
dev_t dev,
rtems_filesystem_location_info_t *pathloc
)
{
20230fc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
2023100: c2 07 20 10 ld [ %i4 + 0x10 ], %g1 <== NOT EXECUTED
msdos_token_types_t type = 0;
/*
* Figure out what type of msdos node this is.
*/
if (S_ISDIR(mode))
2023104: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
rtems_filesystem_location_info_t *pathloc
)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = pathloc->mt_entry->fs_info;
2023108: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
msdos_token_types_t type = 0;
/*
* Figure out what type of msdos node this is.
*/
if (S_ISDIR(mode))
202310c: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2023110: 82 0e 40 01 and %i1, %g1, %g1 <== NOT EXECUTED
2023114: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2023118: 02 80 00 1a be 2023180 <msdos_mknod+0x84> <== NOT EXECUTED
202311c: 05 00 00 20 sethi %hi(0x8000), %g2 <== NOT EXECUTED
{
type = MSDOS_DIRECTORY;
}
else if (S_ISREG(mode))
2023120: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2023124: 12 80 00 1f bne 20231a0 <msdos_mknod+0xa4> <== NOT EXECUTED
2023128: a2 10 20 05 mov 5, %l1 <== NOT EXECUTED
type = MSDOS_REGULAR_FILE;
}
else
rtems_set_errno_and_return_minus_one(EINVAL);
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
202312c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
2023130: 92 10 20 00 clr %o1 <== NOT EXECUTED
2023134: 7f ff a9 41 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2023138: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
202313c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023140: 12 80 00 12 bne 2023188 <msdos_mknod+0x8c> <== NOT EXECUTED
2023144: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(EIO);
/* Create an MSDOS node */
rc = msdos_creat_node(pathloc, type, name, strlen(name), mode, NULL);
2023148: 40 00 b8 8a call 2051370 <strlen> <== NOT EXECUTED
202314c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2023150: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
2023154: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2023158: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202315c: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
2023160: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
2023164: 40 00 61 c5 call 203b878 <msdos_creat_node> <== NOT EXECUTED
2023168: 9a 10 20 00 clr %o5 <== NOT EXECUTED
202316c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release(fs_info->vol_sema);
2023170: 7f ff a9 79 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2023174: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
2023178: 81 c7 e0 08 ret <== NOT EXECUTED
202317c: 81 e8 00 00 restore <== NOT EXECUTED
else if (S_ISREG(mode))
{
type = MSDOS_REGULAR_FILE;
}
else
rtems_set_errno_and_return_minus_one(EINVAL);
2023180: 10 bf ff eb b 202312c <msdos_mknod+0x30> <== NOT EXECUTED
2023184: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2023188: 40 00 9c be call 204a480 <__errno> <== NOT EXECUTED
202318c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2023190: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2023194: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2023198: 81 c7 e0 08 ret <== NOT EXECUTED
202319c: 81 e8 00 00 restore <== NOT EXECUTED
else if (S_ISREG(mode))
{
type = MSDOS_REGULAR_FILE;
}
else
rtems_set_errno_and_return_minus_one(EINVAL);
20231a0: 40 00 9c b8 call 204a480 <__errno> <== NOT EXECUTED
20231a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20231a8: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20231ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20231b0: 81 c7 e0 08 ret <== NOT EXECUTED
20231b4: 81 e8 00 00 restore <== NOT EXECUTED
020231b8 <msdos_node_type>:
* node type
*
*/
rtems_filesystem_node_types_t
msdos_node_type(rtems_filesystem_location_info_t *pathloc)
{
20231b8: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
* call
*/
fat_fd = pathloc->node_access;
return fat_fd->fat_file_type;
}
20231bc: 81 c3 e0 08 retl <== NOT EXECUTED
20231c0: d0 00 60 10 ld [ %g1 + 0x10 ], %o0 <== NOT EXECUTED
020231c4 <msdos_rename>:
int
msdos_rename(rtems_filesystem_location_info_t *old_parent_loc,
rtems_filesystem_location_info_t *old_loc,
rtems_filesystem_location_info_t *new_parent_loc,
const char *new_name)
{
20231c4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = new_parent_loc->mt_entry->fs_info;
20231c8: c2 06 a0 10 ld [ %i2 + 0x10 ], %g1 <== NOT EXECUTED
int len;
/*
* check spelling and format new node name
*/
if (MSDOS_NAME != msdos_get_token(new_name, strlen(new_name), &token, &len)) {
20231cc: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
20231d0: 40 00 b8 68 call 2051370 <strlen> <== NOT EXECUTED
20231d4: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
20231d8: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
20231dc: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
const char *new_name)
{
int rc = RC_OK;
rtems_status_code sc = RTEMS_SUCCESSFUL;
msdos_fs_info_t *fs_info = new_parent_loc->mt_entry->fs_info;
fat_file_fd_t *old_fat_fd = old_loc->node_access;
20231e0: e2 06 40 00 ld [ %i1 ], %l1 <== NOT EXECUTED
int len;
/*
* check spelling and format new node name
*/
if (MSDOS_NAME != msdos_get_token(new_name, strlen(new_name), &token, &len)) {
20231e4: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
20231e8: 40 00 6a 58 call 203db48 <msdos_get_token> <== NOT EXECUTED
20231ec: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
20231f0: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
20231f4: 12 80 00 1d bne 2023268 <msdos_rename+0xa4> <== NOT EXECUTED
20231f8: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENAMETOOLONG);
}
/*
* lock volume
*/
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
20231fc: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
2023200: 7f ff a9 0e call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2023204: 94 10 20 00 clr %o2 <== NOT EXECUTED
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
2023208: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202320c: 12 80 00 1d bne 2023280 <msdos_rename+0xbc> <== NOT EXECUTED
2023210: d6 07 bf f8 ld [ %fp + -8 ], %o3 <== NOT EXECUTED
/*
* create new directory entry as "hard link", copying relevant info from
* existing file
*/
rc = msdos_creat_node(new_parent_loc,
2023214: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2023218: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
202321c: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
2023220: 19 00 00 20 sethi %hi(0x8000), %o4 <== NOT EXECUTED
2023224: 40 00 61 95 call 203b878 <msdos_creat_node> <== NOT EXECUTED
2023228: 9a 10 00 11 mov %l1, %o5 <== NOT EXECUTED
MSDOS_HARD_LINK,new_name,len,S_IFREG,
old_fat_fd);
if (rc != RC_OK)
202322c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2023230: 12 80 00 0a bne 2023258 <msdos_rename+0x94> <== NOT EXECUTED
2023234: 92 04 60 20 add %l1, 0x20, %o1 <== NOT EXECUTED
}
/*
* mark file removed
*/
rc = msdos_set_first_char4file_name(old_loc->mt_entry,
2023238: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
202323c: 40 00 69 77 call 203d818 <msdos_set_first_char4file_name> <== NOT EXECUTED
2023240: 94 10 20 e5 mov 0xe5, %o2 <== NOT EXECUTED
2023244: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
&old_fat_fd->dir_pos,
MSDOS_THIS_DIR_ENTRY_EMPTY);
rtems_semaphore_release(fs_info->vol_sema);
2023248: 7f ff a9 43 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202324c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
}
2023250: 81 c7 e0 08 ret <== NOT EXECUTED
2023254: 81 e8 00 00 restore <== NOT EXECUTED
rc = msdos_creat_node(new_parent_loc,
MSDOS_HARD_LINK,new_name,len,S_IFREG,
old_fat_fd);
if (rc != RC_OK)
{
rtems_semaphore_release(fs_info->vol_sema);
2023258: 7f ff a9 3f call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202325c: d0 04 20 98 ld [ %l0 + 0x98 ], %o0 <== NOT EXECUTED
return rc;
2023260: 81 c7 e0 08 ret <== NOT EXECUTED
2023264: 81 e8 00 00 restore <== NOT EXECUTED
/*
* check spelling and format new node name
*/
if (MSDOS_NAME != msdos_get_token(new_name, strlen(new_name), &token, &len)) {
rtems_set_errno_and_return_minus_one(ENAMETOOLONG);
2023268: 40 00 9c 86 call 204a480 <__errno> <== NOT EXECUTED
202326c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2023270: 82 10 20 5b mov 0x5b, %g1 <== NOT EXECUTED
2023274: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2023278: 81 c7 e0 08 ret <== NOT EXECUTED
202327c: 81 e8 00 00 restore <== NOT EXECUTED
* lock volume
*/
sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,
MSDOS_VOLUME_SEMAPHORE_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_set_errno_and_return_minus_one(EIO);
2023280: 40 00 9c 80 call 204a480 <__errno> <== NOT EXECUTED
2023284: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2023288: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
202328c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2023290: 81 c7 e0 08 ret <== NOT EXECUTED
2023294: 81 e8 00 00 restore <== NOT EXECUTED
0203d9e0 <msdos_set_dir_wrt_time_and_date>:
int
msdos_set_dir_wrt_time_and_date(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
203d9e0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uint16_t time_val;
uint16_t date;
uint32_t sec = 0;
uint32_t byte = 0;
msdos_date_unix2dos(fat_fd->mtime, &date, &time_val);
203d9e4: d0 06 60 40 ld [ %i1 + 0x40 ], %o0 <== NOT EXECUTED
203d9e8: a0 07 bf fc add %fp, -4, %l0 <== NOT EXECUTED
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
ssize_t ret1 = 0, ret2 = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203d9ec: e8 06 20 34 ld [ %i0 + 0x34 ], %l4 <== NOT EXECUTED
uint16_t time_val;
uint16_t date;
uint32_t sec = 0;
uint32_t byte = 0;
msdos_date_unix2dos(fat_fd->mtime, &date, &time_val);
203d9f0: a6 07 bf fe add %fp, -2, %l3 <== NOT EXECUTED
203d9f4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
203d9f8: 40 00 2a e7 call 2048594 <msdos_date_unix2dos> <== NOT EXECUTED
203d9fc: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
203da00: c4 06 60 20 ld [ %i1 + 0x20 ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203da04: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203da08: 12 80 00 06 bne 203da20 <msdos_set_dir_wrt_time_and_date+0x40><== NOT EXECUTED
203da0c: c2 06 20 34 ld [ %i0 + 0x34 ], %g1 <== NOT EXECUTED
203da10: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
203da14: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
203da18: 32 80 00 07 bne,a 203da34 <msdos_set_dir_wrt_time_and_date+0x54><== NOT EXECUTED
203da1c: e4 00 60 1c ld [ %g1 + 0x1c ], %l2 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
203da20: c6 00 60 30 ld [ %g1 + 0x30 ], %g3 <== NOT EXECUTED
203da24: c2 08 60 05 ldub [ %g1 + 5 ], %g1 <== NOT EXECUTED
203da28: a4 00 bf fe add %g2, -2, %l2 <== NOT EXECUTED
203da2c: a5 2c 80 01 sll %l2, %g1, %l2 <== NOT EXECUTED
203da30: a4 04 80 03 add %l2, %g3, %l2 <== NOT EXECUTED
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203da34: c4 06 60 24 ld [ %i1 + 0x24 ], %g2 <== NOT EXECUTED
203da38: c2 0d 20 02 ldub [ %l4 + 2 ], %g1 <== NOT EXECUTED
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
203da3c: e2 15 00 00 lduh [ %l4 ], %l1 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203da40: 83 30 80 01 srl %g2, %g1, %g1 <== NOT EXECUTED
203da44: a4 04 80 01 add %l2, %g1, %l2 <== NOT EXECUTED
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
time_val = CT_LE_W(time_val);
203da48: c2 17 bf fe lduh [ %fp + -2 ], %g1 <== NOT EXECUTED
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
203da4c: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
time_val = CT_LE_W(time_val);
203da50: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
203da54: a2 0c 40 02 and %l1, %g2, %l1 <== NOT EXECUTED
time_val = CT_LE_W(time_val);
203da58: 85 30 60 18 srl %g1, 0x18, %g2 <== NOT EXECUTED
203da5c: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203da60: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
ret1 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WTIME_OFFSET,
203da64: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
time_val = CT_LE_W(time_val);
203da68: c2 37 bf fe sth %g1, [ %fp + -2 ] <== NOT EXECUTED
ret1 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WTIME_OFFSET,
203da6c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
203da70: 94 04 60 16 add %l1, 0x16, %o2 <== NOT EXECUTED
203da74: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
203da78: 7f ff af 75 call 202984c <_fat_block_write> <== NOT EXECUTED
203da7c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2, (char *)(&time_val));
date = CT_LE_W(date);
203da80: c2 17 bf fc lduh [ %fp + -4 ], %g1 <== NOT EXECUTED
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
time_val = CT_LE_W(time_val);
ret1 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WTIME_OFFSET,
203da84: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
2, (char *)(&time_val));
date = CT_LE_W(date);
203da88: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
203da8c: 85 30 60 18 srl %g1, 0x18, %g2 <== NOT EXECUTED
203da90: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203da94: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
ret2 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WDATE_OFFSET,
203da98: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203da9c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
203daa0: 94 04 60 18 add %l1, 0x18, %o2 <== NOT EXECUTED
203daa4: 98 10 00 10 mov %l0, %o4 <== NOT EXECUTED
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
time_val = CT_LE_W(time_val);
ret1 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WTIME_OFFSET,
2, (char *)(&time_val));
date = CT_LE_W(date);
203daa8: c2 37 bf fc sth %g1, [ %fp + -4 ] <== NOT EXECUTED
ret2 = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_WDATE_OFFSET,
203daac: 7f ff af 68 call 202984c <_fat_block_write> <== NOT EXECUTED
203dab0: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
2, (char *)(&date));
if ( (ret1 < 0) || (ret2 < 0) )
203dab4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203dab8: 06 80 00 06 bl 203dad0 <msdos_set_dir_wrt_time_and_date+0xf0><== NOT EXECUTED
203dabc: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
203dac0: 06 80 00 04 bl 203dad0 <msdos_set_dir_wrt_time_and_date+0xf0><== NOT EXECUTED
203dac4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return -1;
return RC_OK;
}
203dac8: 81 c7 e0 08 ret <== NOT EXECUTED
203dacc: 81 e8 00 00 restore <== NOT EXECUTED
203dad0: 81 c7 e0 08 ret <== NOT EXECUTED
203dad4: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0203d690 <msdos_set_file_size>:
int
msdos_set_file_size(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
203d690: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t le_new_length = 0;
uint32_t sec = 0;
uint32_t byte = 0;
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
203d694: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
int
msdos_set_file_size(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
203d698: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203d69c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203d6a0: 12 80 00 06 bne 203d6b8 <msdos_set_file_size+0x28> <== NOT EXECUTED
203d6a4: c4 06 20 34 ld [ %i0 + 0x34 ], %g2 <== NOT EXECUTED
203d6a8: c6 08 a0 0a ldub [ %g2 + 0xa ], %g3 <== NOT EXECUTED
203d6ac: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
203d6b0: 32 80 00 07 bne,a 203d6cc <msdos_set_file_size+0x3c> <== NOT EXECUTED
203d6b4: d2 00 a0 1c ld [ %g2 + 0x1c ], %o1 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
203d6b8: c8 08 a0 05 ldub [ %g2 + 5 ], %g4 <== NOT EXECUTED
203d6bc: c6 00 a0 30 ld [ %g2 + 0x30 ], %g3 <== NOT EXECUTED
203d6c0: 92 00 7f fe add %g1, -2, %o1 <== NOT EXECUTED
203d6c4: 93 2a 40 04 sll %o1, %g4, %o1 <== NOT EXECUTED
203d6c8: 92 02 40 03 add %o1, %g3, %o1 <== NOT EXECUTED
uint32_t le_new_length = 0;
uint32_t sec = 0;
uint32_t byte = 0;
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d6cc: c6 06 60 24 ld [ %i1 + 0x24 ], %g3 <== NOT EXECUTED
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
203d6d0: d4 10 80 00 lduh [ %g2 ], %o2 <== NOT EXECUTED
uint32_t le_new_length = 0;
uint32_t sec = 0;
uint32_t byte = 0;
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d6d4: c4 08 a0 02 ldub [ %g2 + 2 ], %g2 <== NOT EXECUTED
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
le_new_length = CT_LE_L((fat_fd->fat_file_size));
203d6d8: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
uint32_t sec = 0;
uint32_t byte = 0;
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
203d6dc: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
203d6e0: 94 0a 80 03 and %o2, %g3, %o2 <== NOT EXECUTED
uint32_t le_new_length = 0;
uint32_t sec = 0;
uint32_t byte = 0;
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d6e4: 87 30 c0 02 srl %g3, %g2, %g3 <== NOT EXECUTED
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
le_new_length = CT_LE_L((fat_fd->fat_file_size));
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_SIZE_OFFSET, 4,
203d6e8: 92 02 40 03 add %o1, %g3, %o1 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
le_new_length = CT_LE_L((fat_fd->fat_file_size));
203d6ec: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
203d6f0: 85 30 60 10 srl %g1, 0x10, %g2 <== NOT EXECUTED
203d6f4: 89 28 60 18 sll %g1, 0x18, %g4 <== NOT EXECUTED
203d6f8: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
203d6fc: 88 11 00 03 or %g4, %g3, %g4 <== NOT EXECUTED
203d700: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
203d704: 87 30 60 08 srl %g1, 8, %g3 <== NOT EXECUTED
203d708: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
203d70c: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203d710: 82 11 00 03 or %g4, %g3, %g1 <== NOT EXECUTED
203d714: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_SIZE_OFFSET, 4,
203d718: 94 02 a0 1c add %o2, 0x1c, %o2 <== NOT EXECUTED
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
byte = (fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
le_new_length = CT_LE_L((fat_fd->fat_file_size));
203d71c: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_SIZE_OFFSET, 4,
203d720: 96 10 20 04 mov 4, %o3 <== NOT EXECUTED
203d724: 7f ff b0 4a call 202984c <_fat_block_write> <== NOT EXECUTED
203d728: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
(char *)(&le_new_length));
if ( ret < 0 )
return -1;
return RC_OK;
}
203d72c: b1 3a 20 1f sra %o0, 0x1f, %i0 <== NOT EXECUTED
203d730: 81 c7 e0 08 ret <== NOT EXECUTED
203d734: 81 e8 00 00 restore <== NOT EXECUTED
0203d818 <msdos_set_first_char4file_name>:
msdos_set_first_char4file_name(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_dir_pos_t *dir_pos,
unsigned char fchar
)
{
203d818: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
ssize_t ret;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203d81c: c4 06 20 34 ld [ %i0 + 0x34 ], %g2 <== NOT EXECUTED
uint32_t dir_block_size;
fat_pos_t start = dir_pos->lname;
203d820: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
203d824: c6 06 60 08 ld [ %i1 + 8 ], %g3 <== NOT EXECUTED
msdos_set_first_char4file_name(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_dir_pos_t *dir_pos,
unsigned char fchar
)
{
203d828: f4 2f a0 4c stb %i2, [ %fp + 0x4c ] <== NOT EXECUTED
ssize_t ret;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t dir_block_size;
fat_pos_t start = dir_pos->lname;
203d82c: c6 27 bf f8 st %g3, [ %fp + -8 ] <== NOT EXECUTED
203d830: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
fat_pos_t end = dir_pos->sname;
203d834: e4 06 40 00 ld [ %i1 ], %l2 <== NOT EXECUTED
if ((end.cln == fs_info->fat.vol.rdir_cl) &&
203d838: c2 00 a0 38 ld [ %g2 + 0x38 ], %g1 <== NOT EXECUTED
msdos_set_first_char4file_name(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_dir_pos_t *dir_pos,
unsigned char fchar
)
{
203d83c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
ssize_t ret;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203d840: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
uint32_t dir_block_size;
fat_pos_t start = dir_pos->lname;
fat_pos_t end = dir_pos->sname;
if ((end.cln == fs_info->fat.vol.rdir_cl) &&
203d844: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
203d848: 02 80 00 5a be 203d9b0 <msdos_set_first_char4file_name+0x198><== NOT EXECUTED
203d84c: ea 06 60 04 ld [ %i1 + 4 ], %l5 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
dir_block_size = fs_info->fat.vol.rdir_size;
else
dir_block_size = fs_info->fat.vol.bpc;
if (dir_pos->lname.cln == FAT_FILE_SHORT_NAME)
203d850: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
203d854: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
203d858: 02 80 00 5d be 203d9cc <msdos_set_first_char4file_name+0x1b4><== NOT EXECUTED
203d85c: e8 10 a0 06 lduh [ %g2 + 6 ], %l4 <== NOT EXECUTED
start = dir_pos->sname;
203d860: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
203d864: c6 08 a0 02 ldub [ %g2 + 2 ], %g3 <== NOT EXECUTED
203d868: d4 10 80 00 lduh [ %g2 ], %o2 <== NOT EXECUTED
203d86c: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
203d870: a6 07 a0 4c add %fp, 0x4c, %l3 <== NOT EXECUTED
{
int rc;
if ((end.cln == fs_info->fat.vol.rdir_cl) &&
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
break;
rc = fat_get_fat_cluster(mt_entry, start.cln, &start.cln);
203d874: 10 80 00 1e b 203d8ec <msdos_set_first_char4file_name+0xd4><== NOT EXECUTED
203d878: ac 07 bf f8 add %fp, -8, %l6 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203d87c: 80 89 20 03 btst 3, %g4 <== NOT EXECUTED
203d880: 22 80 00 1f be,a 203d8fc <msdos_set_first_char4file_name+0xe4><== NOT EXECUTED
203d884: c8 00 a0 30 ld [ %g2 + 0x30 ], %g4 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
203d888: d2 00 a0 1c ld [ %g2 + 0x1c ], %o1 <== NOT EXECUTED
{
uint32_t sec = (fat_cluster_num_to_sector_num(mt_entry, start.cln) +
(start.ofs >> fs_info->fat.vol.sec_log2));
uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));;
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_NAME_OFFSET, 1,
203d88c: 85 30 40 03 srl %g1, %g3, %g2 <== NOT EXECUTED
203d890: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
203d894: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
203d898: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
203d89c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203d8a0: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
203d8a4: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203d8a8: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
203d8ac: 7f ff af e8 call 202984c <_fat_block_write> <== NOT EXECUTED
203d8b0: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
&fchar);
if (ret < 0)
203d8b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d8b8: 06 80 00 23 bl 203d944 <msdos_set_first_char4file_name+0x12c><== NOT EXECUTED
203d8bc: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
return -1;
if ((start.cln == end.cln) && (start.ofs == end.ofs))
203d8c0: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
203d8c4: 80 a2 40 12 cmp %o1, %l2 <== NOT EXECUTED
203d8c8: 02 80 00 21 be 203d94c <msdos_set_first_char4file_name+0x134><== NOT EXECUTED
203d8cc: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
break;
start.ofs += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
203d8d0: 82 00 60 20 add %g1, 0x20, %g1 <== NOT EXECUTED
if (start.ofs >= dir_block_size)
203d8d4: 80 a5 00 01 cmp %l4, %g1 <== NOT EXECUTED
203d8d8: 08 80 00 23 bleu 203d964 <msdos_set_first_char4file_name+0x14c><== NOT EXECUTED
203d8dc: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
203d8e0: c4 04 20 34 ld [ %l0 + 0x34 ], %g2 <== NOT EXECUTED
203d8e4: c6 0c 60 02 ldub [ %l1 + 2 ], %g3 <== NOT EXECUTED
203d8e8: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203d8ec: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
203d8f0: 22 bf ff e3 be,a 203d87c <msdos_set_first_char4file_name+0x64><== NOT EXECUTED
203d8f4: c8 08 a0 0a ldub [ %g2 + 0xa ], %g4 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
203d8f8: c8 00 a0 30 ld [ %g2 + 0x30 ], %g4 <== NOT EXECUTED
203d8fc: c4 08 a0 05 ldub [ %g2 + 5 ], %g2 <== NOT EXECUTED
203d900: 92 02 7f fe add %o1, -2, %o1 <== NOT EXECUTED
203d904: 93 2a 40 02 sll %o1, %g2, %o1 <== NOT EXECUTED
{
uint32_t sec = (fat_cluster_num_to_sector_num(mt_entry, start.cln) +
(start.ofs >> fs_info->fat.vol.sec_log2));
uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));;
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_NAME_OFFSET, 1,
203d908: 85 30 40 03 srl %g1, %g3, %g2 <== NOT EXECUTED
203d90c: 92 02 40 04 add %o1, %g4, %o1 <== NOT EXECUTED
203d910: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
203d914: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
203d918: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
203d91c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203d920: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED
203d924: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203d928: 94 0a 80 01 and %o2, %g1, %o2 <== NOT EXECUTED
203d92c: 7f ff af c8 call 202984c <_fat_block_write> <== NOT EXECUTED
203d930: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
&fchar);
if (ret < 0)
203d934: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d938: 16 bf ff e3 bge 203d8c4 <msdos_set_first_char4file_name+0xac><== NOT EXECUTED
203d93c: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
break;
rc = fat_get_fat_cluster(mt_entry, start.cln, &start.cln);
if ( rc != RC_OK )
return rc;
start.ofs = 0;
203d940: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
}
}
return RC_OK;
}
203d944: 81 c7 e0 08 ret <== NOT EXECUTED
203d948: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
ret = _fat_block_write(mt_entry, sec, byte + MSDOS_FILE_NAME_OFFSET, 1,
&fchar);
if (ret < 0)
return -1;
if ((start.cln == end.cln) && (start.ofs == end.ofs))
203d94c: 80 a0 40 15 cmp %g1, %l5 <== NOT EXECUTED
203d950: 32 bf ff e1 bne,a 203d8d4 <msdos_set_first_char4file_name+0xbc><== NOT EXECUTED
203d954: 82 00 60 20 add %g1, 0x20, %g1 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
break;
rc = fat_get_fat_cluster(mt_entry, start.cln, &start.cln);
if ( rc != RC_OK )
return rc;
start.ofs = 0;
203d958: 90 10 20 00 clr %o0 <== NOT EXECUTED
}
}
return RC_OK;
}
203d95c: 81 c7 e0 08 ret <== NOT EXECUTED
203d960: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
start.ofs += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
if (start.ofs >= dir_block_size)
{
int rc;
if ((end.cln == fs_info->fat.vol.rdir_cl) &&
203d964: c2 04 60 38 ld [ %l1 + 0x38 ], %g1 <== NOT EXECUTED
203d968: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
203d96c: 12 80 00 06 bne 203d984 <msdos_set_first_char4file_name+0x16c><== NOT EXECUTED
203d970: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
203d974: c2 0c 60 0a ldub [ %l1 + 0xa ], %g1 <== NOT EXECUTED
203d978: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
203d97c: 32 bf ff f8 bne,a 203d95c <msdos_set_first_char4file_name+0x144><== NOT EXECUTED
203d980: 90 10 20 00 clr %o0 <== NOT EXECUTED
break;
rc = fat_get_fat_cluster(mt_entry, start.cln, &start.cln);
203d984: 40 00 1e 20 call 2045204 <fat_get_fat_cluster> <== NOT EXECUTED
203d988: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
if ( rc != RC_OK )
203d98c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d990: 12 bf ff ed bne 203d944 <msdos_set_first_char4file_name+0x12c><== NOT EXECUTED
203d994: 82 10 20 00 clr %g1 <== NOT EXECUTED
return rc;
start.ofs = 0;
203d998: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
203d99c: c4 04 20 34 ld [ %l0 + 0x34 ], %g2 <== NOT EXECUTED
203d9a0: c6 0c 60 02 ldub [ %l1 + 2 ], %g3 <== NOT EXECUTED
203d9a4: d4 14 40 00 lduh [ %l1 ], %o2 <== NOT EXECUTED
203d9a8: 10 bf ff d1 b 203d8ec <msdos_set_first_char4file_name+0xd4><== NOT EXECUTED
203d9ac: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
uint32_t dir_block_size;
fat_pos_t start = dir_pos->lname;
fat_pos_t end = dir_pos->sname;
if ((end.cln == fs_info->fat.vol.rdir_cl) &&
(fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))
203d9b0: c2 08 a0 0a ldub [ %g2 + 0xa ], %g1 <== NOT EXECUTED
203d9b4: 80 88 60 03 btst 3, %g1 <== NOT EXECUTED
203d9b8: 02 bf ff a7 be 203d854 <msdos_set_first_char4file_name+0x3c><== NOT EXECUTED
203d9bc: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
dir_block_size = fs_info->fat.vol.rdir_size;
else
dir_block_size = fs_info->fat.vol.bpc;
if (dir_pos->lname.cln == FAT_FILE_SHORT_NAME)
203d9c0: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
203d9c4: 12 bf ff a7 bne 203d860 <msdos_set_first_char4file_name+0x48><== NOT EXECUTED
203d9c8: e8 00 a0 28 ld [ %g2 + 0x28 ], %l4 <== NOT EXECUTED
start = dir_pos->sname;
203d9cc: c6 06 60 04 ld [ %i1 + 4 ], %g3 <== NOT EXECUTED
203d9d0: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
203d9d4: c6 27 bf fc st %g3, [ %fp + -4 ] <== NOT EXECUTED
203d9d8: 10 bf ff a2 b 203d860 <msdos_set_first_char4file_name+0x48><== NOT EXECUTED
203d9dc: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
0203d738 <msdos_set_first_cluster_num>:
int
msdos_set_first_cluster_num(
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
203d738: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
203d73c: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
rtems_filesystem_mount_table_entry_t *mt_entry,
fat_file_fd_t *fat_fd
)
{
ssize_t ret1 = 0, ret2 = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
203d740: c4 06 20 34 ld [ %i0 + 0x34 ], %g2 <== NOT EXECUTED
uint32_t cln
)
{
register fat_fs_info_t *fs_info = mt_entry->fs_info;
if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
203d744: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203d748: 12 80 00 06 bne 203d760 <msdos_set_first_cluster_num+0x28><== NOT EXECUTED
203d74c: e4 06 60 1c ld [ %i1 + 0x1c ], %l2 <== NOT EXECUTED
203d750: c6 08 a0 0a ldub [ %g2 + 0xa ], %g3 <== NOT EXECUTED
203d754: 80 88 e0 03 btst 3, %g3 <== NOT EXECUTED
203d758: 32 80 00 07 bne,a 203d774 <msdos_set_first_cluster_num+0x3c><== NOT EXECUTED
203d75c: e2 00 a0 1c ld [ %g2 + 0x1c ], %l1 <== NOT EXECUTED
return fs_info->vol.rdir_loc;
return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +
203d760: c8 08 a0 05 ldub [ %g2 + 5 ], %g4 <== NOT EXECUTED
203d764: c6 00 a0 30 ld [ %g2 + 0x30 ], %g3 <== NOT EXECUTED
203d768: a2 00 7f fe add %g1, -2, %l1 <== NOT EXECUTED
203d76c: a3 2c 40 04 sll %l1, %g4, %l1 <== NOT EXECUTED
203d770: a2 04 40 03 add %l1, %g3, %l1 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d774: c2 08 a0 02 ldub [ %g2 + 2 ], %g1 <== NOT EXECUTED
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
203d778: e0 10 80 00 lduh [ %g2 ], %l0 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d77c: c6 06 60 24 ld [ %i1 + 0x24 ], %g3 <== NOT EXECUTED
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
203d780: a0 04 3f ff add %l0, -1, %l0 <== NOT EXECUTED
203d784: a0 0c 00 03 and %l0, %g3, %l0 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d788: 87 30 c0 01 srl %g3, %g1, %g3 <== NOT EXECUTED
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
203d78c: 83 2c a0 10 sll %l2, 0x10, %g1 <== NOT EXECUTED
203d790: 85 30 60 18 srl %g1, 0x18, %g2 <== NOT EXECUTED
203d794: 83 30 60 08 srl %g1, 8, %g1 <== NOT EXECUTED
203d798: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
/*
* calculate input for _fat_block_write: convert (cluster num, offset) to
* (sector num, new offset)
*/
sec = fat_cluster_num_to_sector_num(mt_entry, fat_fd->dir_pos.sname.cln);
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
203d79c: a2 04 40 03 add %l1, %g3, %l1 <== NOT EXECUTED
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
203d7a0: c2 37 bf fe sth %g1, [ %fp + -2 ] <== NOT EXECUTED
ret1 = _fat_block_write(mt_entry, sec,
203d7a4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203d7a8: 94 04 20 1a add %l0, 0x1a, %o2 <== NOT EXECUTED
203d7ac: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
203d7b0: 98 07 bf fe add %fp, -2, %o4 <== NOT EXECUTED
{
ssize_t ret1 = 0, ret2 = 0;
msdos_fs_info_t *fs_info = mt_entry->fs_info;
uint32_t new_cln = fat_fd->cln;
uint16_t le_cl_low = 0;
uint16_t le_cl_hi = 0;
203d7b4: c0 37 bf fc clrh [ %fp + -4 ] <== NOT EXECUTED
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
ret1 = _fat_block_write(mt_entry, sec,
203d7b8: 7f ff b0 25 call 202984c <_fat_block_write> <== NOT EXECUTED
203d7bc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
byte + MSDOS_FIRST_CLUSTER_LOW_OFFSET, 2,
(char *)(&le_cl_low));
le_cl_hi = CT_LE_W((uint16_t )((new_cln & 0xFFFF0000) >> 16));
203d7c0: a5 34 a0 10 srl %l2, 0x10, %l2 <== NOT EXECUTED
203d7c4: a5 2c a0 10 sll %l2, 0x10, %l2 <== NOT EXECUTED
203d7c8: 83 34 a0 18 srl %l2, 0x18, %g1 <== NOT EXECUTED
sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
/* byte from points to start of 32bytes structure */
byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
ret1 = _fat_block_write(mt_entry, sec,
203d7cc: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
byte + MSDOS_FIRST_CLUSTER_LOW_OFFSET, 2,
(char *)(&le_cl_low));
le_cl_hi = CT_LE_W((uint16_t )((new_cln & 0xFFFF0000) >> 16));
ret2 = _fat_block_write(mt_entry, sec,
203d7d0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203d7d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203d7d8: 94 04 20 14 add %l0, 0x14, %o2 <== NOT EXECUTED
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
ret1 = _fat_block_write(mt_entry, sec,
byte + MSDOS_FIRST_CLUSTER_LOW_OFFSET, 2,
(char *)(&le_cl_low));
le_cl_hi = CT_LE_W((uint16_t )((new_cln & 0xFFFF0000) >> 16));
203d7dc: a5 34 a0 08 srl %l2, 8, %l2 <== NOT EXECUTED
ret2 = _fat_block_write(mt_entry, sec,
203d7e0: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
le_cl_low = CT_LE_W((uint16_t )(new_cln & 0x0000FFFF));
ret1 = _fat_block_write(mt_entry, sec,
byte + MSDOS_FIRST_CLUSTER_LOW_OFFSET, 2,
(char *)(&le_cl_low));
le_cl_hi = CT_LE_W((uint16_t )((new_cln & 0xFFFF0000) >> 16));
203d7e4: a4 14 80 01 or %l2, %g1, %l2 <== NOT EXECUTED
ret2 = _fat_block_write(mt_entry, sec,
203d7e8: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
203d7ec: 7f ff b0 18 call 202984c <_fat_block_write> <== NOT EXECUTED
203d7f0: e4 37 bf fc sth %l2, [ %fp + -4 ] <== NOT EXECUTED
byte + MSDOS_FIRST_CLUSTER_HI_OFFSET, 2,
(char *)(&le_cl_hi));
if ( (ret1 < 0) || (ret2 < 0) )
203d7f4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203d7f8: 06 80 00 06 bl 203d810 <msdos_set_first_cluster_num+0xd8> <== NOT EXECUTED
203d7fc: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
203d800: 06 80 00 04 bl 203d810 <msdos_set_first_cluster_num+0xd8> <== NOT EXECUTED
203d804: b0 10 20 00 clr %i0 <== NOT EXECUTED
return -1;
return RC_OK;
}
203d808: 81 c7 e0 08 ret <== NOT EXECUTED
203d80c: 81 e8 00 00 restore <== NOT EXECUTED
203d810: 81 c7 e0 08 ret <== NOT EXECUTED
203d814: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
0203c980 <msdos_shut_down>:
* RC_OK on success, or -1 if error occured (errno set apropriately).
*
*/
int
msdos_shut_down(rtems_filesystem_mount_table_entry_t *temp_mt_entry)
{
203c980: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = RC_OK;
msdos_fs_info_t *fs_info = temp_mt_entry->fs_info;
fat_file_fd_t *fat_fd = temp_mt_entry->mt_fs_root.node_access;
/* close fat-file which correspondes to root directory */
if (fat_file_close(temp_mt_entry, fat_fd) != RC_OK)
203c984: d2 06 20 1c ld [ %i0 + 0x1c ], %o1 <== NOT EXECUTED
*/
int
msdos_shut_down(rtems_filesystem_mount_table_entry_t *temp_mt_entry)
{
int rc = RC_OK;
msdos_fs_info_t *fs_info = temp_mt_entry->fs_info;
203c988: e2 06 20 34 ld [ %i0 + 0x34 ], %l1 <== NOT EXECUTED
fat_file_fd_t *fat_fd = temp_mt_entry->mt_fs_root.node_access;
/* close fat-file which correspondes to root directory */
if (fat_file_close(temp_mt_entry, fat_fd) != RC_OK)
203c98c: 7f ff b1 92 call 2028fd4 <fat_file_close> <== NOT EXECUTED
203c990: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203c994: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
* RC_OK on success, or -1 if error occured (errno set apropriately).
*
*/
int
msdos_shut_down(rtems_filesystem_mount_table_entry_t *temp_mt_entry)
{
203c998: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc = RC_OK;
msdos_fs_info_t *fs_info = temp_mt_entry->fs_info;
fat_file_fd_t *fat_fd = temp_mt_entry->mt_fs_root.node_access;
/* close fat-file which correspondes to root directory */
if (fat_file_close(temp_mt_entry, fat_fd) != RC_OK)
203c99c: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
{
/* no return - try to free as much as possible */
rc = -1;
}
if (fat_shutdown_drive(temp_mt_entry) != RC_OK)
203c9a0: 7f ff b4 0a call 20299c8 <fat_shutdown_drive> <== NOT EXECUTED
203c9a4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203c9a8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203c9ac: 32 80 00 02 bne,a 203c9b4 <msdos_shut_down+0x34> <== NOT EXECUTED
203c9b0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
/* no return - try to free as much as possible */
rc = -1;
}
rtems_semaphore_delete(fs_info->vol_sema);
203c9b4: 7f ff 42 db call 200d520 <rtems_semaphore_delete> <== NOT EXECUTED
203c9b8: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
free(fs_info->cl_buf);
203c9bc: 7f ff 2f c8 call 20088dc <free> <== NOT EXECUTED
203c9c0: d0 04 60 9c ld [ %l1 + 0x9c ], %o0 <== NOT EXECUTED
free(temp_mt_entry->fs_info);
203c9c4: 7f ff 2f c6 call 20088dc <free> <== NOT EXECUTED
203c9c8: d0 04 20 34 ld [ %l0 + 0x34 ], %o0 <== NOT EXECUTED
return rc;
}
203c9cc: 81 c7 e0 08 ret <== NOT EXECUTED
203c9d0: 81 e8 00 00 restore <== NOT EXECUTED
0202bb4c <nanosleep>:
int nanosleep(
const struct timespec *rqtp,
struct timespec *rmtp
)
{
202bb4c: 9d e3 bf a0 save %sp, -96, %sp
Watchdog_Interval ticks;
if ( !_Timespec_Is_valid( rqtp ) )
202bb50: 40 00 00 67 call 202bcec <_Timespec_Is_valid>
202bb54: 90 10 00 18 mov %i0, %o0
202bb58: 80 8a 20 ff btst 0xff, %o0
202bb5c: 02 80 00 43 be 202bc68 <nanosleep+0x11c>
202bb60: 01 00 00 00 nop
* Return EINVAL if the delay interval is negative.
*
* NOTE: This behavior is beyond the POSIX specification.
* FSU and GNU/Linux pthreads shares this behavior.
*/
if ( rqtp->tv_sec < 0 || rqtp->tv_nsec < 0 )
202bb64: c2 06 00 00 ld [ %i0 ], %g1
202bb68: 80 a0 60 00 cmp %g1, 0
202bb6c: 06 80 00 3f bl 202bc68 <nanosleep+0x11c> <== NEVER TAKEN
202bb70: 01 00 00 00 nop
202bb74: c2 06 20 04 ld [ %i0 + 4 ], %g1
202bb78: 80 a0 60 00 cmp %g1, 0
202bb7c: 06 80 00 3b bl 202bc68 <nanosleep+0x11c> <== NEVER TAKEN
202bb80: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
ticks = _Timespec_To_ticks( rqtp );
202bb84: 7f ff b2 8a call 20185ac <_Timespec_To_ticks>
202bb88: 90 10 00 18 mov %i0, %o0
* A nanosleep for zero time is implemented as a yield.
* This behavior is also beyond the POSIX specification but is
* consistent with the RTEMS API and yields desirable behavior.
*/
if ( !ticks ) {
202bb8c: b0 92 20 00 orcc %o0, 0, %i0
202bb90: 02 80 00 28 be 202bc30 <nanosleep+0xe4>
202bb94: 03 00 80 c8 sethi %hi(0x2032000), %g1
202bb98: c4 00 60 d0 ld [ %g1 + 0xd0 ], %g2 ! 20320d0 <_Thread_Dispatch_disable_level>
202bb9c: 84 00 a0 01 inc %g2
202bba0: c4 20 60 d0 st %g2, [ %g1 + 0xd0 ]
/*
* Block for the desired amount of time
*/
_Thread_Disable_dispatch();
_Thread_Set_state(
202bba4: 21 00 80 c8 sethi %hi(0x2032000), %l0
202bba8: d0 04 21 90 ld [ %l0 + 0x190 ], %o0 ! 2032190 <_Thread_Executing>
202bbac: 13 04 00 00 sethi %hi(0x10000000), %o1
202bbb0: 7f ff 8f d2 call 200faf8 <_Thread_Set_state>
202bbb4: 92 12 60 08 or %o1, 8, %o1 ! 10000008 <RAM_END+0xdc00008>
_Thread_Executing,
STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL
);
_Watchdog_Initialize(
&_Thread_Executing->Timer,
202bbb8: c2 04 21 90 ld [ %l0 + 0x190 ], %g1
202bbbc: 11 00 80 c8 sethi %hi(0x2032000), %o0
_Thread_Disable_dispatch();
_Thread_Set_state(
_Thread_Executing,
STATES_DELAYING | STATES_INTERRUPTIBLE_BY_SIGNAL
);
_Watchdog_Initialize(
202bbc0: c4 00 60 08 ld [ %g1 + 8 ], %g2
202bbc4: 90 12 21 b0 or %o0, 0x1b0, %o0
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
the_watchdog->id = id;
202bbc8: c4 20 60 68 st %g2, [ %g1 + 0x68 ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
202bbcc: 92 00 60 48 add %g1, 0x48, %o1
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
202bbd0: 05 00 80 3b sethi %hi(0x200ec00), %g2
202bbd4: 84 10 a2 78 or %g2, 0x278, %g2 ! 200ee78 <_Thread_Delay_ended>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
202bbd8: c0 20 60 50 clr [ %g1 + 0x50 ]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
202bbdc: c0 20 60 6c clr [ %g1 + 0x6c ]
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
202bbe0: f0 20 60 54 st %i0, [ %g1 + 0x54 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
202bbe4: 7f ff 91 fb call 20103d0 <_Watchdog_Insert>
202bbe8: c4 20 60 64 st %g2, [ %g1 + 0x64 ]
_Thread_Delay_ended,
_Thread_Executing->Object.id,
NULL
);
_Watchdog_Insert_ticks( &_Thread_Executing->Timer, ticks );
_Thread_Enable_dispatch();
202bbec: 7f ff 8d 1b call 200f058 <_Thread_Enable_dispatch>
202bbf0: 01 00 00 00 nop
/* calculate time remaining */
if ( rmtp ) {
202bbf4: 80 a6 60 00 cmp %i1, 0
202bbf8: 02 80 00 0c be 202bc28 <nanosleep+0xdc>
202bbfc: c2 04 21 90 ld [ %l0 + 0x190 ], %g1
ticks -=
_Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time;
_Timespec_From_ticks( ticks, rmtp );
202bc00: 92 10 00 19 mov %i1, %o1
_Thread_Enable_dispatch();
/* calculate time remaining */
if ( rmtp ) {
ticks -=
202bc04: c4 00 60 60 ld [ %g1 + 0x60 ], %g2
202bc08: c2 00 60 5c ld [ %g1 + 0x5c ], %g1
202bc0c: 82 20 40 02 sub %g1, %g2, %g1
202bc10: b0 00 40 18 add %g1, %i0, %i0
_Thread_Executing->Timer.stop_time - _Thread_Executing->Timer.start_time;
_Timespec_From_ticks( ticks, rmtp );
202bc14: 40 00 00 21 call 202bc98 <_Timespec_From_ticks>
202bc18: 90 10 00 18 mov %i0, %o0
*/
#if defined(RTEMS_POSIX_API)
/*
* If there is time remaining, then we were interrupted by a signal.
*/
if ( ticks )
202bc1c: 80 a6 20 00 cmp %i0, 0
202bc20: 12 80 00 18 bne 202bc80 <nanosleep+0x134>
202bc24: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINTR );
#endif
}
return 0;
}
202bc28: 81 c7 e0 08 ret
202bc2c: 91 e8 20 00 restore %g0, 0, %o0
202bc30: c4 00 60 d0 ld [ %g1 + 0xd0 ], %g2
202bc34: 84 00 a0 01 inc %g2
202bc38: c4 20 60 d0 st %g2, [ %g1 + 0xd0 ]
* consistent with the RTEMS API and yields desirable behavior.
*/
if ( !ticks ) {
_Thread_Disable_dispatch();
_Thread_Yield_processor();
202bc3c: 7f ff 90 b3 call 200ff08 <_Thread_Yield_processor>
202bc40: 01 00 00 00 nop
_Thread_Enable_dispatch();
202bc44: 7f ff 8d 05 call 200f058 <_Thread_Enable_dispatch>
202bc48: 01 00 00 00 nop
if ( rmtp ) {
202bc4c: 80 a6 60 00 cmp %i1, 0
202bc50: 02 bf ff f6 be 202bc28 <nanosleep+0xdc>
202bc54: 01 00 00 00 nop
rmtp->tv_sec = 0;
rmtp->tv_nsec = 0;
202bc58: c0 26 60 04 clr [ %i1 + 4 ]
if ( !ticks ) {
_Thread_Disable_dispatch();
_Thread_Yield_processor();
_Thread_Enable_dispatch();
if ( rmtp ) {
rmtp->tv_sec = 0;
202bc5c: c0 26 40 00 clr [ %i1 ]
202bc60: 81 c7 e0 08 ret
202bc64: 81 e8 00 00 restore
*
* NOTE: This behavior is beyond the POSIX specification.
* FSU and GNU/Linux pthreads shares this behavior.
*/
if ( rqtp->tv_sec < 0 || rqtp->tv_nsec < 0 )
rtems_set_errno_and_return_minus_one( EINVAL );
202bc68: 7f ff c1 a9 call 201c30c <__errno>
202bc6c: b0 10 3f ff mov -1, %i0
202bc70: 82 10 20 16 mov 0x16, %g1
202bc74: c2 22 00 00 st %g1, [ %o0 ]
202bc78: 81 c7 e0 08 ret
202bc7c: 81 e8 00 00 restore
#if defined(RTEMS_POSIX_API)
/*
* If there is time remaining, then we were interrupted by a signal.
*/
if ( ticks )
rtems_set_errno_and_return_minus_one( EINTR );
202bc80: 7f ff c1 a3 call 201c30c <__errno>
202bc84: b0 10 3f ff mov -1, %i0
202bc88: 82 10 20 04 mov 4, %g1
202bc8c: c2 22 00 00 st %g1, [ %o0 ]
202bc90: 81 c7 e0 08 ret
202bc94: 81 e8 00 00 restore
020036c0 <newlib_delete_hook>:
void newlib_delete_hook(
rtems_tcb *current_task,
rtems_tcb *deleted_task
)
{
20036c0: 9d e3 bf a0 save %sp, -96, %sp
/*
* The reentrancy structure was allocated by newlib using malloc()
*/
if (current_task == deleted_task) {
20036c4: 80 a6 00 19 cmp %i0, %i1
20036c8: 02 80 00 16 be 2003720 <newlib_delete_hook+0x60>
20036cc: 03 00 80 7a sethi %hi(0x201e800), %g1
ptr = _REENT;
} else {
ptr = deleted_task->libc_reent;
20036d0: e0 06 61 64 ld [ %i1 + 0x164 ], %l0
}
if (ptr && ptr != _global_impure_ptr) {
20036d4: 80 a4 20 00 cmp %l0, 0
20036d8: 02 80 00 0b be 2003704 <newlib_delete_hook+0x44> <== NEVER TAKEN
20036dc: 03 00 80 78 sethi %hi(0x201e000), %g1
20036e0: c2 00 62 d0 ld [ %g1 + 0x2d0 ], %g1 ! 201e2d0 <_global_impure_ptr>
20036e4: 80 a4 00 01 cmp %l0, %g1
20036e8: 02 80 00 07 be 2003704 <newlib_delete_hook+0x44>
20036ec: 13 00 80 0d sethi %hi(0x2003400), %o1
_reclaim_reent(ptr);
*/
/*
* Just in case there are some buffers lying around.
*/
_fwalk(ptr, newlib_free_buffers);
20036f0: 90 10 00 10 mov %l0, %o0
20036f4: 40 00 3a dc call 2012264 <_fwalk>
20036f8: 92 12 63 28 or %o1, 0x328, %o1
#if REENT_MALLOCED
free(ptr);
#else
_Workspace_Free(ptr);
20036fc: 40 00 1b 38 call 200a3dc <_Workspace_Free>
2003700: 90 10 00 10 mov %l0, %o0
/*
* Require the switch back to another task to install its own
*/
if ( current_task == deleted_task ) {
2003704: 80 a6 00 19 cmp %i0, %i1
2003708: 12 80 00 04 bne 2003718 <newlib_delete_hook+0x58>
200370c: c0 26 61 64 clr [ %i1 + 0x164 ]
_REENT = 0;
2003710: 03 00 80 7a sethi %hi(0x201e800), %g1
2003714: c0 20 62 30 clr [ %g1 + 0x230 ] ! 201ea30 <_impure_ptr>
2003718: 81 c7 e0 08 ret
200371c: 81 e8 00 00 restore
/*
* The reentrancy structure was allocated by newlib using malloc()
*/
if (current_task == deleted_task) {
ptr = _REENT;
2003720: 10 bf ff ed b 20036d4 <newlib_delete_hook+0x14>
2003724: e0 00 62 30 ld [ %g1 + 0x230 ], %l0
02003728 <newlib_free_buffers>:
*/
int newlib_free_buffers(
FILE *fp
)
{
2003728: 9d e3 bf a0 save %sp, -96, %sp
switch ( fileno(fp) ) {
200372c: 40 00 39 ce call 2011e64 <fileno>
2003730: 90 10 00 18 mov %i0, %o0
2003734: 80 a2 20 02 cmp %o0, 2
2003738: 28 80 00 06 bleu,a 2003750 <newlib_free_buffers+0x28> <== ALWAYS TAKEN
200373c: c2 16 20 0c lduh [ %i0 + 0xc ], %g1
fp->_flags &= ~__SMBF;
fp->_bf._base = fp->_p = (unsigned char *) NULL;
}
break;
default:
fclose(fp);
2003740: 40 00 39 07 call 2011b5c <fclose> <== NOT EXECUTED
2003744: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
}
return 0;
}
2003748: 81 c7 e0 08 ret
200374c: 91 e8 20 00 restore %g0, 0, %o0
{
switch ( fileno(fp) ) {
case 0:
case 1:
case 2:
if (fp->_flags & __SMBF) {
2003750: 80 88 60 80 btst 0x80, %g1
2003754: 02 bf ff fd be 2003748 <newlib_free_buffers+0x20> <== ALWAYS TAKEN
2003758: 01 00 00 00 nop
free( fp->_bf._base );
200375c: 7f ff fd 64 call 2002cec <free> <== NOT EXECUTED
2003760: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
fp->_flags &= ~__SMBF;
2003764: c2 16 20 0c lduh [ %i0 + 0xc ], %g1 <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
2003768: 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;
200376c: 82 08 7f 7f and %g1, -129, %g1 <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
2003770: 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;
2003774: c2 36 20 0c sth %g1, [ %i0 + 0xc ] <== NOT EXECUTED
break;
default:
fclose(fp);
}
return 0;
}
2003778: 81 c7 e0 08 ret <== NOT EXECUTED
200377c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02002fa0 <null_initialize>:
rtems_device_driver null_initialize(
rtems_device_major_number major,
rtems_device_minor_number minor __attribute__((unused)),
void *pargp __attribute__((unused))
)
{
2002fa0: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_driver status;
if ( !initialized ) {
2002fa4: 03 00 80 90 sethi %hi(0x2024000), %g1
2002fa8: c4 48 60 c0 ldsb [ %g1 + 0xc0 ], %g2 ! 20240c0 <initialized>
2002fac: 80 a0 a0 00 cmp %g2, 0
2002fb0: 02 80 00 04 be 2002fc0 <null_initialize+0x20>
2002fb4: 84 10 20 01 mov 1, %g2
NULL_major = major;
}
return RTEMS_SUCCESSFUL;
}
2002fb8: 81 c7 e0 08 ret
2002fbc: 91 e8 20 00 restore %g0, 0, %o0
rtems_device_driver status;
if ( !initialized ) {
initialized = 1;
status = rtems_io_register_name(
2002fc0: 11 00 80 86 sethi %hi(0x2021800), %o0
)
{
rtems_device_driver status;
if ( !initialized ) {
initialized = 1;
2002fc4: c4 28 60 c0 stb %g2, [ %g1 + 0xc0 ]
status = rtems_io_register_name(
2002fc8: 90 12 21 60 or %o0, 0x160, %o0
2002fcc: 92 10 00 18 mov %i0, %o1
2002fd0: 40 00 01 ce call 2003708 <rtems_io_register_name>
2002fd4: 94 10 20 00 clr %o2
"/dev/null",
major,
(rtems_device_minor_number) 0
);
if (status != RTEMS_SUCCESSFUL)
2002fd8: 80 a2 20 00 cmp %o0, 0
2002fdc: 12 80 00 05 bne 2002ff0 <null_initialize+0x50> <== NEVER TAKEN
2002fe0: 03 00 80 90 sethi %hi(0x2024000), %g1
rtems_fatal_error_occurred(status);
NULL_major = major;
2002fe4: f0 20 63 70 st %i0, [ %g1 + 0x370 ] ! 2024370 <NULL_major>
}
return RTEMS_SUCCESSFUL;
}
2002fe8: 81 c7 e0 08 ret
2002fec: 91 e8 20 00 restore %g0, 0, %o0
major,
(rtems_device_minor_number) 0
);
if (status != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred(status);
2002ff0: 40 00 14 00 call 2007ff0 <rtems_fatal_error_occurred> <== NOT EXECUTED
02002f7c <null_write>:
void *pargp
)
{
rtems_libio_rw_args_t *rw_args = (rtems_libio_rw_args_t *) pargp;
if ( rw_args )
2002f7c: 80 a2 a0 00 cmp %o2, 0
2002f80: 02 80 00 04 be 2002f90 <null_write+0x14> <== ALWAYS TAKEN
2002f84: 01 00 00 00 nop
rw_args->bytes_moved = rw_args->count;
2002f88: c2 02 a0 14 ld [ %o2 + 0x14 ], %g1 <== NOT EXECUTED
2002f8c: c2 22 a0 1c st %g1, [ %o2 + 0x1c ] <== NOT EXECUTED
return NULL_SUCCESSFUL;
}
2002f90: 81 c3 e0 08 retl
2002f94: 90 10 20 00 clr %o0
020039c8 <open>:
int open(
const char *pathname,
int flags,
...
)
{
20039c8: 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);
20039cc: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
20039d0: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
20039d4: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
20039d8: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
/*
* Set the Evaluation flags
*/
eval_flags = 0;
status = flags + 1;
20039dc: a2 06 60 01 add %i1, 1, %l1
if ( ( status & _FREAD ) == _FREAD )
eval_flags |= RTEMS_LIBIO_PERMS_READ;
if ( ( status & _FWRITE ) == _FWRITE )
20039e0: 80 8c 60 02 btst 2, %l1
* Set the Evaluation flags
*/
eval_flags = 0;
status = flags + 1;
if ( ( status & _FREAD ) == _FREAD )
20039e4: a2 0c 60 01 and %l1, 1, %l1
eval_flags |= RTEMS_LIBIO_PERMS_READ;
if ( ( status & _FWRITE ) == _FWRITE )
20039e8: 02 80 00 03 be 20039f4 <open+0x2c>
20039ec: a3 2c 60 02 sll %l1, 2, %l1
eval_flags |= RTEMS_LIBIO_PERMS_WRITE;
20039f0: a2 14 60 02 or %l1, 2, %l1
va_start(ap, flags);
mode = va_arg( ap, int );
20039f4: 82 07 a0 50 add %fp, 0x50, %g1
20039f8: e4 07 a0 4c ld [ %fp + 0x4c ], %l2
20039fc: 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();
2003a00: 40 00 24 c5 call 200cd14 <rtems_libio_allocate>
2003a04: a6 10 20 17 mov 0x17, %l3
if ( iop == 0 ) {
2003a08: a0 92 20 00 orcc %o0, 0, %l0
2003a0c: 02 80 00 6c be 2003bbc <open+0x1f4>
2003a10: 01 00 00 00 nop
/*
* See if the file exists.
*/
status = rtems_filesystem_evaluate_path(
2003a14: 40 00 3b c7 call 2012930 <strlen>
2003a18: 90 10 00 18 mov %i0, %o0
2003a1c: 94 10 00 11 mov %l1, %o2
2003a20: 92 10 00 08 mov %o0, %o1
2003a24: a2 07 bf e8 add %fp, -24, %l1
2003a28: 90 10 00 18 mov %i0, %o0
2003a2c: 96 10 00 11 mov %l1, %o3
2003a30: 7f ff fc 90 call 2002c70 <rtems_filesystem_evaluate_path>
2003a34: 98 10 20 01 mov 1, %o4
pathname, strlen( pathname ), eval_flags, &loc, true );
if ( status == -1 ) {
2003a38: 80 a2 3f ff cmp %o0, -1
2003a3c: 02 80 00 65 be 2003bd0 <open+0x208>
2003a40: 82 0e 6a 00 and %i1, 0xa00, %g1
if ( status != 0 ) { /* The file did not exist */
rc = EACCES;
goto done;
}
} else if ((flags & (O_EXCL|O_CREAT)) == (O_EXCL|O_CREAT)) {
2003a44: a8 10 00 11 mov %l1, %l4
2003a48: 80 a0 6a 00 cmp %g1, 0xa00
2003a4c: 02 80 00 4a be 2003b74 <open+0x1ac>
2003a50: 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;
2003a54: c2 07 bf f0 ld [ %fp + -16 ], %g1
iop->file_info = loc.node_access;
iop->flags |= rtems_libio_fcntl_flags( flags );
2003a58: e6 04 20 18 ld [ %l0 + 0x18 ], %l3
/*
* Fill in the file control block based on the loc structure
* returned by successful path evaluation.
*/
iop->handlers = loc.handlers;
2003a5c: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
iop->file_info = loc.node_access;
2003a60: c2 07 bf e8 ld [ %fp + -24 ], %g1
iop->flags |= rtems_libio_fcntl_flags( flags );
2003a64: 90 10 00 19 mov %i1, %o0
2003a68: 40 00 24 ec call 200ce18 <rtems_libio_fcntl_flags>
2003a6c: c2 24 20 3c st %g1, [ %l0 + 0x3c ]
iop->pathinfo = loc;
2003a70: c4 07 bf e8 ld [ %fp + -24 ], %g2
if ( !iop->handlers || !iop->handlers->open_h ) {
2003a74: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
*/
iop->handlers = loc.handlers;
iop->file_info = loc.node_access;
iop->flags |= rtems_libio_fcntl_flags( flags );
iop->pathinfo = loc;
2003a78: c4 24 20 1c st %g2, [ %l0 + 0x1c ]
2003a7c: c4 07 bf ec ld [ %fp + -20 ], %g2
* returned by successful path evaluation.
*/
iop->handlers = loc.handlers;
iop->file_info = loc.node_access;
iop->flags |= rtems_libio_fcntl_flags( flags );
2003a80: 90 12 00 13 or %o0, %l3, %o0
iop->pathinfo = loc;
2003a84: c4 24 20 20 st %g2, [ %l0 + 0x20 ]
2003a88: c4 07 bf f0 ld [ %fp + -16 ], %g2
* returned by successful path evaluation.
*/
iop->handlers = loc.handlers;
iop->file_info = loc.node_access;
iop->flags |= rtems_libio_fcntl_flags( flags );
2003a8c: d0 24 20 18 st %o0, [ %l0 + 0x18 ]
iop->pathinfo = loc;
2003a90: c4 24 20 24 st %g2, [ %l0 + 0x24 ]
2003a94: c4 07 bf f4 ld [ %fp + -12 ], %g2
if ( !iop->handlers || !iop->handlers->open_h ) {
2003a98: 80 a0 60 00 cmp %g1, 0
*/
iop->handlers = loc.handlers;
iop->file_info = loc.node_access;
iop->flags |= rtems_libio_fcntl_flags( flags );
iop->pathinfo = loc;
2003a9c: c4 24 20 28 st %g2, [ %l0 + 0x28 ]
2003aa0: c4 07 bf f8 ld [ %fp + -8 ], %g2
if ( !iop->handlers || !iop->handlers->open_h ) {
2003aa4: 02 80 00 32 be 2003b6c <open+0x1a4> <== NEVER TAKEN
2003aa8: c4 24 20 2c st %g2, [ %l0 + 0x2c ]
2003aac: c2 00 40 00 ld [ %g1 ], %g1
2003ab0: 80 a0 60 00 cmp %g1, 0
2003ab4: 02 80 00 2e be 2003b6c <open+0x1a4> <== NEVER TAKEN
2003ab8: 92 10 00 18 mov %i0, %o1
rc = ENOTSUP;
goto done;
}
rc = (*iop->handlers->open_h)( iop, pathname, flags, mode );
2003abc: 96 10 00 12 mov %l2, %o3
2003ac0: 90 10 00 10 mov %l0, %o0
2003ac4: 9f c0 40 00 call %g1
2003ac8: 94 10 00 19 mov %i1, %o2
if ( rc ) {
2003acc: 80 a2 20 00 cmp %o0, 0
2003ad0: 12 80 00 12 bne 2003b18 <open+0x150>
2003ad4: 80 8e 64 00 btst 0x400, %i1
/*
* Optionally truncate the file.
*/
if ( (flags & O_TRUNC) == O_TRUNC ) {
2003ad8: 12 80 00 48 bne 2003bf8 <open+0x230>
2003adc: 23 00 80 7c sethi %hi(0x201f000), %l1
if ( loc_to_free )
rtems_filesystem_freenode( loc_to_free );
rtems_set_errno_and_return_minus_one( rc );
}
return iop - rtems_libio_iops;
2003ae0: c2 04 61 c4 ld [ %l1 + 0x1c4 ], %g1 ! 201f1c4 <rtems_libio_iops>
2003ae4: a0 24 00 01 sub %l0, %g1, %l0
2003ae8: a1 3c 20 03 sra %l0, 3, %l0
2003aec: 85 2c 20 06 sll %l0, 6, %g2
2003af0: 83 2c 20 03 sll %l0, 3, %g1
2003af4: 82 20 80 01 sub %g2, %g1, %g1
2003af8: 85 28 60 06 sll %g1, 6, %g2
2003afc: 82 00 40 02 add %g1, %g2, %g1
2003b00: 82 00 40 10 add %g1, %l0, %g1
2003b04: b1 28 60 0f sll %g1, 0xf, %i0
2003b08: b0 26 00 01 sub %i0, %g1, %i0
2003b0c: b1 2e 20 03 sll %i0, 3, %i0
}
2003b10: 81 c7 e0 08 ret
2003b14: 91 ee 00 10 restore %i0, %l0, %o0
goto done;
}
rc = (*iop->handlers->open_h)( iop, pathname, flags, mode );
if ( rc ) {
rc = errno;
2003b18: a8 10 00 11 mov %l1, %l4
2003b1c: 40 00 37 b8 call 20119fc <__errno>
2003b20: 01 00 00 00 nop
2003b24: e6 02 00 00 ld [ %o0 ], %l3
*/
done:
va_end(ap);
if ( rc ) {
2003b28: 80 a4 e0 00 cmp %l3, 0
2003b2c: 12 80 00 12 bne 2003b74 <open+0x1ac> <== ALWAYS TAKEN
2003b30: 23 00 80 7c sethi %hi(0x201f000), %l1
if ( loc_to_free )
rtems_filesystem_freenode( loc_to_free );
rtems_set_errno_and_return_minus_one( rc );
}
return iop - rtems_libio_iops;
2003b34: c2 04 61 c4 ld [ %l1 + 0x1c4 ], %g1 ! 201f1c4 <rtems_libio_iops><== NOT EXECUTED
2003b38: a0 24 00 01 sub %l0, %g1, %l0 <== NOT EXECUTED
2003b3c: a1 3c 20 03 sra %l0, 3, %l0 <== NOT EXECUTED
2003b40: 85 2c 20 06 sll %l0, 6, %g2 <== NOT EXECUTED
2003b44: 83 2c 20 03 sll %l0, 3, %g1 <== NOT EXECUTED
2003b48: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
2003b4c: 85 28 60 06 sll %g1, 6, %g2 <== NOT EXECUTED
2003b50: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2003b54: 82 00 40 10 add %g1, %l0, %g1 <== NOT EXECUTED
2003b58: b1 28 60 0f sll %g1, 0xf, %i0 <== NOT EXECUTED
2003b5c: b0 26 00 01 sub %i0, %g1, %i0 <== NOT EXECUTED
2003b60: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED
}
2003b64: 81 c7 e0 08 ret <== NOT EXECUTED
2003b68: 91 ee 00 10 restore %i0, %l0, %o0 <== NOT EXECUTED
if ( loc_to_free )
rtems_filesystem_freenode( loc_to_free );
rtems_set_errno_and_return_minus_one( rc );
}
return iop - rtems_libio_iops;
2003b6c: a8 10 00 11 mov %l1, %l4 <== NOT EXECUTED
2003b70: a6 10 20 86 mov 0x86, %l3 <== NOT EXECUTED
done:
va_end(ap);
if ( rc ) {
if ( iop )
2003b74: 80 a4 20 00 cmp %l0, 0
2003b78: 02 80 00 05 be 2003b8c <open+0x1c4> <== NEVER TAKEN
2003b7c: 80 a5 20 00 cmp %l4, 0
rtems_libio_free( iop );
2003b80: 40 00 24 4e call 200ccb8 <rtems_libio_free>
2003b84: 90 10 00 10 mov %l0, %o0
if ( loc_to_free )
2003b88: 80 a5 20 00 cmp %l4, 0
2003b8c: 02 80 00 0c be 2003bbc <open+0x1f4>
2003b90: 01 00 00 00 nop
rtems_filesystem_freenode( loc_to_free );
2003b94: c2 05 20 0c ld [ %l4 + 0xc ], %g1
2003b98: 80 a0 60 00 cmp %g1, 0
2003b9c: 02 80 00 08 be 2003bbc <open+0x1f4> <== NEVER TAKEN
2003ba0: 01 00 00 00 nop
2003ba4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2003ba8: 80 a0 60 00 cmp %g1, 0
2003bac: 02 80 00 04 be 2003bbc <open+0x1f4> <== NEVER TAKEN
2003bb0: 01 00 00 00 nop
2003bb4: 9f c0 40 00 call %g1
2003bb8: 90 10 00 14 mov %l4, %o0
rtems_set_errno_and_return_minus_one( rc );
2003bbc: 40 00 37 90 call 20119fc <__errno>
2003bc0: b0 10 3f ff mov -1, %i0
2003bc4: e6 22 00 00 st %l3, [ %o0 ]
2003bc8: 81 c7 e0 08 ret
2003bcc: 81 e8 00 00 restore
status = rtems_filesystem_evaluate_path(
pathname, strlen( pathname ), eval_flags, &loc, true );
if ( status == -1 ) {
if ( errno != ENOENT ) {
2003bd0: 40 00 37 8b call 20119fc <__errno>
2003bd4: 01 00 00 00 nop
2003bd8: c2 02 00 00 ld [ %o0 ], %g1
2003bdc: 80 a0 60 02 cmp %g1, 2
2003be0: 02 80 00 31 be 2003ca4 <open+0x2dc>
2003be4: 80 8e 62 00 btst 0x200, %i1
rc = errno;
2003be8: 40 00 37 85 call 20119fc <__errno>
2003bec: a8 10 20 00 clr %l4
goto done;
2003bf0: 10 bf ff ce b 2003b28 <open+0x160>
2003bf4: e6 02 00 00 ld [ %o0 ], %l3
/*
* Optionally truncate the file.
*/
if ( (flags & O_TRUNC) == O_TRUNC ) {
rc = ftruncate( iop - rtems_libio_iops, 0 );
2003bf8: c2 04 61 c4 ld [ %l1 + 0x1c4 ], %g1
2003bfc: 92 10 20 00 clr %o1
2003c00: 82 24 00 01 sub %l0, %g1, %g1
2003c04: 83 38 60 03 sra %g1, 3, %g1
2003c08: 87 28 60 06 sll %g1, 6, %g3
2003c0c: 85 28 60 03 sll %g1, 3, %g2
2003c10: 84 20 c0 02 sub %g3, %g2, %g2
2003c14: 87 28 a0 06 sll %g2, 6, %g3
2003c18: 84 00 80 03 add %g2, %g3, %g2
2003c1c: 84 00 80 01 add %g2, %g1, %g2
2003c20: 91 28 a0 0f sll %g2, 0xf, %o0
2003c24: 84 22 00 02 sub %o0, %g2, %g2
2003c28: 94 10 20 00 clr %o2
2003c2c: 91 28 a0 03 sll %g2, 3, %o0
2003c30: 40 00 23 75 call 200ca04 <ftruncate>
2003c34: 90 02 00 01 add %o0, %g1, %o0
if ( rc ) {
2003c38: a6 92 20 00 orcc %o0, 0, %l3
2003c3c: 02 bf ff aa be 2003ae4 <open+0x11c> <== ALWAYS TAKEN
2003c40: c2 04 61 c4 ld [ %l1 + 0x1c4 ], %g1
if(errno) rc = errno;
2003c44: 40 00 37 6e call 20119fc <__errno> <== NOT EXECUTED
2003c48: 01 00 00 00 nop <== NOT EXECUTED
2003c4c: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
2003c50: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2003c54: 12 80 00 2e bne 2003d0c <open+0x344> <== NOT EXECUTED
2003c58: 01 00 00 00 nop <== NOT EXECUTED
close( iop - rtems_libio_iops );
2003c5c: c2 04 61 c4 ld [ %l1 + 0x1c4 ], %g1 <== NOT EXECUTED
2003c60: a8 10 20 00 clr %l4 <== NOT EXECUTED
2003c64: 82 24 00 01 sub %l0, %g1, %g1 <== NOT EXECUTED
2003c68: 83 38 60 03 sra %g1, 3, %g1 <== NOT EXECUTED
2003c6c: 87 28 60 06 sll %g1, 6, %g3 <== NOT EXECUTED
2003c70: 85 28 60 03 sll %g1, 3, %g2 <== NOT EXECUTED
2003c74: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
2003c78: 87 28 a0 06 sll %g2, 6, %g3 <== NOT EXECUTED
2003c7c: 84 00 80 03 add %g2, %g3, %g2 <== NOT EXECUTED
2003c80: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED
2003c84: 87 28 a0 0f sll %g2, 0xf, %g3 <== NOT EXECUTED
2003c88: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
2003c8c: a0 10 20 00 clr %l0 <== NOT EXECUTED
2003c90: 91 28 a0 03 sll %g2, 3, %o0 <== NOT EXECUTED
2003c94: 40 00 23 2c call 200c944 <close> <== NOT EXECUTED
2003c98: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
*/
done:
va_end(ap);
if ( rc ) {
2003c9c: 10 bf ff a4 b 2003b2c <open+0x164> <== NOT EXECUTED
2003ca0: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
rc = errno;
goto done;
}
/* If the file does not exist and we are not trying to create it--> error */
if ( !(flags & O_CREAT) ) {
2003ca4: a8 10 20 00 clr %l4
2003ca8: 02 bf ff b3 be 2003b74 <open+0x1ac>
2003cac: a6 10 20 02 mov 2, %l3
rc = ENOENT;
goto done;
}
/* Create the node for the new regular file */
rc = mknod( pathname, S_IFREG | mode, 0LL );
2003cb0: 13 00 00 20 sethi %hi(0x8000), %o1
2003cb4: 90 10 00 18 mov %i0, %o0
2003cb8: 92 14 80 09 or %l2, %o1, %o1
2003cbc: 94 10 20 00 clr %o2
2003cc0: 7f ff fd 3b call 20031ac <mknod>
2003cc4: 96 10 20 00 clr %o3
if ( rc ) {
2003cc8: 80 a2 20 00 cmp %o0, 0
2003ccc: 12 bf ff 94 bne 2003b1c <open+0x154> <== NEVER TAKEN
2003cd0: 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 );
2003cd4: 40 00 3b 17 call 2012930 <strlen>
2003cd8: 90 10 00 18 mov %i0, %o0
2003cdc: 94 10 20 00 clr %o2
2003ce0: 92 10 00 08 mov %o0, %o1
2003ce4: 96 10 00 11 mov %l1, %o3
2003ce8: 90 10 00 18 mov %i0, %o0
2003cec: 98 10 20 01 mov 1, %o4
2003cf0: 7f ff fb e0 call 2002c70 <rtems_filesystem_evaluate_path>
2003cf4: a8 10 20 00 clr %l4
if ( status != 0 ) { /* The file did not exist */
2003cf8: 80 a2 20 00 cmp %o0, 0
2003cfc: 12 bf ff 9e bne 2003b74 <open+0x1ac> <== NEVER TAKEN
2003d00: a6 10 20 0d mov 0xd, %l3
/*
* Fill in the file control block based on the loc structure
* returned by successful path evaluation.
*/
iop->handlers = loc.handlers;
2003d04: 10 bf ff 55 b 2003a58 <open+0x90>
2003d08: c2 07 bf f0 ld [ %fp + -16 ], %g1
*/
if ( (flags & O_TRUNC) == O_TRUNC ) {
rc = ftruncate( iop - rtems_libio_iops, 0 );
if ( rc ) {
if(errno) rc = errno;
2003d0c: 40 00 37 3c call 20119fc <__errno> <== NOT EXECUTED
2003d10: 01 00 00 00 nop <== NOT EXECUTED
2003d14: 10 bf ff d2 b 2003c5c <open+0x294> <== NOT EXECUTED
2003d18: e6 02 00 00 ld [ %o0 ], %l3 <== NOT EXECUTED
02003954 <open_dev_console>:
/*
* This is a replaceable stub which opens the console, if present.
*/
void open_dev_console(void)
{
2003954: 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) {
2003958: 21 00 80 75 sethi %hi(0x201d400), %l0
200395c: 92 10 20 00 clr %o1
2003960: 90 14 21 a0 or %l0, 0x1a0, %o0
2003964: 40 00 00 19 call 20039c8 <open>
2003968: 94 10 20 00 clr %o2
200396c: 80 a2 3f ff cmp %o0, -1
2003970: 02 80 00 0e be 20039a8 <open_dev_console+0x54>
2003974: 90 14 21 a0 or %l0, 0x1a0, %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)
2003978: 92 10 20 01 mov 1, %o1
200397c: 40 00 00 13 call 20039c8 <open>
2003980: 94 10 20 00 clr %o2
2003984: 80 a2 3f ff cmp %o0, -1
2003988: 02 80 00 0c be 20039b8 <open_dev_console+0x64> <== NEVER TAKEN
200398c: 92 10 20 01 mov 1, %o1
rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */
if ((stderr_fd = open("/dev/console", O_WRONLY, 0)) == -1)
2003990: 90 14 21 a0 or %l0, 0x1a0, %o0
2003994: 40 00 00 0d call 20039c8 <open>
2003998: 94 10 20 00 clr %o2
200399c: 80 a2 3f ff cmp %o0, -1
20039a0: 02 80 00 04 be 20039b0 <open_dev_console+0x5c> <== NEVER TAKEN
20039a4: 11 15 55 11 sethi %hi(0x55544400), %o0
20039a8: 81 c7 e0 08 ret
20039ac: 81 e8 00 00 restore
rtems_fatal_error_occurred( 0x55544432 ); /* error STD2 */
20039b0: 40 00 0d 6a call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
20039b4: 90 12 20 32 or %o0, 0x32, %o0 <== NOT EXECUTED
/*
* 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)
rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */
20039b8: 11 15 55 11 sethi %hi(0x55544400), %o0 <== NOT EXECUTED
20039bc: 40 00 0d 67 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
20039c0: 90 12 20 31 or %o0, 0x31, %o0 ! 55544431 <RAM_END+0x53144431><== NOT EXECUTED
020045b0 <oproc>:
/*
* Handle output processing
*/
static void
oproc (unsigned char c, struct rtems_termios_tty *tty)
{
20045b0: 9d e3 bf a0 save %sp, -96, %sp
int i;
if (tty->termios.c_oflag & OPOST) {
20045b4: c2 06 60 34 ld [ %i1 + 0x34 ], %g1
20045b8: 80 88 60 01 btst 1, %g1
20045bc: 02 80 00 19 be 2004620 <oproc+0x70> <== NEVER TAKEN
20045c0: f0 2f a0 44 stb %i0, [ %fp + 0x44 ]
switch (c) {
20045c4: b0 0e 20 ff and %i0, 0xff, %i0
20045c8: 80 a6 20 09 cmp %i0, 9
20045cc: 22 80 00 42 be,a 20046d4 <oproc+0x124>
20045d0: c6 06 60 28 ld [ %i1 + 0x28 ], %g3
20045d4: 08 80 00 19 bleu 2004638 <oproc+0x88> <== NEVER TAKEN
20045d8: 80 a6 20 08 cmp %i0, 8
20045dc: 80 a6 20 0a cmp %i0, 0xa
20045e0: 02 80 00 22 be 2004668 <oproc+0xb8>
20045e4: 80 a6 20 0d cmp %i0, 0xd
20045e8: 02 80 00 2d be 200469c <oproc+0xec> <== NEVER TAKEN
20045ec: 80 88 60 10 btst 0x10, %g1
if (tty->column > 0)
tty->column--;
break;
default:
if (tty->termios.c_oflag & OLCUC)
20045f0: 80 88 60 02 btst 2, %g1
20045f4: 12 80 00 46 bne 200470c <oproc+0x15c> <== NEVER TAKEN
20045f8: 03 00 80 7a sethi %hi(0x201e800), %g1
20045fc: c2 00 62 2c ld [ %g1 + 0x22c ], %g1 ! 201ea2c <__ctype_ptr__>
c = toupper(c);
if (!iscntrl(c))
2004600: b0 00 40 18 add %g1, %i0, %i0
2004604: c2 0e 20 01 ldub [ %i0 + 1 ], %g1
2004608: 80 88 60 20 btst 0x20, %g1
200460c: 12 80 00 06 bne 2004624 <oproc+0x74> <== NEVER TAKEN
2004610: 94 10 00 19 mov %i1, %o2
tty->column++;
2004614: c2 06 60 28 ld [ %i1 + 0x28 ], %g1
2004618: 82 00 60 01 inc %g1
200461c: c2 26 60 28 st %g1, [ %i1 + 0x28 ]
break;
}
}
rtems_termios_puts (&c, 1, tty);
2004620: 94 10 00 19 mov %i1, %o2
2004624: 90 07 a0 44 add %fp, 0x44, %o0
2004628: 7f ff ff 93 call 2004474 <rtems_termios_puts>
200462c: 92 10 20 01 mov 1, %o1
2004630: 81 c7 e0 08 ret
2004634: 81 e8 00 00 restore
oproc (unsigned char c, struct rtems_termios_tty *tty)
{
int i;
if (tty->termios.c_oflag & OPOST) {
switch (c) {
2004638: 12 bf ff ef bne 20045f4 <oproc+0x44> <== NOT EXECUTED
200463c: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
}
tty->column += i;
break;
case '\b':
if (tty->column > 0)
2004640: c2 06 60 28 ld [ %i1 + 0x28 ], %g1 <== NOT EXECUTED
2004644: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004648: 04 bf ff f6 ble 2004620 <oproc+0x70> <== NOT EXECUTED
200464c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (!iscntrl(c))
tty->column++;
break;
}
}
rtems_termios_puts (&c, 1, tty);
2004650: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
tty->column += i;
break;
case '\b':
if (tty->column > 0)
tty->column--;
2004654: c2 26 60 28 st %g1, [ %i1 + 0x28 ] <== NOT EXECUTED
if (!iscntrl(c))
tty->column++;
break;
}
}
rtems_termios_puts (&c, 1, tty);
2004658: 90 07 a0 44 add %fp, 0x44, %o0 <== NOT EXECUTED
200465c: 7f ff ff 86 call 2004474 <rtems_termios_puts> <== NOT EXECUTED
2004660: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004664: 30 80 00 3e b,a 200475c <oproc+0x1ac> <== NOT EXECUTED
int i;
if (tty->termios.c_oflag & OPOST) {
switch (c) {
case '\n':
if (tty->termios.c_oflag & ONLRET)
2004668: 80 88 60 20 btst 0x20, %g1
200466c: 32 80 00 02 bne,a 2004674 <oproc+0xc4> <== NEVER TAKEN
2004670: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
tty->column = 0;
if (tty->termios.c_oflag & ONLCR) {
2004674: 80 88 60 04 btst 4, %g1
2004678: 02 bf ff eb be 2004624 <oproc+0x74> <== NEVER TAKEN
200467c: 94 10 00 19 mov %i1, %o2
rtems_termios_puts ("\r", 1, tty);
2004680: 11 00 80 75 sethi %hi(0x201d400), %o0
2004684: 92 10 20 01 mov 1, %o1
2004688: 90 12 21 b0 or %o0, 0x1b0, %o0
200468c: 7f ff ff 7a call 2004474 <rtems_termios_puts>
2004690: 94 10 00 19 mov %i1, %o2
tty->column = 0;
2004694: 10 bf ff e3 b 2004620 <oproc+0x70>
2004698: c0 26 60 28 clr [ %i1 + 0x28 ]
}
break;
case '\r':
if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0))
200469c: 02 80 00 06 be 20046b4 <oproc+0x104> <== NOT EXECUTED
20046a0: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
20046a4: c4 06 60 28 ld [ %i1 + 0x28 ], %g2 <== NOT EXECUTED
20046a8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20046ac: 02 bf ff e1 be 2004630 <oproc+0x80> <== NOT EXECUTED
20046b0: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
return;
if (tty->termios.c_oflag & OCRNL) {
20046b4: 22 bf ff db be,a 2004620 <oproc+0x70> <== NOT EXECUTED
20046b8: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
c = '\n';
20046bc: 84 10 20 0a mov 0xa, %g2 <== NOT EXECUTED
if (tty->termios.c_oflag & ONLRET)
20046c0: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
20046c4: 02 bf ff d7 be 2004620 <oproc+0x70> <== NOT EXECUTED
20046c8: c4 2f a0 44 stb %g2, [ %fp + 0x44 ] <== NOT EXECUTED
tty->column = 0;
break;
}
tty->column = 0;
break;
20046cc: 10 bf ff d5 b 2004620 <oproc+0x70> <== NOT EXECUTED
20046d0: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
case '\t':
i = 8 - (tty->column & 7);
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
20046d4: 05 00 00 06 sethi %hi(0x1800), %g2
20046d8: 82 08 40 02 and %g1, %g2, %g1
}
tty->column = 0;
break;
case '\t':
i = 8 - (tty->column & 7);
20046dc: 92 10 20 08 mov 8, %o1
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
20046e0: 80 a0 40 02 cmp %g1, %g2
}
tty->column = 0;
break;
case '\t':
i = 8 - (tty->column & 7);
20046e4: 82 08 e0 07 and %g3, 7, %g1
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
20046e8: 02 80 00 17 be 2004744 <oproc+0x194> <== ALWAYS TAKEN
20046ec: 92 22 40 01 sub %o1, %g1, %o1
tty->column += i;
rtems_termios_puts ( " ", i, tty);
return;
}
tty->column += i;
20046f0: 86 02 40 03 add %o1, %g3, %g3 <== NOT EXECUTED
if (!iscntrl(c))
tty->column++;
break;
}
}
rtems_termios_puts (&c, 1, tty);
20046f4: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
tty->column += i;
rtems_termios_puts ( " ", i, tty);
return;
}
tty->column += i;
20046f8: c6 26 60 28 st %g3, [ %i1 + 0x28 ] <== NOT EXECUTED
if (!iscntrl(c))
tty->column++;
break;
}
}
rtems_termios_puts (&c, 1, tty);
20046fc: 90 07 a0 44 add %fp, 0x44, %o0 <== NOT EXECUTED
2004700: 7f ff ff 5d call 2004474 <rtems_termios_puts> <== NOT EXECUTED
2004704: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2004708: 30 80 00 15 b,a 200475c <oproc+0x1ac> <== NOT EXECUTED
tty->column--;
break;
default:
if (tty->termios.c_oflag & OLCUC)
c = toupper(c);
200470c: c2 00 62 2c ld [ %g1 + 0x22c ], %g1 <== NOT EXECUTED
2004710: 84 10 00 18 mov %i0, %g2 <== NOT EXECUTED
2004714: b0 00 40 18 add %g1, %i0, %i0 <== NOT EXECUTED
2004718: c6 0e 20 01 ldub [ %i0 + 1 ], %g3 <== NOT EXECUTED
200471c: 86 08 e0 03 and %g3, 3, %g3 <== NOT EXECUTED
2004720: 80 a0 e0 02 cmp %g3, 2 <== NOT EXECUTED
2004724: 22 80 00 05 be,a 2004738 <oproc+0x188> <== NOT EXECUTED
2004728: 84 00 bf e0 add %g2, -32, %g2 <== NOT EXECUTED
200472c: c4 2f a0 44 stb %g2, [ %fp + 0x44 ] <== NOT EXECUTED
2004730: 10 bf ff b4 b 2004600 <oproc+0x50> <== NOT EXECUTED
2004734: b0 08 a0 ff and %g2, 0xff, %i0 <== NOT EXECUTED
2004738: c4 2f a0 44 stb %g2, [ %fp + 0x44 ] <== NOT EXECUTED
200473c: 10 bf ff b1 b 2004600 <oproc+0x50> <== NOT EXECUTED
2004740: b0 08 a0 ff and %g2, 0xff, %i0 <== NOT EXECUTED
break;
case '\t':
i = 8 - (tty->column & 7);
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
tty->column += i;
2004744: 86 02 40 03 add %o1, %g3, %g3
rtems_termios_puts ( " ", i, tty);
2004748: 94 10 00 19 mov %i1, %o2
break;
case '\t':
i = 8 - (tty->column & 7);
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
tty->column += i;
200474c: c6 26 60 28 st %g3, [ %i1 + 0x28 ]
rtems_termios_puts ( " ", i, tty);
2004750: 11 00 80 75 sethi %hi(0x201d400), %o0
2004754: 7f ff ff 48 call 2004474 <rtems_termios_puts>
2004758: 90 12 21 b8 or %o0, 0x1b8, %o0 ! 201d5b8 <rtems_filesystem_default_pathconf+0x50>
return;
200475c: 81 c7 e0 08 ret
2004760: 81 e8 00 00 restore
0200fdb0 <pipe_create>:
* Called by pipe() to create an anonymous pipe.
*/
int pipe_create(
int filsdes[2]
)
{
200fdb0: 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)
200fdb4: 23 00 80 77 sethi %hi(0x201dc00), %l1
200fdb8: a0 07 bf dc add %fp, -36, %l0
200fdbc: 92 10 20 03 mov 3, %o1
200fdc0: 90 14 63 00 or %l1, 0x300, %o0
200fdc4: 94 10 20 07 mov 7, %o2
200fdc8: 96 10 00 10 mov %l0, %o3
200fdcc: 7f ff cb a9 call 2002c70 <rtems_filesystem_evaluate_path>
200fdd0: 98 10 20 01 mov 1, %o4
200fdd4: 80 a2 20 00 cmp %o0, 0
200fdd8: 12 80 00 43 bne 200fee4 <pipe_create+0x134> <== ALWAYS TAKEN
200fddc: c2 07 bf e8 ld [ %fp + -24 ], %g1
return -1;
if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0)
return -1;
}
else
rtems_filesystem_freenode(&loc);
200fde0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200fde4: 22 80 00 09 be,a 200fe08 <pipe_create+0x58> <== NOT EXECUTED
200fde8: 03 00 80 7c sethi %hi(0x201f000), %g1 <== NOT EXECUTED
200fdec: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 ! 201f01c <rtems_termios_linesw+0xdc><== NOT EXECUTED
200fdf0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200fdf4: 22 80 00 05 be,a 200fe08 <pipe_create+0x58> <== NOT EXECUTED
200fdf8: 03 00 80 7c sethi %hi(0x201f000), %g1 <== NOT EXECUTED
200fdfc: 9f c0 40 00 call %g1 <== NOT EXECUTED
200fe00: 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 ++);
200fe04: 03 00 80 7c sethi %hi(0x201f000), %g1 <== NOT EXECUTED
200fe08: c4 10 60 50 lduh [ %g1 + 0x50 ], %g2 ! 201f050 <rtems_pipe_no>
else
rtems_filesystem_freenode(&loc);
/* /tmp/.fifoXXXX */
char fifopath[15];
memcpy(fifopath, "/tmp/.fifo", 10);
200fe0c: 07 0b cb 99 sethi %hi(0x2f2e6400), %g3
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200fe10: 95 28 a0 10 sll %g2, 0x10, %o2
200fe14: 84 00 a0 01 inc %g2
else
rtems_filesystem_freenode(&loc);
/* /tmp/.fifoXXXX */
char fifopath[15];
memcpy(fifopath, "/tmp/.fifo", 10);
200fe18: 86 10 e2 69 or %g3, 0x269, %g3
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200fe1c: c4 30 60 50 sth %g2, [ %g1 + 0x50 ]
else
rtems_filesystem_freenode(&loc);
/* /tmp/.fifoXXXX */
char fifopath[15];
memcpy(fifopath, "/tmp/.fifo", 10);
200fe20: 05 0b dd 1b sethi %hi(0x2f746c00), %g2
200fe24: 03 00 00 19 sethi %hi(0x6400), %g1
200fe28: 84 10 a1 70 or %g2, 0x170, %g2
200fe2c: 82 10 62 6f or %g1, 0x26f, %g1
200fe30: a0 07 bf f0 add %fp, -16, %l0
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200fe34: 95 32 a0 10 srl %o2, 0x10, %o2
else
rtems_filesystem_freenode(&loc);
/* /tmp/.fifoXXXX */
char fifopath[15];
memcpy(fifopath, "/tmp/.fifo", 10);
200fe38: c4 3f bf f0 std %g2, [ %fp + -16 ]
200fe3c: c2 34 20 08 sth %g1, [ %l0 + 8 ]
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200fe40: 90 07 bf fa add %fp, -6, %o0
200fe44: 13 00 80 77 sethi %hi(0x201dc00), %o1
200fe48: 40 00 09 d9 call 20125ac <sprintf>
200fe4c: 92 12 63 08 or %o1, 0x308, %o1 ! 201df08 <__FUNCTION__.6119+0x20>
/* Try creating FIFO file until find an available file name */
while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) {
200fe50: 90 10 00 10 mov %l0, %o0
200fe54: 40 00 01 f2 call 201061c <mkfifo>
200fe58: 92 10 21 80 mov 0x180, %o1
200fe5c: 80 a2 20 00 cmp %o0, 0
200fe60: 12 80 00 1d bne 200fed4 <pipe_create+0x124> <== NEVER TAKEN
200fe64: 90 10 00 10 mov %l0, %o0
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);
200fe68: 7f ff ce d8 call 20039c8 <open>
200fe6c: 13 00 00 10 sethi %hi(0x4000), %o1
if (filsdes[0] < 0) {
200fe70: 80 a2 20 00 cmp %o0, 0
200fe74: 06 80 00 2f bl 200ff30 <pipe_create+0x180> <== ALWAYS TAKEN
200fe78: d0 26 00 00 st %o0, [ %i0 ]
the file node will be deleted after it is closed by all. */
unlink(fifopath);
}
else {
/* Reset open file to blocking mode */
iop = rtems_libio_iop(filsdes[0]);
200fe7c: 03 00 80 79 sethi %hi(0x201e400), %g1 <== NOT EXECUTED
200fe80: c4 00 63 b4 ld [ %g1 + 0x3b4 ], %g2 ! 201e7b4 <rtems_libio_number_iops><== NOT EXECUTED
200fe84: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED
200fe88: 0a 80 00 23 bcs 200ff14 <pipe_create+0x164> <== NOT EXECUTED
200fe8c: 82 10 20 00 clr %g1 <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
200fe90: c4 00 60 18 ld [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
200fe94: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
unlink(fifopath);
}
else {
/* Reset open file to blocking mode */
iop = rtems_libio_iop(filsdes[0]);
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
200fe98: 84 08 bf fe and %g2, -2, %g2 <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
200fe9c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
200fea0: 7f ff ce ca call 20039c8 <open> <== NOT EXECUTED
200fea4: c4 20 60 18 st %g2, [ %g1 + 0x18 ] <== NOT EXECUTED
200fea8: d0 26 20 04 st %o0, [ %i0 + 4 ] <== NOT EXECUTED
if (filsdes[1] < 0) {
200feac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200feb0: 06 80 00 26 bl 200ff48 <pipe_create+0x198> <== NOT EXECUTED
200feb4: a2 10 20 00 clr %l1 <== NOT EXECUTED
err = errno;
close(filsdes[0]);
}
unlink(fifopath);
200feb8: 40 00 01 e1 call 201063c <unlink> <== NOT EXECUTED
200febc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
rtems_set_errno_and_return_minus_one(err);
200fec0: 40 00 06 cf call 20119fc <__errno>
200fec4: b0 10 3f ff mov -1, %i0
200fec8: e2 22 00 00 st %l1, [ %o0 ]
}
200fecc: 81 c7 e0 08 ret
200fed0: 81 e8 00 00 restore
memcpy(fifopath, "/tmp/.fifo", 10);
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
/* Try creating FIFO file until find an available file name */
while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) {
if (errno != EEXIST){
200fed4: 40 00 06 ca call 20119fc <__errno> <== NOT EXECUTED
200fed8: 01 00 00 00 nop <== NOT EXECUTED
}
unlink(fifopath);
}
rtems_set_errno_and_return_minus_one(err);
}
200fedc: 81 c7 e0 08 ret <== NOT EXECUTED
200fee0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
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)
!= 0) {
if (errno != ENOENT)
200fee4: 40 00 06 c6 call 20119fc <__errno>
200fee8: 01 00 00 00 nop
200feec: c2 02 00 00 ld [ %o0 ], %g1
200fef0: 80 a0 60 02 cmp %g1, 2
200fef4: 12 bf ff fa bne 200fedc <pipe_create+0x12c> <== NEVER TAKEN
200fef8: 90 14 63 00 or %l1, 0x300, %o0
return -1;
if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0)
200fefc: 7f ff cc a4 call 200318c <mkdir>
200ff00: 92 10 23 ff mov 0x3ff, %o1
200ff04: 80 a2 20 00 cmp %o0, 0
200ff08: 02 bf ff c0 be 200fe08 <pipe_create+0x58> <== ALWAYS TAKEN
200ff0c: 03 00 80 7c sethi %hi(0x201f000), %g1
200ff10: 30 bf ff f3 b,a 200fedc <pipe_create+0x12c> <== NOT EXECUTED
the file node will be deleted after it is closed by all. */
unlink(fifopath);
}
else {
/* Reset open file to blocking mode */
iop = rtems_libio_iop(filsdes[0]);
200ff14: 03 00 80 7c sethi %hi(0x201f000), %g1 <== NOT EXECUTED
200ff18: c2 00 61 c4 ld [ %g1 + 0x1c4 ], %g1 ! 201f1c4 <rtems_libio_iops><== NOT EXECUTED
200ff1c: 85 2a 20 06 sll %o0, 6, %g2 <== NOT EXECUTED
200ff20: 91 2a 20 03 sll %o0, 3, %o0 <== NOT EXECUTED
200ff24: 90 02 00 02 add %o0, %g2, %o0 <== NOT EXECUTED
200ff28: 10 bf ff da b 200fe90 <pipe_create+0xe0> <== NOT EXECUTED
200ff2c: 82 00 40 08 add %g1, %o0, %g1 <== NOT EXECUTED
}
/* Non-blocking open to avoid waiting for writers */
filsdes[0] = open(fifopath, O_RDONLY | O_NONBLOCK);
if (filsdes[0] < 0) {
err = errno;
200ff30: 40 00 06 b3 call 20119fc <__errno>
200ff34: 01 00 00 00 nop
200ff38: 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);
200ff3c: 40 00 01 c0 call 201063c <unlink>
200ff40: 90 10 00 10 mov %l0, %o0
200ff44: 30 bf ff df b,a 200fec0 <pipe_create+0x110>
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
filsdes[1] = open(fifopath, O_WRONLY);
if (filsdes[1] < 0) {
err = errno;
200ff48: 40 00 06 ad call 20119fc <__errno> <== NOT EXECUTED
200ff4c: 01 00 00 00 nop <== NOT EXECUTED
200ff50: e2 02 00 00 ld [ %o0 ], %l1 <== NOT EXECUTED
close(filsdes[0]);
200ff54: 7f ff f2 7c call 200c944 <close> <== NOT EXECUTED
200ff58: d0 06 00 00 ld [ %i0 ], %o0 <== NOT EXECUTED
200ff5c: 30 bf ff d7 b,a 200feb8 <pipe_create+0x108> <== NOT EXECUTED
0200ab70 <pipe_ioctl>:
pipe_control_t *pipe,
uint32_t cmd,
void *buffer,
rtems_libio_t *iop
)
{
200ab70: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (cmd == FIONREAD) {
200ab74: 03 10 01 19 sethi %hi(0x40046400), %g1 <== NOT EXECUTED
pipe_control_t *pipe,
uint32_t cmd,
void *buffer,
rtems_libio_t *iop
)
{
200ab78: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (cmd == FIONREAD) {
200ab7c: 82 10 62 7f or %g1, 0x27f, %g1 <== NOT EXECUTED
200ab80: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
200ab84: 12 80 00 12 bne 200abcc <pipe_ioctl+0x5c> <== NOT EXECUTED
200ab88: b0 10 3f ea mov -22, %i0 <== NOT EXECUTED
if (buffer == NULL)
200ab8c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
200ab90: 02 80 00 0f be 200abcc <pipe_ioctl+0x5c> <== NOT EXECUTED
200ab94: b0 10 3f f2 mov -14, %i0 <== NOT EXECUTED
return -EFAULT;
if (! PIPE_LOCK(pipe))
200ab98: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200ab9c: 92 10 20 00 clr %o1 <== NOT EXECUTED
200aba0: 94 10 20 00 clr %o2 <== NOT EXECUTED
200aba4: 7f ff ef 4c call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200aba8: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
200abac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200abb0: 12 80 00 07 bne 200abcc <pipe_ioctl+0x5c> <== NOT EXECUTED
200abb4: 01 00 00 00 nop <== NOT EXECUTED
return -EINTR;
/* Return length of pipe */
*(unsigned int *)buffer = pipe->Length;
200abb8: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200abbc: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe))
return -EINTR;
/* Return length of pipe */
*(unsigned int *)buffer = pipe->Length;
200abc0: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200abc4: 7f ff ef 8b call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200abc8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
return -EINVAL;
}
200abcc: 81 c7 e0 08 ret <== NOT EXECUTED
200abd0: 81 e8 00 00 restore <== NOT EXECUTED
0200aaf8 <pipe_lseek>:
rtems_libio_t *iop
)
{
/* Seek on pipe is not supported */
return -ESPIPE;
}
200aaf8: 81 c3 e0 08 retl <== NOT EXECUTED
200aafc: 90 10 3f e3 mov -29, %o0 <== NOT EXECUTED
0200abd4 <pipe_read>:
pipe_control_t *pipe,
void *buffer,
size_t count,
rtems_libio_t *iop
)
{
200abd4: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0;
if (! PIPE_LOCK(pipe))
200abd8: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
pipe_control_t *pipe,
void *buffer,
size_t count,
rtems_libio_t *iop
)
{
200abdc: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0;
if (! PIPE_LOCK(pipe))
200abe0: 92 10 20 00 clr %o1 <== NOT EXECUTED
200abe4: 94 10 20 00 clr %o2 <== NOT EXECUTED
200abe8: 7f ff ef 3b call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200abec: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
200abf0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200abf4: 12 80 00 2f bne 200acb0 <pipe_read+0xdc> <== NOT EXECUTED
200abf8: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
/* WARN waitingReaders not restored! */
ret = -EINTR;
goto out_nolock;
}
pipe->waitingReaders --;
if (ret != 0)
200abfc: a4 10 20 00 clr %l2 <== NOT EXECUTED
200ac00: b0 10 20 00 clr %i0 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0;
if (! PIPE_LOCK(pipe))
return -EINTR;
while (read < count) {
200ac04: 02 80 00 26 be 200ac9c <pipe_read+0xc8> <== NOT EXECUTED
200ac08: a2 10 20 00 clr %l1 <== NOT EXECUTED
/* For buffering optimization */
if (PIPE_EMPTY(pipe))
pipe->Start = 0;
if (pipe->waitingWriters > 0)
PIPE_WAKEUPWRITERS(pipe);
200ac0c: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
if (! PIPE_LOCK(pipe))
return -EINTR;
while (read < count) {
while (PIPE_EMPTY(pipe)) {
200ac10: e2 04 20 0c ld [ %l0 + 0xc ], %l1 <== NOT EXECUTED
200ac14: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
200ac18: 12 80 00 2a bne 200acc0 <pipe_read+0xec> <== NOT EXECUTED
200ac1c: 82 26 80 12 sub %i2, %l2, %g1 <== NOT EXECUTED
/* Not an error */
if (pipe->Writers == 0)
200ac20: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
200ac24: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ac28: 22 80 00 1d be,a 200ac9c <pipe_read+0xc8> <== NOT EXECUTED
200ac2c: a2 10 20 00 clr %l1 <== NOT EXECUTED
goto out_locked;
if (LIBIO_NODELAY(iop)) {
200ac30: c2 06 e0 18 ld [ %i3 + 0x18 ], %g1 <== NOT EXECUTED
200ac34: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
200ac38: 32 80 00 19 bne,a 200ac9c <pipe_read+0xc8> <== NOT EXECUTED
200ac3c: a2 10 3f f5 mov -11, %l1 <== NOT EXECUTED
ret = -EAGAIN;
goto out_locked;
}
/* Wait until pipe is no more empty or no writer exists */
pipe->waitingReaders ++;
200ac40: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200ac44: 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 ++;
200ac48: 82 00 60 01 inc %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200ac4c: 7f ff ef 69 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200ac50: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
200ac54: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200ac58: 40 00 0c 11 call 200dc9c <rtems_barrier_wait> <== NOT EXECUTED
200ac5c: 92 10 20 00 clr %o1 <== NOT EXECUTED
200ac60: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ac64: 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))
200ac68: a2 40 3f ff addx %g0, -1, %l1 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ac6c: 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))
200ac70: a2 0c 60 04 and %l1, 4, %l1 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ac74: 94 10 20 00 clr %o2 <== NOT EXECUTED
200ac78: 7f ff ef 17 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200ac7c: a2 04 7f fc add %l1, -4, %l1 <== NOT EXECUTED
200ac80: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ac84: 12 80 00 32 bne 200ad4c <pipe_read+0x178> <== NOT EXECUTED
200ac88: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
/* WARN waitingReaders not restored! */
ret = -EINTR;
goto out_nolock;
}
pipe->waitingReaders --;
200ac8c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
200ac90: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (ret != 0)
200ac94: 02 bf ff df be 200ac10 <pipe_read+0x3c> <== NOT EXECUTED
200ac98: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
read += chunk;
}
out_locked:
PIPE_UNLOCK(pipe);
200ac9c: 7f ff ef 55 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200aca0: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
out_nolock:
if (read > 0)
200aca4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200aca8: 04 80 00 04 ble 200acb8 <pipe_read+0xe4> <== NOT EXECUTED
200acac: 01 00 00 00 nop <== NOT EXECUTED
return read;
return ret;
}
200acb0: 81 c7 e0 08 ret <== NOT EXECUTED
200acb4: 81 e8 00 00 restore <== NOT EXECUTED
200acb8: 81 c7 e0 08 ret <== NOT EXECUTED
200acbc: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
if (ret != 0)
goto out_locked;
}
/* Read chunk bytes */
chunk = MIN(count - read, pipe->Length);
200acc0: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
200acc4: 38 80 00 02 bgu,a 200accc <pipe_read+0xf8> <== NOT EXECUTED
200acc8: a2 10 00 01 mov %g1, %l1 <== NOT EXECUTED
chunk1 = pipe->Size - pipe->Start;
200accc: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
200acd0: e8 04 20 04 ld [ %l0 + 4 ], %l4 <== NOT EXECUTED
200acd4: a8 25 00 01 sub %l4, %g1, %l4 <== NOT EXECUTED
if (chunk > chunk1) {
200acd8: 80 a4 40 14 cmp %l1, %l4 <== NOT EXECUTED
200acdc: 14 80 00 1e bg 200ad54 <pipe_read+0x180> <== NOT EXECUTED
200ace0: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1);
}
else
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);
200ace4: 90 06 40 12 add %i1, %l2, %o0 <== NOT EXECUTED
200ace8: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED
200acec: 40 00 1d 80 call 20122ec <memcpy> <== NOT EXECUTED
200acf0: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
pipe->Start += chunk;
200acf4: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
pipe->Start %= pipe->Size;
200acf8: 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;
200acfc: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
pipe->Start %= pipe->Size;
200ad00: 40 00 41 3e call 201b1f8 <.urem> <== NOT EXECUTED
200ad04: d0 24 20 08 st %o0, [ %l0 + 8 ] <== NOT EXECUTED
pipe->Length -= chunk;
200ad08: 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;
200ad0c: d0 24 20 08 st %o0, [ %l0 + 8 ] <== NOT EXECUTED
pipe->Length -= chunk;
200ad10: 82 20 40 11 sub %g1, %l1, %g1 <== NOT EXECUTED
/* For buffering optimization */
if (PIPE_EMPTY(pipe))
200ad14: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ad18: 12 80 00 03 bne 200ad24 <pipe_read+0x150> <== NOT EXECUTED
200ad1c: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
pipe->Start = 0;
200ad20: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
if (pipe->waitingWriters > 0)
200ad24: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
200ad28: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ad2c: 32 80 00 15 bne,a 200ad80 <pipe_read+0x1ac> <== NOT EXECUTED
200ad30: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
read += chunk;
200ad34: 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) {
200ad38: 80 a6 00 1a cmp %i0, %i2 <== NOT EXECUTED
200ad3c: 0a bf ff b5 bcs 200ac10 <pipe_read+0x3c> <== NOT EXECUTED
200ad40: a4 10 00 18 mov %i0, %l2 <== NOT EXECUTED
200ad44: 10 bf ff d6 b 200ac9c <pipe_read+0xc8> <== NOT EXECUTED
200ad48: a2 10 20 00 clr %l1 <== NOT EXECUTED
/* Wait until pipe is no more empty or no writer exists */
pipe->waitingReaders ++;
PIPE_UNLOCK(pipe);
if (! PIPE_READWAIT(pipe))
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ad4c: 10 bf ff d6 b 200aca4 <pipe_read+0xd0> <== NOT EXECUTED
200ad50: a2 10 3f fc mov -4, %l1 <== NOT EXECUTED
/* Read chunk bytes */
chunk = MIN(count - read, pipe->Length);
chunk1 = pipe->Size - pipe->Start;
if (chunk > chunk1) {
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);
200ad54: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
200ad58: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED
200ad5c: 40 00 1d 64 call 20122ec <memcpy> <== NOT EXECUTED
200ad60: 90 06 40 12 add %i1, %l2, %o0 <== NOT EXECUTED
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1);
200ad64: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
200ad68: 90 04 80 14 add %l2, %l4, %o0 <== NOT EXECUTED
200ad6c: 94 24 40 14 sub %l1, %l4, %o2 <== NOT EXECUTED
200ad70: 40 00 1d 5f call 20122ec <memcpy> <== NOT EXECUTED
200ad74: 90 06 40 08 add %i1, %o0, %o0 <== NOT EXECUTED
}
else
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);
pipe->Start += chunk;
200ad78: 10 bf ff e0 b 200acf8 <pipe_read+0x124> <== NOT EXECUTED
200ad7c: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
/* For buffering optimization */
if (PIPE_EMPTY(pipe))
pipe->Start = 0;
if (pipe->waitingWriters > 0)
PIPE_WAKEUPWRITERS(pipe);
200ad80: 40 00 0b b0 call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200ad84: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
read += chunk;
200ad88: 10 bf ff ec b 200ad38 <pipe_read+0x164> <== NOT EXECUTED
200ad8c: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
0200afac <pipe_release>:
*/
int pipe_release(
pipe_control_t **pipep,
rtems_libio_t *iop
)
{
200afac: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
pipe_control_t *pipe = *pipep;
200afb0: e0 06 00 00 ld [ %i0 ], %l0 <== NOT EXECUTED
uint32_t mode;
rtems_status_code sc;
sc = rtems_semaphore_obtain(pipe->Semaphore,
200afb4: 92 10 20 00 clr %o1 <== NOT EXECUTED
200afb8: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200afbc: 7f ff ee 46 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200afc0: 94 10 20 00 clr %o2 <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT);
/* WARN pipe not released! */
if(sc != RTEMS_SUCCESSFUL)
200afc4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200afc8: 12 80 00 47 bne 200b0e4 <pipe_release+0x138> <== NOT EXECUTED
200afcc: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred(sc);
mode = LIBIO_ACCMODE(iop);
200afd0: e4 06 60 18 ld [ %i1 + 0x18 ], %l2 <== NOT EXECUTED
if (mode & LIBIO_FLAGS_READ)
200afd4: 80 8c a0 02 btst 2, %l2 <== NOT EXECUTED
200afd8: 02 80 00 05 be 200afec <pipe_release+0x40> <== NOT EXECUTED
200afdc: a4 0c a0 06 and %l2, 6, %l2 <== NOT EXECUTED
pipe->Readers --;
200afe0: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200afe4: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
200afe8: c2 24 20 10 st %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
if (mode & LIBIO_FLAGS_WRITE)
200afec: 80 8c a0 04 btst 4, %l2 <== NOT EXECUTED
200aff0: 32 80 00 1d bne,a 200b064 <pipe_release+0xb8> <== NOT EXECUTED
200aff4: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
pipe->Writers --;
sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
200aff8: 23 00 80 7c sethi %hi(0x201f000), %l1 <== NOT EXECUTED
200affc: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 ! 201f048 <rtems_pipe_semaphore><== NOT EXECUTED
200b000: 92 10 20 00 clr %o1 <== NOT EXECUTED
200b004: 7f ff ee 34 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200b008: 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)
200b00c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200b010: 12 80 00 35 bne 200b0e4 <pipe_release+0x138> <== NOT EXECUTED
200b014: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred(sc);
PIPE_UNLOCK(pipe);
200b018: 7f ff ee 76 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b01c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (pipe->Readers == 0 && pipe->Writers == 0) {
200b020: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200b024: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b028: 12 80 00 12 bne 200b070 <pipe_release+0xc4> <== NOT EXECUTED
200b02c: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
200b030: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b034: 02 80 00 1c be 200b0a4 <pipe_release+0xf8> <== NOT EXECUTED
200b038: 80 a4 a0 04 cmp %l2, 4 <== NOT EXECUTED
delfile = TRUE;
#endif
pipe_free(pipe);
*pipep = NULL;
}
else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE)
200b03c: 02 80 00 06 be 200b054 <pipe_release+0xa8> <== NOT EXECUTED
200b040: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */
PIPE_WAKEUPWRITERS(pipe);
200b044: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
200b048: 40 00 0a fe call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b04c: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
PIPE_WAKEUPREADERS(pipe);
rtems_semaphore_release(rtems_pipe_semaphore);
200b050: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 <== NOT EXECUTED
200b054: 7f ff ee 67 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b058: b0 10 20 00 clr %i0 <== NOT EXECUTED
if(iop->pathinfo.ops->unlink_h(&iop->pathinfo))
return -errno;
#endif
return 0;
}
200b05c: 81 c7 e0 08 ret <== NOT EXECUTED
200b060: 81 e8 00 00 restore <== NOT EXECUTED
mode = LIBIO_ACCMODE(iop);
if (mode & LIBIO_FLAGS_READ)
pipe->Readers --;
if (mode & LIBIO_FLAGS_WRITE)
pipe->Writers --;
200b064: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
200b068: 10 bf ff e4 b 200aff8 <pipe_release+0x4c> <== NOT EXECUTED
200b06c: c2 24 20 14 st %g1, [ %l0 + 0x14 ] <== NOT EXECUTED
*pipep = NULL;
}
else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE)
/* Notify waiting Writers that all their partners left */
PIPE_WAKEUPWRITERS(pipe);
else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
200b070: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200b074: 12 bf ff f7 bne 200b050 <pipe_release+0xa4> <== NOT EXECUTED
200b078: 80 a4 a0 02 cmp %l2, 2 <== NOT EXECUTED
200b07c: 02 bf ff f6 be 200b054 <pipe_release+0xa8> <== NOT EXECUTED
200b080: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200b084: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200b088: 40 00 0a ee call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200b08c: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
rtems_semaphore_release(rtems_pipe_semaphore);
200b090: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 <== NOT EXECUTED
200b094: 7f ff ee 57 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b098: b0 10 20 00 clr %i0 <== NOT EXECUTED
if(iop->pathinfo.ops->unlink_h(&iop->pathinfo))
return -errno;
#endif
return 0;
}
200b09c: 81 c7 e0 08 ret <== NOT EXECUTED
200b0a0: 81 e8 00 00 restore <== NOT EXECUTED
/* Called with rtems_pipe_semaphore held. */
static inline void pipe_free(
pipe_control_t *pipe
)
{
rtems_barrier_delete(pipe->readBarrier);
200b0a4: 40 00 0a cd call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b0a8: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
rtems_barrier_delete(pipe->writeBarrier);
200b0ac: 40 00 0a cb call 200dbd8 <rtems_barrier_delete> <== NOT EXECUTED
200b0b0: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
rtems_semaphore_delete(pipe->Semaphore);
200b0b4: 7f ff ed db call 2006820 <rtems_semaphore_delete> <== NOT EXECUTED
200b0b8: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
free(pipe->Buffer);
200b0bc: 7f ff df 0c call 2002cec <free> <== NOT EXECUTED
200b0c0: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
free(pipe);
200b0c4: 7f ff df 0a call 2002cec <free> <== NOT EXECUTED
200b0c8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */
PIPE_WAKEUPWRITERS(pipe);
else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
PIPE_WAKEUPREADERS(pipe);
rtems_semaphore_release(rtems_pipe_semaphore);
200b0cc: d0 04 60 48 ld [ %l1 + 0x48 ], %o0 <== NOT EXECUTED
/* To delete an anonymous pipe file when all users closed it */
if (pipe->Anonymous)
delfile = TRUE;
#endif
pipe_free(pipe);
*pipep = NULL;
200b0d0: c0 26 00 00 clr [ %i0 ] <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */
PIPE_WAKEUPWRITERS(pipe);
else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
PIPE_WAKEUPREADERS(pipe);
rtems_semaphore_release(rtems_pipe_semaphore);
200b0d4: 7f ff ee 47 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200b0d8: b0 10 20 00 clr %i0 <== NOT EXECUTED
if(iop->pathinfo.ops->unlink_h(&iop->pathinfo))
return -errno;
#endif
return 0;
}
200b0dc: 81 c7 e0 08 ret <== NOT EXECUTED
200b0e0: 81 e8 00 00 restore <== NOT EXECUTED
sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
RTEMS_WAIT, RTEMS_NO_TIMEOUT);
/* WARN pipe not freed and pipep not set to NULL! */
if(sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred(sc);
200b0e4: 7f ff ef 9d call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
0200ad90 <pipe_write>:
pipe_control_t *pipe,
const void *buffer,
size_t count,
rtems_libio_t *iop
)
{
200ad90: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
200ad94: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int chunk, chunk1, written = 0, ret = 0;
/* Write nothing */
if (count == 0)
200ad98: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
200ad9c: 12 80 00 04 bne 200adac <pipe_write+0x1c> <== NOT EXECUTED
200ada0: b0 10 20 00 clr %i0 <== NOT EXECUTED
#endif
if (written > 0)
return written;
return ret;
}
200ada4: 81 c7 e0 08 ret <== NOT EXECUTED
200ada8: 81 e8 00 00 restore <== NOT EXECUTED
/* Write nothing */
if (count == 0)
return 0;
if (! PIPE_LOCK(pipe))
200adac: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200adb0: 92 10 20 00 clr %o1 <== NOT EXECUTED
200adb4: 94 10 20 00 clr %o2 <== NOT EXECUTED
200adb8: 7f ff ee c7 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200adbc: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
200adc0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200adc4: 12 bf ff f8 bne 200ada4 <pipe_write+0x14> <== NOT EXECUTED
200adc8: 01 00 00 00 nop <== NOT EXECUTED
return -EINTR;
if (pipe->Readers == 0) {
200adcc: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200add0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200add4: 02 80 00 56 be 200af2c <pipe_write+0x19c> <== NOT EXECUTED
200add8: a2 10 3f e0 mov -32, %l1 <== NOT EXECUTED
ret = -EPIPE;
goto out_locked;
}
/* Write of PIPE_BUF bytes or less shall not be interleaved */
chunk = count <= pipe->Size ? count : 1;
200addc: ea 04 20 04 ld [ %l0 + 4 ], %l5 <== NOT EXECUTED
200ade0: 80 a6 80 15 cmp %i2, %l5 <== NOT EXECUTED
200ade4: 18 80 00 03 bgu 200adf0 <pipe_write+0x60> <== NOT EXECUTED
200ade8: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
200adec: a4 10 00 1a mov %i2, %l2 <== NOT EXECUTED
}
pipe->waitingWriters --;
if (ret != 0)
goto out_locked;
if (pipe->Readers == 0) {
200adf0: a6 10 20 00 clr %l3 <== NOT EXECUTED
200adf4: 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);
200adf8: 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) {
200adfc: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
200ae00: a2 25 40 01 sub %l5, %g1, %l1 <== NOT EXECUTED
200ae04: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
200ae08: 1a 80 00 28 bcc 200aea8 <pipe_write+0x118> <== NOT EXECUTED
200ae0c: 84 26 80 13 sub %i2, %l3, %g2 <== NOT EXECUTED
if (LIBIO_NODELAY(iop)) {
200ae10: c2 06 e0 18 ld [ %i3 + 0x18 ], %g1 <== NOT EXECUTED
200ae14: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
200ae18: 32 80 00 46 bne,a 200af30 <pipe_write+0x1a0> <== NOT EXECUTED
200ae1c: a2 10 3f f5 mov -11, %l1 <== NOT EXECUTED
ret = -EAGAIN;
goto out_locked;
}
/* Wait until there is chunk bytes space or no reader exists */
pipe->waitingWriters ++;
200ae20: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200ae24: 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 ++;
200ae28: 82 00 60 01 inc %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200ae2c: 7f ff ee f1 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200ae30: c2 24 20 1c st %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
200ae34: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
200ae38: 40 00 0b 99 call 200dc9c <rtems_barrier_wait> <== NOT EXECUTED
200ae3c: 92 10 20 00 clr %o1 <== NOT EXECUTED
200ae40: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ae44: 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))
200ae48: a2 40 3f ff addx %g0, -1, %l1 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ae4c: 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))
200ae50: a2 0c 60 04 and %l1, 4, %l1 <== NOT EXECUTED
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200ae54: 94 10 20 00 clr %o2 <== NOT EXECUTED
200ae58: 7f ff ee 9f call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200ae5c: a2 04 7f fc add %l1, -4, %l1 <== NOT EXECUTED
200ae60: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ae64: 12 80 00 43 bne 200af70 <pipe_write+0x1e0> <== NOT EXECUTED
200ae68: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
/* WARN waitingWriters not restored! */
ret = -EINTR;
goto out_nolock;
}
pipe->waitingWriters --;
200ae6c: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
200ae70: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (ret != 0)
200ae74: 12 80 00 2f bne 200af30 <pipe_write+0x1a0> <== NOT EXECUTED
200ae78: c2 24 20 1c st %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
goto out_locked;
if (pipe->Readers == 0) {
200ae7c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200ae80: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ae84: 02 80 00 2b be 200af30 <pipe_write+0x1a0> <== NOT EXECUTED
200ae88: a2 10 3f e0 mov -32, %l1 <== NOT EXECUTED
200ae8c: ea 04 20 04 ld [ %l0 + 4 ], %l5 <== 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) {
200ae90: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
200ae94: a2 25 40 01 sub %l5, %g1, %l1 <== NOT EXECUTED
200ae98: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
200ae9c: 2a bf ff de bcs,a 200ae14 <pipe_write+0x84> <== NOT EXECUTED
200aea0: c2 06 e0 18 ld [ %i3 + 0x18 ], %g1 <== NOT EXECUTED
ret = -EPIPE;
goto out_locked;
}
}
chunk = MIN(count - written, PIPE_SPACE(pipe));
200aea4: 84 26 80 13 sub %i2, %l3, %g2 <== NOT EXECUTED
200aea8: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED
200aeac: 38 80 00 02 bgu,a 200aeb4 <pipe_write+0x124> <== NOT EXECUTED
200aeb0: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
chunk1 = pipe->Size - PIPE_WSTART(pipe);
200aeb4: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
200aeb8: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
200aebc: 40 00 40 cf call 201b1f8 <.urem> <== NOT EXECUTED
200aec0: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
200aec4: a4 25 40 08 sub %l5, %o0, %l2 <== NOT EXECUTED
if (chunk > chunk1) {
200aec8: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
200aecc: 04 80 00 2b ble 200af78 <pipe_write+0x1e8> <== NOT EXECUTED
200aed0: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1);
200aed4: 92 06 40 13 add %i1, %l3, %o1 <== NOT EXECUTED
200aed8: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
200aedc: 40 00 1d 04 call 20122ec <memcpy> <== NOT EXECUTED
200aee0: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1);
200aee4: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
200aee8: 92 04 80 13 add %l2, %l3, %o1 <== NOT EXECUTED
200aeec: 94 24 40 12 sub %l1, %l2, %o2 <== NOT EXECUTED
200aef0: 40 00 1c ff call 20122ec <memcpy> <== NOT EXECUTED
200aef4: 92 06 40 09 add %i1, %o1, %o1 <== NOT EXECUTED
}
else
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk);
pipe->Length += chunk;
200aef8: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
200aefc: 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;
200af00: 84 00 80 11 add %g2, %l1, %g2 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
200af04: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200af08: 12 80 00 22 bne 200af90 <pipe_write+0x200> <== NOT EXECUTED
200af0c: c4 24 20 0c st %g2, [ %l0 + 0xc ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
written += chunk;
200af10: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
}
/* Write of PIPE_BUF bytes or less shall not be interleaved */
chunk = count <= pipe->Size ? count : 1;
while (written < count) {
200af14: 80 a6 80 18 cmp %i2, %i0 <== NOT EXECUTED
200af18: 08 80 00 23 bleu 200afa4 <pipe_write+0x214> <== NOT EXECUTED
200af1c: a6 10 00 18 mov %i0, %l3 <== NOT EXECUTED
200af20: ea 04 20 04 ld [ %l0 + 4 ], %l5 <== NOT EXECUTED
200af24: 10 bf ff b6 b 200adfc <pipe_write+0x6c> <== NOT EXECUTED
200af28: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
200af2c: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* Write of more than PIPE_BUF bytes can be interleaved */
chunk = 1;
}
out_locked:
PIPE_UNLOCK(pipe);
200af30: 7f ff ee b0 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200af34: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
out_nolock:
#ifdef RTEMS_POSIX_API
/* Signal SIGPIPE */
if (ret == -EPIPE)
200af38: 80 a4 7f e0 cmp %l1, -32 <== NOT EXECUTED
200af3c: 02 80 00 07 be 200af58 <pipe_write+0x1c8> <== NOT EXECUTED
200af40: 01 00 00 00 nop <== NOT EXECUTED
kill(getpid(), SIGPIPE);
#endif
if (written > 0)
200af44: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200af48: 14 bf ff 97 bg 200ada4 <pipe_write+0x14> <== NOT EXECUTED
200af4c: 01 00 00 00 nop <== NOT EXECUTED
return written;
return ret;
}
200af50: 81 c7 e0 08 ret <== NOT EXECUTED
200af54: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
out_nolock:
#ifdef RTEMS_POSIX_API
/* Signal SIGPIPE */
if (ret == -EPIPE)
kill(getpid(), SIGPIPE);
200af58: 40 00 06 fc call 200cb48 <getpid> <== NOT EXECUTED
200af5c: 01 00 00 00 nop <== NOT EXECUTED
200af60: 40 00 09 09 call 200d384 <kill> <== NOT EXECUTED
200af64: 92 10 20 0d mov 0xd, %o1 ! d <PROM_START+0xd> <== NOT EXECUTED
#endif
if (written > 0)
200af68: 10 bf ff f8 b 200af48 <pipe_write+0x1b8> <== NOT EXECUTED
200af6c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
/* Wait until there is chunk bytes space or no reader exists */
pipe->waitingWriters ++;
PIPE_UNLOCK(pipe);
if (! PIPE_WRITEWAIT(pipe))
ret = -EINTR;
if (! PIPE_LOCK(pipe)) {
200af70: 10 bf ff f5 b 200af44 <pipe_write+0x1b4> <== NOT EXECUTED
200af74: a2 10 3f fc mov -4, %l1 <== NOT EXECUTED
if (chunk > chunk1) {
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1);
memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1);
}
else
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk);
200af78: 92 06 40 13 add %i1, %l3, %o1 <== NOT EXECUTED
200af7c: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
200af80: 40 00 1c db call 20122ec <memcpy> <== NOT EXECUTED
200af84: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
pipe->Length += chunk;
200af88: 10 bf ff dd b 200aefc <pipe_write+0x16c> <== NOT EXECUTED
200af8c: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
PIPE_WAKEUPREADERS(pipe);
200af90: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200af94: 40 00 0b 2b call 200dc40 <rtems_barrier_release> <== NOT EXECUTED
200af98: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
written += chunk;
200af9c: 10 bf ff de b 200af14 <pipe_write+0x184> <== NOT EXECUTED
200afa0: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
}
/* Write of PIPE_BUF bytes or less shall not be interleaved */
chunk = count <= pipe->Size ? count : 1;
while (written < count) {
200afa4: 10 bf ff e3 b 200af30 <pipe_write+0x1a0> <== NOT EXECUTED
200afa8: a2 10 20 00 clr %l1 <== NOT EXECUTED
020074f4 <posix_memalign>:
)
{
/*
* Update call statistics
*/
MSBUMP(memalign_calls, 1);
20074f4: 05 00 80 a5 sethi %hi(0x2029400), %g2
20074f8: 84 10 a0 60 or %g2, 0x60, %g2 ! 2029460 <rtems_malloc_statistics>
20074fc: c6 00 a0 08 ld [ %g2 + 8 ], %g3
2007500: 86 00 e0 01 inc %g3
2007504: c6 20 a0 08 st %g3, [ %g2 + 8 ]
if (((alignment - 1) & alignment) != 0 || (alignment < sizeof(void *)))
2007508: 84 02 7f ff add %o1, -1, %g2
200750c: 80 88 80 09 btst %g2, %o1
2007510: 02 80 00 04 be 2007520 <posix_memalign+0x2c> <== ALWAYS TAKEN
2007514: 80 a2 60 03 cmp %o1, 3
/*
* rtems_memalign does all of the error checking work EXCEPT
* for adding restrictionso on the alignment.
*/
return rtems_memalign( pointer, alignment, size );
}
2007518: 81 c3 e0 08 retl
200751c: 90 10 20 16 mov 0x16, %o0
/*
* Update call statistics
*/
MSBUMP(memalign_calls, 1);
if (((alignment - 1) & alignment) != 0 || (alignment < sizeof(void *)))
2007520: 08 bf ff fe bleu 2007518 <posix_memalign+0x24>
2007524: 01 00 00 00 nop
/*
* rtems_memalign does all of the error checking work EXCEPT
* for adding restrictionso on the alignment.
*/
return rtems_memalign( pointer, alignment, size );
2007528: 82 13 c0 00 mov %o7, %g1
200752c: 40 00 00 68 call 20076cc <rtems_memalign>
2007530: 9e 10 40 00 mov %g1, %o7
0200b294 <pthread_attr_setschedpolicy>:
int pthread_attr_setschedpolicy(
pthread_attr_t *attr,
int policy
)
{
if ( !attr || !attr->is_initialized )
200b294: 80 a2 20 00 cmp %o0, 0
200b298: 02 80 00 11 be 200b2dc <pthread_attr_setschedpolicy+0x48>
200b29c: 01 00 00 00 nop
200b2a0: c2 02 00 00 ld [ %o0 ], %g1
200b2a4: 80 a0 60 00 cmp %g1, 0
200b2a8: 02 80 00 0d be 200b2dc <pthread_attr_setschedpolicy+0x48>
200b2ac: 80 a2 60 04 cmp %o1, 4
return EINVAL;
switch ( policy ) {
200b2b0: 08 80 00 04 bleu 200b2c0 <pthread_attr_setschedpolicy+0x2c>
200b2b4: 82 10 20 01 mov 1, %g1
200b2b8: 81 c3 e0 08 retl
200b2bc: 90 10 20 86 mov 0x86, %o0
200b2c0: 83 28 40 09 sll %g1, %o1, %g1
200b2c4: 80 88 60 17 btst 0x17, %g1
200b2c8: 02 bf ff fc be 200b2b8 <pthread_attr_setschedpolicy+0x24> <== NEVER TAKEN
200b2cc: 01 00 00 00 nop
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
case SCHED_SPORADIC:
attr->schedpolicy = policy;
200b2d0: d2 22 20 14 st %o1, [ %o0 + 0x14 ]
return 0;
200b2d4: 81 c3 e0 08 retl
200b2d8: 90 10 20 00 clr %o0
default:
return ENOTSUP;
}
}
200b2dc: 81 c3 e0 08 retl
200b2e0: 90 10 20 16 mov 0x16, %o0
02006e04 <pthread_barrier_init>:
int pthread_barrier_init(
pthread_barrier_t *barrier,
const pthread_barrierattr_t *attr,
unsigned int count
)
{
2006e04: 9d e3 bf 90 save %sp, -112, %sp
const pthread_barrierattr_t *the_attr;
/*
* Error check parameters
*/
if ( !barrier )
2006e08: 80 a6 20 00 cmp %i0, 0
2006e0c: 02 80 00 27 be 2006ea8 <pthread_barrier_init+0xa4>
2006e10: 80 a6 a0 00 cmp %i2, 0
return EINVAL;
if ( count == 0 )
2006e14: 02 80 00 25 be 2006ea8 <pthread_barrier_init+0xa4>
2006e18: 80 a6 60 00 cmp %i1, 0
return EINVAL;
/*
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
2006e1c: 22 80 00 29 be,a 2006ec0 <pthread_barrier_init+0xbc>
2006e20: b2 07 bf f0 add %fp, -16, %i1
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
2006e24: c2 06 40 00 ld [ %i1 ], %g1
2006e28: 80 a0 60 00 cmp %g1, 0
2006e2c: 02 80 00 1f be 2006ea8 <pthread_barrier_init+0xa4>
2006e30: 01 00 00 00 nop
return EINVAL;
switch ( the_attr->process_shared ) {
2006e34: c2 06 60 04 ld [ %i1 + 4 ], %g1
2006e38: 80 a0 60 00 cmp %g1, 0
2006e3c: 12 80 00 1b bne 2006ea8 <pthread_barrier_init+0xa4> <== NEVER TAKEN
2006e40: 03 00 80 83 sethi %hi(0x2020c00), %g1
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2006e44: c4 00 62 a0 ld [ %g1 + 0x2a0 ], %g2 ! 2020ea0 <_Thread_Dispatch_disable_level>
/*
* Convert from POSIX attributes to Core Barrier attributes
*/
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
the_attributes.maximum_count = count;
2006e48: f4 27 bf fc st %i2, [ %fp + -4 ]
2006e4c: 84 00 a0 01 inc %g2
}
/*
* Convert from POSIX attributes to Core Barrier attributes
*/
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
2006e50: c0 27 bf f8 clr [ %fp + -8 ]
2006e54: c4 20 62 a0 st %g2, [ %g1 + 0x2a0 ]
* This function allocates a barrier control block from
* the inactive chain of free barrier control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_Barrier_Control *_POSIX_Barrier_Allocate( void )
{
return (POSIX_Barrier_Control *)
2006e58: 23 00 80 84 sethi %hi(0x2021000), %l1
2006e5c: 40 00 08 cd call 2009190 <_Objects_Allocate>
2006e60: 90 14 62 b0 or %l1, 0x2b0, %o0 ! 20212b0 <_POSIX_Barrier_Information>
*/
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _POSIX_Barrier_Allocate();
if ( !the_barrier ) {
2006e64: a0 92 20 00 orcc %o0, 0, %l0
2006e68: 02 80 00 12 be 2006eb0 <pthread_barrier_init+0xac>
2006e6c: 90 04 20 10 add %l0, 0x10, %o0
_Thread_Enable_dispatch();
return EAGAIN;
}
_CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes );
2006e70: 40 00 06 20 call 20086f0 <_CORE_barrier_Initialize>
2006e74: 92 07 bf f8 add %fp, -8, %o1
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2006e78: c4 14 20 0a lduh [ %l0 + 0xa ], %g2
2006e7c: a2 14 62 b0 or %l1, 0x2b0, %l1
2006e80: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
2006e84: c2 04 20 08 ld [ %l0 + 8 ], %g1
2006e88: 85 28 a0 02 sll %g2, 2, %g2
2006e8c: e0 20 c0 02 st %l0, [ %g3 + %g2 ]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
2006e90: c0 24 20 0c clr [ %l0 + 0xc ]
);
/*
* Exit the critical section and return the user an operational barrier
*/
*barrier = the_barrier->Object.id;
2006e94: c2 26 00 00 st %g1, [ %i0 ]
_Thread_Enable_dispatch();
2006e98: 40 00 0c 91 call 200a0dc <_Thread_Enable_dispatch>
2006e9c: b0 10 20 00 clr %i0
return 0;
2006ea0: 81 c7 e0 08 ret
2006ea4: 81 e8 00 00 restore
}
2006ea8: 81 c7 e0 08 ret
2006eac: 91 e8 20 16 restore %g0, 0x16, %o0
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _POSIX_Barrier_Allocate();
if ( !the_barrier ) {
_Thread_Enable_dispatch();
2006eb0: 40 00 0c 8b call 200a0dc <_Thread_Enable_dispatch>
2006eb4: b0 10 20 0b mov 0xb, %i0
return EAGAIN;
2006eb8: 81 c7 e0 08 ret
2006ebc: 81 e8 00 00 restore
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
the_attr = attr;
} else {
(void) pthread_barrierattr_init( &my_attr );
2006ec0: 7f ff ff 9b call 2006d2c <pthread_barrierattr_init>
2006ec4: 90 10 00 19 mov %i1, %o0
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
2006ec8: 10 bf ff d8 b 2006e28 <pthread_barrier_init+0x24>
2006ecc: c2 06 40 00 ld [ %i1 ], %g1
0200658c <pthread_cleanup_push>:
void pthread_cleanup_push(
void (*routine)( void * ),
void *arg
)
{
200658c: 9d e3 bf a0 save %sp, -96, %sp
/*
* The POSIX standard does not address what to do when the routine
* is NULL. It also does not address what happens when we cannot
* allocate memory or anything else bad happens.
*/
if ( !routine )
2006590: 80 a6 20 00 cmp %i0, 0
2006594: 02 80 00 12 be 20065dc <pthread_cleanup_push+0x50>
2006598: 03 00 80 84 sethi %hi(0x2021000), %g1
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
200659c: c4 00 63 70 ld [ %g1 + 0x370 ], %g2 ! 2021370 <_Thread_Dispatch_disable_level>
20065a0: 84 00 a0 01 inc %g2
20065a4: c4 20 63 70 st %g2, [ %g1 + 0x370 ]
return;
_Thread_Disable_dispatch();
handler = _Workspace_Allocate( sizeof( POSIX_Cancel_Handler_control ) );
20065a8: 40 00 12 96 call 200b000 <_Workspace_Allocate>
20065ac: 90 10 20 10 mov 0x10, %o0
if ( handler ) {
20065b0: 92 92 20 00 orcc %o0, 0, %o1
20065b4: 02 80 00 08 be 20065d4 <pthread_cleanup_push+0x48> <== NEVER TAKEN
20065b8: 03 00 80 85 sethi %hi(0x2021400), %g1
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
handler_stack = &thread_support->Cancellation_Handlers;
20065bc: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 ! 2021430 <_Thread_Executing>
handler->routine = routine;
20065c0: f0 22 60 08 st %i0, [ %o1 + 8 ]
handler = _Workspace_Allocate( sizeof( POSIX_Cancel_Handler_control ) );
if ( handler ) {
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
handler_stack = &thread_support->Cancellation_Handlers;
20065c4: d0 00 61 6c ld [ %g1 + 0x16c ], %o0
handler->routine = routine;
handler->arg = arg;
20065c8: f2 22 60 0c st %i1, [ %o1 + 0xc ]
_Chain_Append( handler_stack, &handler->Node );
20065cc: 40 00 06 62 call 2007f54 <_Chain_Append>
20065d0: 90 02 20 e0 add %o0, 0xe0, %o0
}
_Thread_Enable_dispatch();
20065d4: 40 00 0c d5 call 2009928 <_Thread_Enable_dispatch>
20065d8: 81 e8 00 00 restore
20065dc: 81 c7 e0 08 ret
20065e0: 81 e8 00 00 restore
020076c8 <pthread_cond_init>:
int pthread_cond_init(
pthread_cond_t *cond,
const pthread_condattr_t *attr
)
{
20076c8: 9d e3 bf a0 save %sp, -96, %sp
POSIX_Condition_variables_Control *the_cond;
const pthread_condattr_t *the_attr;
if ( attr ) the_attr = attr;
20076cc: 25 00 80 81 sethi %hi(0x2020400), %l2
20076d0: 80 a6 60 00 cmp %i1, 0
20076d4: 02 80 00 03 be 20076e0 <pthread_cond_init+0x18>
20076d8: a4 14 a0 78 or %l2, 0x78, %l2
20076dc: a4 10 00 19 mov %i1, %l2
/*
* Be careful about attributes when global!!!
*/
if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )
20076e0: c2 04 a0 04 ld [ %l2 + 4 ], %g1
20076e4: 80 a0 60 01 cmp %g1, 1
20076e8: 02 80 00 06 be 2007700 <pthread_cond_init+0x38> <== NEVER TAKEN
20076ec: 01 00 00 00 nop
return EINVAL;
if ( !the_attr->is_initialized )
20076f0: c2 04 80 00 ld [ %l2 ], %g1
20076f4: 80 a0 60 00 cmp %g1, 0
20076f8: 12 80 00 04 bne 2007708 <pthread_cond_init+0x40>
20076fc: 03 00 80 88 sethi %hi(0x2022000), %g1
*cond = the_cond->Object.id;
_Thread_Enable_dispatch();
return 0;
}
2007700: 81 c7 e0 08 ret
2007704: 91 e8 20 16 restore %g0, 0x16, %o0
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2007708: c4 00 62 40 ld [ %g1 + 0x240 ], %g2
200770c: 84 00 a0 01 inc %g2
2007710: c4 20 62 40 st %g2, [ %g1 + 0x240 ]
*/
RTEMS_INLINE_ROUTINE POSIX_Condition_variables_Control
*_POSIX_Condition_variables_Allocate( void )
{
return (POSIX_Condition_variables_Control *)
2007714: 23 00 80 89 sethi %hi(0x2022400), %l1
2007718: 40 00 0a 6b call 200a0c4 <_Objects_Allocate>
200771c: 90 14 62 e8 or %l1, 0x2e8, %o0 ! 20226e8 <_POSIX_Condition_variables_Information>
_Thread_Disable_dispatch();
the_cond = _POSIX_Condition_variables_Allocate();
if ( !the_cond ) {
2007720: a0 92 20 00 orcc %o0, 0, %l0
2007724: 02 80 00 15 be 2007778 <pthread_cond_init+0xb0>
2007728: 90 04 20 18 add %l0, 0x18, %o0
_Thread_Enable_dispatch();
return ENOMEM;
}
the_cond->process_shared = the_attr->process_shared;
200772c: c2 04 a0 04 ld [ %l2 + 4 ], %g1
2007730: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;
/* XXX some more initialization might need to go here */
_Thread_queue_Initialize(
2007734: 92 10 20 00 clr %o1
2007738: 94 10 28 00 mov 0x800, %o2
200773c: 96 10 20 74 mov 0x74, %o3
2007740: 40 00 10 84 call 200b950 <_Thread_queue_Initialize>
2007744: c0 24 20 14 clr [ %l0 + 0x14 ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2007748: c4 14 20 0a lduh [ %l0 + 0xa ], %g2
200774c: a2 14 62 e8 or %l1, 0x2e8, %l1
2007750: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
2007754: c2 04 20 08 ld [ %l0 + 8 ], %g1
2007758: 85 28 a0 02 sll %g2, 2, %g2
200775c: e0 20 c0 02 st %l0, [ %g3 + %g2 ]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
2007760: c0 24 20 0c clr [ %l0 + 0xc ]
&_POSIX_Condition_variables_Information,
&the_cond->Object,
0
);
*cond = the_cond->Object.id;
2007764: c2 26 00 00 st %g1, [ %i0 ]
_Thread_Enable_dispatch();
2007768: 40 00 0e 2a call 200b010 <_Thread_Enable_dispatch>
200776c: b0 10 20 00 clr %i0
return 0;
2007770: 81 c7 e0 08 ret
2007774: 81 e8 00 00 restore
_Thread_Disable_dispatch();
the_cond = _POSIX_Condition_variables_Allocate();
if ( !the_cond ) {
_Thread_Enable_dispatch();
2007778: 40 00 0e 26 call 200b010 <_Thread_Enable_dispatch>
200777c: b0 10 20 0c mov 0xc, %i0
return ENOMEM;
2007780: 81 c7 e0 08 ret
2007784: 81 e8 00 00 restore
0200753c <pthread_condattr_destroy>:
int pthread_condattr_destroy(
pthread_condattr_t *attr
)
{
if ( !attr || attr->is_initialized == false )
200753c: 80 a2 20 00 cmp %o0, 0
2007540: 02 80 00 09 be 2007564 <pthread_condattr_destroy+0x28>
2007544: 01 00 00 00 nop
2007548: c2 02 00 00 ld [ %o0 ], %g1
200754c: 80 a0 60 00 cmp %g1, 0
2007550: 02 80 00 05 be 2007564 <pthread_condattr_destroy+0x28> <== NEVER TAKEN
2007554: 01 00 00 00 nop
return EINVAL;
attr->is_initialized = false;
2007558: c0 22 00 00 clr [ %o0 ]
return 0;
200755c: 81 c3 e0 08 retl
2007560: 90 10 20 00 clr %o0
}
2007564: 81 c3 e0 08 retl
2007568: 90 10 20 16 mov 0x16, %o0
02006afc <pthread_create>:
pthread_t *thread,
const pthread_attr_t *attr,
void *(*start_routine)( void * ),
void *arg
)
{
2006afc: 9d e3 bf 58 save %sp, -168, %sp
2006b00: a0 10 00 18 mov %i0, %l0
int schedpolicy = SCHED_RR;
struct sched_param schedparam;
Objects_Name name;
int rc;
if ( !start_routine )
2006b04: 80 a6 a0 00 cmp %i2, 0
2006b08: 02 80 00 66 be 2006ca0 <pthread_create+0x1a4>
2006b0c: b0 10 20 0e mov 0xe, %i0
return EFAULT;
the_attr = (attr) ? attr : &_POSIX_Threads_Default_attributes;
2006b10: 23 00 80 7a sethi %hi(0x201e800), %l1
2006b14: 80 a6 60 00 cmp %i1, 0
2006b18: 02 80 00 03 be 2006b24 <pthread_create+0x28>
2006b1c: a2 14 63 f8 or %l1, 0x3f8, %l1
2006b20: a2 10 00 19 mov %i1, %l1
if ( !the_attr->is_initialized )
2006b24: c2 04 40 00 ld [ %l1 ], %g1
2006b28: 80 a0 60 00 cmp %g1, 0
2006b2c: 22 80 00 5d be,a 2006ca0 <pthread_create+0x1a4>
2006b30: b0 10 20 16 mov 0x16, %i0
* stack space if it is allowed to allocate it itself.
*
* NOTE: If the user provides the stack we will let it drop below
* twice the minimum.
*/
if ( the_attr->stackaddr && !_Stack_Is_enough(the_attr->stacksize) )
2006b34: c2 04 60 04 ld [ %l1 + 4 ], %g1
2006b38: 80 a0 60 00 cmp %g1, 0
2006b3c: 02 80 00 07 be 2006b58 <pthread_create+0x5c>
2006b40: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006b44: c4 04 60 08 ld [ %l1 + 8 ], %g2
2006b48: c2 00 62 74 ld [ %g1 + 0x274 ], %g1
2006b4c: 80 a0 80 01 cmp %g2, %g1
2006b50: 2a 80 00 54 bcs,a 2006ca0 <pthread_create+0x1a4>
2006b54: b0 10 20 16 mov 0x16, %i0
* If inheritsched is set to PTHREAD_INHERIT_SCHED, then this thread
* inherits scheduling attributes from the creating thread. If it is
* PTHREAD_EXPLICIT_SCHED, then scheduling parameters come from the
* attributes structure.
*/
switch ( the_attr->inheritsched ) {
2006b58: c2 04 60 10 ld [ %l1 + 0x10 ], %g1
2006b5c: 80 a0 60 01 cmp %g1, 1
2006b60: 02 80 00 52 be 2006ca8 <pthread_create+0x1ac>
2006b64: 80 a0 60 02 cmp %g1, 2
2006b68: 22 80 00 04 be,a 2006b78 <pthread_create+0x7c>
2006b6c: c2 04 60 18 ld [ %l1 + 0x18 ], %g1
*/
*thread = the_thread->Object.id;
_RTEMS_Unlock_allocator();
return 0;
}
2006b70: 81 c7 e0 08 ret
2006b74: 91 e8 20 16 restore %g0, 0x16, %o0
schedpolicy = api->schedpolicy;
schedparam = api->schedparam;
break;
case PTHREAD_EXPLICIT_SCHED:
schedpolicy = the_attr->schedpolicy;
2006b78: e4 04 60 14 ld [ %l1 + 0x14 ], %l2
schedparam = the_attr->schedparam;
2006b7c: c2 27 bf dc st %g1, [ %fp + -36 ]
2006b80: c2 04 60 1c ld [ %l1 + 0x1c ], %g1
2006b84: c2 27 bf e0 st %g1, [ %fp + -32 ]
2006b88: c2 04 60 20 ld [ %l1 + 0x20 ], %g1
2006b8c: c2 27 bf e4 st %g1, [ %fp + -28 ]
2006b90: c2 04 60 24 ld [ %l1 + 0x24 ], %g1
2006b94: c2 27 bf e8 st %g1, [ %fp + -24 ]
2006b98: c2 04 60 28 ld [ %l1 + 0x28 ], %g1
2006b9c: c2 27 bf ec st %g1, [ %fp + -20 ]
2006ba0: c2 04 60 2c ld [ %l1 + 0x2c ], %g1
2006ba4: c2 27 bf f0 st %g1, [ %fp + -16 ]
2006ba8: c2 04 60 30 ld [ %l1 + 0x30 ], %g1
2006bac: c2 27 bf f4 st %g1, [ %fp + -12 ]
/*
* Check the contentionscope since rtems only supports PROCESS wide
* contention (i.e. no system wide contention).
*/
if ( the_attr->contentionscope != PTHREAD_SCOPE_PROCESS )
2006bb0: c2 04 60 0c ld [ %l1 + 0xc ], %g1
2006bb4: 80 a0 60 00 cmp %g1, 0
2006bb8: 12 80 00 3a bne 2006ca0 <pthread_create+0x1a4>
2006bbc: b0 10 20 86 mov 0x86, %i0
return ENOTSUP;
/*
* Interpret the scheduling parameters.
*/
if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) )
2006bc0: 40 00 20 32 call 200ec88 <_POSIX_Priority_Is_valid>
2006bc4: d0 07 bf dc ld [ %fp + -36 ], %o0
2006bc8: 80 8a 20 ff btst 0xff, %o0
2006bcc: 02 80 00 35 be 2006ca0 <pthread_create+0x1a4> <== NEVER TAKEN
2006bd0: b0 10 20 16 mov 0x16, %i0
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(
int priority
)
{
return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
2006bd4: 03 00 80 7f sethi %hi(0x201fc00), %g1
return EINVAL;
core_priority = _POSIX_Priority_To_core( schedparam.sched_priority );
2006bd8: ea 07 bf dc ld [ %fp + -36 ], %l5
2006bdc: ec 08 62 78 ldub [ %g1 + 0x278 ], %l6
/*
* Set the core scheduling policy information.
*/
rc = _POSIX_Thread_Translate_sched_param(
2006be0: 90 10 00 12 mov %l2, %o0
2006be4: 92 07 bf dc add %fp, -36, %o1
2006be8: 94 07 bf fc add %fp, -4, %o2
2006bec: 40 00 20 34 call 200ecbc <_POSIX_Thread_Translate_sched_param>
2006bf0: 96 07 bf f8 add %fp, -8, %o3
schedpolicy,
&schedparam,
&budget_algorithm,
&budget_callout
);
if ( rc )
2006bf4: b0 92 20 00 orcc %o0, 0, %i0
2006bf8: 12 80 00 2a bne 2006ca0 <pthread_create+0x1a4>
2006bfc: 29 00 80 82 sethi %hi(0x2020800), %l4
#endif
/*
* Lock the allocator mutex for protection
*/
_RTEMS_Lock_allocator();
2006c00: d0 05 22 48 ld [ %l4 + 0x248 ], %o0 ! 2020a48 <_RTEMS_Allocator_Mutex>
2006c04: 40 00 06 86 call 200861c <_API_Mutex_Lock>
2006c08: 2f 00 80 83 sethi %hi(0x2020c00), %l7
* _POSIX_Threads_Allocate
*/
RTEMS_INLINE_ROUTINE Thread_Control *_POSIX_Threads_Allocate( void )
{
return (Thread_Control *) _Objects_Allocate( &_POSIX_Threads_Information );
2006c0c: 40 00 09 48 call 200912c <_Objects_Allocate>
2006c10: 90 15 e0 20 or %l7, 0x20, %o0 ! 2020c20 <_POSIX_Threads_Information>
* Allocate the thread control block.
*
* NOTE: Global threads are not currently supported.
*/
the_thread = _POSIX_Threads_Allocate();
if ( !the_thread ) {
2006c14: a6 92 20 00 orcc %o0, 0, %l3
2006c18: 02 80 00 1f be 2006c94 <pthread_create+0x198>
2006c1c: 05 00 80 7f sethi %hi(0x201fc00), %g2
/*
* Initialize the core thread for this task.
*/
name.name_p = NULL; /* posix threads don't have a name by default */
status = _Thread_Initialize(
2006c20: c2 04 60 08 ld [ %l1 + 8 ], %g1
2006c24: d6 00 a2 74 ld [ %g2 + 0x274 ], %o3
2006c28: c0 27 bf d4 clr [ %fp + -44 ]
2006c2c: 97 2a e0 01 sll %o3, 1, %o3
2006c30: 80 a2 c0 01 cmp %o3, %g1
2006c34: 1a 80 00 03 bcc 2006c40 <pthread_create+0x144>
2006c38: d4 04 60 04 ld [ %l1 + 4 ], %o2
2006c3c: 96 10 00 01 mov %g1, %o3
2006c40: c2 07 bf fc ld [ %fp + -4 ], %g1
2006c44: 9a 0d a0 ff and %l6, 0xff, %o5
2006c48: c2 23 a0 60 st %g1, [ %sp + 0x60 ]
2006c4c: c2 07 bf f8 ld [ %fp + -8 ], %g1
2006c50: 9a 23 40 15 sub %o5, %l5, %o5
2006c54: c2 23 a0 64 st %g1, [ %sp + 0x64 ]
2006c58: 82 07 bf d4 add %fp, -44, %g1
2006c5c: c0 23 a0 68 clr [ %sp + 0x68 ]
2006c60: 90 15 e0 20 or %l7, 0x20, %o0
2006c64: aa 10 20 01 mov 1, %l5
2006c68: c2 23 a0 6c st %g1, [ %sp + 0x6c ]
2006c6c: ea 23 a0 5c st %l5, [ %sp + 0x5c ]
2006c70: 92 10 00 13 mov %l3, %o1
2006c74: 40 00 0d 50 call 200a1b4 <_Thread_Initialize>
2006c78: 98 10 20 01 mov 1, %o4
budget_callout,
0, /* isr level */
name /* posix threads don't have a name */
);
if ( !status ) {
2006c7c: 80 8a 20 ff btst 0xff, %o0
2006c80: 12 80 00 1d bne 2006cf4 <pthread_create+0x1f8>
2006c84: 11 00 80 83 sethi %hi(0x2020c00), %o0
RTEMS_INLINE_ROUTINE void _POSIX_Threads_Free (
Thread_Control *the_pthread
)
{
_Objects_Free( &_POSIX_Threads_Information, &the_pthread->Object );
2006c88: 92 10 00 13 mov %l3, %o1
2006c8c: 40 00 0a 14 call 20094dc <_Objects_Free>
2006c90: 90 12 20 20 or %o0, 0x20, %o0
_POSIX_Threads_Free( the_thread );
_RTEMS_Unlock_allocator();
2006c94: d0 05 22 48 ld [ %l4 + 0x248 ], %o0
2006c98: 40 00 06 77 call 2008674 <_API_Mutex_Unlock>
2006c9c: b0 10 20 0b mov 0xb, %i0
return EAGAIN;
2006ca0: 81 c7 e0 08 ret
2006ca4: 81 e8 00 00 restore
* PTHREAD_EXPLICIT_SCHED, then scheduling parameters come from the
* attributes structure.
*/
switch ( the_attr->inheritsched ) {
case PTHREAD_INHERIT_SCHED:
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
2006ca8: 03 00 80 82 sethi %hi(0x2020800), %g1
2006cac: c2 00 62 50 ld [ %g1 + 0x250 ], %g1 ! 2020a50 <_Thread_Executing>
2006cb0: c2 00 61 6c ld [ %g1 + 0x16c ], %g1
schedpolicy = api->schedpolicy;
schedparam = api->schedparam;
2006cb4: c4 00 60 84 ld [ %g1 + 0x84 ], %g2
* attributes structure.
*/
switch ( the_attr->inheritsched ) {
case PTHREAD_INHERIT_SCHED:
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
schedpolicy = api->schedpolicy;
2006cb8: e4 00 60 80 ld [ %g1 + 0x80 ], %l2
schedparam = api->schedparam;
2006cbc: c4 27 bf dc st %g2, [ %fp + -36 ]
2006cc0: c4 00 60 88 ld [ %g1 + 0x88 ], %g2
2006cc4: c4 27 bf e0 st %g2, [ %fp + -32 ]
2006cc8: c4 00 60 8c ld [ %g1 + 0x8c ], %g2
2006ccc: c4 27 bf e4 st %g2, [ %fp + -28 ]
2006cd0: c4 00 60 90 ld [ %g1 + 0x90 ], %g2
2006cd4: c4 27 bf e8 st %g2, [ %fp + -24 ]
2006cd8: c4 00 60 94 ld [ %g1 + 0x94 ], %g2
2006cdc: c4 27 bf ec st %g2, [ %fp + -20 ]
2006ce0: c4 00 60 98 ld [ %g1 + 0x98 ], %g2
2006ce4: c4 27 bf f0 st %g2, [ %fp + -16 ]
2006ce8: c2 00 60 9c ld [ %g1 + 0x9c ], %g1
break;
2006cec: 10 bf ff b1 b 2006bb0 <pthread_create+0xb4>
2006cf0: c2 27 bf f4 st %g1, [ %fp + -12 ]
}
/*
* finish initializing the per API structure
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
2006cf4: ec 04 e1 6c ld [ %l3 + 0x16c ], %l6
api->Attributes = *the_attr;
2006cf8: 92 10 00 11 mov %l1, %o1
2006cfc: 94 10 20 3c mov 0x3c, %o2
2006d00: 40 00 31 aa call 20133a8 <memcpy>
2006d04: 90 10 00 16 mov %l6, %o0
api->detachstate = the_attr->detachstate;
2006d08: c2 04 60 38 ld [ %l1 + 0x38 ], %g1
api->schedpolicy = schedpolicy;
2006d0c: e4 25 a0 80 st %l2, [ %l6 + 0x80 ]
* finish initializing the per API structure
*/
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
2006d10: c2 25 a0 3c st %g1, [ %l6 + 0x3c ]
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d14: c2 07 bf dc ld [ %fp + -36 ], %g1
* This insures we evaluate the process-wide signals pending when we
* first run.
*
* NOTE: Since the thread starts with all unblocked, this is necessary.
*/
the_thread->do_post_task_switch_extension = true;
2006d18: ea 2c e0 74 stb %l5, [ %l3 + 0x74 ]
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d1c: c2 25 a0 84 st %g1, [ %l6 + 0x84 ]
2006d20: c2 07 bf e0 ld [ %fp + -32 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d24: 94 10 00 1a mov %i2, %o2
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d28: c2 25 a0 88 st %g1, [ %l6 + 0x88 ]
2006d2c: c2 07 bf e4 ld [ %fp + -28 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d30: 96 10 00 1b mov %i3, %o3
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d34: c2 25 a0 8c st %g1, [ %l6 + 0x8c ]
2006d38: c2 07 bf e8 ld [ %fp + -24 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d3c: 90 10 00 13 mov %l3, %o0
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d40: c2 25 a0 90 st %g1, [ %l6 + 0x90 ]
2006d44: c2 07 bf ec ld [ %fp + -20 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d48: 92 10 20 01 mov 1, %o1
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d4c: c2 25 a0 94 st %g1, [ %l6 + 0x94 ]
2006d50: c2 07 bf f0 ld [ %fp + -16 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d54: 98 10 20 00 clr %o4
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
api->Attributes = *the_attr;
api->detachstate = the_attr->detachstate;
api->schedpolicy = schedpolicy;
api->schedparam = schedparam;
2006d58: c2 25 a0 98 st %g1, [ %l6 + 0x98 ]
2006d5c: c2 07 bf f4 ld [ %fp + -12 ], %g1
the_thread->do_post_task_switch_extension = true;
/*
* POSIX threads are allocated and started in one operation.
*/
status = _Thread_Start(
2006d60: 40 00 10 34 call 200ae30 <_Thread_Start>
2006d64: c2 25 a0 9c st %g1, [ %l6 + 0x9c ]
_RTEMS_Unlock_allocator();
return EINVAL;
}
#endif
if ( schedpolicy == SCHED_SPORADIC ) {
2006d68: 80 a4 a0 04 cmp %l2, 4
2006d6c: 02 80 00 08 be 2006d8c <pthread_create+0x290>
2006d70: 01 00 00 00 nop
}
/*
* Return the id and indicate we successfully created the thread
*/
*thread = the_thread->Object.id;
2006d74: c2 04 e0 08 ld [ %l3 + 8 ], %g1
_RTEMS_Unlock_allocator();
2006d78: d0 05 22 48 ld [ %l4 + 0x248 ], %o0
2006d7c: 40 00 06 3e call 2008674 <_API_Mutex_Unlock>
2006d80: c2 24 00 00 st %g1, [ %l0 ]
return 0;
2006d84: 81 c7 e0 08 ret
2006d88: 81 e8 00 00 restore
return EINVAL;
}
#endif
if ( schedpolicy == SCHED_SPORADIC ) {
_Watchdog_Insert_ticks(
2006d8c: 40 00 10 d6 call 200b0e4 <_Timespec_To_ticks>
2006d90: 90 05 a0 8c add %l6, 0x8c, %o0
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2006d94: 92 05 a0 a4 add %l6, 0xa4, %o1
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2006d98: d0 25 a0 b0 st %o0, [ %l6 + 0xb0 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2006d9c: 11 00 80 82 sethi %hi(0x2020800), %o0
2006da0: 40 00 11 bf call 200b49c <_Watchdog_Insert>
2006da4: 90 12 22 70 or %o0, 0x270, %o0 ! 2020a70 <_Watchdog_Ticks_chain>
}
/*
* Return the id and indicate we successfully created the thread
*/
*thread = the_thread->Object.id;
2006da8: 10 bf ff f4 b 2006d78 <pthread_create+0x27c>
2006dac: c2 04 e0 08 ld [ %l3 + 8 ], %g1
020111cc <pthread_kill>:
int pthread_kill(
pthread_t thread,
int sig
)
{
20111cc: 9d e3 bf 98 save %sp, -104, %sp
POSIX_API_Control *api;
Thread_Control *the_thread;
Objects_Locations location;
if ( !sig )
20111d0: 80 a6 60 00 cmp %i1, 0
20111d4: 02 80 00 2d be 2011288 <pthread_kill+0xbc> <== NEVER TAKEN
20111d8: a2 06 7f ff add %i1, -1, %l1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
20111dc: 80 a4 60 1f cmp %l1, 0x1f
20111e0: 18 80 00 2a bgu 2011288 <pthread_kill+0xbc>
20111e4: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one( EINVAL );
the_thread = _Thread_Get( thread, &location );
20111e8: 7f ff de fc call 2008dd8 <_Thread_Get>
20111ec: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
20111f0: c2 07 bf fc ld [ %fp + -4 ], %g1
20111f4: 80 a0 60 00 cmp %g1, 0
20111f8: 12 80 00 2a bne 20112a0 <pthread_kill+0xd4> <== NEVER TAKEN
20111fc: a0 10 00 08 mov %o0, %l0
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( sig ) {
if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) {
2011200: 83 2e 60 02 sll %i1, 2, %g1
2011204: 85 2e 60 04 sll %i1, 4, %g2
2011208: 84 20 80 01 sub %g2, %g1, %g2
201120c: 03 00 80 7e sethi %hi(0x201f800), %g1
2011210: 82 10 61 28 or %g1, 0x128, %g1 ! 201f928 <_POSIX_signals_Vectors>
2011214: 82 00 40 02 add %g1, %g2, %g1
2011218: c4 00 60 08 ld [ %g1 + 8 ], %g2
201121c: 80 a0 a0 01 cmp %g2, 1
2011220: 02 80 00 14 be 2011270 <pthread_kill+0xa4> <== NEVER TAKEN
2011224: c2 02 21 6c ld [ %o0 + 0x16c ], %g1
return 0;
}
/* XXX critical section */
api->signals_pending |= signo_to_mask( sig );
2011228: c4 00 60 d0 ld [ %g1 + 0xd0 ], %g2
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
201122c: 92 10 00 19 mov %i1, %o1
2011230: 94 10 20 00 clr %o2
return 0;
}
/* XXX critical section */
api->signals_pending |= signo_to_mask( sig );
2011234: b2 10 20 01 mov 1, %i1
2011238: a3 2e 40 11 sll %i1, %l1, %l1
201123c: a2 10 80 11 or %g2, %l1, %l1
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
2011240: 7f ff ff 46 call 2010f58 <_POSIX_signals_Unblock_thread>
2011244: e2 20 60 d0 st %l1, [ %g1 + 0xd0 ]
the_thread->do_post_task_switch_extension = true;
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2011248: 03 00 80 7d sethi %hi(0x201f400), %g1
201124c: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 ! 201f43c <_ISR_Nest_level>
2011250: 80 a0 60 00 cmp %g1, 0
2011254: 02 80 00 07 be 2011270 <pthread_kill+0xa4>
2011258: f2 2c 20 74 stb %i1, [ %l0 + 0x74 ]
201125c: 03 00 80 7d sethi %hi(0x201f400), %g1
2011260: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 201f460 <_Thread_Executing>
2011264: 80 a4 00 01 cmp %l0, %g1
2011268: 02 80 00 06 be 2011280 <pthread_kill+0xb4>
201126c: 03 00 80 7d sethi %hi(0x201f400), %g1
_ISR_Signals_to_thread_executing = true;
}
_Thread_Enable_dispatch();
2011270: 7f ff de cc call 2008da0 <_Thread_Enable_dispatch>
2011274: b0 10 20 00 clr %i0
return 0;
2011278: 81 c7 e0 08 ret
201127c: 81 e8 00 00 restore
(void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
the_thread->do_post_task_switch_extension = true;
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
_ISR_Signals_to_thread_executing = true;
2011280: 10 bf ff fc b 2011270 <pthread_kill+0xa4>
2011284: f2 28 60 f8 stb %i1, [ %g1 + 0xf8 ]
if ( !sig )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
rtems_set_errno_and_return_minus_one( EINVAL );
2011288: 40 00 01 dd call 20119fc <__errno>
201128c: b0 10 3f ff mov -1, %i0
2011290: 82 10 20 16 mov 0x16, %g1
2011294: c2 22 00 00 st %g1, [ %o0 ]
2011298: 81 c7 e0 08 ret
201129c: 81 e8 00 00 restore
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( ESRCH );
20112a0: 40 00 01 d7 call 20119fc <__errno> <== NOT EXECUTED
20112a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20112a8: 82 10 20 03 mov 3, %g1 <== NOT EXECUTED
20112ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
20112b0: 81 c7 e0 08 ret <== NOT EXECUTED
20112b4: 81 e8 00 00 restore <== NOT EXECUTED
02006314 <pthread_mutexattr_gettype>:
int pthread_mutexattr_gettype(
const pthread_mutexattr_t *attr,
int *type
)
{
if ( !attr )
2006314: 80 a2 20 00 cmp %o0, 0
2006318: 02 80 00 0c be 2006348 <pthread_mutexattr_gettype+0x34>
200631c: 01 00 00 00 nop
return EINVAL;
if ( !attr->is_initialized )
2006320: c2 02 00 00 ld [ %o0 ], %g1
2006324: 80 a0 60 00 cmp %g1, 0
2006328: 02 80 00 08 be 2006348 <pthread_mutexattr_gettype+0x34>
200632c: 80 a2 60 00 cmp %o1, 0
return EINVAL;
if ( !type )
2006330: 02 80 00 06 be 2006348 <pthread_mutexattr_gettype+0x34> <== NEVER TAKEN
2006334: 01 00 00 00 nop
return EINVAL;
*type = attr->type;
2006338: c2 02 20 10 ld [ %o0 + 0x10 ], %g1
200633c: 90 10 20 00 clr %o0
return 0;
2006340: 81 c3 e0 08 retl
2006344: c2 22 40 00 st %g1, [ %o1 ]
}
2006348: 81 c3 e0 08 retl
200634c: 90 10 20 16 mov 0x16, %o0
020088e0 <pthread_mutexattr_setpshared>:
int pthread_mutexattr_setpshared(
pthread_mutexattr_t *attr,
int pshared
)
{
if ( !attr || !attr->is_initialized )
20088e0: 80 a2 20 00 cmp %o0, 0
20088e4: 02 80 00 08 be 2008904 <pthread_mutexattr_setpshared+0x24>
20088e8: 01 00 00 00 nop
20088ec: c2 02 00 00 ld [ %o0 ], %g1
20088f0: 80 a0 60 00 cmp %g1, 0
20088f4: 02 80 00 04 be 2008904 <pthread_mutexattr_setpshared+0x24>
20088f8: 80 a2 60 01 cmp %o1, 1
return EINVAL;
switch ( pshared ) {
20088fc: 28 80 00 04 bleu,a 200890c <pthread_mutexattr_setpshared+0x2c><== ALWAYS TAKEN
2008900: d2 22 20 04 st %o1, [ %o0 + 4 ]
return 0;
default:
return EINVAL;
}
}
2008904: 81 c3 e0 08 retl
2008908: 90 10 20 16 mov 0x16, %o0
switch ( pshared ) {
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
200890c: 81 c3 e0 08 retl
2008910: 90 10 20 00 clr %o0
020063a0 <pthread_mutexattr_settype>:
int pthread_mutexattr_settype(
pthread_mutexattr_t *attr,
int type
)
{
if ( !attr || !attr->is_initialized )
20063a0: 80 a2 20 00 cmp %o0, 0
20063a4: 02 80 00 08 be 20063c4 <pthread_mutexattr_settype+0x24>
20063a8: 01 00 00 00 nop
20063ac: c2 02 00 00 ld [ %o0 ], %g1
20063b0: 80 a0 60 00 cmp %g1, 0
20063b4: 02 80 00 04 be 20063c4 <pthread_mutexattr_settype+0x24> <== NEVER TAKEN
20063b8: 80 a2 60 03 cmp %o1, 3
return EINVAL;
switch ( type ) {
20063bc: 28 80 00 04 bleu,a 20063cc <pthread_mutexattr_settype+0x2c>
20063c0: d2 22 20 10 st %o1, [ %o0 + 0x10 ]
return 0;
default:
return EINVAL;
}
}
20063c4: 81 c3 e0 08 retl
20063c8: 90 10 20 16 mov 0x16, %o0
case PTHREAD_MUTEX_NORMAL:
case PTHREAD_MUTEX_RECURSIVE:
case PTHREAD_MUTEX_ERRORCHECK:
case PTHREAD_MUTEX_DEFAULT:
attr->type = type;
return 0;
20063cc: 81 c3 e0 08 retl
20063d0: 90 10 20 00 clr %o0
02007298 <pthread_once>:
int pthread_once(
pthread_once_t *once_control,
void (*init_routine)(void)
)
{
2007298: 9d e3 bf 98 save %sp, -104, %sp
if ( !once_control || !init_routine )
200729c: 80 a6 60 00 cmp %i1, 0
20072a0: 02 80 00 0b be 20072cc <pthread_once+0x34>
20072a4: a0 10 00 18 mov %i0, %l0
20072a8: 80 a6 20 00 cmp %i0, 0
20072ac: 02 80 00 08 be 20072cc <pthread_once+0x34>
20072b0: 01 00 00 00 nop
return EINVAL;
if ( !once_control->init_executed ) {
20072b4: c2 06 20 04 ld [ %i0 + 4 ], %g1
20072b8: 80 a0 60 00 cmp %g1, 0
20072bc: 02 80 00 06 be 20072d4 <pthread_once+0x3c>
20072c0: b0 10 20 00 clr %i0
(*init_routine)();
}
rtems_task_mode(saveMode, RTEMS_PREEMPT_MASK, &saveMode);
}
return 0;
}
20072c4: 81 c7 e0 08 ret
20072c8: 81 e8 00 00 restore
int pthread_once(
pthread_once_t *once_control,
void (*init_routine)(void)
)
{
if ( !once_control || !init_routine )
20072cc: 81 c7 e0 08 ret
20072d0: 91 e8 20 16 restore %g0, 0x16, %o0
return EINVAL;
if ( !once_control->init_executed ) {
rtems_mode saveMode;
rtems_task_mode(RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &saveMode);
20072d4: a2 07 bf fc add %fp, -4, %l1
20072d8: 90 10 21 00 mov 0x100, %o0
20072dc: 92 10 21 00 mov 0x100, %o1
20072e0: 40 00 03 05 call 2007ef4 <rtems_task_mode>
20072e4: 94 10 00 11 mov %l1, %o2
if ( !once_control->init_executed ) {
20072e8: c2 04 20 04 ld [ %l0 + 4 ], %g1
20072ec: 80 a0 60 00 cmp %g1, 0
20072f0: 02 80 00 09 be 2007314 <pthread_once+0x7c> <== ALWAYS TAKEN
20072f4: 82 10 20 01 mov 1, %g1
once_control->is_initialized = true;
once_control->init_executed = true;
(*init_routine)();
}
rtems_task_mode(saveMode, RTEMS_PREEMPT_MASK, &saveMode);
20072f8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
20072fc: 94 10 00 11 mov %l1, %o2
2007300: 92 10 21 00 mov 0x100, %o1
2007304: 40 00 02 fc call 2007ef4 <rtems_task_mode>
2007308: b0 10 20 00 clr %i0
}
return 0;
}
200730c: 81 c7 e0 08 ret
2007310: 81 e8 00 00 restore
if ( !once_control->init_executed ) {
rtems_mode saveMode;
rtems_task_mode(RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &saveMode);
if ( !once_control->init_executed ) {
once_control->is_initialized = true;
once_control->init_executed = true;
2007314: c2 24 20 04 st %g1, [ %l0 + 4 ]
(*init_routine)();
2007318: 9f c6 40 00 call %i1
200731c: c2 24 00 00 st %g1, [ %l0 ]
}
rtems_task_mode(saveMode, RTEMS_PREEMPT_MASK, &saveMode);
2007320: 10 bf ff f7 b 20072fc <pthread_once+0x64>
2007324: d0 07 bf fc ld [ %fp + -4 ], %o0
02007928 <pthread_rwlock_init>:
int pthread_rwlock_init(
pthread_rwlock_t *rwlock,
const pthread_rwlockattr_t *attr
)
{
2007928: 9d e3 bf 90 save %sp, -112, %sp
const pthread_rwlockattr_t *the_attr;
/*
* Error check parameters
*/
if ( !rwlock )
200792c: 80 a6 20 00 cmp %i0, 0
2007930: 02 80 00 23 be 20079bc <pthread_rwlock_init+0x94>
2007934: 80 a6 60 00 cmp %i1, 0
return EINVAL;
/*
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
2007938: 22 80 00 27 be,a 20079d4 <pthread_rwlock_init+0xac>
200793c: b2 07 bf f4 add %fp, -12, %i1
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
2007940: c2 06 40 00 ld [ %i1 ], %g1
2007944: 80 a0 60 00 cmp %g1, 0
2007948: 02 80 00 1d be 20079bc <pthread_rwlock_init+0x94> <== NEVER TAKEN
200794c: 01 00 00 00 nop
return EINVAL;
switch ( the_attr->process_shared ) {
2007950: c2 06 60 04 ld [ %i1 + 4 ], %g1
2007954: 80 a0 60 00 cmp %g1, 0
2007958: 12 80 00 19 bne 20079bc <pthread_rwlock_init+0x94> <== NEVER TAKEN
200795c: 03 00 80 89 sethi %hi(0x2022400), %g1
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2007960: c4 00 63 30 ld [ %g1 + 0x330 ], %g2 ! 2022730 <_Thread_Dispatch_disable_level>
2007964: 84 00 a0 01 inc %g2
2007968: c4 20 63 30 st %g2, [ %g1 + 0x330 ]
* This function allocates a RWLock control block from
* the inactive chain of free RWLock control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_RWLock_Control *_POSIX_RWLock_Allocate( void )
{
return (POSIX_RWLock_Control *)
200796c: 23 00 80 8a sethi %hi(0x2022800), %l1
2007970: 40 00 0a 64 call 200a300 <_Objects_Allocate>
2007974: 90 14 61 80 or %l1, 0x180, %o0 ! 2022980 <_POSIX_RWLock_Information>
*/
_Thread_Disable_dispatch(); /* prevents deletion */
the_rwlock = _POSIX_RWLock_Allocate();
if ( !the_rwlock ) {
2007978: a0 92 20 00 orcc %o0, 0, %l0
200797c: 02 80 00 12 be 20079c4 <pthread_rwlock_init+0x9c>
2007980: 90 04 20 10 add %l0, 0x10, %o0
_Thread_Enable_dispatch();
return EAGAIN;
}
_CORE_RWLock_Initialize( &the_rwlock->RWLock, &the_attributes );
2007984: 40 00 08 12 call 20099cc <_CORE_RWLock_Initialize>
2007988: 92 07 bf fc add %fp, -4, %o1
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
200798c: c4 14 20 0a lduh [ %l0 + 0xa ], %g2
2007990: a2 14 61 80 or %l1, 0x180, %l1
2007994: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
2007998: c2 04 20 08 ld [ %l0 + 8 ], %g1
200799c: 85 28 a0 02 sll %g2, 2, %g2
20079a0: e0 20 c0 02 st %l0, [ %g3 + %g2 ]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
20079a4: c0 24 20 0c clr [ %l0 + 0xc ]
&_POSIX_RWLock_Information,
&the_rwlock->Object,
0
);
*rwlock = the_rwlock->Object.id;
20079a8: c2 26 00 00 st %g1, [ %i0 ]
_Thread_Enable_dispatch();
20079ac: 40 00 0e 28 call 200b24c <_Thread_Enable_dispatch>
20079b0: b0 10 20 00 clr %i0
return 0;
20079b4: 81 c7 e0 08 ret
20079b8: 81 e8 00 00 restore
}
20079bc: 81 c7 e0 08 ret
20079c0: 91 e8 20 16 restore %g0, 0x16, %o0
_Thread_Disable_dispatch(); /* prevents deletion */
the_rwlock = _POSIX_RWLock_Allocate();
if ( !the_rwlock ) {
_Thread_Enable_dispatch();
20079c4: 40 00 0e 22 call 200b24c <_Thread_Enable_dispatch>
20079c8: b0 10 20 0b mov 0xb, %i0
return EAGAIN;
20079cc: 81 c7 e0 08 ret
20079d0: 81 e8 00 00 restore
* If the user passed in NULL, use the default attributes
*/
if ( attr ) {
the_attr = attr;
} else {
(void) pthread_rwlockattr_init( &default_attr );
20079d4: 40 00 02 8d call 2008408 <pthread_rwlockattr_init>
20079d8: 90 10 00 19 mov %i1, %o0
}
/*
* Now start error checking the attributes that we are going to use
*/
if ( !the_attr->is_initialized )
20079dc: 10 bf ff da b 2007944 <pthread_rwlock_init+0x1c>
20079e0: c2 06 40 00 ld [ %i1 ], %g1
02007a50 <pthread_rwlock_timedrdlock>:
int pthread_rwlock_timedrdlock(
pthread_rwlock_t *rwlock,
const struct timespec *abstime
)
{
2007a50: 9d e3 bf 98 save %sp, -104, %sp
Objects_Locations location;
Watchdog_Interval ticks;
bool do_wait = true;
POSIX_Absolute_timeout_conversion_results_t status;
if ( !rwlock )
2007a54: 80 a6 20 00 cmp %i0, 0
2007a58: 02 80 00 24 be 2007ae8 <pthread_rwlock_timedrdlock+0x98>
2007a5c: 92 07 bf f8 add %fp, -8, %o1
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
2007a60: 40 00 20 ac call 200fd10 <_POSIX_Absolute_timeout_to_ticks>
2007a64: 90 10 00 19 mov %i1, %o0
2007a68: d2 06 00 00 ld [ %i0 ], %o1
2007a6c: a0 10 00 08 mov %o0, %l0
2007a70: 94 07 bf fc add %fp, -4, %o2
2007a74: 11 00 80 8a sethi %hi(0x2022800), %o0
2007a78: 40 00 0b 76 call 200a850 <_Objects_Get>
2007a7c: 90 12 21 80 or %o0, 0x180, %o0 ! 2022980 <_POSIX_RWLock_Information>
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
2007a80: c2 07 bf fc ld [ %fp + -4 ], %g1
2007a84: 80 a0 60 00 cmp %g1, 0
2007a88: 12 80 00 18 bne 2007ae8 <pthread_rwlock_timedrdlock+0x98>
2007a8c: d6 07 bf f8 ld [ %fp + -8 ], %o3
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_reading(
2007a90: d2 06 00 00 ld [ %i0 ], %o1
int _EXFUN(pthread_rwlock_init,
(pthread_rwlock_t *__rwlock, _CONST pthread_rwlockattr_t *__attr));
int _EXFUN(pthread_rwlock_destroy, (pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_rdlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_tryrdlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_timedrdlock,
2007a94: 82 1c 20 03 xor %l0, 3, %g1
2007a98: 90 02 20 10 add %o0, 0x10, %o0
2007a9c: 80 a0 00 01 cmp %g0, %g1
2007aa0: 98 10 20 00 clr %o4
2007aa4: a2 60 3f ff subx %g0, -1, %l1
2007aa8: 40 00 07 d4 call 20099f8 <_CORE_RWLock_Obtain_for_reading>
2007aac: 94 10 00 11 mov %l1, %o2
do_wait,
ticks,
NULL
);
_Thread_Enable_dispatch();
2007ab0: 40 00 0d e7 call 200b24c <_Thread_Enable_dispatch>
2007ab4: 01 00 00 00 nop
if ( !do_wait ) {
2007ab8: 80 a4 60 00 cmp %l1, 0
2007abc: 12 80 00 13 bne 2007b08 <pthread_rwlock_timedrdlock+0xb8>
2007ac0: 03 00 80 89 sethi %hi(0x2022400), %g1
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
2007ac4: c2 00 63 f0 ld [ %g1 + 0x3f0 ], %g1 ! 20227f0 <_Thread_Executing>
2007ac8: d0 00 60 34 ld [ %g1 + 0x34 ], %o0
2007acc: 80 a2 20 02 cmp %o0, 2
2007ad0: 02 80 00 08 be 2007af0 <pthread_rwlock_timedrdlock+0xa0>
2007ad4: 80 a4 20 00 cmp %l0, 0
break;
}
}
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
2007ad8: 40 00 00 40 call 2007bd8 <_POSIX_RWLock_Translate_core_RWLock_return_code>
2007adc: 01 00 00 00 nop
2007ae0: 81 c7 e0 08 ret
2007ae4: 91 e8 00 08 restore %g0, %o0, %o0
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
2007ae8: 81 c7 e0 08 ret
2007aec: 91 e8 20 16 restore %g0, 0x16, %o0
);
_Thread_Enable_dispatch();
if ( !do_wait ) {
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
switch (status) {
2007af0: 02 bf ff fe be 2007ae8 <pthread_rwlock_timedrdlock+0x98> <== NEVER TAKEN
2007af4: 80 a4 20 02 cmp %l0, 2
2007af8: 18 bf ff f8 bgu 2007ad8 <pthread_rwlock_timedrdlock+0x88> <== NEVER TAKEN
2007afc: b0 10 20 74 mov 0x74, %i0
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
2007b00: 81 c7 e0 08 ret
2007b04: 81 e8 00 00 restore
);
_Thread_Enable_dispatch();
if ( !do_wait ) {
if ( _Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
switch (status) {
2007b08: c2 00 63 f0 ld [ %g1 + 0x3f0 ], %g1
2007b0c: 10 bf ff f3 b 2007ad8 <pthread_rwlock_timedrdlock+0x88>
2007b10: d0 00 60 34 ld [ %g1 + 0x34 ], %o0
02007b14 <pthread_rwlock_timedwrlock>:
int pthread_rwlock_timedwrlock(
pthread_rwlock_t *rwlock,
const struct timespec *abstime
)
{
2007b14: 9d e3 bf 98 save %sp, -104, %sp
Objects_Locations location;
Watchdog_Interval ticks;
bool do_wait = true;
POSIX_Absolute_timeout_conversion_results_t status;
if ( !rwlock )
2007b18: 80 a6 20 00 cmp %i0, 0
2007b1c: 02 80 00 24 be 2007bac <pthread_rwlock_timedwrlock+0x98>
2007b20: 92 07 bf f8 add %fp, -8, %o1
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
2007b24: 40 00 20 7b call 200fd10 <_POSIX_Absolute_timeout_to_ticks>
2007b28: 90 10 00 19 mov %i1, %o0
2007b2c: d2 06 00 00 ld [ %i0 ], %o1
2007b30: a0 10 00 08 mov %o0, %l0
2007b34: 94 07 bf fc add %fp, -4, %o2
2007b38: 11 00 80 8a sethi %hi(0x2022800), %o0
2007b3c: 40 00 0b 45 call 200a850 <_Objects_Get>
2007b40: 90 12 21 80 or %o0, 0x180, %o0 ! 2022980 <_POSIX_RWLock_Information>
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
the_rwlock = _POSIX_RWLock_Get( rwlock, &location );
switch ( location ) {
2007b44: c2 07 bf fc ld [ %fp + -4 ], %g1
2007b48: 80 a0 60 00 cmp %g1, 0
2007b4c: 12 80 00 18 bne 2007bac <pthread_rwlock_timedwrlock+0x98>
2007b50: d6 07 bf f8 ld [ %fp + -8 ], %o3
case OBJECTS_LOCAL:
_CORE_RWLock_Obtain_for_writing(
2007b54: d2 06 00 00 ld [ %i0 ], %o1
(pthread_rwlock_t *__rwlock, _CONST struct timespec *__abstime));
int _EXFUN(pthread_rwlock_unlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_wrlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_trywrlock,(pthread_rwlock_t *__rwlock));
int _EXFUN(pthread_rwlock_timedwrlock,
2007b58: 82 1c 20 03 xor %l0, 3, %g1
2007b5c: 90 02 20 10 add %o0, 0x10, %o0
2007b60: 80 a0 00 01 cmp %g0, %g1
2007b64: 98 10 20 00 clr %o4
2007b68: a2 60 3f ff subx %g0, -1, %l1
2007b6c: 40 00 07 d8 call 2009acc <_CORE_RWLock_Obtain_for_writing>
2007b70: 94 10 00 11 mov %l1, %o2
do_wait,
ticks,
NULL
);
_Thread_Enable_dispatch();
2007b74: 40 00 0d b6 call 200b24c <_Thread_Enable_dispatch>
2007b78: 01 00 00 00 nop
if ( !do_wait &&
2007b7c: 80 a4 60 00 cmp %l1, 0
2007b80: 12 80 00 13 bne 2007bcc <pthread_rwlock_timedwrlock+0xb8>
2007b84: 03 00 80 89 sethi %hi(0x2022400), %g1
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
2007b88: c2 00 63 f0 ld [ %g1 + 0x3f0 ], %g1 ! 20227f0 <_Thread_Executing>
2007b8c: d0 00 60 34 ld [ %g1 + 0x34 ], %o0
ticks,
NULL
);
_Thread_Enable_dispatch();
if ( !do_wait &&
2007b90: 80 a2 20 02 cmp %o0, 2
2007b94: 02 80 00 08 be 2007bb4 <pthread_rwlock_timedwrlock+0xa0>
2007b98: 80 a4 20 00 cmp %l0, 0
case POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE:
break;
}
}
return _POSIX_RWLock_Translate_core_RWLock_return_code(
2007b9c: 40 00 00 0f call 2007bd8 <_POSIX_RWLock_Translate_core_RWLock_return_code>
2007ba0: 01 00 00 00 nop
2007ba4: 81 c7 e0 08 ret
2007ba8: 91 e8 00 08 restore %g0, %o0, %o0
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
2007bac: 81 c7 e0 08 ret
2007bb0: 91 e8 20 16 restore %g0, 0x16, %o0
);
_Thread_Enable_dispatch();
if ( !do_wait &&
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
switch (status) {
2007bb4: 02 bf ff fe be 2007bac <pthread_rwlock_timedwrlock+0x98> <== NEVER TAKEN
2007bb8: 80 a4 20 02 cmp %l0, 2
2007bbc: 18 bf ff f8 bgu 2007b9c <pthread_rwlock_timedwrlock+0x88> <== NEVER TAKEN
2007bc0: b0 10 20 74 mov 0x74, %i0
case OBJECTS_ERROR:
break;
}
return EINVAL;
}
2007bc4: 81 c7 e0 08 ret
2007bc8: 81 e8 00 00 restore
);
_Thread_Enable_dispatch();
if ( !do_wait &&
(_Thread_Executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
switch (status) {
2007bcc: c2 00 63 f0 ld [ %g1 + 0x3f0 ], %g1
2007bd0: 10 bf ff f3 b 2007b9c <pthread_rwlock_timedwrlock+0x88>
2007bd4: d0 00 60 34 ld [ %g1 + 0x34 ], %o0
0200842c <pthread_rwlockattr_setpshared>:
int pthread_rwlockattr_setpshared(
pthread_rwlockattr_t *attr,
int pshared
)
{
if ( !attr )
200842c: 80 a2 20 00 cmp %o0, 0
2008430: 02 80 00 08 be 2008450 <pthread_rwlockattr_setpshared+0x24>
2008434: 01 00 00 00 nop
return EINVAL;
if ( !attr->is_initialized )
2008438: c2 02 00 00 ld [ %o0 ], %g1
200843c: 80 a0 60 00 cmp %g1, 0
2008440: 02 80 00 04 be 2008450 <pthread_rwlockattr_setpshared+0x24>
2008444: 80 a2 60 01 cmp %o1, 1
return EINVAL;
switch ( pshared ) {
2008448: 28 80 00 04 bleu,a 2008458 <pthread_rwlockattr_setpshared+0x2c><== ALWAYS TAKEN
200844c: d2 22 20 04 st %o1, [ %o0 + 4 ]
return 0;
default:
return EINVAL;
}
}
2008450: 81 c3 e0 08 retl
2008454: 90 10 20 16 mov 0x16, %o0
switch ( pshared ) {
case PTHREAD_PROCESS_SHARED:
case PTHREAD_PROCESS_PRIVATE:
attr->process_shared = pshared;
return 0;
2008458: 81 c3 e0 08 retl
200845c: 90 10 20 00 clr %o0
020096b4 <pthread_setschedparam>:
int pthread_setschedparam(
pthread_t thread,
int policy,
struct sched_param *param
)
{
20096b4: 9d e3 bf 90 save %sp, -112, %sp
20096b8: a0 10 00 18 mov %i0, %l0
int rc;
/*
* Check all the parameters
*/
if ( !param )
20096bc: 80 a6 a0 00 cmp %i2, 0
20096c0: 02 80 00 3a be 20097a8 <pthread_setschedparam+0xf4>
20096c4: b0 10 20 16 mov 0x16, %i0
return EINVAL;
rc = _POSIX_Thread_Translate_sched_param(
20096c8: 90 10 00 19 mov %i1, %o0
20096cc: 92 10 00 1a mov %i2, %o1
20096d0: 94 07 bf fc add %fp, -4, %o2
20096d4: 40 00 1e 50 call 2011014 <_POSIX_Thread_Translate_sched_param>
20096d8: 96 07 bf f8 add %fp, -8, %o3
policy,
param,
&budget_algorithm,
&budget_callout
);
if ( rc )
20096dc: b0 92 20 00 orcc %o0, 0, %i0
20096e0: 12 80 00 32 bne 20097a8 <pthread_setschedparam+0xf4>
20096e4: 90 10 00 10 mov %l0, %o0
return rc;
/*
* Actually change the scheduling policy and parameters
*/
the_thread = _Thread_Get( thread, &location );
20096e8: 40 00 0b 29 call 200c38c <_Thread_Get>
20096ec: 92 07 bf f4 add %fp, -12, %o1
switch ( location ) {
20096f0: c2 07 bf f4 ld [ %fp + -12 ], %g1
20096f4: 80 a0 60 00 cmp %g1, 0
20096f8: 12 80 00 2e bne 20097b0 <pthread_setschedparam+0xfc>
20096fc: a2 10 00 08 mov %o0, %l1
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
2009700: e0 02 21 6c ld [ %o0 + 0x16c ], %l0
if ( api->schedpolicy == SCHED_SPORADIC )
2009704: c2 04 20 80 ld [ %l0 + 0x80 ], %g1
2009708: 80 a0 60 04 cmp %g1, 4
200970c: 02 80 00 36 be 20097e4 <pthread_setschedparam+0x130>
2009710: 01 00 00 00 nop
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
2009714: f2 24 20 80 st %i1, [ %l0 + 0x80 ]
api->schedparam = *param;
2009718: c2 06 80 00 ld [ %i2 ], %g1
the_thread->budget_algorithm = budget_algorithm;
200971c: c6 07 bf fc ld [ %fp + -4 ], %g3
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
2009720: c2 24 20 84 st %g1, [ %l0 + 0x84 ]
2009724: c4 06 a0 04 ld [ %i2 + 4 ], %g2
the_thread->budget_algorithm = budget_algorithm;
2009728: c6 24 60 7c st %g3, [ %l1 + 0x7c ]
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
200972c: c4 24 20 88 st %g2, [ %l0 + 0x88 ]
2009730: c4 06 a0 08 ld [ %i2 + 8 ], %g2
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
2009734: c6 07 bf f8 ld [ %fp + -8 ], %g3
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
2009738: c4 24 20 8c st %g2, [ %l0 + 0x8c ]
200973c: c4 06 a0 0c ld [ %i2 + 0xc ], %g2
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
2009740: c6 24 60 80 st %g3, [ %l1 + 0x80 ]
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
2009744: c4 24 20 90 st %g2, [ %l0 + 0x90 ]
2009748: c4 06 a0 10 ld [ %i2 + 0x10 ], %g2
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
switch ( api->schedpolicy ) {
200974c: 80 a6 60 00 cmp %i1, 0
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
api->schedpolicy = policy;
api->schedparam = *param;
2009750: c4 24 20 94 st %g2, [ %l0 + 0x94 ]
2009754: c4 06 a0 14 ld [ %i2 + 0x14 ], %g2
2009758: c4 24 20 98 st %g2, [ %l0 + 0x98 ]
200975c: c4 06 a0 18 ld [ %i2 + 0x18 ], %g2
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
switch ( api->schedpolicy ) {
2009760: 06 80 00 10 bl 20097a0 <pthread_setschedparam+0xec> <== NEVER TAKEN
2009764: c4 24 20 9c st %g2, [ %l0 + 0x9c ]
2009768: 80 a6 60 02 cmp %i1, 2
200976c: 14 80 00 13 bg 20097b8 <pthread_setschedparam+0x104>
2009770: 80 a6 60 04 cmp %i1, 4
2009774: c2 04 20 84 ld [ %l0 + 0x84 ], %g1
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
2009778: 05 00 80 93 sethi %hi(0x2024c00), %g2
200977c: 07 00 80 90 sethi %hi(0x2024000), %g3
2009780: c4 00 a2 78 ld [ %g2 + 0x278 ], %g2
2009784: d2 08 e3 a8 ldub [ %g3 + 0x3a8 ], %o1
the_thread->real_priority =
_POSIX_Priority_To_core( api->schedparam.sched_priority );
_Thread_Change_priority(
2009788: 90 10 00 11 mov %l1, %o0
200978c: 92 22 40 01 sub %o1, %g1, %o1
switch ( api->schedpolicy ) {
case SCHED_OTHER:
case SCHED_FIFO:
case SCHED_RR:
the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
2009790: c4 24 60 78 st %g2, [ %l1 + 0x78 ]
the_thread->real_priority =
2009794: d2 24 60 18 st %o1, [ %l1 + 0x18 ]
_POSIX_Priority_To_core( api->schedparam.sched_priority );
_Thread_Change_priority(
2009798: 40 00 09 51 call 200bcdc <_Thread_Change_priority>
200979c: 94 10 20 01 mov 1, %o2
_Watchdog_Remove( &api->Sporadic_timer );
_POSIX_Threads_Sporadic_budget_TSR( 0, the_thread );
break;
}
_Thread_Enable_dispatch();
20097a0: 40 00 0a ed call 200c354 <_Thread_Enable_dispatch>
20097a4: 01 00 00 00 nop
case OBJECTS_ERROR:
break;
}
return ESRCH;
}
20097a8: 81 c7 e0 08 ret
20097ac: 81 e8 00 00 restore
/*
* Actually change the scheduling policy and parameters
*/
the_thread = _Thread_Get( thread, &location );
switch ( location ) {
20097b0: 81 c7 e0 08 ret
20097b4: 91 e8 20 03 restore %g0, 3, %o0
api->schedpolicy = policy;
api->schedparam = *param;
the_thread->budget_algorithm = budget_algorithm;
the_thread->budget_callout = budget_callout;
switch ( api->schedpolicy ) {
20097b8: 12 bf ff fa bne 20097a0 <pthread_setschedparam+0xec> <== NEVER TAKEN
20097bc: 01 00 00 00 nop
true
);
break;
case SCHED_SPORADIC:
api->ss_high_priority = api->schedparam.sched_priority;
20097c0: c2 24 20 a0 st %g1, [ %l0 + 0xa0 ]
_Watchdog_Remove( &api->Sporadic_timer );
20097c4: 40 00 10 7e call 200d9bc <_Watchdog_Remove>
20097c8: 90 04 20 a4 add %l0, 0xa4, %o0
_POSIX_Threads_Sporadic_budget_TSR( 0, the_thread );
20097cc: 92 10 00 11 mov %l1, %o1
20097d0: 7f ff ff 93 call 200961c <_POSIX_Threads_Sporadic_budget_TSR>
20097d4: 90 10 20 00 clr %o0
break;
}
_Thread_Enable_dispatch();
20097d8: 40 00 0a df call 200c354 <_Thread_Enable_dispatch>
20097dc: 01 00 00 00 nop
20097e0: 30 bf ff f2 b,a 20097a8 <pthread_setschedparam+0xf4>
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
if ( api->schedpolicy == SCHED_SPORADIC )
(void) _Watchdog_Remove( &api->Sporadic_timer );
20097e4: 40 00 10 76 call 200d9bc <_Watchdog_Remove>
20097e8: 90 04 20 a4 add %l0, 0xa4, %o0
api->schedpolicy = policy;
20097ec: 10 bf ff cb b 2009718 <pthread_setschedparam+0x64>
20097f0: f2 24 20 80 st %i1, [ %l0 + 0x80 ]
02006e38 <pthread_testcancel>:
*
* 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183
*/
void pthread_testcancel( void )
{
2006e38: 9d e3 bf a0 save %sp, -96, %sp
* Don't even think about deleting a resource from an ISR.
* Besides this request is supposed to be for _Thread_Executing
* and the ISR context is not a thread.
*/
if ( _ISR_Is_in_progress() )
2006e3c: 03 00 80 85 sethi %hi(0x2021400), %g1
2006e40: c2 00 60 0c ld [ %g1 + 0xc ], %g1 ! 202140c <_ISR_Nest_level>
2006e44: 80 a0 60 00 cmp %g1, 0
2006e48: 12 80 00 15 bne 2006e9c <pthread_testcancel+0x64> <== NEVER TAKEN
2006e4c: 03 00 80 84 sethi %hi(0x2021000), %g1
return;
thread_support = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
2006e50: 21 00 80 85 sethi %hi(0x2021400), %l0
2006e54: c6 00 63 70 ld [ %g1 + 0x370 ], %g3
2006e58: c4 04 20 30 ld [ %l0 + 0x30 ], %g2
2006e5c: 86 00 e0 01 inc %g3
2006e60: c6 20 63 70 st %g3, [ %g1 + 0x370 ]
2006e64: c2 00 a1 6c ld [ %g2 + 0x16c ], %g1
_Thread_Disable_dispatch();
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
2006e68: c4 00 60 d4 ld [ %g1 + 0xd4 ], %g2
2006e6c: 80 a0 a0 00 cmp %g2, 0
2006e70: 12 80 00 0d bne 2006ea4 <pthread_testcancel+0x6c> <== NEVER TAKEN
2006e74: 01 00 00 00 nop
thread_support->cancelation_requested )
2006e78: c2 00 60 dc ld [ %g1 + 0xdc ], %g1
2006e7c: 80 a0 60 00 cmp %g1, 0
2006e80: 02 80 00 09 be 2006ea4 <pthread_testcancel+0x6c>
2006e84: 01 00 00 00 nop
cancel = true;
_Thread_Enable_dispatch();
2006e88: 40 00 0a a8 call 2009928 <_Thread_Enable_dispatch>
2006e8c: b2 10 3f ff mov -1, %i1 ! ffffffff <RAM_END+0xfdbfffff>
if ( cancel )
_POSIX_Thread_Exit( _Thread_Executing, PTHREAD_CANCELED );
2006e90: f0 04 20 30 ld [ %l0 + 0x30 ], %i0
2006e94: 40 00 1e 15 call 200e6e8 <_POSIX_Thread_Exit>
2006e98: 81 e8 00 00 restore
2006e9c: 81 c7 e0 08 ret <== NOT EXECUTED
2006ea0: 81 e8 00 00 restore <== NOT EXECUTED
_Thread_Disable_dispatch();
if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
thread_support->cancelation_requested )
cancel = true;
_Thread_Enable_dispatch();
2006ea4: 40 00 0a a1 call 2009928 <_Thread_Enable_dispatch>
2006ea8: 81 e8 00 00 restore
02003550 <putk>:
* putk
*
* Kernel putk (e.g. puts) function requiring minimal infrastrure.
*/
void putk(const char *s)
{
2003550: 9d e3 bf a0 save %sp, -96, %sp
const char *p = s;
for (p=s ; *p ; p++ )
2003554: d0 0e 00 00 ldub [ %i0 ], %o0
2003558: 91 2a 20 18 sll %o0, 0x18, %o0
200355c: 80 a2 20 00 cmp %o0, 0
2003560: 02 80 00 0c be 2003590 <putk+0x40> <== NEVER TAKEN
2003564: 23 00 80 66 sethi %hi(0x2019800), %l1
2003568: a0 14 61 40 or %l1, 0x140, %l0 ! 2019940 <BSP_output_char>
BSP_output_char(*p);
200356c: c2 04 00 00 ld [ %l0 ], %g1
2003570: 9f c0 40 00 call %g1
2003574: 91 3a 20 18 sra %o0, 0x18, %o0
*/
void putk(const char *s)
{
const char *p = s;
for (p=s ; *p ; p++ )
2003578: b0 06 20 01 inc %i0
200357c: d0 0e 00 00 ldub [ %i0 ], %o0
2003580: 91 2a 20 18 sll %o0, 0x18, %o0
2003584: 80 a2 20 00 cmp %o0, 0
2003588: 32 bf ff fa bne,a 2003570 <putk+0x20>
200358c: c2 04 00 00 ld [ %l0 ], %g1
BSP_output_char(*p);
BSP_output_char('\n');
2003590: c2 04 61 40 ld [ %l1 + 0x140 ], %g1
2003594: 9f c0 40 00 call %g1
2003598: 90 10 20 0a mov 0xa, %o0
}
200359c: 81 c7 e0 08 ret
20035a0: 81 e8 00 00 restore
0200bfdc <ramdisk_allocate>:
void *area_begin,
uint32_t block_size,
rtems_blkdev_bnum block_count,
bool trace
)
{
200bfdc: 9d e3 bf a0 save %sp, -96, %sp
struct ramdisk *rd = malloc(sizeof(struct ramdisk));
200bfe0: 7f ff e0 54 call 2004130 <malloc>
200bfe4: 90 10 20 10 mov 0x10, %o0
if (rd == NULL) {
200bfe8: a0 92 20 00 orcc %o0, 0, %l0
200bfec: 02 80 00 0c be 200c01c <ramdisk_allocate+0x40> <== NEVER TAKEN
200bff0: a2 10 00 10 mov %l0, %l1
return NULL;
}
if (area_begin == NULL) {
200bff4: 80 a6 20 00 cmp %i0, 0
200bff8: 02 80 00 0b be 200c024 <ramdisk_allocate+0x48> <== ALWAYS TAKEN
200bffc: 90 10 00 1a mov %i2, %o0
return NULL;
}
rd->malloced = true;
} else {
rd->malloced = false;
200c000: c0 2c 20 0d clrb [ %l0 + 0xd ] <== NOT EXECUTED
}
rd->block_size = block_size;
rd->block_num = block_count;
rd->area = area_begin;
rd->trace = trace;
rd->initialized = true;
200c004: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
}
rd->malloced = true;
} else {
rd->malloced = false;
}
rd->block_size = block_size;
200c008: f2 24 40 00 st %i1, [ %l1 ]
rd->block_num = block_count;
200c00c: f4 24 60 04 st %i2, [ %l1 + 4 ]
rd->area = area_begin;
200c010: f0 24 60 08 st %i0, [ %l1 + 8 ]
rd->trace = trace;
200c014: f6 2c 60 0e stb %i3, [ %l1 + 0xe ]
rd->initialized = true;
200c018: c2 2c 60 0c stb %g1, [ %l1 + 0xc ]
return rd;
}
200c01c: 81 c7 e0 08 ret
200c020: 91 e8 00 10 restore %g0, %l0, %o0
if (rd == NULL) {
return NULL;
}
if (area_begin == NULL) {
area_begin = calloc(block_count, block_size);
200c024: 7f ff de b8 call 2003b04 <calloc>
200c028: 92 10 00 19 mov %i1, %o1
if (area_begin == NULL) {
200c02c: b0 92 20 00 orcc %o0, 0, %i0
200c030: 02 80 00 04 be 200c040 <ramdisk_allocate+0x64> <== NEVER TAKEN
200c034: 82 10 20 01 mov 1, %g1
free(rd);
return NULL;
}
rd->malloced = true;
200c038: 10 bf ff f4 b 200c008 <ramdisk_allocate+0x2c>
200c03c: c2 2c 20 0d stb %g1, [ %l0 + 0xd ]
}
if (area_begin == NULL) {
area_begin = calloc(block_count, block_size);
if (area_begin == NULL) {
free(rd);
200c040: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200c044: 7f ff df 53 call 2003d90 <free> <== NOT EXECUTED
200c048: a0 10 20 00 clr %l0 <== NOT EXECUTED
return NULL;
200c04c: 30 bf ff f4 b,a 200c01c <ramdisk_allocate+0x40> <== NOT EXECUTED
0200bf9c <ramdisk_free>:
return rd;
}
void ramdisk_free(ramdisk *rd)
{
200bf9c: 9d e3 bf a0 save %sp, -96, %sp
if (rd != NULL) {
200bfa0: 80 a6 20 00 cmp %i0, 0
200bfa4: 02 80 00 0c be 200bfd4 <ramdisk_free+0x38> <== NEVER TAKEN
200bfa8: 01 00 00 00 nop
if (rd->malloced) {
200bfac: c2 0e 20 0d ldub [ %i0 + 0xd ], %g1
200bfb0: 80 a0 60 00 cmp %g1, 0
200bfb4: 12 80 00 04 bne 200bfc4 <ramdisk_free+0x28> <== ALWAYS TAKEN
200bfb8: 01 00 00 00 nop
free(rd->area);
}
free(rd);
200bfbc: 7f ff df 75 call 2003d90 <free> <== NOT EXECUTED
200bfc0: 81 e8 00 00 restore <== NOT EXECUTED
void ramdisk_free(ramdisk *rd)
{
if (rd != NULL) {
if (rd->malloced) {
free(rd->area);
200bfc4: 7f ff df 73 call 2003d90 <free>
200bfc8: d0 06 20 08 ld [ %i0 + 8 ], %o0
}
free(rd);
200bfcc: 7f ff df 71 call 2003d90 <free>
200bfd0: 81 e8 00 00 restore
200bfd4: 81 c7 e0 08 ret <== NOT EXECUTED
200bfd8: 81 e8 00 00 restore <== NOT EXECUTED
02023d44 <ramdisk_initialize>:
rtems_device_driver
ramdisk_initialize(
rtems_device_major_number major,
rtems_device_minor_number minor __attribute__((unused)),
void *arg __attribute__((unused)))
{
2023d44: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
rtems_device_minor_number i;
rtems_ramdisk_config *c = rtems_ramdisk_configuration;
struct ramdisk *r;
rtems_status_code rc;
rc = rtems_disk_io_initialize();
2023d48: 7f ff 8c be call 2007040 <rtems_disk_io_initialize> <== NOT EXECUTED
2023d4c: 01 00 00 00 nop <== NOT EXECUTED
if (rc != RTEMS_SUCCESSFUL)
2023d50: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2023d54: 02 80 00 04 be 2023d64 <ramdisk_initialize+0x20> <== NOT EXECUTED
2023d58: 2b 00 81 c2 sethi %hi(0x2070800), %l5 <== NOT EXECUTED
}
r->initialized = false;
}
}
return RTEMS_SUCCESSFUL;
}
2023d5c: 81 c7 e0 08 ret <== NOT EXECUTED
2023d60: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
* This is allocating memory for a RAM disk which will persist for
* the life of the system. RTEMS has no "de-initialize" driver call
* so there is no corresponding free(r). Coverity is correct that
* it is never freed but this is not a problem.
*/
r = calloc(rtems_ramdisk_configuration_size, sizeof(struct ramdisk));
2023d64: d0 05 63 20 ld [ %l5 + 0x320 ], %o0 <== NOT EXECUTED
2023d68: 7f ff 91 3b call 2008254 <calloc> <== NOT EXECUTED
2023d6c: 92 10 20 10 mov 0x10, %o1 <== NOT EXECUTED
r->trace = false;
for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)
2023d70: c2 05 63 20 ld [ %l5 + 0x320 ], %g1 <== NOT EXECUTED
* the life of the system. RTEMS has no "de-initialize" driver call
* so there is no corresponding free(r). Coverity is correct that
* it is never freed but this is not a problem.
*/
r = calloc(rtems_ramdisk_configuration_size, sizeof(struct ramdisk));
r->trace = false;
2023d74: c0 2a 20 0e clrb [ %o0 + 0xe ] <== NOT EXECUTED
for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)
2023d78: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023d7c: 02 bf ff f8 be 2023d5c <ramdisk_initialize+0x18> <== NOT EXECUTED
2023d80: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2023d84: 27 00 81 c2 sethi %hi(0x2070800), %l3 <== NOT EXECUTED
2023d88: a6 14 e3 14 or %l3, 0x314, %l3 ! 2070b14 <rtems_ramdisk_configuration><== NOT EXECUTED
{
dev_t dev = rtems_filesystem_make_dev_t(major, i);
char name [] = RAMDISK_DEVICE_BASE_NAME "a";
name [sizeof(RAMDISK_DEVICE_BASE_NAME)] += i;
r->block_size = c->block_size;
2023d8c: d4 04 c0 00 ld [ %l3 ], %o2 <== NOT EXECUTED
r->block_num = c->block_num;
2023d90: d6 04 e0 04 ld [ %l3 + 4 ], %o3 <== NOT EXECUTED
if (c->location == NULL)
2023d94: c2 04 e0 08 ld [ %l3 + 8 ], %g1 <== NOT EXECUTED
* so there is no corresponding free(r). Coverity is correct that
* it is never freed but this is not a problem.
*/
r = calloc(rtems_ramdisk_configuration_size, sizeof(struct ramdisk));
r->trace = false;
for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)
2023d98: a4 10 20 00 clr %l2 <== NOT EXECUTED
{
dev_t dev = rtems_filesystem_make_dev_t(major, i);
char name [] = RAMDISK_DEVICE_BASE_NAME "a";
2023d9c: 2d 0b d9 19 sethi %hi(0x2f646400), %l6 <== NOT EXECUTED
2023da0: 2f 0b dc 99 sethi %hi(0x2f726400), %l7 <== NOT EXECUTED
2023da4: ac 15 a1 76 or %l6, 0x176, %l6 <== NOT EXECUTED
2023da8: ae 15 e0 61 or %l7, 0x61, %l7 <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
2023dac: f0 27 bf f8 st %i0, [ %fp + -8 ] <== NOT EXECUTED
temp.__overlay.minor = _minor;
2023db0: e4 27 bf fc st %l2, [ %fp + -4 ] <== NOT EXECUTED
2023db4: ec 3f bf e8 std %l6, [ %fp + -24 ] <== NOT EXECUTED
name [sizeof(RAMDISK_DEVICE_BASE_NAME)] += i;
2023db8: e4 2f bf f0 stb %l2, [ %fp + -16 ] <== NOT EXECUTED
r->block_size = c->block_size;
2023dbc: d4 24 40 00 st %o2, [ %l1 ] <== NOT EXECUTED
r->block_num = c->block_num;
2023dc0: d6 24 60 04 st %o3, [ %l1 + 4 ] <== NOT EXECUTED
{
r->malloced = false;
r->initialized = true;
r->area = c->location;
}
rc = rtems_disk_create_phys(dev, c->block_size, c->block_num,
2023dc4: 39 00 80 8f sethi %hi(0x2023c00), %i4 <== NOT EXECUTED
2023dc8: aa 15 63 20 or %l5, 0x320, %l5 <== NOT EXECUTED
2023dcc: b8 17 22 b4 or %i4, 0x2b4, %i4 <== NOT EXECUTED
2023dd0: ba 07 bf e8 add %fp, -24, %i5 <== NOT EXECUTED
}
}
else
{
r->malloced = false;
r->initialized = true;
2023dd4: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
dev_t dev = rtems_filesystem_make_dev_t(major, i);
char name [] = RAMDISK_DEVICE_BASE_NAME "a";
name [sizeof(RAMDISK_DEVICE_BASE_NAME)] += i;
r->block_size = c->block_size;
r->block_num = c->block_num;
if (c->location == NULL)
2023dd8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023ddc: 02 80 00 25 be 2023e70 <ramdisk_initialize+0x12c> <== NOT EXECUTED
2023de0: f4 1f bf f8 ldd [ %fp + -8 ], %i2 <== NOT EXECUTED
}
else
{
r->malloced = false;
r->initialized = true;
r->area = c->location;
2023de4: c2 24 60 08 st %g1, [ %l1 + 8 ] <== NOT EXECUTED
r->initialized = true;
}
}
else
{
r->malloced = false;
2023de8: c0 2c 60 0d clrb [ %l1 + 0xd ] <== NOT EXECUTED
r->initialized = true;
2023dec: e8 2c 60 0c stb %l4, [ %l1 + 0xc ] <== NOT EXECUTED
r->area = c->location;
}
rc = rtems_disk_create_phys(dev, c->block_size, c->block_num,
2023df0: fa 23 a0 5c st %i5, [ %sp + 0x5c ] <== NOT EXECUTED
2023df4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2023df8: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2023dfc: 98 10 00 1c mov %i4, %o4 <== NOT EXECUTED
2023e00: 7f ff 8e 6d call 20077b4 <rtems_disk_create_phys> <== NOT EXECUTED
2023e04: 9a 10 00 11 mov %l1, %o5 <== NOT EXECUTED
ramdisk_ioctl, r, name);
if (rc != RTEMS_SUCCESSFUL)
2023e08: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023e0c: 22 80 00 08 be,a 2023e2c <ramdisk_initialize+0xe8> <== NOT EXECUTED
2023e10: c2 05 40 00 ld [ %l5 ], %g1 <== NOT EXECUTED
{
if (r->malloced)
2023e14: c2 0c 60 0d ldub [ %l1 + 0xd ], %g1 <== NOT EXECUTED
2023e18: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023e1c: 12 80 00 22 bne 2023ea4 <ramdisk_initialize+0x160> <== NOT EXECUTED
2023e20: 01 00 00 00 nop <== NOT EXECUTED
{
free(r->area);
}
r->initialized = false;
2023e24: c0 2c 60 0c clrb [ %l1 + 0xc ] <== NOT EXECUTED
* so there is no corresponding free(r). Coverity is correct that
* it is never freed but this is not a problem.
*/
r = calloc(rtems_ramdisk_configuration_size, sizeof(struct ramdisk));
r->trace = false;
for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)
2023e28: c2 05 40 00 ld [ %l5 ], %g1 <== NOT EXECUTED
2023e2c: a4 04 a0 01 inc %l2 <== NOT EXECUTED
2023e30: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
2023e34: 08 bf ff ca bleu 2023d5c <ramdisk_initialize+0x18> <== NOT EXECUTED
2023e38: a6 04 e0 0c add %l3, 0xc, %l3 <== NOT EXECUTED
{
dev_t dev = rtems_filesystem_make_dev_t(major, i);
char name [] = RAMDISK_DEVICE_BASE_NAME "a";
name [sizeof(RAMDISK_DEVICE_BASE_NAME)] += i;
r->block_size = c->block_size;
2023e3c: d4 04 c0 00 ld [ %l3 ], %o2 <== NOT EXECUTED
r->block_num = c->block_num;
2023e40: d6 04 e0 04 ld [ %l3 + 4 ], %o3 <== NOT EXECUTED
if (c->location == NULL)
2023e44: c2 04 e0 08 ld [ %l3 + 8 ], %g1 <== NOT EXECUTED
* so there is no corresponding free(r). Coverity is correct that
* it is never freed but this is not a problem.
*/
r = calloc(rtems_ramdisk_configuration_size, sizeof(struct ramdisk));
r->trace = false;
for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)
2023e48: a2 04 60 10 add %l1, 0x10, %l1 <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
2023e4c: f0 27 bf f8 st %i0, [ %fp + -8 ] <== NOT EXECUTED
temp.__overlay.minor = _minor;
2023e50: e4 27 bf fc st %l2, [ %fp + -4 ] <== NOT EXECUTED
{
dev_t dev = rtems_filesystem_make_dev_t(major, i);
char name [] = RAMDISK_DEVICE_BASE_NAME "a";
2023e54: ec 3f bf e8 std %l6, [ %fp + -24 ] <== NOT EXECUTED
name [sizeof(RAMDISK_DEVICE_BASE_NAME)] += i;
2023e58: e4 2f bf f0 stb %l2, [ %fp + -16 ] <== NOT EXECUTED
r->block_size = c->block_size;
2023e5c: d4 24 40 00 st %o2, [ %l1 ] <== NOT EXECUTED
r->block_num = c->block_num;
2023e60: d6 24 60 04 st %o3, [ %l1 + 4 ] <== NOT EXECUTED
if (c->location == NULL)
2023e64: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023e68: 12 bf ff df bne 2023de4 <ramdisk_initialize+0xa0> <== NOT EXECUTED
2023e6c: f4 1f bf f8 ldd [ %fp + -8 ], %i2 <== NOT EXECUTED
{
r->malloced = true;
r->area = malloc(r->block_size * r->block_num);
2023e70: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
2023e74: 90 10 00 0b mov %o3, %o0 <== NOT EXECUTED
2023e78: 7f ff 7b 45 call 2002b8c <.umul> <== NOT EXECUTED
2023e7c: e8 2c 60 0d stb %l4, [ %l1 + 0xd ] <== NOT EXECUTED
2023e80: 7f ff 94 78 call 2009060 <malloc> <== NOT EXECUTED
2023e84: 01 00 00 00 nop <== NOT EXECUTED
if (r->area == NULL) /* No enough memory for this disk */
2023e88: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023e8c: 02 bf ff e6 be 2023e24 <ramdisk_initialize+0xe0> <== NOT EXECUTED
2023e90: d0 24 60 08 st %o0, [ %l1 + 8 ] <== NOT EXECUTED
r->initialized = false;
continue;
}
else
{
r->initialized = true;
2023e94: e8 2c 60 0c stb %l4, [ %l1 + 0xc ] <== NOT EXECUTED
2023e98: d4 04 c0 00 ld [ %l3 ], %o2 <== NOT EXECUTED
2023e9c: 10 bf ff d5 b 2023df0 <ramdisk_initialize+0xac> <== NOT EXECUTED
2023ea0: d6 04 e0 04 ld [ %l3 + 4 ], %o3 <== NOT EXECUTED
ramdisk_ioctl, r, name);
if (rc != RTEMS_SUCCESSFUL)
{
if (r->malloced)
{
free(r->area);
2023ea4: 7f ff 92 8e call 20088dc <free> <== NOT EXECUTED
2023ea8: d0 04 60 08 ld [ %l1 + 8 ], %o0 <== NOT EXECUTED
}
r->initialized = false;
2023eac: 10 bf ff df b 2023e28 <ramdisk_initialize+0xe4> <== NOT EXECUTED
2023eb0: c0 2c 60 0c clrb [ %l1 + 0xc ] <== NOT EXECUTED
0200be78 <ramdisk_ioctl>:
return 0;
}
int
ramdisk_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)
{
200be78: 9d e3 bf a0 save %sp, -96, %sp
switch (req)
200be7c: 03 30 06 10 sethi %hi(0xc0184000), %g1
200be80: 82 10 62 01 or %g1, 0x201, %g1 ! c0184201 <RAM_END+0xbdd84201>
200be84: 80 a6 40 01 cmp %i1, %g1
200be88: 02 80 00 04 be 200be98 <ramdisk_ioctl+0x20>
200be8c: a0 10 00 1a mov %i2, %l0
}
break;
}
default:
return rtems_blkdev_ioctl (dd, req, argp);
200be90: 40 00 0a a8 call 200e930 <rtems_blkdev_ioctl>
200be94: 81 e8 00 00 restore
case RTEMS_BLKIO_REQUEST:
{
rtems_blkdev_request *r = argp;
struct ramdisk *rd = rtems_disk_get_driver_data(dd);
switch (r->req)
200be98: c4 06 80 00 ld [ %i2 ], %g2
200be9c: 80 a0 a0 00 cmp %g2, 0
200bea0: 12 80 00 1d bne 200bf14 <ramdisk_ioctl+0x9c> <== ALWAYS TAKEN
200bea4: e6 06 20 2c ld [ %i0 + 0x2c ], %l3
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk read: start=%d, blocks=%d",
req->bufs[0].block, req->bufnum);
#endif
for (i = 0, sg = req->bufs; i < req->bufnum; i++, sg++)
200bea8: c2 06 a0 10 ld [ %i2 + 0x10 ], %g1 <== NOT EXECUTED
200beac: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200beb0: 02 80 00 11 be 200bef4 <ramdisk_ioctl+0x7c> <== NOT EXECUTED
200beb4: ea 04 e0 08 ld [ %l3 + 8 ], %l5 <== NOT EXECUTED
200beb8: a2 06 a0 18 add %i2, 0x18, %l1 <== NOT EXECUTED
200bebc: a4 10 20 00 clr %l2 <== NOT EXECUTED
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk read: buf=%d block=%d length=%d off=%d addr=%p",
i, sg->block, sg->length, sg->block * rd->block_size,
from + (sg->block * rd->block_size));
#endif
memcpy(sg->buffer, from + (sg->block * rd->block_size), sg->length);
200bec0: d2 04 40 00 ld [ %l1 ], %o1 <== NOT EXECUTED
200bec4: d0 04 c0 00 ld [ %l3 ], %o0 <== NOT EXECUTED
200bec8: 40 00 4b ef call 201ee84 <.umul> <== NOT EXECUTED
200becc: e8 04 60 08 ld [ %l1 + 8 ], %l4 <== NOT EXECUTED
200bed0: d4 04 60 04 ld [ %l1 + 4 ], %o2 <== NOT EXECUTED
200bed4: 92 05 40 08 add %l5, %o0, %o1 <== NOT EXECUTED
200bed8: 40 00 29 7f call 20164d4 <memcpy> <== NOT EXECUTED
200bedc: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk read: start=%d, blocks=%d",
req->bufs[0].block, req->bufnum);
#endif
for (i = 0, sg = req->bufs; i < req->bufnum; i++, sg++)
200bee0: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
200bee4: a4 04 a0 01 inc %l2 <== NOT EXECUTED
200bee8: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED
200beec: 0a bf ff f5 bcs 200bec0 <ramdisk_ioctl+0x48> <== NOT EXECUTED
200bef0: a2 04 60 10 add %l1, 0x10, %l1 <== NOT EXECUTED
to + (sg->block * rd->block_size));
#endif
memcpy(to + (sg->block * rd->block_size), sg->buffer, sg->length);
}
req->status = RTEMS_SUCCESSFUL;
req->req_done(req->done_arg, RTEMS_SUCCESSFUL);
200bef4: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
200bef8: c2 04 20 04 ld [ %l0 + 4 ], %g1 <== NOT EXECUTED
i, sg->block, sg->length, sg->block * rd->block_size,
to + (sg->block * rd->block_size));
#endif
memcpy(to + (sg->block * rd->block_size), sg->buffer, sg->length);
}
req->status = RTEMS_SUCCESSFUL;
200befc: c0 24 20 0c clr [ %l0 + 0xc ] <== NOT EXECUTED
req->req_done(req->done_arg, RTEMS_SUCCESSFUL);
200bf00: 92 10 20 00 clr %o1 <== NOT EXECUTED
200bf04: 9f c0 40 00 call %g1 <== NOT EXECUTED
200bf08: b0 10 20 00 clr %i0 <== NOT EXECUTED
{
case RTEMS_BLKDEV_REQ_READ:
return ramdisk_read(rd, r);
case RTEMS_BLKDEV_REQ_WRITE:
return ramdisk_write(rd, r);
200bf0c: 81 c7 e0 08 ret <== NOT EXECUTED
200bf10: 81 e8 00 00 restore <== NOT EXECUTED
case RTEMS_BLKIO_REQUEST:
{
rtems_blkdev_request *r = argp;
struct ramdisk *rd = rtems_disk_get_driver_data(dd);
switch (r->req)
200bf14: 80 a0 a0 01 cmp %g2, 1
200bf18: 22 80 00 08 be,a 200bf38 <ramdisk_ioctl+0xc0> <== ALWAYS TAKEN
200bf1c: c2 06 a0 10 ld [ %i2 + 0x10 ], %g1
case RTEMS_BLKDEV_REQ_WRITE:
return ramdisk_write(rd, r);
default:
errno = EINVAL;
200bf20: 40 00 27 31 call 2015be4 <__errno> <== NOT EXECUTED
200bf24: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200bf28: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200bf2c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
200bf30: 81 c7 e0 08 ret <== NOT EXECUTED
200bf34: 81 e8 00 00 restore <== NOT EXECUTED
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk write: start=%d, blocks=%d",
req->bufs[0].block, req->bufnum);
#endif
for (i = 0, sg = req->bufs; i < req->bufnum; i++, sg++)
200bf38: 80 a0 60 00 cmp %g1, 0
200bf3c: 02 bf ff ee be 200bef4 <ramdisk_ioctl+0x7c> <== NEVER TAKEN
200bf40: e8 04 e0 08 ld [ %l3 + 8 ], %l4
200bf44: a2 06 a0 18 add %i2, 0x18, %l1
200bf48: a4 10 20 00 clr %l2
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk write: buf=%d block=%d length=%d off=%d addr=%p",
i, sg->block, sg->length, sg->block * rd->block_size,
to + (sg->block * rd->block_size));
#endif
memcpy(to + (sg->block * rd->block_size), sg->buffer, sg->length);
200bf4c: d2 04 40 00 ld [ %l1 ], %o1
200bf50: d0 04 c0 00 ld [ %l3 ], %o0
200bf54: 40 00 4b cc call 201ee84 <.umul>
200bf58: a4 04 a0 01 inc %l2
200bf5c: d2 04 60 08 ld [ %l1 + 8 ], %o1
200bf60: d4 04 60 04 ld [ %l1 + 4 ], %o2
200bf64: 40 00 29 5c call 20164d4 <memcpy>
200bf68: 90 05 00 08 add %l4, %o0, %o0
#if RTEMS_RAMDISK_TRACE
rtems_ramdisk_printf (rd, "ramdisk write: start=%d, blocks=%d",
req->bufs[0].block, req->bufnum);
#endif
for (i = 0, sg = req->bufs; i < req->bufnum; i++, sg++)
200bf6c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
200bf70: 80 a4 80 01 cmp %l2, %g1
200bf74: 0a bf ff f6 bcs 200bf4c <ramdisk_ioctl+0xd4> <== NEVER TAKEN
200bf78: a2 04 60 10 add %l1, 0x10, %l1
to + (sg->block * rd->block_size));
#endif
memcpy(to + (sg->block * rd->block_size), sg->buffer, sg->length);
}
req->status = RTEMS_SUCCESSFUL;
req->req_done(req->done_arg, RTEMS_SUCCESSFUL);
200bf7c: d0 04 20 08 ld [ %l0 + 8 ], %o0
200bf80: c2 04 20 04 ld [ %l0 + 4 ], %g1
i, sg->block, sg->length, sg->block * rd->block_size,
to + (sg->block * rd->block_size));
#endif
memcpy(to + (sg->block * rd->block_size), sg->buffer, sg->length);
}
req->status = RTEMS_SUCCESSFUL;
200bf84: c0 24 20 0c clr [ %l0 + 0xc ]
req->req_done(req->done_arg, RTEMS_SUCCESSFUL);
200bf88: 92 10 20 00 clr %o1
200bf8c: 9f c0 40 00 call %g1
200bf90: b0 10 20 00 clr %i0
{
case RTEMS_BLKDEV_REQ_READ:
return ramdisk_read(rd, r);
case RTEMS_BLKDEV_REQ_WRITE:
return ramdisk_write(rd, r);
200bf94: 81 c7 e0 08 ret
200bf98: 81 e8 00 00 restore
0200c050 <ramdisk_register>:
rtems_blkdev_bnum block_count,
bool trace,
const char *disk,
dev_t *dev_ptr
)
{
200c050: 9d e3 bf 90 save %sp, -112, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_device_major_number major = 0;
ramdisk *rd = NULL;
dev_t dev = 0;
sc = rtems_io_register_driver(0, &ramdisk_ops, &major);
200c054: 90 10 20 00 clr %o0
const char *disk,
dev_t *dev_ptr
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_device_major_number major = 0;
200c058: c0 27 bf fc clr [ %fp + -4 ]
rtems_blkdev_bnum block_count,
bool trace,
const char *disk,
dev_t *dev_ptr
)
{
200c05c: a0 10 00 18 mov %i0, %l0
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_device_major_number major = 0;
ramdisk *rd = NULL;
dev_t dev = 0;
sc = rtems_io_register_driver(0, &ramdisk_ops, &major);
200c060: 13 00 80 85 sethi %hi(0x2021400), %o1
200c064: 94 07 bf fc add %fp, -4, %o2
200c068: 92 12 62 84 or %o1, 0x284, %o1
200c06c: 7f ff f0 ee call 2008424 <rtems_io_register_driver>
200c070: b0 10 20 0d mov 0xd, %i0
if (sc != RTEMS_SUCCESSFUL) {
200c074: 80 a2 20 00 cmp %o0, 0
200c078: 12 80 00 1d bne 200c0ec <ramdisk_register+0x9c> <== NEVER TAKEN
200c07c: 96 0e a0 ff and %i2, 0xff, %o3
return RTEMS_UNSATISFIED;
}
rd = ramdisk_allocate(NULL, block_size, block_count, trace);
200c080: 92 10 00 10 mov %l0, %o1
200c084: 7f ff ff d6 call 200bfdc <ramdisk_allocate>
200c088: 94 10 00 19 mov %i1, %o2
if (rd == NULL) {
200c08c: a2 92 20 00 orcc %o0, 0, %l1
200c090: 02 80 00 19 be 200c0f4 <ramdisk_register+0xa4> <== NEVER TAKEN
200c094: e4 07 bf fc ld [ %fp + -4 ], %l2
return RTEMS_UNSATISFIED;
}
dev = rtems_filesystem_make_dev_t(major, 0);
sc = rtems_disk_create_phys(
200c098: f6 23 a0 5c st %i3, [ %sp + 0x5c ]
200c09c: 94 10 00 10 mov %l0, %o2
200c0a0: 96 10 00 19 mov %i1, %o3
200c0a4: 90 10 00 12 mov %l2, %o0
200c0a8: 92 10 20 00 clr %o1
200c0ac: 19 00 80 2f sethi %hi(0x200bc00), %o4
200c0b0: 9a 10 00 11 mov %l1, %o5
200c0b4: 7f ff dc 4c call 20031e4 <rtems_disk_create_phys>
200c0b8: 98 13 22 78 or %o4, 0x278, %o4
block_count,
ramdisk_ioctl,
rd,
disk
);
if (sc != RTEMS_SUCCESSFUL) {
200c0bc: 80 a2 20 00 cmp %o0, 0
200c0c0: 12 80 00 06 bne 200c0d8 <ramdisk_register+0x88> <== NEVER TAKEN
200c0c4: 01 00 00 00 nop
rtems_io_unregister_driver(major);
return RTEMS_UNSATISFIED;
}
*dev_ptr = dev;
200c0c8: e4 27 00 00 st %l2, [ %i4 ]
200c0cc: c0 27 20 04 clr [ %i4 + 4 ]
return RTEMS_SUCCESSFUL;
}
200c0d0: 81 c7 e0 08 ret
200c0d4: 91 e8 20 00 restore %g0, 0, %o0
ramdisk_ioctl,
rd,
disk
);
if (sc != RTEMS_SUCCESSFUL) {
ramdisk_free(rd);
200c0d8: 7f ff ff b1 call 200bf9c <ramdisk_free> <== NOT EXECUTED
200c0dc: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_io_unregister_driver(major);
200c0e0: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
200c0e4: 7f ff f1 33 call 20085b0 <rtems_io_unregister_driver> <== NOT EXECUTED
200c0e8: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED
return RTEMS_UNSATISFIED;
200c0ec: 81 c7 e0 08 ret <== NOT EXECUTED
200c0f0: 81 e8 00 00 restore <== NOT EXECUTED
return RTEMS_UNSATISFIED;
}
rd = ramdisk_allocate(NULL, block_size, block_count, trace);
if (rd == NULL) {
rtems_io_unregister_driver(major);
200c0f4: 7f ff f1 2f call 20085b0 <rtems_io_unregister_driver> <== NOT EXECUTED
200c0f8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
return RTEMS_UNSATISFIED;
200c0fc: 81 c7 e0 08 ret <== NOT EXECUTED
200c100: 81 e8 00 00 restore <== NOT EXECUTED
0201c708 <read>:
ssize_t read(
int fd,
void *buffer,
size_t count
)
{
201c708: 9d e3 bf a0 save %sp, -96, %sp
ssize_t rc;
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
201c70c: 03 00 80 79 sethi %hi(0x201e400), %g1
201c710: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
201c714: 80 a6 00 01 cmp %i0, %g1
201c718: 1a 80 00 23 bcc 201c7a4 <read+0x9c> <== NEVER TAKEN
201c71c: 03 00 80 7c sethi %hi(0x201f000), %g1
iop = rtems_libio_iop( fd );
201c720: e0 00 61 c4 ld [ %g1 + 0x1c4 ], %l0 ! 201f1c4 <rtems_libio_iops>
201c724: 83 2e 20 06 sll %i0, 6, %g1
201c728: b1 2e 20 03 sll %i0, 3, %i0
201c72c: b0 06 00 01 add %i0, %g1, %i0
201c730: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open( iop );
201c734: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
201c738: 80 88 61 00 btst 0x100, %g1
201c73c: 02 80 00 1a be 201c7a4 <read+0x9c>
201c740: 80 a6 60 00 cmp %i1, 0
rtems_libio_check_buffer( buffer );
201c744: 02 80 00 24 be 201c7d4 <read+0xcc> <== NEVER TAKEN
201c748: 80 a6 a0 00 cmp %i2, 0
rtems_libio_check_count( count );
201c74c: 02 80 00 14 be 201c79c <read+0x94> <== NEVER TAKEN
201c750: b0 10 20 00 clr %i0
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_READ, EBADF );
201c754: 80 88 60 02 btst 2, %g1
201c758: 02 80 00 13 be 201c7a4 <read+0x9c> <== NEVER TAKEN
201c75c: 01 00 00 00 nop
/*
* Now process the read().
*/
if ( !iop->handlers->read_h )
201c760: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
201c764: c2 00 60 08 ld [ %g1 + 8 ], %g1
201c768: 80 a0 60 00 cmp %g1, 0
201c76c: 02 80 00 14 be 201c7bc <read+0xb4> <== NEVER TAKEN
201c770: 92 10 00 19 mov %i1, %o1
rtems_set_errno_and_return_minus_one( ENOTSUP );
rc = (*iop->handlers->read_h)( iop, buffer, count );
201c774: 94 10 00 1a mov %i2, %o2
201c778: 9f c0 40 00 call %g1
201c77c: 90 10 00 10 mov %l0, %o0
if ( rc > 0 )
201c780: b0 92 20 00 orcc %o0, 0, %i0
201c784: 04 80 00 06 ble 201c79c <read+0x94>
201c788: 85 3e 20 1f sra %i0, 0x1f, %g2
iop->offset += rc;
201c78c: d8 1c 20 10 ldd [ %l0 + 0x10 ], %o4
201c790: 86 83 40 18 addcc %o5, %i0, %g3
201c794: 84 43 00 02 addx %o4, %g2, %g2
201c798: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
return rc;
}
201c79c: 81 c7 e0 08 ret
201c7a0: 81 e8 00 00 restore
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_buffer( buffer );
rtems_libio_check_count( count );
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_READ, EBADF );
201c7a4: 7f ff d4 96 call 20119fc <__errno>
201c7a8: b0 10 3f ff mov -1, %i0
201c7ac: 82 10 20 09 mov 9, %g1
201c7b0: c2 22 00 00 st %g1, [ %o0 ]
201c7b4: 81 c7 e0 08 ret
201c7b8: 81 e8 00 00 restore
/*
* Now process the read().
*/
if ( !iop->handlers->read_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
201c7bc: 7f ff d4 90 call 20119fc <__errno> <== NOT EXECUTED
201c7c0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201c7c4: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
201c7c8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201c7cc: 81 c7 e0 08 ret <== NOT EXECUTED
201c7d0: 81 e8 00 00 restore <== NOT EXECUTED
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_buffer( buffer );
201c7d4: 7f ff d4 8a call 20119fc <__errno> <== NOT EXECUTED
201c7d8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201c7dc: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
201c7e0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201c7e4: 81 c7 e0 08 ret <== NOT EXECUTED
201c7e8: 81 e8 00 00 restore <== NOT EXECUTED
0202e344 <readlink>:
ssize_t readlink(
const char *pathname,
char *buf,
size_t bufsize
)
{
202e344: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc;
int result;
if (!buf)
202e348: 80 a6 60 00 cmp %i1, 0
202e34c: 02 80 00 2b be 202e3f8 <readlink+0xb4> <== NEVER TAKEN
202e350: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ),
202e354: 40 00 8c 07 call 2051370 <strlen>
202e358: 90 10 00 18 mov %i0, %o0
202e35c: a0 07 bf ec add %fp, -20, %l0
202e360: 92 10 00 08 mov %o0, %o1
202e364: 94 10 20 00 clr %o2
202e368: 90 10 00 18 mov %i0, %o0
202e36c: 96 10 00 10 mov %l0, %o3
202e370: 98 10 20 00 clr %o4
202e374: 7f ff 69 3b call 2008860 <rtems_filesystem_evaluate_path>
202e378: b0 10 3f ff mov -1, %i0
0, &loc, false );
if ( result != 0 )
202e37c: 80 a2 20 00 cmp %o0, 0
202e380: 12 80 00 1c bne 202e3f0 <readlink+0xac> <== NEVER TAKEN
202e384: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1;
if ( !loc.ops->node_type_h ){
202e388: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1
202e38c: 80 a0 60 00 cmp %g1, 0
202e390: 22 80 00 31 be,a 202e454 <readlink+0x110> <== NEVER TAKEN
202e394: 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 ){
202e398: 9f c0 40 00 call %g1
202e39c: 90 10 00 10 mov %l0, %o0
202e3a0: 80 a2 20 04 cmp %o0, 4
202e3a4: 12 80 00 1b bne 202e410 <readlink+0xcc>
202e3a8: c4 07 bf f8 ld [ %fp + -8 ], %g2
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( !loc.ops->readlink_h ){
202e3ac: c2 00 a0 3c ld [ %g2 + 0x3c ], %g1
202e3b0: 80 a0 60 00 cmp %g1, 0
202e3b4: 02 80 00 27 be 202e450 <readlink+0x10c> <== NEVER TAKEN
202e3b8: 92 10 00 19 mov %i1, %o1
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.ops->readlink_h)( &loc, buf, bufsize );
202e3bc: 94 10 00 1a mov %i2, %o2
202e3c0: 9f c0 40 00 call %g1
202e3c4: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
202e3c8: c2 07 bf f8 ld [ %fp + -8 ], %g1
202e3cc: 80 a0 60 00 cmp %g1, 0
202e3d0: 02 80 00 08 be 202e3f0 <readlink+0xac> <== NEVER TAKEN
202e3d4: b0 10 00 08 mov %o0, %i0
202e3d8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e3dc: 80 a0 60 00 cmp %g1, 0
202e3e0: 02 80 00 26 be 202e478 <readlink+0x134> <== NEVER TAKEN
202e3e4: 01 00 00 00 nop
202e3e8: 9f c0 40 00 call %g1
202e3ec: 90 10 00 10 mov %l0, %o0
return result;
}
202e3f0: 81 c7 e0 08 ret
202e3f4: 81 e8 00 00 restore
{
rtems_filesystem_location_info_t loc;
int result;
if (!buf)
rtems_set_errno_and_return_minus_one( EFAULT );
202e3f8: 40 00 70 22 call 204a480 <__errno> <== NOT EXECUTED
202e3fc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202e400: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
202e404: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202e408: 81 c7 e0 08 ret <== NOT EXECUTED
202e40c: 81 e8 00 00 restore <== 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 ){
rtems_filesystem_freenode( &loc );
202e410: c2 07 bf f8 ld [ %fp + -8 ], %g1
202e414: 80 a0 60 00 cmp %g1, 0
202e418: 02 80 00 08 be 202e438 <readlink+0xf4> <== NEVER TAKEN
202e41c: 01 00 00 00 nop
202e420: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e424: 80 a0 60 00 cmp %g1, 0
202e428: 02 80 00 04 be 202e438 <readlink+0xf4> <== NEVER TAKEN
202e42c: 01 00 00 00 nop
202e430: 9f c0 40 00 call %g1
202e434: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( EINVAL );
202e438: 40 00 70 12 call 204a480 <__errno>
202e43c: b0 10 3f ff mov -1, %i0
202e440: 82 10 20 16 mov 0x16, %g1
202e444: c2 22 00 00 st %g1, [ %o0 ]
202e448: 81 c7 e0 08 ret
202e44c: 81 e8 00 00 restore
}
if ( !loc.ops->readlink_h ){
rtems_filesystem_freenode( &loc );
202e450: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
202e454: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e458: 02 80 00 04 be 202e468 <readlink+0x124> <== NOT EXECUTED
202e45c: 01 00 00 00 nop <== NOT EXECUTED
202e460: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e464: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202e468: 40 00 70 06 call 204a480 <__errno> <== NOT EXECUTED
202e46c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202e470: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202e474: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202e478: 81 c7 e0 08 ret <== NOT EXECUTED
202e47c: 81 e8 00 00 restore <== NOT EXECUTED
02004b90 <readv>:
ssize_t readv(
int fd,
const struct iovec *iov,
int iovcnt
)
{
2004b90: 9d e3 bf a0 save %sp, -96, %sp
int v;
int bytes;
rtems_libio_t *iop;
bool all_zeros;
rtems_libio_check_fd( fd );
2004b94: 03 00 80 84 sethi %hi(0x2021000), %g1
2004b98: c2 00 63 d4 ld [ %g1 + 0x3d4 ], %g1 ! 20213d4 <rtems_libio_number_iops>
2004b9c: 80 a6 00 01 cmp %i0, %g1
2004ba0: 1a 80 00 50 bcc 2004ce0 <readv+0x150> <== NEVER TAKEN
2004ba4: 03 00 80 89 sethi %hi(0x2022400), %g1
iop = rtems_libio_iop( fd );
2004ba8: e4 00 61 b4 ld [ %g1 + 0x1b4 ], %l2 ! 20225b4 <rtems_libio_iops>
2004bac: 83 2e 20 06 sll %i0, 6, %g1
2004bb0: b1 2e 20 03 sll %i0, 3, %i0
2004bb4: b0 06 00 01 add %i0, %g1, %i0
2004bb8: a4 04 80 18 add %l2, %i0, %l2
rtems_libio_check_is_open( iop );
2004bbc: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1
2004bc0: 80 88 61 00 btst 0x100, %g1
2004bc4: 02 80 00 47 be 2004ce0 <readv+0x150> <== NEVER TAKEN
2004bc8: 80 88 60 02 btst 2, %g1
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_READ, EBADF );
2004bcc: 02 80 00 45 be 2004ce0 <readv+0x150> <== NEVER TAKEN
2004bd0: 80 a6 60 00 cmp %i1, 0
/*
* Argument validation on IO vector
*/
if ( !iov )
2004bd4: 02 80 00 24 be 2004c64 <readv+0xd4>
2004bd8: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL );
if ( iovcnt <= 0 )
2004bdc: 04 80 00 22 ble 2004c64 <readv+0xd4>
2004be0: 80 a6 a4 00 cmp %i2, 0x400
rtems_set_errno_and_return_minus_one( EINVAL );
if ( iovcnt > IOV_MAX )
2004be4: 14 80 00 20 bg 2004c64 <readv+0xd4> <== NEVER TAKEN
2004be8: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !iop->handlers->read_h )
2004bec: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1
2004bf0: c2 00 60 08 ld [ %g1 + 8 ], %g1
2004bf4: 80 a0 60 00 cmp %g1, 0
2004bf8: 02 80 00 42 be 2004d00 <readv+0x170> <== NEVER TAKEN
2004bfc: 96 10 20 01 mov 1, %o3
rtems_set_errno_and_return_minus_one( ENOTSUP );
2004c00: 84 10 00 19 mov %i1, %g2
2004c04: 86 10 20 00 clr %g3
2004c08: 10 80 00 03 b 2004c14 <readv+0x84>
2004c0c: 88 10 20 00 clr %g4
* 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++ ) {
2004c10: 88 10 00 0c mov %o4, %g4
ssize_t old;
if ( !iov[v].iov_base )
2004c14: da 00 80 00 ld [ %g2 ], %o5
2004c18: 80 a3 60 00 cmp %o5, 0
2004c1c: 02 80 00 12 be 2004c64 <readv+0xd4>
2004c20: 86 00 e0 01 inc %g3
if ( iov[v].iov_len < 0 )
rtems_set_errno_and_return_minus_one( EINVAL );
/* check for wrap */
old = total;
total += iov[v].iov_len;
2004c24: da 00 a0 04 ld [ %g2 + 4 ], %o5
2004c28: 98 01 00 0d add %g4, %o5, %o4
if ( total < old )
2004c2c: 80 a3 00 04 cmp %o4, %g4
2004c30: 06 80 00 0d bl 2004c64 <readv+0xd4>
2004c34: 84 00 a0 08 add %g2, 8, %g2
rtems_set_errno_and_return_minus_one( EINVAL );
if ( iov[v].iov_len )
2004c38: 80 a0 00 0d cmp %g0, %o5
2004c3c: 88 40 3f ff addx %g0, -1, %g4
* 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++ ) {
2004c40: 80 a6 80 03 cmp %i2, %g3
2004c44: 14 bf ff f3 bg 2004c10 <readv+0x80>
2004c48: 96 0a c0 04 and %o3, %g4, %o3
/*
* 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 ) {
2004c4c: 80 8a e0 ff btst 0xff, %o3
2004c50: a6 10 20 00 clr %l3
2004c54: 02 80 00 0c be 2004c84 <readv+0xf4>
2004c58: b0 10 20 00 clr %i0
if (bytes != iov[ v ].iov_len)
break;
}
return total;
}
2004c5c: 81 c7 e0 08 ret
2004c60: 81 e8 00 00 restore
/* check for wrap */
old = total;
total += iov[v].iov_len;
if ( total < old )
rtems_set_errno_and_return_minus_one( EINVAL );
2004c64: 40 00 37 e9 call 2012c08 <__errno>
2004c68: b0 10 3f ff mov -1, %i0
2004c6c: 82 10 20 16 mov 0x16, %g1
2004c70: c2 22 00 00 st %g1, [ %o0 ]
2004c74: 81 c7 e0 08 ret
2004c78: 81 e8 00 00 restore
}
/*
* Now process the readv().
*/
for ( total=0, v=0 ; v < iovcnt ; v++ ) {
2004c7c: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1
2004c80: c2 00 60 08 ld [ %g1 + 8 ], %g1
bytes = (*iop->handlers->read_h)( iop, iov[v].iov_base, iov[v].iov_len );
2004c84: d2 06 40 00 ld [ %i1 ], %o1
2004c88: d4 06 60 04 ld [ %i1 + 4 ], %o2
2004c8c: 9f c0 40 00 call %g1
2004c90: 90 10 00 12 mov %l2, %o0
if ( bytes < 0 )
2004c94: 80 a2 20 00 cmp %o0, 0
2004c98: 06 80 00 18 bl 2004cf8 <readv+0x168> <== NEVER TAKEN
2004c9c: 01 00 00 00 nop
return -1;
if ( bytes > 0 ) {
2004ca0: 02 80 00 07 be 2004cbc <readv+0x12c> <== NEVER TAKEN
2004ca4: a1 3a 20 1f sra %o0, 0x1f, %l0
iop->offset += bytes;
2004ca8: c4 1c a0 10 ldd [ %l2 + 0x10 ], %g2
2004cac: 86 80 c0 08 addcc %g3, %o0, %g3
total += bytes;
2004cb0: b0 06 00 08 add %i0, %o0, %i0
if ( bytes < 0 )
return -1;
if ( bytes > 0 ) {
iop->offset += bytes;
2004cb4: 84 40 80 10 addx %g2, %l0, %g2
2004cb8: c4 3c a0 10 std %g2, [ %l2 + 0x10 ]
total += bytes;
}
if (bytes != iov[ v ].iov_len)
2004cbc: c2 06 60 04 ld [ %i1 + 4 ], %g1
2004cc0: 80 a2 00 01 cmp %o0, %g1
2004cc4: 12 bf ff e6 bne 2004c5c <readv+0xcc> <== NEVER TAKEN
2004cc8: a6 04 e0 01 inc %l3
}
/*
* Now process the readv().
*/
for ( total=0, v=0 ; v < iovcnt ; v++ ) {
2004ccc: 80 a6 80 13 cmp %i2, %l3
2004cd0: 14 bf ff eb bg 2004c7c <readv+0xec>
2004cd4: b2 06 60 08 add %i1, 8, %i1
if (bytes != iov[ v ].iov_len)
break;
}
return total;
}
2004cd8: 81 c7 e0 08 ret
2004cdc: 81 e8 00 00 restore
bool all_zeros;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_READ, EBADF );
2004ce0: 40 00 37 ca call 2012c08 <__errno> <== NOT EXECUTED
2004ce4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2004ce8: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
2004cec: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2004cf0: 81 c7 e0 08 ret <== NOT EXECUTED
2004cf4: 81 e8 00 00 restore <== NOT EXECUTED
if (bytes != iov[ v ].iov_len)
break;
}
return total;
}
2004cf8: 81 c7 e0 08 ret <== NOT EXECUTED
2004cfc: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
if ( iovcnt > IOV_MAX )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !iop->handlers->read_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
2004d00: 40 00 37 c2 call 2012c08 <__errno> <== NOT EXECUTED
2004d04: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2004d08: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2004d0c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2004d10: 81 c7 e0 08 ret <== NOT EXECUTED
2004d14: 81 e8 00 00 restore <== NOT EXECUTED
0201c870 <realloc>:
{
uintptr_t old_size;
char *new_area;
uintptr_t resize;
MSBUMP(realloc_calls, 1);
201c870: 9d e3 bf 98 save %sp, -104, %sp
201c874: 21 00 80 7c sethi %hi(0x201f000), %l0
201c878: a0 14 21 e0 or %l0, 0x1e0, %l0 ! 201f1e0 <rtems_malloc_statistics>
201c87c: c4 04 20 10 ld [ %l0 + 0x10 ], %g2
/*
* Do not attempt to allocate memory if in a critical section or ISR.
*/
if (_System_state_Is_up(_System_state_Get())) {
201c880: 03 00 80 7d sethi %hi(0x201f400), %g1
201c884: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 201f540 <_System_state_Current>
{
uintptr_t old_size;
char *new_area;
uintptr_t resize;
MSBUMP(realloc_calls, 1);
201c888: 84 00 a0 01 inc %g2
/*
* Do not attempt to allocate memory if in a critical section or ISR.
*/
if (_System_state_Is_up(_System_state_Get())) {
201c88c: 80 a0 60 03 cmp %g1, 3
201c890: 02 80 00 36 be 201c968 <realloc+0xf8> <== ALWAYS TAKEN
201c894: c4 24 20 10 st %g2, [ %l0 + 0x10 ]
}
/*
* Continue with realloc().
*/
if ( !ptr )
201c898: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
201c89c: 02 80 00 3e be 201c994 <realloc+0x124>
201c8a0: 80 a6 60 00 cmp %i1, 0
return malloc( size );
if ( !size ) {
201c8a4: 02 80 00 11 be 201c8e8 <realloc+0x78> <== NEVER TAKEN
201c8a8: 23 00 80 79 sethi %hi(0x201e400), %l1
free( ptr );
return (void *) 0;
}
if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) {
201c8ac: d0 04 63 c0 ld [ %l1 + 0x3c0 ], %o0 ! 201e7c0 <RTEMS_Malloc_Heap>
201c8b0: 92 10 00 18 mov %i0, %o1
201c8b4: 40 00 00 75 call 201ca88 <_Protected_heap_Get_block_size>
201c8b8: 94 07 bf fc add %fp, -4, %o2
201c8bc: 80 8a 20 ff btst 0xff, %o0
201c8c0: 02 80 00 0f be 201c8fc <realloc+0x8c>
201c8c4: d0 04 63 c0 ld [ %l1 + 0x3c0 ], %o0
#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 ) ) {
201c8c8: 92 10 00 18 mov %i0, %o1
201c8cc: 40 00 00 7c call 201cabc <_Protected_heap_Resize_block>
201c8d0: 94 10 00 19 mov %i1, %o2
201c8d4: 80 8a 20 ff btst 0xff, %o0
201c8d8: 02 80 00 0f be 201c914 <realloc+0xa4>
201c8dc: 01 00 00 00 nop
memcpy( new_area, ptr, (size < old_size) ? size : old_size );
free( ptr );
return new_area;
}
201c8e0: 81 c7 e0 08 ret
201c8e4: 81 e8 00 00 restore
*/
if ( !ptr )
return malloc( size );
if ( !size ) {
free( ptr );
201c8e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
201c8ec: 7f ff 99 00 call 2002cec <free> <== NOT EXECUTED
201c8f0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return (void *) 0;
201c8f4: 81 c7 e0 08 ret <== NOT EXECUTED
201c8f8: 81 e8 00 00 restore <== NOT EXECUTED
}
if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) {
errno = EINVAL;
201c8fc: 7f ff d4 40 call 20119fc <__errno>
201c900: b0 10 20 00 clr %i0
201c904: 82 10 20 16 mov 0x16, %g1
201c908: c2 22 00 00 st %g1, [ %o0 ]
return (void *) 0;
201c90c: 81 c7 e0 08 ret
201c910: 81 e8 00 00 restore
* 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 );
201c914: 7f ff 99 de call 200308c <malloc>
201c918: 90 10 00 19 mov %i1, %o0
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
201c91c: c2 04 20 04 ld [ %l0 + 4 ], %g1
* 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 );
201c920: a2 10 00 08 mov %o0, %l1
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
201c924: 82 00 7f ff add %g1, -1, %g1
if ( !new_area ) {
201c928: 80 a2 20 00 cmp %o0, 0
201c92c: 02 80 00 18 be 201c98c <realloc+0x11c>
201c930: c2 24 20 04 st %g1, [ %l0 + 4 ]
return (void *) 0;
}
memcpy( new_area, ptr, (size < old_size) ? size : old_size );
201c934: c2 07 bf fc ld [ %fp + -4 ], %g1
201c938: 80 a6 40 01 cmp %i1, %g1
201c93c: 08 80 00 03 bleu 201c948 <realloc+0xd8> <== NEVER TAKEN
201c940: 94 10 00 19 mov %i1, %o2
201c944: 94 10 00 01 mov %g1, %o2
201c948: 92 10 00 18 mov %i0, %o1
201c94c: 7f ff d6 68 call 20122ec <memcpy>
201c950: 90 10 00 11 mov %l1, %o0
free( ptr );
201c954: 90 10 00 18 mov %i0, %o0
201c958: 7f ff 98 e5 call 2002cec <free>
201c95c: b0 10 00 11 mov %l1, %i0
return new_area;
201c960: 81 c7 e0 08 ret
201c964: 81 e8 00 00 restore
/*
* Do not attempt to allocate memory if in a critical section or ISR.
*/
if (_System_state_Is_up(_System_state_Get())) {
if (_Thread_Dispatch_disable_level > 0)
201c968: 03 00 80 7c sethi %hi(0x201f000), %g1
201c96c: c2 00 63 a0 ld [ %g1 + 0x3a0 ], %g1 ! 201f3a0 <_Thread_Dispatch_disable_level>
201c970: 80 a0 60 00 cmp %g1, 0
201c974: 12 80 00 06 bne 201c98c <realloc+0x11c> <== NEVER TAKEN
201c978: 03 00 80 7d sethi %hi(0x201f400), %g1
return (void *) 0;
if (_ISR_Nest_level > 0)
201c97c: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 ! 201f43c <_ISR_Nest_level>
201c980: 80 a0 60 00 cmp %g1, 0
201c984: 02 bf ff c6 be 201c89c <realloc+0x2c> <== ALWAYS TAKEN
201c988: 80 a6 20 00 cmp %i0, 0
memcpy( new_area, ptr, (size < old_size) ? size : old_size );
free( ptr );
return new_area;
}
201c98c: 81 c7 e0 08 ret
201c990: 91 e8 20 00 restore %g0, 0, %o0
/*
* Continue with realloc().
*/
if ( !ptr )
return malloc( size );
201c994: 7f ff 99 be call 200308c <malloc>
201c998: 90 10 00 19 mov %i1, %o0
201c99c: 81 c7 e0 08 ret
201c9a0: 91 e8 00 08 restore %g0, %o0, %o0
0202e480 <rmdir>:
#include <rtems/seterr.h>
int rmdir(
const char *pathname
)
{
202e480: 9d e3 bf 70 save %sp, -144, %sp
/*
* Get the parent node of the node we wish to remove. Find the parent path.
*/
parentpathlen = rtems_filesystem_dirname ( pathname );
202e484: 7f ff 68 a3 call 2008710 <rtems_filesystem_dirname>
202e488: 90 10 00 18 mov %i0, %o0
if ( parentpathlen == 0 )
202e48c: 80 a2 20 00 cmp %o0, 0
202e490: 12 80 00 6a bne 202e638 <rmdir+0x1b8>
202e494: a2 07 bf e8 add %fp, -24, %l1
rtems_filesystem_get_start_loc( pathname, &i, &parentloc );
202e498: 90 10 00 18 mov %i0, %o0
202e49c: 92 07 bf fc add %fp, -4, %o1
202e4a0: 94 10 00 11 mov %l1, %o2
202e4a4: 7f ff 70 11 call 200a4e8 <rtems_filesystem_get_start_loc>
202e4a8: a0 10 20 00 clr %l0
202e4ac: a4 10 20 00 clr %l2
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
202e4b0: c2 07 bf e8 ld [ %fp + -24 ], %g1
name = pathname + parentpathlen;
202e4b4: b0 06 00 10 add %i0, %l0, %i0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
202e4b8: c2 27 bf d4 st %g1, [ %fp + -44 ]
202e4bc: c2 07 bf ec ld [ %fp + -20 ], %g1
name = pathname + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
202e4c0: 90 10 00 18 mov %i0, %o0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
202e4c4: c2 27 bf d8 st %g1, [ %fp + -40 ]
202e4c8: c2 07 bf f0 ld [ %fp + -16 ], %g1
name = pathname + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
202e4cc: a0 07 bf d4 add %fp, -44, %l0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
202e4d0: c2 27 bf dc st %g1, [ %fp + -36 ]
202e4d4: c2 07 bf f4 ld [ %fp + -12 ], %g1
202e4d8: c2 27 bf e0 st %g1, [ %fp + -32 ]
202e4dc: c2 07 bf f8 ld [ %fp + -8 ], %g1
name = pathname + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
202e4e0: 40 00 8b a4 call 2051370 <strlen>
202e4e4: c2 27 bf e4 st %g1, [ %fp + -28 ]
202e4e8: 92 10 00 08 mov %o0, %o1
202e4ec: 7f ff 68 6e call 20086a4 <rtems_filesystem_prefix_separators>
202e4f0: 90 10 00 18 mov %i0, %o0
202e4f4: b0 06 00 08 add %i0, %o0, %i0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
202e4f8: 40 00 8b 9e call 2051370 <strlen>
202e4fc: 90 10 00 18 mov %i0, %o0
202e500: 94 10 20 00 clr %o2
202e504: 92 10 00 08 mov %o0, %o1
202e508: 96 10 00 10 mov %l0, %o3
202e50c: 90 10 00 18 mov %i0, %o0
202e510: 7f ff 68 93 call 200875c <rtems_filesystem_evaluate_relative_path>
202e514: 98 10 20 00 clr %o4
0, &loc, false );
if ( result != 0 ) {
202e518: 80 a2 20 00 cmp %o0, 0
202e51c: 12 80 00 53 bne 202e668 <rmdir+0x1e8>
202e520: c4 07 bf e0 ld [ %fp + -32 ], %g2
/*
* Verify you can remove this node as a directory.
*/
if ( !loc.ops->node_type_h ){
202e524: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1
202e528: 80 a0 60 00 cmp %g1, 0
202e52c: 22 80 00 7a be,a 202e714 <rmdir+0x294> <== NEVER TAKEN
202e530: 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 ){
202e534: 9f c0 40 00 call %g1
202e538: 90 10 00 10 mov %l0, %o0
202e53c: 80 a2 20 01 cmp %o0, 1
202e540: 12 80 00 22 bne 202e5c8 <rmdir+0x148>
202e544: c2 07 bf dc ld [ %fp + -36 ], %g1
/*
* Use the filesystems rmnod to remove the node.
*/
if ( !loc.handlers->rmnod_h ){
202e548: c2 00 60 34 ld [ %g1 + 0x34 ], %g1
202e54c: 80 a0 60 00 cmp %g1, 0
202e550: 02 80 00 55 be 202e6a4 <rmdir+0x224> <== NEVER TAKEN
202e554: 90 10 00 11 mov %l1, %o0
if ( free_parentloc )
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.handlers->rmnod_h)( &parentloc, &loc );
202e558: 9f c0 40 00 call %g1
202e55c: 92 10 00 10 mov %l0, %o1
rtems_filesystem_freenode( &loc );
202e560: c2 07 bf e0 ld [ %fp + -32 ], %g1
202e564: 80 a0 60 00 cmp %g1, 0
202e568: 02 80 00 08 be 202e588 <rmdir+0x108> <== NEVER TAKEN
202e56c: b0 10 00 08 mov %o0, %i0
202e570: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e574: 80 a0 60 00 cmp %g1, 0
202e578: 02 80 00 05 be 202e58c <rmdir+0x10c> <== NEVER TAKEN
202e57c: 80 8c a0 ff btst 0xff, %l2
202e580: 9f c0 40 00 call %g1
202e584: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
202e588: 80 8c a0 ff btst 0xff, %l2
202e58c: 02 80 00 0b be 202e5b8 <rmdir+0x138>
202e590: c2 07 bf f4 ld [ %fp + -12 ], %g1
rtems_filesystem_freenode( &parentloc );
202e594: 80 a0 60 00 cmp %g1, 0
202e598: 02 80 00 5d be 202e70c <rmdir+0x28c> <== NEVER TAKEN
202e59c: 01 00 00 00 nop
202e5a0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e5a4: 80 a0 60 00 cmp %g1, 0
202e5a8: 02 80 00 59 be 202e70c <rmdir+0x28c> <== NEVER TAKEN
202e5ac: 01 00 00 00 nop
202e5b0: 9f c0 40 00 call %g1
202e5b4: 90 10 00 11 mov %l1, %o0
202e5b8: 81 c7 e0 08 ret
202e5bc: 81 e8 00 00 restore
return result;
}
202e5c0: 81 c7 e0 08 ret <== NOT EXECUTED
202e5c4: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ){
rtems_filesystem_freenode( &loc );
202e5c8: c2 07 bf e0 ld [ %fp + -32 ], %g1
202e5cc: 80 a0 60 00 cmp %g1, 0
202e5d0: 02 80 00 09 be 202e5f4 <rmdir+0x174> <== NEVER TAKEN
202e5d4: 80 8c a0 ff btst 0xff, %l2
202e5d8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e5dc: 80 a0 60 00 cmp %g1, 0
202e5e0: 02 80 00 05 be 202e5f4 <rmdir+0x174> <== NEVER TAKEN
202e5e4: 80 8c a0 ff btst 0xff, %l2
202e5e8: 9f c0 40 00 call %g1
202e5ec: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
202e5f0: 80 8c a0 ff btst 0xff, %l2
202e5f4: 02 80 00 0b be 202e620 <rmdir+0x1a0> <== NEVER TAKEN
202e5f8: c2 07 bf f4 ld [ %fp + -12 ], %g1
rtems_filesystem_freenode( &parentloc );
202e5fc: 80 a0 60 00 cmp %g1, 0
202e600: 02 80 00 08 be 202e620 <rmdir+0x1a0> <== NEVER TAKEN
202e604: 01 00 00 00 nop
202e608: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e60c: 80 a0 60 00 cmp %g1, 0
202e610: 02 80 00 04 be 202e620 <rmdir+0x1a0> <== NEVER TAKEN
202e614: 01 00 00 00 nop
202e618: 9f c0 40 00 call %g1
202e61c: 90 10 00 11 mov %l1, %o0
rtems_set_errno_and_return_minus_one( ENOTDIR );
202e620: 40 00 6f 98 call 204a480 <__errno>
202e624: b0 10 3f ff mov -1, %i0
202e628: 82 10 20 14 mov 0x14, %g1
202e62c: c2 22 00 00 st %g1, [ %o0 ]
202e630: 81 c7 e0 08 ret
202e634: 81 e8 00 00 restore
parentpathlen = rtems_filesystem_dirname ( pathname );
if ( parentpathlen == 0 )
rtems_filesystem_get_start_loc( pathname, &i, &parentloc );
else {
result = rtems_filesystem_evaluate_path(pathname, parentpathlen,
202e638: a0 10 00 08 mov %o0, %l0
202e63c: 90 10 00 18 mov %i0, %o0
202e640: 92 10 00 10 mov %l0, %o1
202e644: 94 10 20 02 mov 2, %o2
202e648: 96 10 00 11 mov %l1, %o3
202e64c: 7f ff 68 85 call 2008860 <rtems_filesystem_evaluate_path>
202e650: 98 10 20 00 clr %o4
RTEMS_LIBIO_PERMS_WRITE,
&parentloc,
false );
if ( result != 0 )
202e654: 80 a2 20 00 cmp %o0, 0
202e658: 12 bf ff da bne 202e5c0 <rmdir+0x140> <== NEVER TAKEN
202e65c: a4 10 20 01 mov 1, %l2
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
202e660: 10 bf ff 95 b 202e4b4 <rmdir+0x34>
202e664: c2 07 bf e8 ld [ %fp + -24 ], %g1
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
0, &loc, false );
if ( result != 0 ) {
if ( free_parentloc )
202e668: 80 8c a0 ff btst 0xff, %l2
202e66c: 02 bf ff d3 be 202e5b8 <rmdir+0x138> <== ALWAYS TAKEN
202e670: b0 10 3f ff mov -1, %i0
rtems_filesystem_freenode( &parentloc );
202e674: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
202e678: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e67c: 02 80 00 24 be 202e70c <rmdir+0x28c> <== NOT EXECUTED
202e680: 01 00 00 00 nop <== NOT EXECUTED
202e684: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e688: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e68c: 02 bf ff cb be 202e5b8 <rmdir+0x138> <== NOT EXECUTED
202e690: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202e694: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e698: 01 00 00 00 nop <== NOT EXECUTED
202e69c: 81 c7 e0 08 ret <== NOT EXECUTED
202e6a0: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Use the filesystems rmnod to remove the node.
*/
if ( !loc.handlers->rmnod_h ){
rtems_filesystem_freenode( &loc );
202e6a4: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
202e6a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e6ac: 02 80 00 09 be 202e6d0 <rmdir+0x250> <== NOT EXECUTED
202e6b0: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
202e6b4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e6b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e6bc: 02 80 00 05 be 202e6d0 <rmdir+0x250> <== NOT EXECUTED
202e6c0: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
202e6c4: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e6c8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_parentloc )
202e6cc: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
202e6d0: 02 80 00 0b be 202e6fc <rmdir+0x27c> <== NOT EXECUTED
202e6d4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
202e6d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e6dc: 02 80 00 08 be 202e6fc <rmdir+0x27c> <== NOT EXECUTED
202e6e0: 01 00 00 00 nop <== NOT EXECUTED
202e6e4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e6e8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e6ec: 02 80 00 04 be 202e6fc <rmdir+0x27c> <== NOT EXECUTED
202e6f0: 01 00 00 00 nop <== NOT EXECUTED
202e6f4: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e6f8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202e6fc: 40 00 6f 61 call 204a480 <__errno> <== NOT EXECUTED
202e700: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202e704: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202e708: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202e70c: 81 c7 e0 08 ret <== NOT EXECUTED
202e710: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Verify you can remove this node as a directory.
*/
if ( !loc.ops->node_type_h ){
rtems_filesystem_freenode( &loc );
202e714: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e718: 12 bf ff eb bne 202e6c4 <rmdir+0x244> <== NOT EXECUTED
202e71c: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
202e720: 30 bf ff ec b,a 202e6d0 <rmdir+0x250> <== NOT EXECUTED
0201050c <rtems_assoc_local_by_remote_bitfield>:
uint32_t rtems_assoc_local_by_remote_bitfield(
const rtems_assoc_t *ap,
uint32_t remote_value
)
{
201050c: 9d e3 bf a0 save %sp, -96, %sp
2010510: a4 10 20 00 clr %l2
2010514: a0 10 00 18 mov %i0, %l0
2010518: a2 10 20 01 mov 1, %l1
201051c: 10 80 00 05 b 2010530 <rtems_assoc_local_by_remote_bitfield+0x24>
2010520: b0 10 20 00 clr %i0
uint32_t b;
uint32_t local_value = 0;
for (b = 1; b; b <<= 1) {
2010524: 80 a4 a0 20 cmp %l2, 0x20
2010528: 02 80 00 0d be 201055c <rtems_assoc_local_by_remote_bitfield+0x50>
201052c: a3 2c 60 01 sll %l1, 1, %l1
if (b & remote_value)
2010530: 80 8c 40 19 btst %l1, %i1
2010534: 22 bf ff fc be,a 2010524 <rtems_assoc_local_by_remote_bitfield+0x18>
2010538: a4 04 a0 01 inc %l2
local_value |= rtems_assoc_local_by_remote(ap, b);
201053c: 92 10 00 11 mov %l1, %o1
2010540: 40 00 00 09 call 2010564 <rtems_assoc_local_by_remote>
2010544: 90 10 00 10 mov %l0, %o0
)
{
uint32_t b;
uint32_t local_value = 0;
for (b = 1; b; b <<= 1) {
2010548: a4 04 a0 01 inc %l2
if (b & remote_value)
local_value |= rtems_assoc_local_by_remote(ap, b);
201054c: b0 16 00 08 or %i0, %o0, %i0
)
{
uint32_t b;
uint32_t local_value = 0;
for (b = 1; b; b <<= 1) {
2010550: 80 a4 a0 20 cmp %l2, 0x20
2010554: 12 bf ff f7 bne 2010530 <rtems_assoc_local_by_remote_bitfield+0x24><== ALWAYS TAKEN
2010558: a3 2c 60 01 sll %l1, 1, %l1
if (b & remote_value)
local_value |= rtems_assoc_local_by_remote(ap, b);
}
return local_value;
}
201055c: 81 c7 e0 08 ret
2010560: 81 e8 00 00 restore
020165dc <rtems_assoc_name_bad>:
uint32_t bad_value
#else
uint32_t bad_value __attribute((unused))
#endif
)
{
20165dc: 11 00 80 a0 sethi %hi(0x2028000), %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;
}
20165e0: 81 c3 e0 08 retl <== NOT EXECUTED
20165e4: 90 12 23 d0 or %o0, 0x3d0, %o0 ! 20283d0 <bad_buffer.4958><== NOT EXECUTED
0201271c <rtems_assoc_name_by_local>:
const char *rtems_assoc_name_by_local(
const rtems_assoc_t *ap,
uint32_t local_value
)
{
201271c: 9d e3 bf a0 save %sp, -96, %sp
const rtems_assoc_t *nap;
nap = rtems_assoc_ptr_by_local(ap, local_value);
2012720: 90 10 00 18 mov %i0, %o0
2012724: 40 00 00 0b call 2012750 <rtems_assoc_ptr_by_local>
2012728: 92 10 00 19 mov %i1, %o1
if (nap)
201272c: 80 a2 20 00 cmp %o0, 0
2012730: 02 80 00 05 be 2012744 <rtems_assoc_name_by_local+0x28> <== NEVER TAKEN
2012734: 01 00 00 00 nop
return nap->name;
return rtems_assoc_name_bad(local_value);
}
2012738: f0 02 00 00 ld [ %o0 ], %i0
201273c: 81 c7 e0 08 ret
2012740: 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);
2012744: 40 00 0f a6 call 20165dc <rtems_assoc_name_bad> <== NOT EXECUTED
2012748: 91 e8 00 19 restore %g0, %i1, %o0 <== NOT EXECUTED
0201194c <rtems_assoc_ptr_by_local>:
const rtems_assoc_t *rtems_assoc_ptr_by_local(
const rtems_assoc_t *ap,
uint32_t local_value
)
{
201194c: 9d e3 bf a0 save %sp, -96, %sp
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
2011950: d0 06 00 00 ld [ %i0 ], %o0
2011954: 80 a2 20 00 cmp %o0, 0
2011958: 02 80 00 1d be 20119cc <rtems_assoc_ptr_by_local+0x80> <== NEVER TAKEN
201195c: 13 00 80 78 sethi %hi(0x201e000), %o1
2011960: 40 00 03 8e call 2012798 <strcmp>
2011964: 92 12 60 38 or %o1, 0x38, %o1 ! 201e038 <errno_assoc+0x88>
2011968: 80 a2 20 00 cmp %o0, 0
201196c: 02 80 00 11 be 20119b0 <rtems_assoc_ptr_by_local+0x64> <== NEVER TAKEN
2011970: 84 10 20 00 clr %g2
default_ap = ap++;
for ( ; ap->name; ap++)
if (ap->local_value == local_value)
2011974: c2 06 20 04 ld [ %i0 + 4 ], %g1
2011978: 80 a0 40 19 cmp %g1, %i1
201197c: 32 80 00 07 bne,a 2011998 <rtems_assoc_ptr_by_local+0x4c>
2011980: b0 06 20 0c add %i0, 0xc, %i0
2011984: 30 80 00 14 b,a 20119d4 <rtems_assoc_ptr_by_local+0x88>
2011988: 80 a0 40 19 cmp %g1, %i1
201198c: 02 80 00 12 be 20119d4 <rtems_assoc_ptr_by_local+0x88>
2011990: 01 00 00 00 nop
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
default_ap = ap++;
for ( ; ap->name; ap++)
2011994: b0 06 20 0c add %i0, 0xc, %i0
2011998: c2 06 00 00 ld [ %i0 ], %g1
201199c: 80 a0 60 00 cmp %g1, 0
20119a0: 32 bf ff fa bne,a 2011988 <rtems_assoc_ptr_by_local+0x3c>
20119a4: c2 06 20 04 ld [ %i0 + 4 ], %g1
if (ap->local_value == local_value)
return ap;
return default_ap;
}
20119a8: 81 c7 e0 08 ret
20119ac: 91 e8 00 02 restore %g0, %g2, %o0
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
default_ap = ap++;
for ( ; ap->name; ap++)
20119b0: c4 06 20 0c ld [ %i0 + 0xc ], %g2 <== NOT EXECUTED
20119b4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20119b8: 02 80 00 07 be 20119d4 <rtems_assoc_ptr_by_local+0x88> <== NOT EXECUTED
20119bc: 82 06 20 0c add %i0, 0xc, %g1 <== NOT EXECUTED
20119c0: 84 10 00 18 mov %i0, %g2 <== NOT EXECUTED
20119c4: 10 bf ff ec b 2011974 <rtems_assoc_ptr_by_local+0x28> <== NOT EXECUTED
20119c8: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
uint32_t local_value
)
{
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
20119cc: 81 c7 e0 08 ret <== NOT EXECUTED
20119d0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
20119d4: 81 c7 e0 08 ret
20119d8: 81 e8 00 00 restore
0201058c <rtems_assoc_ptr_by_remote>:
const rtems_assoc_t *rtems_assoc_ptr_by_remote(
const rtems_assoc_t *ap,
uint32_t remote_value
)
{
201058c: 9d e3 bf a0 save %sp, -96, %sp
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
2010590: d0 06 00 00 ld [ %i0 ], %o0
2010594: 80 a2 20 00 cmp %o0, 0
2010598: 02 80 00 1d be 201060c <rtems_assoc_ptr_by_remote+0x80> <== NEVER TAKEN
201059c: 13 00 80 77 sethi %hi(0x201dc00), %o1
20105a0: 40 00 08 7e call 2012798 <strcmp>
20105a4: 92 12 63 10 or %o1, 0x310, %o1 ! 201df10 <__FUNCTION__.6119+0x28>
20105a8: 80 a2 20 00 cmp %o0, 0
20105ac: 02 80 00 11 be 20105f0 <rtems_assoc_ptr_by_remote+0x64> <== NEVER TAKEN
20105b0: 84 10 20 00 clr %g2
default_ap = ap++;
for ( ; ap->name; ap++)
if (ap->remote_value == remote_value)
20105b4: c2 06 20 08 ld [ %i0 + 8 ], %g1
20105b8: 80 a0 40 19 cmp %g1, %i1
20105bc: 32 80 00 07 bne,a 20105d8 <rtems_assoc_ptr_by_remote+0x4c>
20105c0: b0 06 20 0c add %i0, 0xc, %i0
20105c4: 30 80 00 14 b,a 2010614 <rtems_assoc_ptr_by_remote+0x88>
20105c8: 80 a0 40 19 cmp %g1, %i1
20105cc: 02 80 00 12 be 2010614 <rtems_assoc_ptr_by_remote+0x88>
20105d0: 01 00 00 00 nop
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
default_ap = ap++;
for ( ; ap->name; ap++)
20105d4: b0 06 20 0c add %i0, 0xc, %i0
20105d8: c2 06 00 00 ld [ %i0 ], %g1
20105dc: 80 a0 60 00 cmp %g1, 0
20105e0: 32 bf ff fa bne,a 20105c8 <rtems_assoc_ptr_by_remote+0x3c>
20105e4: c2 06 20 08 ld [ %i0 + 8 ], %g1
if (ap->remote_value == remote_value)
return ap;
return default_ap;
}
20105e8: 81 c7 e0 08 ret
20105ec: 91 e8 00 02 restore %g0, %g2, %o0
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
default_ap = ap++;
for ( ; ap->name; ap++)
20105f0: c4 06 20 0c ld [ %i0 + 0xc ], %g2 <== NOT EXECUTED
20105f4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20105f8: 02 80 00 07 be 2010614 <rtems_assoc_ptr_by_remote+0x88> <== NOT EXECUTED
20105fc: 82 06 20 0c add %i0, 0xc, %g1 <== NOT EXECUTED
2010600: 84 10 00 18 mov %i0, %g2 <== NOT EXECUTED
2010604: 10 bf ff ec b 20105b4 <rtems_assoc_ptr_by_remote+0x28> <== NOT EXECUTED
2010608: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
uint32_t remote_value
)
{
const rtems_assoc_t *default_ap = 0;
if (rtems_assoc_is_default(ap))
201060c: 81 c7 e0 08 ret <== NOT EXECUTED
2010610: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
2010614: 81 c7 e0 08 ret
2010618: 81 e8 00 00 restore
02011890 <rtems_assoc_remote_by_local>:
uint32_t rtems_assoc_remote_by_local(
const rtems_assoc_t *ap,
uint32_t local_value
)
{
2011890: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
const rtems_assoc_t *nap;
nap = rtems_assoc_ptr_by_local(ap, local_value);
2011894: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2011898: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
201189c: 40 00 00 2c call 201194c <rtems_assoc_ptr_by_local> <== NOT EXECUTED
20118a0: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (nap)
20118a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20118a8: 32 80 00 02 bne,a 20118b0 <rtems_assoc_remote_by_local+0x20><== NOT EXECUTED
20118ac: f0 02 20 08 ld [ %o0 + 8 ], %i0 <== NOT EXECUTED
return nap->remote_value;
return 0;
}
20118b0: 81 c7 e0 08 ret <== NOT EXECUTED
20118b4: 81 e8 00 00 restore <== NOT EXECUTED
0200daf8 <rtems_barrier_create>:
rtems_name name,
rtems_attribute attribute_set,
uint32_t maximum_waiters,
rtems_id *id
)
{
200daf8: 9d e3 bf 98 save %sp, -104, %sp
Barrier_Control *the_barrier;
CORE_barrier_Attributes the_attributes;
if ( !rtems_is_name_valid( name ) )
200dafc: a0 96 20 00 orcc %i0, 0, %l0
200db00: 02 80 00 23 be 200db8c <rtems_barrier_create+0x94>
200db04: b0 10 20 03 mov 3, %i0
return RTEMS_INVALID_NAME;
if ( !id )
200db08: 80 a6 e0 00 cmp %i3, 0
200db0c: 02 80 00 20 be 200db8c <rtems_barrier_create+0x94>
200db10: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
/* Initialize core barrier attributes */
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
200db14: 80 8e 60 10 btst 0x10, %i1
200db18: 02 80 00 1f be 200db94 <rtems_barrier_create+0x9c>
200db1c: 80 a6 a0 00 cmp %i2, 0
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
if ( maximum_waiters == 0 )
200db20: 02 80 00 1b be 200db8c <rtems_barrier_create+0x94>
200db24: b0 10 20 0a mov 0xa, %i0
200db28: 03 00 80 7c sethi %hi(0x201f000), %g1
200db2c: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
if ( !id )
return RTEMS_INVALID_ADDRESS;
/* Initialize core barrier attributes */
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
200db30: c0 27 bf f8 clr [ %fp + -8 ]
if ( maximum_waiters == 0 )
return RTEMS_INVALID_NUMBER;
} else
the_attributes.discipline = CORE_BARRIER_MANUAL_RELEASE;
the_attributes.maximum_count = maximum_waiters;
200db34: f4 27 bf fc st %i2, [ %fp + -4 ]
200db38: 84 00 a0 01 inc %g2
200db3c: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
* This function allocates a barrier control block from
* the inactive chain of free barrier control blocks.
*/
RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Allocate( void )
{
return (Barrier_Control *) _Objects_Allocate( &_Barrier_Information );
200db40: 25 00 80 7f sethi %hi(0x201fc00), %l2
200db44: 7f ff e8 96 call 2007d9c <_Objects_Allocate>
200db48: 90 14 a0 c8 or %l2, 0xc8, %o0 ! 201fcc8 <_Barrier_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _Barrier_Allocate();
if ( !the_barrier ) {
200db4c: a2 92 20 00 orcc %o0, 0, %l1
200db50: 02 80 00 1e be 200dbc8 <rtems_barrier_create+0xd0> <== NEVER TAKEN
200db54: 90 04 60 14 add %l1, 0x14, %o0
return RTEMS_TOO_MANY;
}
the_barrier->attribute_set = attribute_set;
_CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes );
200db58: 92 07 bf f8 add %fp, -8, %o1
200db5c: 40 00 01 54 call 200e0ac <_CORE_barrier_Initialize>
200db60: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
200db64: c2 14 60 0a lduh [ %l1 + 0xa ], %g1
200db68: c6 04 60 08 ld [ %l1 + 8 ], %g3
200db6c: a4 14 a0 c8 or %l2, 0xc8, %l2
200db70: c4 04 a0 1c ld [ %l2 + 0x1c ], %g2
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
200db74: e0 24 60 0c st %l0, [ %l1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
200db78: 83 28 60 02 sll %g1, 2, %g1
&_Barrier_Information,
&the_barrier->Object,
(Objects_Name) name
);
*id = the_barrier->Object.id;
200db7c: c6 26 c0 00 st %g3, [ %i3 ]
200db80: e2 20 80 01 st %l1, [ %g2 + %g1 ]
_Thread_Enable_dispatch();
200db84: 7f ff ec 87 call 2008da0 <_Thread_Enable_dispatch>
200db88: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
200db8c: 81 c7 e0 08 ret
200db90: 81 e8 00 00 restore
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
if ( maximum_waiters == 0 )
return RTEMS_INVALID_NUMBER;
} else
the_attributes.discipline = CORE_BARRIER_MANUAL_RELEASE;
200db94: 82 10 20 01 mov 1, %g1
200db98: c2 27 bf f8 st %g1, [ %fp + -8 ]
200db9c: 03 00 80 7c sethi %hi(0x201f000), %g1
200dba0: c4 00 63 a0 ld [ %g1 + 0x3a0 ], %g2 ! 201f3a0 <_Thread_Dispatch_disable_level>
the_attributes.maximum_count = maximum_waiters;
200dba4: f4 27 bf fc st %i2, [ %fp + -4 ]
200dba8: 84 00 a0 01 inc %g2
200dbac: c4 20 63 a0 st %g2, [ %g1 + 0x3a0 ]
200dbb0: 25 00 80 7f sethi %hi(0x201fc00), %l2
200dbb4: 7f ff e8 7a call 2007d9c <_Objects_Allocate>
200dbb8: 90 14 a0 c8 or %l2, 0xc8, %o0 ! 201fcc8 <_Barrier_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _Barrier_Allocate();
if ( !the_barrier ) {
200dbbc: a2 92 20 00 orcc %o0, 0, %l1
200dbc0: 12 bf ff e6 bne 200db58 <rtems_barrier_create+0x60>
200dbc4: 90 04 60 14 add %l1, 0x14, %o0
_Thread_Enable_dispatch();
200dbc8: 7f ff ec 76 call 2008da0 <_Thread_Enable_dispatch>
200dbcc: b0 10 20 05 mov 5, %i0
return RTEMS_TOO_MANY;
200dbd0: 81 c7 e0 08 ret
200dbd4: 81 e8 00 00 restore
0200c5f4 <rtems_bdbuf_add_to_modified_list_after_access>:
}
}
static void
rtems_bdbuf_add_to_modified_list_after_access (rtems_bdbuf_buffer *bd)
{
200c5f4: 9d e3 bf a0 save %sp, -96, %sp
if (bdbuf_cache.sync_active && bdbuf_cache.sync_device == bd->dev)
200c5f8: 21 00 80 8b sethi %hi(0x2022c00), %l0
200c5fc: a0 14 23 78 or %l0, 0x378, %l0 ! 2022f78 <bdbuf_cache>
200c600: c2 0c 20 30 ldub [ %l0 + 0x30 ], %g1
200c604: 80 a0 60 00 cmp %g1, 0
200c608: 02 80 00 07 be 200c624 <rtems_bdbuf_add_to_modified_list_after_access+0x30><== ALWAYS TAKEN
200c60c: 01 00 00 00 nop
200c610: c4 1c 20 38 ldd [ %l0 + 0x38 ], %g2 <== NOT EXECUTED
200c614: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
200c618: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200c61c: 22 80 00 2a be,a 200c6c4 <rtems_bdbuf_add_to_modified_list_after_access+0xd0><== NOT EXECUTED
200c620: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
* nothing being written? We have tended to think we should hold changes for
* only a specific period of time even if still changing and get onto disk
* and letting the file system try and recover this position if it can.
*/
if (bd->state == RTEMS_BDBUF_STATE_ACCESS_CACHED
|| bd->state == RTEMS_BDBUF_STATE_ACCESS_EMPTY)
200c624: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
* difficult question. Is a snapshot of a block that is changing better than
* nothing being written? We have tended to think we should hold changes for
* only a specific period of time even if still changing and get onto disk
* and letting the file system try and recover this position if it can.
*/
if (bd->state == RTEMS_BDBUF_STATE_ACCESS_CACHED
200c628: 80 a0 60 03 cmp %g1, 3
200c62c: 02 80 00 18 be 200c68c <rtems_bdbuf_add_to_modified_list_after_access+0x98>
200c630: 03 00 80 83 sethi %hi(0x2020c00), %g1
|| bd->state == RTEMS_BDBUF_STATE_ACCESS_EMPTY)
200c634: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
* difficult question. Is a snapshot of a block that is changing better than
* nothing being written? We have tended to think we should hold changes for
* only a specific period of time even if still changing and get onto disk
* and letting the file system try and recover this position if it can.
*/
if (bd->state == RTEMS_BDBUF_STATE_ACCESS_CACHED
200c638: 80 a0 60 05 cmp %g1, 5
200c63c: 02 80 00 13 be 200c688 <rtems_bdbuf_add_to_modified_list_after_access+0x94>
200c640: 82 10 20 07 mov 7, %g1
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200c644: 11 00 80 8b sethi %hi(0x2022c00), %o0
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200c648: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
200c64c: 90 12 23 c8 or %o0, 0x3c8, %o0
200c650: 7f ff f0 98 call 20088b0 <_Chain_Append>
200c654: 92 10 00 18 mov %i0, %o1
bd->hold_timer = bdbuf_config.swap_block_hold;
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_MODIFIED);
rtems_chain_append (&bdbuf_cache.modified, &bd->link);
if (bd->waiters)
200c658: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
200c65c: 80 a0 60 00 cmp %g1, 0
200c660: 12 80 00 17 bne 200c6bc <rtems_bdbuf_add_to_modified_list_after_access+0xc8>
200c664: 31 00 80 8b sethi %hi(0x2022c00), %i0
}
static bool
rtems_bdbuf_has_buffer_waiters (void)
{
return bdbuf_cache.buffer_waiters.count;
200c668: c2 04 20 78 ld [ %l0 + 0x78 ], %g1
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_MODIFIED);
rtems_chain_append (&bdbuf_cache.modified, &bd->link);
if (bd->waiters)
rtems_bdbuf_wake (&bdbuf_cache.access_waiters);
else if (rtems_bdbuf_has_buffer_waiters ())
200c66c: 80 a0 60 00 cmp %g1, 0
200c670: 12 80 00 04 bne 200c680 <rtems_bdbuf_add_to_modified_list_after_access+0x8c>
200c674: 01 00 00 00 nop
200c678: 81 c7 e0 08 ret
200c67c: 81 e8 00 00 restore
rtems_bdbuf_wake_swapper ();
200c680: 7f ff ff d0 call 200c5c0 <rtems_bdbuf_wake_swapper>
200c684: 81 e8 00 00 restore
* only a specific period of time even if still changing and get onto disk
* and letting the file system try and recover this position if it can.
*/
if (bd->state == RTEMS_BDBUF_STATE_ACCESS_CACHED
|| bd->state == RTEMS_BDBUF_STATE_ACCESS_EMPTY)
bd->hold_timer = bdbuf_config.swap_block_hold;
200c688: 03 00 80 83 sethi %hi(0x2020c00), %g1
200c68c: c2 00 63 bc ld [ %g1 + 0x3bc ], %g1 ! 2020fbc <rtems_bdbuf_configuration+0x10>
200c690: 11 00 80 8b sethi %hi(0x2022c00), %o0
200c694: c2 26 20 34 st %g1, [ %i0 + 0x34 ]
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200c698: 82 10 20 07 mov 7, %g1
200c69c: 90 12 23 c8 or %o0, 0x3c8, %o0
200c6a0: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
200c6a4: 7f ff f0 83 call 20088b0 <_Chain_Append>
200c6a8: 92 10 00 18 mov %i0, %o1
bd->hold_timer = bdbuf_config.swap_block_hold;
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_MODIFIED);
rtems_chain_append (&bdbuf_cache.modified, &bd->link);
if (bd->waiters)
200c6ac: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
200c6b0: 80 a0 60 00 cmp %g1, 0
200c6b4: 02 bf ff ed be 200c668 <rtems_bdbuf_add_to_modified_list_after_access+0x74>
200c6b8: 31 00 80 8b sethi %hi(0x2022c00), %i0
rtems_bdbuf_wake (&bdbuf_cache.access_waiters);
200c6bc: 7f ff fe d8 call 200c21c <rtems_bdbuf_wake>
200c6c0: 91 ee 23 e0 restore %i0, 0x3e0, %o0
}
static void
rtems_bdbuf_add_to_modified_list_after_access (rtems_bdbuf_buffer *bd)
{
if (bdbuf_cache.sync_active && bdbuf_cache.sync_device == bd->dev)
200c6c4: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
200c6c8: 12 bf ff d7 bne 200c624 <rtems_bdbuf_add_to_modified_list_after_access+0x30><== NOT EXECUTED
200c6cc: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_bdbuf_unlock_cache ();
200c6d0: 7f ff ff 59 call 200c434 <rtems_bdbuf_unlock_cache> <== NOT EXECUTED
200c6d4: 01 00 00 00 nop <== NOT EXECUTED
* Lock the cache's sync. A single task can nest calls.
*/
static void
rtems_bdbuf_lock_sync (void)
{
rtems_bdbuf_lock (bdbuf_cache.sync_lock, RTEMS_BLKDEV_FATAL_BDBUF_SYNC_LOCK);
200c6d8: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200c6dc: 13 10 80 00 sethi %hi(0x42000000), %o1 <== NOT EXECUTED
200c6e0: 7f ff fe ba call 200c1c8 <rtems_bdbuf_lock> <== NOT EXECUTED
200c6e4: 92 12 60 0b or %o1, 0xb, %o1 ! 4200000b <RAM_END+0x3fc0000b><== NOT EXECUTED
/*
* Wait for the sync lock.
*/
rtems_bdbuf_lock_sync ();
rtems_bdbuf_unlock_sync ();
200c6e8: 7f ff ff 5f call 200c464 <rtems_bdbuf_unlock_sync> <== NOT EXECUTED
200c6ec: 01 00 00 00 nop <== NOT EXECUTED
rtems_bdbuf_lock_cache ();
200c6f0: 7f ff fe c3 call 200c1fc <rtems_bdbuf_lock_cache> <== NOT EXECUTED
200c6f4: 01 00 00 00 nop <== NOT EXECUTED
200c6f8: 30 bf ff cb b,a 200c624 <rtems_bdbuf_add_to_modified_list_after_access+0x30><== NOT EXECUTED
0200c87c <rtems_bdbuf_anonymous_wait>:
* The function assumes the cache is locked on entry and it will be locked on
* exit.
*/
static void
rtems_bdbuf_anonymous_wait (rtems_bdbuf_waiters *waiters)
{
200c87c: 9d e3 bf a0 save %sp, -96, %sp
rtems_mode prev_mode;
/*
* Indicate we are waiting.
*/
++waiters->count;
200c880: c2 06 00 00 ld [ %i0 ], %g1
200c884: 82 00 60 01 inc %g1
200c888: c2 26 00 00 st %g1, [ %i0 ]
* blocking or just hits that window, and before this task has blocked on the
* semaphore. If the preempting task flushes the queue this task will not see
* the flush and may block for ever or until another transaction flushes this
* semaphore.
*/
prev_mode = rtems_bdbuf_disable_preemption ();
200c88c: 7f ff ff de call 200c804 <rtems_bdbuf_disable_preemption>
200c890: 01 00 00 00 nop
/*
* Unlock the cache, wait, and lock the cache when we return.
*/
rtems_bdbuf_unlock_cache ();
200c894: 7f ff fe e8 call 200c434 <rtems_bdbuf_unlock_cache>
200c898: a0 10 00 08 mov %o0, %l0
sc = rtems_semaphore_obtain (waiters->sema, RTEMS_WAIT, RTEMS_BDBUF_WAIT_TIMEOUT);
200c89c: d0 06 20 04 ld [ %i0 + 4 ], %o0
200c8a0: 92 10 20 00 clr %o1
200c8a4: 7f ff ed 09 call 2007cc8 <rtems_semaphore_obtain>
200c8a8: 94 10 20 00 clr %o2
if (sc == RTEMS_TIMEOUT)
200c8ac: 80 a2 20 06 cmp %o0, 6
200c8b0: 02 80 00 0d be 200c8e4 <rtems_bdbuf_anonymous_wait+0x68> <== NEVER TAKEN
200c8b4: 80 a2 20 0d cmp %o0, 0xd
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_CACHE_WAIT_TO);
if (sc != RTEMS_UNSATISFIED)
200c8b8: 12 80 00 0e bne 200c8f0 <rtems_bdbuf_anonymous_wait+0x74> <== NEVER TAKEN
200c8bc: 11 10 80 00 sethi %hi(0x42000000), %o0
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_CACHE_WAIT_2);
rtems_bdbuf_lock_cache ();
200c8c0: 7f ff fe 4f call 200c1fc <rtems_bdbuf_lock_cache>
200c8c4: 01 00 00 00 nop
rtems_bdbuf_restore_preemption (prev_mode);
200c8c8: 7f ff ff de call 200c840 <rtems_bdbuf_restore_preemption>
200c8cc: 90 10 00 10 mov %l0, %o0
--waiters->count;
200c8d0: c2 06 00 00 ld [ %i0 ], %g1
200c8d4: 82 00 7f ff add %g1, -1, %g1
200c8d8: c2 26 00 00 st %g1, [ %i0 ]
}
200c8dc: 81 c7 e0 08 ret
200c8e0: 81 e8 00 00 restore
rtems_bdbuf_unlock_cache ();
sc = rtems_semaphore_obtain (waiters->sema, RTEMS_WAIT, RTEMS_BDBUF_WAIT_TIMEOUT);
if (sc == RTEMS_TIMEOUT)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_CACHE_WAIT_TO);
200c8e4: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200c8e8: 7f ff ee 81 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c8ec: 90 12 20 12 or %o0, 0x12, %o0 ! 42000012 <RAM_END+0x3fc00012><== NOT EXECUTED
if (sc != RTEMS_UNSATISFIED)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_CACHE_WAIT_2);
200c8f0: 7f ff ee 7f call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c8f4: 90 12 20 10 or %o0, 0x10, %o0 <== NOT EXECUTED
0200c804 <rtems_bdbuf_disable_preemption>:
--bd->group->users;
}
static rtems_mode
rtems_bdbuf_disable_preemption (void)
{
200c804: 9d e3 bf 98 save %sp, -104, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_mode prev_mode = 0;
sc = rtems_task_mode (RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &prev_mode);
200c808: 90 10 21 00 mov 0x100, %o0
static rtems_mode
rtems_bdbuf_disable_preemption (void)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_mode prev_mode = 0;
200c80c: c0 27 bf fc clr [ %fp + -4 ]
sc = rtems_task_mode (RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &prev_mode);
200c810: 92 10 21 00 mov 0x100, %o1
200c814: 40 00 16 1e call 201208c <rtems_task_mode>
200c818: 94 07 bf fc add %fp, -4, %o2
if (sc != RTEMS_SUCCESSFUL)
200c81c: 80 a2 20 00 cmp %o0, 0
200c820: 12 80 00 04 bne 200c830 <rtems_bdbuf_disable_preemption+0x2c><== NEVER TAKEN
200c824: f0 07 bf fc ld [ %fp + -4 ], %i0
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_PREEMPT_DIS);
return prev_mode;
}
200c828: 81 c7 e0 08 ret
200c82c: 81 e8 00 00 restore
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_mode prev_mode = 0;
sc = rtems_task_mode (RTEMS_NO_PREEMPT, RTEMS_PREEMPT_MASK, &prev_mode);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_PREEMPT_DIS);
200c830: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200c834: 7f ff ee ae call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c838: 90 12 20 0f or %o0, 0xf, %o0 ! 4200000f <RAM_END+0x3fc0000f><== NOT EXECUTED
0200d5fc <rtems_bdbuf_execute_transfer_request>:
static rtems_status_code
rtems_bdbuf_execute_transfer_request (const rtems_disk_device *dd,
rtems_blkdev_request *req,
bool cache_locked)
{
200d5fc: 9d e3 bf a0 save %sp, -96, %sp
int result = 0;
uint32_t transfer_index = 0;
bool wake_transfer_waiters = false;
bool wake_buffer_waiters = false;
if (cache_locked)
200d600: b4 8e a0 ff andcc %i2, 0xff, %i2
200d604: 12 80 00 5b bne 200d770 <rtems_bdbuf_execute_transfer_request+0x174>
200d608: 01 00 00 00 nop
rtems_bdbuf_unlock_cache ();
result = dd->ioctl (dd->phys_dev, RTEMS_BLKIO_REQUEST, req);
200d60c: d0 06 20 08 ld [ %i0 + 8 ], %o0
200d610: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200d614: 13 30 06 10 sethi %hi(0xc0184000), %o1
200d618: 94 10 00 19 mov %i1, %o2
200d61c: 92 12 62 01 or %o1, 0x201, %o1
200d620: 9f c0 40 00 call %g1
200d624: a8 10 20 00 clr %l4
if (result == 0)
200d628: 80 a2 20 00 cmp %o0, 0
200d62c: 02 80 00 47 be 200d748 <rtems_bdbuf_execute_transfer_request+0x14c>
200d630: b0 10 20 1b mov 0x1b, %i0
sc = req->status;
}
else
sc = RTEMS_IO_ERROR;
rtems_bdbuf_lock_cache ();
200d634: 7f ff fa f2 call 200c1fc <rtems_bdbuf_lock_cache>
200d638: 01 00 00 00 nop
for (transfer_index = 0; transfer_index < req->bufnum; ++transfer_index)
200d63c: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
200d640: 80 a0 60 00 cmp %g1, 0
200d644: 02 80 00 26 be 200d6dc <rtems_bdbuf_execute_transfer_request+0xe0><== NEVER TAKEN
200d648: a4 10 20 00 clr %l2
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200d64c: 2d 00 80 8b sethi %hi(0x2022c00), %l6
200d650: a2 10 00 19 mov %i1, %l1
200d654: ac 15 a3 bc or %l6, 0x3bc, %l6
200d658: a6 10 20 00 clr %l3
200d65c: a0 10 20 00 clr %l0
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d660: aa 10 20 02 mov 2, %l5
rtems_bdbuf_lock_cache ();
for (transfer_index = 0; transfer_index < req->bufnum; ++transfer_index)
{
rtems_bdbuf_buffer *bd = req->bufs [transfer_index].user;
200d664: d2 04 60 24 ld [ %l1 + 0x24 ], %o1
bool waiters = bd->waiters;
200d668: c2 02 60 2c ld [ %o1 + 0x2c ], %g1
if (waiters)
200d66c: 80 a0 60 00 cmp %g1, 0
200d670: 32 80 00 03 bne,a 200d67c <rtems_bdbuf_execute_transfer_request+0x80>
200d674: a6 10 20 01 mov 1, %l3
200d678: a4 10 20 01 mov 1, %l2
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d67c: c2 02 60 30 ld [ %o1 + 0x30 ], %g1
else
wake_buffer_waiters = true;
rtems_bdbuf_group_release (bd);
if (sc == RTEMS_SUCCESSFUL && bd->state == RTEMS_BDBUF_STATE_TRANSFER)
200d680: 80 a6 20 00 cmp %i0, 0
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d684: c4 00 60 0c ld [ %g1 + 0xc ], %g2
rtems_bdbuf_group_release (bd);
if (sc == RTEMS_SUCCESSFUL && bd->state == RTEMS_BDBUF_STATE_TRANSFER)
rtems_bdbuf_make_cached_and_add_to_lru_list (bd);
else
rtems_bdbuf_discard_buffer (bd);
200d688: 90 10 00 09 mov %o1, %o0
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d68c: 84 00 bf ff add %g2, -1, %g2
else
wake_buffer_waiters = true;
rtems_bdbuf_group_release (bd);
if (sc == RTEMS_SUCCESSFUL && bd->state == RTEMS_BDBUF_STATE_TRANSFER)
200d690: 12 80 00 06 bne 200d6a8 <rtems_bdbuf_execute_transfer_request+0xac>
200d694: c4 20 60 0c st %g2, [ %g1 + 0xc ]
200d698: c2 02 60 28 ld [ %o1 + 0x28 ], %g1
200d69c: 80 a0 60 09 cmp %g1, 9
200d6a0: 02 80 00 17 be 200d6fc <rtems_bdbuf_execute_transfer_request+0x100>
200d6a4: 01 00 00 00 nop
rtems_bdbuf_make_cached_and_add_to_lru_list (bd);
else
rtems_bdbuf_discard_buffer (bd);
200d6a8: 7f ff fe cd call 200d1dc <rtems_bdbuf_discard_buffer>
200d6ac: 01 00 00 00 nop
else
sc = RTEMS_IO_ERROR;
rtems_bdbuf_lock_cache ();
for (transfer_index = 0; transfer_index < req->bufnum; ++transfer_index)
200d6b0: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
200d6b4: a0 04 20 01 inc %l0
200d6b8: 80 a0 40 10 cmp %g1, %l0
200d6bc: 18 bf ff ea bgu 200d664 <rtems_bdbuf_execute_transfer_request+0x68>
200d6c0: a2 04 60 10 add %l1, 0x10, %l1
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("transfer", bd);
}
if (wake_transfer_waiters)
200d6c4: 80 8c e0 ff btst 0xff, %l3
200d6c8: 12 80 00 1c bne 200d738 <rtems_bdbuf_execute_transfer_request+0x13c>
200d6cc: 11 00 80 8b sethi %hi(0x2022c00), %o0
rtems_bdbuf_wake (&bdbuf_cache.transfer_waiters);
if (wake_buffer_waiters)
200d6d0: 80 8c a0 ff btst 0xff, %l2
200d6d4: 12 80 00 15 bne 200d728 <rtems_bdbuf_execute_transfer_request+0x12c>
200d6d8: 11 00 80 8b sethi %hi(0x2022c00), %o0
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
if (!cache_locked)
200d6dc: 80 a6 a0 00 cmp %i2, 0
200d6e0: 02 80 00 0e be 200d718 <rtems_bdbuf_execute_transfer_request+0x11c>
200d6e4: 01 00 00 00 nop
rtems_bdbuf_unlock_cache ();
if (sc == RTEMS_SUCCESSFUL || sc == RTEMS_UNSATISFIED)
200d6e8: 80 8d 20 ff btst 0xff, %l4
200d6ec: 02 80 00 09 be 200d710 <rtems_bdbuf_execute_transfer_request+0x114>
200d6f0: 01 00 00 00 nop
return sc;
else
return RTEMS_IO_ERROR;
}
200d6f4: 81 c7 e0 08 ret
200d6f8: 81 e8 00 00 restore
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d6fc: ea 22 60 28 st %l5, [ %o1 + 0x28 ]
200d700: 7f ff ec 6c call 20088b0 <_Chain_Append>
200d704: 90 10 00 16 mov %l6, %o0
else
wake_buffer_waiters = true;
rtems_bdbuf_group_release (bd);
if (sc == RTEMS_SUCCESSFUL && bd->state == RTEMS_BDBUF_STATE_TRANSFER)
200d708: 10 bf ff eb b 200d6b4 <rtems_bdbuf_execute_transfer_request+0xb8>
200d70c: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
if (sc == RTEMS_SUCCESSFUL || sc == RTEMS_UNSATISFIED)
return sc;
else
return RTEMS_IO_ERROR;
}
200d710: 81 c7 e0 08 ret
200d714: 91 e8 20 1b restore %g0, 0x1b, %o0
if (wake_buffer_waiters)
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
if (!cache_locked)
rtems_bdbuf_unlock_cache ();
200d718: 7f ff fb 47 call 200c434 <rtems_bdbuf_unlock_cache>
200d71c: 01 00 00 00 nop
if (sc == RTEMS_SUCCESSFUL || sc == RTEMS_UNSATISFIED)
200d720: 10 bf ff f3 b 200d6ec <rtems_bdbuf_execute_transfer_request+0xf0>
200d724: 80 8d 20 ff btst 0xff, %l4
if (wake_transfer_waiters)
rtems_bdbuf_wake (&bdbuf_cache.transfer_waiters);
if (wake_buffer_waiters)
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200d728: 7f ff fa bd call 200c21c <rtems_bdbuf_wake>
200d72c: 90 12 23 f0 or %o0, 0x3f0, %o0
if (!cache_locked)
200d730: 10 bf ff ec b 200d6e0 <rtems_bdbuf_execute_transfer_request+0xe4>
200d734: 80 a6 a0 00 cmp %i2, 0
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("transfer", bd);
}
if (wake_transfer_waiters)
rtems_bdbuf_wake (&bdbuf_cache.transfer_waiters);
200d738: 7f ff fa b9 call 200c21c <rtems_bdbuf_wake>
200d73c: 90 12 23 e8 or %o0, 0x3e8, %o0
if (wake_buffer_waiters)
200d740: 10 bf ff e5 b 200d6d4 <rtems_bdbuf_execute_transfer_request+0xd8>
200d744: 80 8c a0 ff btst 0xff, %l2
result = dd->ioctl (dd->phys_dev, RTEMS_BLKIO_REQUEST, req);
if (result == 0)
{
rtems_bdbuf_wait_for_event (RTEMS_BDBUF_TRANSFER_SYNC);
200d748: 7f ff fb f5 call 200c71c <rtems_bdbuf_wait_for_event>
200d74c: 90 10 20 02 mov 2, %o0
sc = req->status;
200d750: f0 06 60 0c ld [ %i1 + 0xc ], %i0
200d754: 82 1e 20 0d xor %i0, 0xd, %g1
200d758: 80 a0 00 01 cmp %g0, %g1
200d75c: a8 60 3f ff subx %g0, -1, %l4
200d760: 80 a0 00 18 cmp %g0, %i0
200d764: 82 60 3f ff subx %g0, -1, %g1
200d768: 10 bf ff b3 b 200d634 <rtems_bdbuf_execute_transfer_request+0x38>
200d76c: a8 15 00 01 or %l4, %g1, %l4
uint32_t transfer_index = 0;
bool wake_transfer_waiters = false;
bool wake_buffer_waiters = false;
if (cache_locked)
rtems_bdbuf_unlock_cache ();
200d770: 7f ff fb 31 call 200c434 <rtems_bdbuf_unlock_cache>
200d774: 01 00 00 00 nop
result = dd->ioctl (dd->phys_dev, RTEMS_BLKIO_REQUEST, req);
200d778: 10 bf ff a6 b 200d610 <rtems_bdbuf_execute_transfer_request+0x14>
200d77c: d0 06 20 08 ld [ %i0 + 8 ], %o0
0200e584 <rtems_bdbuf_get>:
rtems_status_code
rtems_bdbuf_get (dev_t dev,
rtems_blkdev_bnum block,
rtems_bdbuf_buffer **bd_ptr)
{
200e584: 9d e3 bf 90 save %sp, -112, %sp
rtems_disk_device *dd = NULL;
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block = 0;
size_t bds_per_group = 0;
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
200e588: 90 10 00 18 mov %i0, %o0
rtems_bdbuf_get (dev_t dev,
rtems_blkdev_bnum block,
rtems_bdbuf_buffer **bd_ptr)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *dd = NULL;
200e58c: c0 27 bf fc clr [ %fp + -4 ]
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block = 0;
200e590: c0 27 bf f8 clr [ %fp + -8 ]
size_t bds_per_group = 0;
200e594: c0 27 bf f4 clr [ %fp + -12 ]
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
200e598: 94 10 00 1a mov %i2, %o2
rtems_status_code
rtems_bdbuf_get (dev_t dev,
rtems_blkdev_bnum block,
rtems_bdbuf_buffer **bd_ptr)
{
200e59c: a0 10 00 18 mov %i0, %l0
rtems_disk_device *dd = NULL;
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block = 0;
size_t bds_per_group = 0;
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
200e5a0: 96 07 bf fc add %fp, -4, %o3
200e5a4: 92 10 00 19 mov %i1, %o1
200e5a8: 98 07 bf f8 add %fp, -8, %o4
200e5ac: 7f ff f7 ba call 200c494 <rtems_bdbuf_obtain_disk>
200e5b0: 9a 07 bf f4 add %fp, -12, %o5
if (sc != RTEMS_SUCCESSFUL)
200e5b4: b0 92 20 00 orcc %o0, 0, %i0
200e5b8: 02 80 00 04 be 200e5c8 <rtems_bdbuf_get+0x44> <== ALWAYS TAKEN
200e5bc: 01 00 00 00 nop
rtems_bdbuf_release_disk (dd);
*bd_ptr = bd;
return RTEMS_SUCCESSFUL;
}
200e5c0: 81 c7 e0 08 ret <== NOT EXECUTED
200e5c4: 81 e8 00 00 restore <== NOT EXECUTED
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
if (sc != RTEMS_SUCCESSFUL)
return sc;
rtems_bdbuf_lock_cache ();
200e5c8: 7f ff f7 0d call 200c1fc <rtems_bdbuf_lock_cache>
200e5cc: 01 00 00 00 nop
*/
if (rtems_bdbuf_tracer)
printf ("bdbuf:get: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n",
media_block, block, (unsigned) dev);
bd = rtems_bdbuf_get_buffer_for_access (dev, media_block, bds_per_group);
200e5d0: d4 07 bf f8 ld [ %fp + -8 ], %o2
200e5d4: d6 07 bf f4 ld [ %fp + -12 ], %o3
200e5d8: 90 10 00 10 mov %l0, %o0
200e5dc: 7f ff ff 55 call 200e330 <rtems_bdbuf_get_buffer_for_access>
200e5e0: 92 10 00 19 mov %i1, %o1
switch (bd->state)
200e5e4: c2 02 20 28 ld [ %o0 + 0x28 ], %g1
200e5e8: 80 a0 60 02 cmp %g1, 2
200e5ec: 02 80 00 16 be 200e644 <rtems_bdbuf_get+0xc0>
200e5f0: a0 10 00 08 mov %o0, %l0
200e5f4: 80 a0 60 07 cmp %g1, 7
200e5f8: 02 80 00 0a be 200e620 <rtems_bdbuf_get+0x9c>
200e5fc: 80 a0 60 01 cmp %g1, 1
200e600: 02 80 00 14 be 200e650 <rtems_bdbuf_get+0xcc> <== ALWAYS TAKEN
200e604: 82 10 20 05 mov 5, %g1
* so just gets the block to fill.
*/
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_2);
200e608: d0 02 20 28 ld [ %o0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e60c: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200e610: 82 10 60 1e or %g1, 0x1e, %g1 ! 4200001e <RAM_END+0x3fc0001e><== NOT EXECUTED
200e614: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200e618: 7f ff e7 35 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e61c: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e620: 82 10 20 04 mov 4, %g1
200e624: c2 22 20 28 st %g1, [ %o0 + 0x28 ]
{
rtems_bdbuf_show_users ("get", bd);
rtems_bdbuf_show_usage ();
}
rtems_bdbuf_unlock_cache ();
200e628: 7f ff f7 83 call 200c434 <rtems_bdbuf_unlock_cache>
200e62c: 01 00 00 00 nop
rtems_bdbuf_release_disk (dd);
200e630: 7f ff f7 d9 call 200c594 <rtems_bdbuf_release_disk>
200e634: d0 07 bf fc ld [ %fp + -4 ], %o0
*bd_ptr = bd;
200e638: e0 26 c0 00 st %l0, [ %i3 ]
return RTEMS_SUCCESSFUL;
}
200e63c: 81 c7 e0 08 ret
200e640: 81 e8 00 00 restore
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e644: 82 10 20 03 mov 3, %g1
200e648: c2 22 20 28 st %g1, [ %o0 + 0x28 ]
switch (bd->state)
{
case RTEMS_BDBUF_STATE_CACHED:
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_CACHED);
break;
200e64c: 30 bf ff f7 b,a 200e628 <rtems_bdbuf_get+0xa4>
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e650: c2 22 20 28 st %g1, [ %o0 + 0x28 ]
case RTEMS_BDBUF_STATE_CACHED:
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_CACHED);
break;
case RTEMS_BDBUF_STATE_EMPTY:
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_EMPTY);
break;
200e654: 30 bf ff f5 b,a 200e628 <rtems_bdbuf_get+0xa4>
0200e330 <rtems_bdbuf_get_buffer_for_access>:
static rtems_bdbuf_buffer *
rtems_bdbuf_get_buffer_for_access (dev_t dev,
rtems_blkdev_bnum block,
size_t bds_per_group)
{
200e330: 9d e3 bf a0 save %sp, -96, %sp
200e334: 21 00 80 8b sethi %hi(0x2022c00), %l0
static bool
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e338: 23 00 80 30 sethi %hi(0x200c000), %l1
200e33c: a0 14 23 78 or %l0, 0x378, %l0
200e340: a2 14 61 30 or %l1, 0x130, %l1
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
break;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200e344: ba 04 20 70 add %l0, 0x70, %i5
}
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
200e348: ae 04 20 68 add %l0, 0x68, %l7
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e34c: ac 10 20 08 mov 8, %l6
200e350: aa 04 20 5c add %l0, 0x5c, %l5
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200e354: a8 04 20 44 add %l0, 0x44, %l4
{
if (rtems_bdbuf_wait_for_recycle (bd))
{
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200e358: a4 04 20 78 add %l0, 0x78, %l2
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200e35c: a6 04 20 54 add %l0, 0x54, %l3
static rtems_bdbuf_buffer *
rtems_bdbuf_avl_search (rtems_bdbuf_buffer** root,
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
200e360: f8 04 20 40 ld [ %l0 + 0x40 ], %i4
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e364: 80 a7 20 00 cmp %i4, 0
200e368: 02 80 00 0e be 200e3a0 <rtems_bdbuf_get_buffer_for_access+0x70>
200e36c: 90 10 00 18 mov %i0, %o0
200e370: c2 07 20 18 ld [ %i4 + 0x18 ], %g1
200e374: 80 a6 00 01 cmp %i0, %g1
200e378: 02 80 00 21 be 200e3fc <rtems_bdbuf_get_buffer_for_access+0xcc>
200e37c: c4 07 20 1c ld [ %i4 + 0x1c ], %g2
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e380: 80 a6 00 01 cmp %i0, %g1
200e384: 08 80 00 18 bleu 200e3e4 <rtems_bdbuf_get_buffer_for_access+0xb4>
200e388: 01 00 00 00 nop
{
p = p->avl.right;
200e38c: f8 07 20 0c ld [ %i4 + 0xc ], %i4
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e390: 80 a7 20 00 cmp %i4, 0
200e394: 32 bf ff f8 bne,a 200e374 <rtems_bdbuf_get_buffer_for_access+0x44>
200e398: c2 07 20 18 ld [ %i4 + 0x18 ], %g1
bd = NULL;
}
}
else
{
bd = rtems_bdbuf_get_buffer_from_lru_list (dev, block, bds_per_group);
200e39c: 90 10 00 18 mov %i0, %o0
200e3a0: 92 10 00 19 mov %i1, %o1
200e3a4: 94 10 00 1a mov %i2, %o2
200e3a8: 7f ff fe d4 call 200def8 <rtems_bdbuf_get_buffer_from_lru_list>
200e3ac: 96 10 00 1b mov %i3, %o3
if (bd == NULL)
200e3b0: b8 92 20 00 orcc %o0, 0, %i4
200e3b4: 32 80 00 22 bne,a 200e43c <rtems_bdbuf_get_buffer_for_access+0x10c>
200e3b8: 23 00 80 30 sethi %hi(0x200c000), %l1
200e3bc: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
200e3c0: 80 a0 40 13 cmp %g1, %l3
200e3c4: 02 80 00 04 be 200e3d4 <rtems_bdbuf_get_buffer_for_access+0xa4>
200e3c8: 01 00 00 00 nop
static void
rtems_bdbuf_wait_for_buffer (void)
{
if (!rtems_chain_is_empty (&bdbuf_cache.modified))
rtems_bdbuf_wake_swapper ();
200e3cc: 7f ff f8 7d call 200c5c0 <rtems_bdbuf_wake_swapper>
200e3d0: 01 00 00 00 nop
rtems_bdbuf_anonymous_wait (&bdbuf_cache.buffer_waiters);
200e3d4: 7f ff f9 2a call 200c87c <rtems_bdbuf_anonymous_wait>
200e3d8: 90 10 00 12 mov %l2, %o0
static rtems_bdbuf_buffer *
rtems_bdbuf_avl_search (rtems_bdbuf_buffer** root,
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
200e3dc: 10 bf ff e2 b 200e364 <rtems_bdbuf_get_buffer_for_access+0x34>
200e3e0: f8 04 20 40 ld [ %l0 + 0x40 ], %i4
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e3e4: 12 80 00 04 bne 200e3f4 <rtems_bdbuf_get_buffer_for_access+0xc4><== ALWAYS TAKEN
200e3e8: 80 a6 40 02 cmp %i1, %g2
200e3ec: 38 bf ff e9 bgu,a 200e390 <rtems_bdbuf_get_buffer_for_access+0x60><== NOT EXECUTED
200e3f0: f8 07 20 0c ld [ %i4 + 0xc ], %i4 <== NOT EXECUTED
{
p = p->avl.right;
}
else
{
p = p->avl.left;
200e3f4: 10 bf ff e7 b 200e390 <rtems_bdbuf_get_buffer_for_access+0x60>
200e3f8: f8 07 20 08 ld [ %i4 + 8 ], %i4
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e3fc: 80 a6 40 02 cmp %i1, %g2
200e400: 12 bf ff e1 bne 200e384 <rtems_bdbuf_get_buffer_for_access+0x54><== NEVER TAKEN
200e404: 80 a6 00 01 cmp %i0, %g1
200e408: c2 07 20 20 ld [ %i4 + 0x20 ], %g1
200e40c: 80 a6 80 01 cmp %i2, %g1
200e410: 22 80 00 06 be,a 200e428 <rtems_bdbuf_get_buffer_for_access+0xf8>
200e414: c2 07 20 30 ld [ %i4 + 0x30 ], %g1
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e418: 38 bf ff de bgu,a 200e390 <rtems_bdbuf_get_buffer_for_access+0x60>
200e41c: f8 07 20 0c ld [ %i4 + 0xc ], %i4
{
p = p->avl.right;
}
else
{
p = p->avl.left;
200e420: 10 bf ff dc b 200e390 <rtems_bdbuf_get_buffer_for_access+0x60>
200e424: f8 07 20 08 ld [ %i4 + 8 ], %i4
{
bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dev, block);
if (bd != NULL)
{
if (bd->group->bds_per_group != bds_per_group)
200e428: c2 00 60 08 ld [ %g1 + 8 ], %g1
200e42c: 80 a0 40 1b cmp %g1, %i3
200e430: 12 80 00 14 bne 200e480 <rtems_bdbuf_get_buffer_for_access+0x150>
200e434: 01 00 00 00 nop
static void
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e438: 23 00 80 30 sethi %hi(0x200c000), %l1
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
break;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200e43c: 21 00 80 8b sethi %hi(0x2022c00), %l0
static void
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e440: a2 14 61 5c or %l1, 0x15c, %l1
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
break;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200e444: a0 14 23 e8 or %l0, 0x3e8, %l0
return;
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
200e448: a4 04 3f f8 add %l0, -8, %l2
static void
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e44c: c2 07 20 28 ld [ %i4 + 0x28 ], %g1
200e450: 80 a0 60 0a cmp %g1, 0xa
200e454: 08 80 00 15 bleu 200e4a8 <rtems_bdbuf_get_buffer_for_access+0x178><== ALWAYS TAKEN
200e458: 83 28 60 02 sll %g1, 2, %g1
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_7);
200e45c: d0 07 20 28 ld [ %i4 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e460: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200e464: 82 10 60 05 or %g1, 5, %g1 ! 42000005 <RAM_END+0x3fc00005><== NOT EXECUTED
200e468: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200e46c: 7f ff e7 a0 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e470: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
}
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
200e474: 90 10 00 1c mov %i4, %o0
200e478: 7f ff f9 21 call 200c8fc <rtems_bdbuf_wait>
200e47c: 92 10 00 17 mov %l7, %o1
static bool
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e480: c2 07 20 28 ld [ %i4 + 0x28 ], %g1
200e484: 80 a0 60 0a cmp %g1, 0xa
200e488: 28 80 00 17 bleu,a 200e4e4 <rtems_bdbuf_get_buffer_for_access+0x1b4><== ALWAYS TAKEN
200e48c: 83 28 60 02 sll %g1, 2, %g1
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_8);
200e490: d0 07 20 28 ld [ %i4 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e494: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200e498: 82 10 60 06 or %g1, 6, %g1 ! 42000006 <RAM_END+0x3fc00006><== NOT EXECUTED
200e49c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200e4a0: 7f ff e7 93 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e4a4: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
static void
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e4a8: c2 04 40 01 ld [ %l1 + %g1 ], %g1
200e4ac: 81 c0 40 00 jmp %g1
200e4b0: 01 00 00 00 nop
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200e4b4: c2 07 20 30 ld [ %i4 + 0x30 ], %g1
200e4b8: c4 00 60 0c ld [ %g1 + 0xc ], %g2
200e4bc: 84 00 bf ff add %g2, -1, %g2
200e4c0: c4 20 60 0c st %g2, [ %g1 + 0xc ]
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200e4c4: 7f ff e9 07 call 20088e0 <_Chain_Extract>
200e4c8: 90 10 00 1c mov %i4, %o0
}
static void
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)
{
++bd->group->users;
200e4cc: c2 07 20 30 ld [ %i4 + 0x30 ], %g1
200e4d0: c4 00 60 0c ld [ %g1 + 0xc ], %g2
200e4d4: 84 00 a0 01 inc %g2
200e4d8: c4 20 60 0c st %g2, [ %g1 + 0xc ]
rtems_bdbuf_wait_for_access (bd);
rtems_bdbuf_group_obtain (bd);
return bd;
}
200e4dc: 81 c7 e0 08 ret
200e4e0: 91 e8 00 1c restore %g0, %i4, %o0
static bool
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200e4e4: c2 04 40 01 ld [ %l1 + %g1 ], %g1
200e4e8: 81 c0 40 00 jmp %g1
200e4ec: 01 00 00 00 nop
200e4f0: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e4f4: ec 27 20 28 st %l6, [ %i4 + 0x28 ] <== NOT EXECUTED
200e4f8: 7f ff e8 fa call 20088e0 <_Chain_Extract> <== NOT EXECUTED
200e4fc: 01 00 00 00 nop <== 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 );
200e500: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
200e504: 7f ff e8 eb call 20088b0 <_Chain_Append> <== NOT EXECUTED
200e508: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
rtems_bdbuf_request_sync_for_modified_buffer (rtems_bdbuf_buffer *bd)
{
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_SYNC);
rtems_chain_extract (&bd->link);
rtems_chain_append (&bdbuf_cache.sync, &bd->link);
rtems_bdbuf_wake_swapper ();
200e50c: 7f ff f8 2d call 200c5c0 <rtems_bdbuf_wake_swapper> <== NOT EXECUTED
200e510: 01 00 00 00 nop <== NOT EXECUTED
200e514: 30 bf ff db b,a 200e480 <rtems_bdbuf_get_buffer_for_access+0x150><== NOT EXECUTED
case RTEMS_BDBUF_STATE_MODIFIED:
rtems_bdbuf_request_sync_for_modified_buffer (bd);
break;
case RTEMS_BDBUF_STATE_CACHED:
case RTEMS_BDBUF_STATE_EMPTY:
if (bd->waiters == 0)
200e518: c2 07 20 2c ld [ %i4 + 0x2c ], %g1
200e51c: 80 a0 60 00 cmp %g1, 0
200e520: 12 bf ff ad bne 200e3d4 <rtems_bdbuf_get_buffer_for_access+0xa4><== ALWAYS TAKEN
200e524: 01 00 00 00 nop
{
if (bd->group->bds_per_group != bds_per_group)
{
if (rtems_bdbuf_wait_for_recycle (bd))
{
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
200e528: 7f ff fb 1b call 200d194 <rtems_bdbuf_remove_from_tree_and_lru_list><== NOT EXECUTED
200e52c: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200e530: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
200e534: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e538: c0 27 20 28 clr [ %i4 + 0x28 ] <== NOT EXECUTED
200e53c: 40 00 10 0f call 2012578 <_Chain_Insert> <== NOT EXECUTED
200e540: 01 00 00 00 nop <== NOT EXECUTED
{
if (rtems_bdbuf_wait_for_recycle (bd))
{
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200e544: 7f ff f7 36 call 200c21c <rtems_bdbuf_wake> <== NOT EXECUTED
200e548: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
static rtems_bdbuf_buffer *
rtems_bdbuf_avl_search (rtems_bdbuf_buffer** root,
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
200e54c: 10 bf ff 86 b 200e364 <rtems_bdbuf_get_buffer_for_access+0x34><== NOT EXECUTED
200e550: f8 04 20 40 ld [ %l0 + 0x40 ], %i4 <== NOT EXECUTED
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
break;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200e554: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
200e558: 7f ff f8 e9 call 200c8fc <rtems_bdbuf_wait> <== NOT EXECUTED
200e55c: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
200e560: 30 bf ff c8 b,a 200e480 <rtems_bdbuf_get_buffer_for_access+0x150><== NOT EXECUTED
return;
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.access_waiters);
200e564: 90 10 00 1c mov %i4, %o0
200e568: 7f ff f8 e5 call 200c8fc <rtems_bdbuf_wait>
200e56c: 92 10 00 12 mov %l2, %o1
200e570: 30 bf ff b7 b,a 200e44c <rtems_bdbuf_get_buffer_for_access+0x11c>
break;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200e574: 90 10 00 1c mov %i4, %o0
200e578: 7f ff f8 e1 call 200c8fc <rtems_bdbuf_wait>
200e57c: 92 10 00 10 mov %l0, %o1
200e580: 30 bf ff b3 b,a 200e44c <rtems_bdbuf_get_buffer_for_access+0x11c>
0200def8 <rtems_bdbuf_get_buffer_from_lru_list>:
static rtems_bdbuf_buffer *
rtems_bdbuf_get_buffer_from_lru_list (dev_t dev,
rtems_blkdev_bnum block,
size_t bds_per_group)
{
200def8: 9d e3 bf 20 save %sp, -224, %sp
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
200defc: 23 00 80 8b sethi %hi(0x2022c00), %l1
200df00: a2 14 63 78 or %l1, 0x378, %l1 ! 2022f78 <bdbuf_cache>
200df04: e0 04 60 44 ld [ %l1 + 0x44 ], %l0
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200df08: ba 04 60 48 add %l1, 0x48, %i5
rtems_chain_node *node = rtems_chain_first (&bdbuf_cache.lru);
while (!rtems_chain_is_tail (&bdbuf_cache.lru, node))
200df0c: 80 a4 00 1d cmp %l0, %i5
200df10: 02 80 00 41 be 200e014 <rtems_bdbuf_get_buffer_from_lru_list+0x11c>
200df14: a4 10 00 18 mov %i0, %l2
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
group->bds_per_group = new_bds_per_group;
bufs_per_bd = bdbuf_cache.max_bds_per_group / new_bds_per_group;
for (b = 1, bd = group->bdbuf + bufs_per_bd;
200df18: ae 04 60 44 add %l1, 0x44, %l7
b < group->bds_per_group;
b++, bd += bufs_per_bd)
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
if (b > 1)
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200df1c: b8 04 60 78 add %l1, 0x78, %i4
bd->group->bds_per_group, bds_per_group);
/*
* If nobody waits for this BD, we may recycle it.
*/
if (bd->waiters == 0)
200df20: c2 04 20 2c ld [ %l0 + 0x2c ], %g1
200df24: 80 a0 60 00 cmp %g1, 0
200df28: 32 80 00 38 bne,a 200e008 <rtems_bdbuf_get_buffer_from_lru_list+0x110>
200df2c: e0 04 00 00 ld [ %l0 ], %l0
{
if (bd->group->bds_per_group == bds_per_group)
200df30: ea 04 20 30 ld [ %l0 + 0x30 ], %l5
200df34: d2 05 60 08 ld [ %l5 + 8 ], %o1
200df38: 80 a2 40 1b cmp %o1, %i3
200df3c: 02 80 00 38 be 200e01c <rtems_bdbuf_get_buffer_from_lru_list+0x124>
200df40: 01 00 00 00 nop
{
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
empty_bd = bd;
}
else if (bd->group->users == 0)
200df44: c2 05 60 0c ld [ %l5 + 0xc ], %g1
200df48: 80 a0 60 00 cmp %g1, 0
200df4c: 32 80 00 2f bne,a 200e008 <rtems_bdbuf_get_buffer_from_lru_list+0x110>
200df50: e0 04 00 00 ld [ %l0 ], %l0
group - bdbuf_cache.groups, group->bds_per_group,
new_bds_per_group);
bufs_per_bd = bdbuf_cache.max_bds_per_group / group->bds_per_group;
for (b = 0, bd = group->bdbuf;
200df54: e8 05 60 10 ld [ %l5 + 0x10 ], %l4
200df58: 80 a2 60 00 cmp %o1, 0
if (rtems_bdbuf_tracer)
printf ("bdbuf:realloc: %tu: %zd -> %zd\n",
group - bdbuf_cache.groups, group->bds_per_group,
new_bds_per_group);
bufs_per_bd = bdbuf_cache.max_bds_per_group / group->bds_per_group;
200df5c: d0 04 60 20 ld [ %l1 + 0x20 ], %o0
for (b = 0, bd = group->bdbuf;
200df60: 02 80 00 0e be 200df98 <rtems_bdbuf_get_buffer_from_lru_list+0xa0><== NEVER TAKEN
200df64: a6 10 00 14 mov %l4, %l3
200df68: 40 00 44 01 call 201ef6c <.udiv>
200df6c: a6 10 20 00 clr %l3
200df70: ad 2a 20 06 sll %o0, 6, %l6
b < group->bds_per_group;
b++, bd += bufs_per_bd)
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
200df74: 7f ff fc 88 call 200d194 <rtems_bdbuf_remove_from_tree_and_lru_list>
200df78: 90 10 00 14 mov %l4, %o0
group - bdbuf_cache.groups, group->bds_per_group,
new_bds_per_group);
bufs_per_bd = bdbuf_cache.max_bds_per_group / group->bds_per_group;
for (b = 0, bd = group->bdbuf;
200df7c: c2 05 60 08 ld [ %l5 + 8 ], %g1
b < group->bds_per_group;
b++, bd += bufs_per_bd)
200df80: a6 04 e0 01 inc %l3
group - bdbuf_cache.groups, group->bds_per_group,
new_bds_per_group);
bufs_per_bd = bdbuf_cache.max_bds_per_group / group->bds_per_group;
for (b = 0, bd = group->bdbuf;
200df84: 80 a4 c0 01 cmp %l3, %g1
200df88: 0a bf ff fb bcs 200df74 <rtems_bdbuf_get_buffer_from_lru_list+0x7c>
200df8c: a8 05 00 16 add %l4, %l6, %l4
200df90: d0 04 60 20 ld [ %l1 + 0x20 ], %o0
200df94: e6 05 60 10 ld [ %l5 + 0x10 ], %l3
b < group->bds_per_group;
b++, bd += bufs_per_bd)
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
group->bds_per_group = new_bds_per_group;
200df98: f6 25 60 08 st %i3, [ %l5 + 8 ]
bufs_per_bd = bdbuf_cache.max_bds_per_group / new_bds_per_group;
for (b = 1, bd = group->bdbuf + bufs_per_bd;
200df9c: 80 a6 e0 01 cmp %i3, 1
200dfa0: 08 80 00 16 bleu 200dff8 <rtems_bdbuf_get_buffer_from_lru_list+0x100>
200dfa4: b0 10 00 13 mov %l3, %i0
200dfa8: 92 10 00 1b mov %i3, %o1
200dfac: 40 00 43 f0 call 201ef6c <.udiv>
200dfb0: a8 10 20 01 mov 1, %l4
200dfb4: ad 2a 20 06 sll %o0, 6, %l6
200dfb8: a6 04 c0 16 add %l3, %l6, %l3
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200dfbc: c0 24 e0 28 clr [ %l3 + 0x28 ]
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200dfc0: 92 10 00 13 mov %l3, %o1
200dfc4: 40 00 11 6d call 2012578 <_Chain_Insert>
200dfc8: 90 10 00 17 mov %l7, %o0
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
group->bds_per_group = new_bds_per_group;
bufs_per_bd = bdbuf_cache.max_bds_per_group / new_bds_per_group;
for (b = 1, bd = group->bdbuf + bufs_per_bd;
200dfcc: c2 05 60 08 ld [ %l5 + 8 ], %g1
b < group->bds_per_group;
b++, bd += bufs_per_bd)
200dfd0: a8 05 20 01 inc %l4
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
group->bds_per_group = new_bds_per_group;
bufs_per_bd = bdbuf_cache.max_bds_per_group / new_bds_per_group;
for (b = 1, bd = group->bdbuf + bufs_per_bd;
200dfd4: 80 a5 00 01 cmp %l4, %g1
200dfd8: 0a bf ff f9 bcs 200dfbc <rtems_bdbuf_get_buffer_from_lru_list+0xc4><== NEVER TAKEN
200dfdc: a6 04 c0 16 add %l3, %l6, %l3
b < group->bds_per_group;
b++, bd += bufs_per_bd)
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
if (b > 1)
200dfe0: 80 a5 20 01 cmp %l4, 1
200dfe4: 28 80 00 05 bleu,a 200dff8 <rtems_bdbuf_get_buffer_from_lru_list+0x100><== NEVER TAKEN
200dfe8: f0 05 60 10 ld [ %l5 + 0x10 ], %i0 <== NOT EXECUTED
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200dfec: 7f ff f8 8c call 200c21c <rtems_bdbuf_wake>
200dff0: 90 10 00 1c mov %i4, %o0
200dff4: f0 05 60 10 ld [ %l5 + 0x10 ], %i0
}
else if (bd->group->users == 0)
empty_bd = rtems_bdbuf_group_realloc (bd->group, bds_per_group);
}
if (empty_bd != NULL)
200dff8: 80 a6 20 00 cmp %i0, 0
200dffc: 32 80 00 0f bne,a 200e038 <rtems_bdbuf_get_buffer_from_lru_list+0x140><== ALWAYS TAKEN
200e000: c0 26 20 08 clr [ %i0 + 8 ]
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
200e004: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED
rtems_blkdev_bnum block,
size_t bds_per_group)
{
rtems_chain_node *node = rtems_chain_first (&bdbuf_cache.lru);
while (!rtems_chain_is_tail (&bdbuf_cache.lru, node))
200e008: 80 a4 00 1d cmp %l0, %i5
200e00c: 12 bf ff c5 bne 200df20 <rtems_bdbuf_get_buffer_from_lru_list+0x28>
200e010: 01 00 00 00 nop
node = rtems_chain_next (node);
}
return NULL;
}
200e014: 81 c7 e0 08 ret
200e018: 91 e8 20 00 restore %g0, 0, %o0
*/
if (bd->waiters == 0)
{
if (bd->group->bds_per_group == bds_per_group)
{
rtems_bdbuf_remove_from_tree_and_lru_list (bd);
200e01c: 7f ff fc 5e call 200d194 <rtems_bdbuf_remove_from_tree_and_lru_list>
200e020: 90 10 00 10 mov %l0, %o0
200e024: b0 10 00 10 mov %l0, %i0
}
else if (bd->group->users == 0)
empty_bd = rtems_bdbuf_group_realloc (bd->group, bds_per_group);
}
if (empty_bd != NULL)
200e028: 80 a6 20 00 cmp %i0, 0
200e02c: 22 bf ff f7 be,a 200e008 <rtems_bdbuf_get_buffer_from_lru_list+0x110><== NEVER TAKEN
200e030: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED
dev_t dev,
rtems_blkdev_bnum block)
{
bd->dev = dev;
bd->block = block;
bd->avl.left = NULL;
200e034: c0 26 20 08 clr [ %i0 + 8 ]
bd->avl.right = NULL;
200e038: c0 26 20 0c clr [ %i0 + 0xc ]
rtems_bdbuf_buffer* node)
{
dev_t dev = node->dev;
rtems_blkdev_bnum block = node->block;
rtems_bdbuf_buffer* p = *root;
200e03c: c2 04 60 40 ld [ %l1 + 0x40 ], %g1
static void
rtems_bdbuf_setup_empty_buffer (rtems_bdbuf_buffer *bd,
dev_t dev,
rtems_blkdev_bnum block)
{
bd->dev = dev;
200e040: e4 26 20 18 st %l2, [ %i0 + 0x18 ]
200e044: f2 26 20 1c st %i1, [ %i0 + 0x1c ]
bd->block = block;
200e048: f4 26 20 20 st %i2, [ %i0 + 0x20 ]
bd->avl.left = NULL;
bd->avl.right = NULL;
bd->waiters = 0;
200e04c: c0 26 20 2c clr [ %i0 + 0x2c ]
rtems_bdbuf_buffer* buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];
rtems_bdbuf_buffer** buf_prev = buf_stack;
bool modified = false;
if (p == NULL)
200e050: 80 a0 60 00 cmp %g1, 0
200e054: 02 80 00 b2 be 200e31c <rtems_bdbuf_get_buffer_from_lru_list+0x424>
200e058: 98 10 20 01 mov 1, %o4
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e05c: c6 00 60 18 ld [ %g1 + 0x18 ], %g3
rtems_bdbuf_buffer* buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];
rtems_bdbuf_buffer** buf_prev = buf_stack;
bool modified = false;
if (p == NULL)
200e060: 96 07 bf 80 add %fp, -128, %o3
200e064: 84 10 00 0b mov %o3, %g2
return 0;
}
while (p != NULL)
{
*buf_prev++ = p;
200e068: c2 22 c0 00 st %g1, [ %o3 ]
break;
}
}
else if ((p->dev != dev) || (p->block != block))
{
p->avl.cache = -1;
200e06c: 94 10 3f ff mov -1, %o2
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e070: 80 a4 80 03 cmp %l2, %g3
return 0;
}
while (p != NULL)
{
*buf_prev++ = p;
200e074: 88 00 a0 04 add %g2, 4, %g4
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e078: 18 80 00 17 bgu 200e0d4 <rtems_bdbuf_get_buffer_from_lru_list+0x1dc><== NEVER TAKEN
200e07c: da 00 60 1c ld [ %g1 + 0x1c ], %o5
200e080: 80 a4 80 03 cmp %l2, %g3
200e084: 32 80 00 09 bne,a 200e0a8 <rtems_bdbuf_get_buffer_from_lru_list+0x1b0><== NEVER TAKEN
200e088: c6 00 60 08 ld [ %g1 + 8 ], %g3 <== NOT EXECUTED
200e08c: 80 a6 40 0d cmp %i1, %o5
200e090: 38 80 00 12 bgu,a 200e0d8 <rtems_bdbuf_get_buffer_from_lru_list+0x1e0><== NEVER TAKEN
200e094: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
200e098: 80 a6 40 0d cmp %i1, %o5
200e09c: 22 80 00 40 be,a 200e19c <rtems_bdbuf_get_buffer_from_lru_list+0x2a4><== ALWAYS TAKEN
200e0a0: c6 00 60 20 ld [ %g1 + 0x20 ], %g3
}
}
else if ((p->dev != dev) || (p->block != block))
{
p->avl.cache = -1;
q = p->avl.left;
200e0a4: c6 00 60 08 ld [ %g1 + 8 ], %g3 <== NOT EXECUTED
if (q == NULL)
200e0a8: 80 a0 e0 00 cmp %g3, 0
200e0ac: 02 80 00 49 be 200e1d0 <rtems_bdbuf_get_buffer_from_lru_list+0x2d8>
200e0b0: d4 28 60 10 stb %o2, [ %g1 + 0x10 ]
{
q = node;
p->avl.left = q;
200e0b4: 82 10 00 03 mov %g3, %g1
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e0b8: c6 00 60 18 ld [ %g1 + 0x18 ], %g3
p->avl.cache = -1;
q = p->avl.left;
if (q == NULL)
{
q = node;
p->avl.left = q;
200e0bc: 84 10 00 04 mov %g4, %g2
return 0;
}
while (p != NULL)
{
*buf_prev++ = p;
200e0c0: c2 20 80 00 st %g1, [ %g2 ]
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e0c4: 80 a4 80 03 cmp %l2, %g3
return 0;
}
while (p != NULL)
{
*buf_prev++ = p;
200e0c8: 88 00 a0 04 add %g2, 4, %g4
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e0cc: 08 bf ff ee bleu 200e084 <rtems_bdbuf_get_buffer_from_lru_list+0x18c><== ALWAYS TAKEN
200e0d0: da 00 60 1c ld [ %g1 + 0x1c ], %o5
{
p->avl.cache = 1;
q = p->avl.right;
200e0d4: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
if (q == NULL)
200e0d8: 80 a0 e0 00 cmp %g3, 0
200e0dc: 12 bf ff f6 bne 200e0b4 <rtems_bdbuf_get_buffer_from_lru_list+0x1bc>
200e0e0: d8 28 60 10 stb %o4, [ %g1 + 0x10 ]
{
q = node;
p->avl.right = q = node;
200e0e4: f0 20 60 0c st %i0, [ %g1 + 0xc ]
200e0e8: c8 08 60 10 ldub [ %g1 + 0x10 ], %g4
}
p = q;
}
q->avl.left = q->avl.right = NULL;
200e0ec: c0 26 20 0c clr [ %i0 + 0xc ]
200e0f0: c0 26 20 08 clr [ %i0 + 8 ]
q->avl.bal = 0;
200e0f4: c0 2e 20 11 clrb [ %i0 + 0x11 ]
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e0f8: 94 10 20 01 mov 1, %o2
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200e0fc: 10 80 00 11 b 200e140 <rtems_bdbuf_get_buffer_from_lru_list+0x248>
200e100: 92 10 3f ff mov -1, %o1
p->avl.bal = 0;
modified = false;
break;
case 0:
p->avl.bal = 1;
200e104: 86 10 00 01 mov %g1, %g3
200e108: 9a 10 20 01 mov 1, %o5
default:
break;
}
}
q = p;
if (buf_prev > buf_stack)
200e10c: 80 a0 80 0b cmp %g2, %o3
200e110: 28 80 00 1f bleu,a 200e18c <rtems_bdbuf_get_buffer_from_lru_list+0x294>
200e114: c6 24 60 40 st %g3, [ %l1 + 0x40 ]
{
p = *--buf_prev;
200e118: 84 00 bf fc add %g2, -4, %g2
200e11c: c2 00 80 00 ld [ %g2 ], %g1
if (p->avl.cache == -1)
200e120: d8 48 60 10 ldsb [ %g1 + 0x10 ], %o4
200e124: 80 a3 3f ff cmp %o4, -1
200e128: 02 80 00 33 be 200e1f4 <rtems_bdbuf_get_buffer_from_lru_list+0x2fc>
200e12c: c8 08 60 10 ldub [ %g1 + 0x10 ], %g4
{
p->avl.left = q;
}
else
{
p->avl.right = q;
200e130: c6 20 60 0c st %g3, [ %g1 + 0xc ]
q->avl.left = q->avl.right = NULL;
q->avl.bal = 0;
modified = true;
buf_prev--;
while (modified)
200e134: 80 8b 60 ff btst 0xff, %o5
200e138: 22 80 00 16 be,a 200e190 <rtems_bdbuf_get_buffer_from_lru_list+0x298>
200e13c: 82 10 20 01 mov 1, %g1
{
if (p->avl.cache == -1)
200e140: 87 29 20 18 sll %g4, 0x18, %g3
200e144: 87 38 e0 18 sra %g3, 0x18, %g3
200e148: 80 a0 ff ff cmp %g3, -1
200e14c: 22 80 00 23 be,a 200e1d8 <rtems_bdbuf_get_buffer_from_lru_list+0x2e0>
200e150: c8 48 60 11 ldsb [ %g1 + 0x11 ], %g4
break;
}
}
else
{
switch (p->avl.bal)
200e154: c6 48 60 11 ldsb [ %g1 + 0x11 ], %g3
200e158: 80 a0 e0 00 cmp %g3, 0
200e15c: 22 bf ff ea be,a 200e104 <rtems_bdbuf_get_buffer_from_lru_list+0x20c>
200e160: d4 28 60 11 stb %o2, [ %g1 + 0x11 ]
200e164: 80 a0 e0 01 cmp %g3, 1
200e168: 02 80 00 25 be 200e1fc <rtems_bdbuf_get_buffer_from_lru_list+0x304>
200e16c: 80 a0 ff ff cmp %g3, -1
200e170: 22 80 00 15 be,a 200e1c4 <rtems_bdbuf_get_buffer_from_lru_list+0x2cc><== ALWAYS TAKEN
200e174: c0 28 60 11 clrb [ %g1 + 0x11 ]
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e178: 86 10 00 01 mov %g1, %g3 <== NOT EXECUTED
default:
break;
}
}
q = p;
if (buf_prev > buf_stack)
200e17c: 80 a0 80 0b cmp %g2, %o3 <== NOT EXECUTED
200e180: 18 bf ff e6 bgu 200e118 <rtems_bdbuf_get_buffer_from_lru_list+0x220><== NOT EXECUTED
200e184: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
p->avl.right = q;
}
}
else
{
*root = p;
200e188: c6 24 60 40 st %g3, [ %l1 + 0x40 ] <== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e18c: 82 10 20 01 mov 1, %g1
200e190: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
if (empty_bd != NULL)
{
rtems_bdbuf_setup_empty_buffer (empty_bd, dev, block);
return empty_bd;
200e194: 81 c7 e0 08 ret
200e198: 81 e8 00 00 restore
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e19c: 80 a6 80 03 cmp %i2, %g3
200e1a0: 38 bf ff ce bgu,a 200e0d8 <rtems_bdbuf_get_buffer_from_lru_list+0x1e0>
200e1a4: c6 00 60 0c ld [ %g1 + 0xc ], %g3
q = node;
p->avl.right = q = node;
break;
}
}
else if ((p->dev != dev) || (p->block != block))
200e1a8: 80 a6 80 03 cmp %i2, %g3
200e1ac: 32 bf ff bf bne,a 200e0a8 <rtems_bdbuf_get_buffer_from_lru_list+0x1b0><== ALWAYS TAKEN
200e1b0: c6 00 60 08 ld [ %g1 + 8 ], %g3
bd->avl.left = NULL;
bd->avl.right = NULL;
bd->waiters = 0;
if (rtems_bdbuf_avl_insert (&bdbuf_cache.tree, bd) != 0)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_RECYCLE);
200e1b4: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200e1b8: 7f ff e8 4d call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e1bc: 90 12 20 1b or %o0, 0x1b, %o0 ! 4200001b <RAM_END+0x3fc0001b><== NOT EXECUTED
else
{
switch (p->avl.bal)
{
case -1:
p->avl.bal = 0;
200e1c0: c0 28 60 11 clrb [ %g1 + 0x11 ] <== NOT EXECUTED
200e1c4: 86 10 00 01 mov %g1, %g3
200e1c8: 10 bf ff d1 b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214>
200e1cc: 9a 10 20 00 clr %o5
p->avl.cache = -1;
q = p->avl.left;
if (q == NULL)
{
q = node;
p->avl.left = q;
200e1d0: 10 bf ff c6 b 200e0e8 <rtems_bdbuf_get_buffer_from_lru_list+0x1f0>
200e1d4: f0 20 60 08 st %i0, [ %g1 + 8 ]
while (modified)
{
if (p->avl.cache == -1)
{
switch (p->avl.bal)
200e1d8: 80 a1 20 00 cmp %g4, 0
200e1dc: 12 80 00 24 bne 200e26c <rtems_bdbuf_get_buffer_from_lru_list+0x374>
200e1e0: 80 a1 20 01 cmp %g4, 1
p->avl.bal = 0;
modified = false;
break;
case 0:
p->avl.bal = -1;
200e1e4: c6 28 60 11 stb %g3, [ %g1 + 0x11 ]
200e1e8: 9a 10 20 01 mov 1, %o5
200e1ec: 10 bf ff c8 b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214>
200e1f0: 86 10 00 01 mov %g1, %g3
{
p = *--buf_prev;
if (p->avl.cache == -1)
{
p->avl.left = q;
200e1f4: 10 bf ff d0 b 200e134 <rtems_bdbuf_get_buffer_from_lru_list+0x23c>
200e1f8: c6 20 60 08 st %g3, [ %g1 + 8 ]
case 0:
p->avl.bal = 1;
break;
case 1:
p1 = p->avl.right;
200e1fc: c6 00 60 0c ld [ %g1 + 0xc ], %g3
if (p1->avl.bal == 1) /* simple RR-turn */
200e200: c8 48 e0 11 ldsb [ %g3 + 0x11 ], %g4
200e204: 80 a1 20 01 cmp %g4, 1
200e208: 02 80 00 35 be 200e2dc <rtems_bdbuf_get_buffer_from_lru_list+0x3e4><== ALWAYS TAKEN
200e20c: c8 00 e0 08 ld [ %g3 + 8 ], %g4
p = p1;
}
else /* double RL-turn */
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
200e210: da 01 20 0c ld [ %g4 + 0xc ], %o5 <== NOT EXECUTED
p2->avl.right = p1;
200e214: c6 21 20 0c st %g3, [ %g4 + 0xc ] <== NOT EXECUTED
p = p1;
}
else /* double RL-turn */
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
200e218: da 20 e0 08 st %o5, [ %g3 + 8 ] <== NOT EXECUTED
p2->avl.right = p1;
p->avl.right = p2->avl.left;
200e21c: d8 01 20 08 ld [ %g4 + 8 ], %o4 <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200e220: da 49 20 11 ldsb [ %g4 + 0x11 ], %o5 <== NOT EXECUTED
else /* double RL-turn */
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
200e224: d8 20 60 0c st %o4, [ %g1 + 0xc ] <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200e228: 80 a3 60 01 cmp %o5, 1 <== NOT EXECUTED
200e22c: 02 80 00 32 be 200e2f4 <rtems_bdbuf_get_buffer_from_lru_list+0x3fc><== NOT EXECUTED
200e230: c2 21 20 08 st %g1, [ %g4 + 8 ] <== NOT EXECUTED
200e234: c0 28 60 11 clrb [ %g1 + 0x11 ] <== NOT EXECUTED
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
200e238: c2 49 20 11 ldsb [ %g4 + 0x11 ], %g1 <== NOT EXECUTED
200e23c: 80 a0 7f ff cmp %g1, -1 <== NOT EXECUTED
200e240: 22 80 00 07 be,a 200e25c <rtems_bdbuf_get_buffer_from_lru_list+0x364><== NOT EXECUTED
200e244: d4 28 e0 11 stb %o2, [ %g3 + 0x11 ] <== NOT EXECUTED
200e248: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
p = p2;
}
p->avl.bal = 0;
200e24c: 9a 10 20 00 clr %o5
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
200e250: 86 10 00 04 mov %g4, %g3
p = p2;
}
p->avl.bal = 0;
200e254: 10 bf ff ae b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214>
200e258: c0 28 e0 11 clrb [ %g3 + 0x11 ]
200e25c: 9a 10 20 00 clr %o5 <== NOT EXECUTED
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
200e260: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
p = p2;
}
p->avl.bal = 0;
200e264: 10 bf ff aa b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214><== NOT EXECUTED
200e268: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
while (modified)
{
if (p->avl.cache == -1)
{
switch (p->avl.bal)
200e26c: 02 bf ff d5 be 200e1c0 <rtems_bdbuf_get_buffer_from_lru_list+0x2c8><== NEVER TAKEN
200e270: 80 a1 3f ff cmp %g4, -1
200e274: 12 bf ff c2 bne 200e17c <rtems_bdbuf_get_buffer_from_lru_list+0x284><== NEVER TAKEN
200e278: 86 10 00 01 mov %g1, %g3
case 0:
p->avl.bal = -1;
break;
case -1:
p1 = p->avl.left;
200e27c: c6 00 60 08 ld [ %g1 + 8 ], %g3
if (p1->avl.bal == -1) /* simple LL-turn */
200e280: c8 48 e0 11 ldsb [ %g3 + 0x11 ], %g4
200e284: 80 a1 3f ff cmp %g4, -1
200e288: 02 80 00 1d be 200e2fc <rtems_bdbuf_get_buffer_from_lru_list+0x404><== NEVER TAKEN
200e28c: c8 00 e0 0c ld [ %g3 + 0xc ], %g4
p = p1;
}
else /* double LR-turn */
{
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
200e290: da 01 20 08 ld [ %g4 + 8 ], %o5
p2->avl.left = p1;
200e294: c6 21 20 08 st %g3, [ %g4 + 8 ]
p = p1;
}
else /* double LR-turn */
{
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
200e298: da 20 e0 0c st %o5, [ %g3 + 0xc ]
p2->avl.left = p1;
p->avl.left = p2->avl.right;
200e29c: d8 01 20 0c ld [ %g4 + 0xc ], %o4
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = +1; else p->avl.bal = 0;
200e2a0: da 49 20 11 ldsb [ %g4 + 0x11 ], %o5
else /* double LR-turn */
{
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
p2->avl.left = p1;
p->avl.left = p2->avl.right;
200e2a4: d8 20 60 08 st %o4, [ %g1 + 8 ]
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = +1; else p->avl.bal = 0;
200e2a8: 80 a3 7f ff cmp %o5, -1
200e2ac: 02 80 00 1a be 200e314 <rtems_bdbuf_get_buffer_from_lru_list+0x41c><== NEVER TAKEN
200e2b0: c2 21 20 0c st %g1, [ %g4 + 0xc ]
200e2b4: c0 28 60 11 clrb [ %g1 + 0x11 ]
if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
200e2b8: c2 49 20 11 ldsb [ %g4 + 0x11 ], %g1
200e2bc: 80 a0 60 01 cmp %g1, 1
200e2c0: 32 bf ff e3 bne,a 200e24c <rtems_bdbuf_get_buffer_from_lru_list+0x354><== ALWAYS TAKEN
200e2c4: c0 28 e0 11 clrb [ %g3 + 0x11 ]
200e2c8: d2 28 e0 11 stb %o1, [ %g3 + 0x11 ] <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e2cc: 9a 10 20 00 clr %o5 <== NOT EXECUTED
p1->avl.right = p2->avl.left;
p2->avl.left = p1;
p->avl.left = p2->avl.right;
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = +1; else p->avl.bal = 0;
if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
200e2d0: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e2d4: 10 bf ff 8e b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214><== NOT EXECUTED
200e2d8: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
p1 = p->avl.right;
if (p1->avl.bal == 1) /* simple RR-turn */
{
p->avl.right = p1->avl.left;
p1->avl.left = p;
p->avl.bal = 0;
200e2dc: c0 28 60 11 clrb [ %g1 + 0x11 ]
case 1:
p1 = p->avl.right;
if (p1->avl.bal == 1) /* simple RR-turn */
{
p->avl.right = p1->avl.left;
200e2e0: c8 20 60 0c st %g4, [ %g1 + 0xc ]
p1->avl.left = p;
200e2e4: c2 20 e0 08 st %g1, [ %g3 + 8 ]
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e2e8: c0 28 e0 11 clrb [ %g3 + 0x11 ]
200e2ec: 10 bf ff 88 b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214>
200e2f0: 9a 10 20 00 clr %o5
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200e2f4: 10 bf ff d1 b 200e238 <rtems_bdbuf_get_buffer_from_lru_list+0x340><== NOT EXECUTED
200e2f8: d2 28 60 11 stb %o1, [ %g1 + 0x11 ] <== NOT EXECUTED
p1 = p->avl.left;
if (p1->avl.bal == -1) /* simple LL-turn */
{
p->avl.left = p1->avl.right;
p1->avl.right = p;
p->avl.bal = 0;
200e2fc: c0 28 60 11 clrb [ %g1 + 0x11 ] <== NOT EXECUTED
case -1:
p1 = p->avl.left;
if (p1->avl.bal == -1) /* simple LL-turn */
{
p->avl.left = p1->avl.right;
200e300: c8 20 60 08 st %g4, [ %g1 + 8 ] <== NOT EXECUTED
p1->avl.right = p;
200e304: c2 20 e0 0c st %g1, [ %g3 + 0xc ] <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
p = p2;
}
p->avl.bal = 0;
200e308: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
200e30c: 10 bf ff 80 b 200e10c <rtems_bdbuf_get_buffer_from_lru_list+0x214><== NOT EXECUTED
200e310: 9a 10 20 00 clr %o5 <== NOT EXECUTED
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
p2->avl.left = p1;
p->avl.left = p2->avl.right;
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = +1; else p->avl.bal = 0;
200e314: 10 bf ff e9 b 200e2b8 <rtems_bdbuf_get_buffer_from_lru_list+0x3c0><== NOT EXECUTED
200e318: d4 28 60 11 stb %o2, [ %g1 + 0x11 ] <== NOT EXECUTED
bool modified = false;
if (p == NULL)
{
*root = node;
200e31c: f0 24 60 40 st %i0, [ %l1 + 0x40 ]
node->avl.left = NULL;
200e320: c0 26 20 08 clr [ %i0 + 8 ]
node->avl.right = NULL;
200e324: c0 26 20 0c clr [ %i0 + 0xc ]
node->avl.bal = 0;
200e328: 10 bf ff 99 b 200e18c <rtems_bdbuf_get_buffer_from_lru_list+0x294>
200e32c: c0 2e 20 11 clrb [ %i0 + 0x11 ]
0200c94c <rtems_bdbuf_init>:
*
* @return rtems_status_code The initialisation status.
*/
rtems_status_code
rtems_bdbuf_init (void)
{
200c94c: 9d e3 bf a0 save %sp, -96, %sp
rtems_mode prev_mode;
if (rtems_bdbuf_tracer)
printf ("bdbuf:init\n");
if (rtems_interrupt_is_in_progress())
200c950: 03 00 80 8c sethi %hi(0x2023000), %g1
200c954: c2 00 63 ec ld [ %g1 + 0x3ec ], %g1 ! 20233ec <_ISR_Nest_level>
200c958: 80 a0 60 00 cmp %g1, 0
200c95c: 12 80 00 0d bne 200c990 <rtems_bdbuf_init+0x44> <== NEVER TAKEN
200c960: b0 10 20 12 mov 0x12, %i0
return RTEMS_CALLED_FROM_ISR;
/*
* Check the configuration table values.
*/
if ((bdbuf_config.buffer_max % bdbuf_config.buffer_min) != 0)
200c964: 25 00 80 83 sethi %hi(0x2020c00), %l2
200c968: a4 14 a3 ac or %l2, 0x3ac, %l2 ! 2020fac <rtems_bdbuf_configuration>
200c96c: e8 04 a0 24 ld [ %l2 + 0x24 ], %l4
200c970: e6 04 a0 20 ld [ %l2 + 0x20 ], %l3
200c974: 90 10 00 14 mov %l4, %o0
200c978: 92 10 00 13 mov %l3, %o1
200c97c: 40 00 4a 28 call 201f21c <.urem>
200c980: b0 10 20 0a mov 0xa, %i0
200c984: 80 a2 20 00 cmp %o0, 0
200c988: 02 80 00 04 be 200c998 <rtems_bdbuf_init+0x4c> <== ALWAYS TAKEN
200c98c: 01 00 00 00 nop
}
bdbuf_cache.initialised = false;
return RTEMS_UNSATISFIED;
}
200c990: 81 c7 e0 08 ret <== NOT EXECUTED
200c994: 81 e8 00 00 restore <== NOT EXECUTED
/*
* We use a special variable to manage the initialisation incase we have
* completing threads doing this. You may get errors if the another thread
* makes a call and we have not finished initialisation.
*/
prev_mode = rtems_bdbuf_disable_preemption ();
200c998: 7f ff ff 9b call 200c804 <rtems_bdbuf_disable_preemption>
200c99c: 23 00 80 8b sethi %hi(0x2022c00), %l1
if (bdbuf_cache.initialised)
200c9a0: a0 14 63 78 or %l1, 0x378, %l0 ! 2022f78 <bdbuf_cache>
200c9a4: c2 0c 20 88 ldub [ %l0 + 0x88 ], %g1
200c9a8: 80 a0 60 00 cmp %g1, 0
200c9ac: 02 80 00 06 be 200c9c4 <rtems_bdbuf_init+0x78> <== ALWAYS TAKEN
200c9b0: aa 10 00 08 mov %o0, %l5
{
rtems_bdbuf_restore_preemption (prev_mode);
200c9b4: 7f ff ff a3 call 200c840 <rtems_bdbuf_restore_preemption> <== NOT EXECUTED
200c9b8: b0 10 20 0c mov 0xc, %i0 <== NOT EXECUTED
return RTEMS_RESOURCE_IN_USE;
200c9bc: 81 c7 e0 08 ret <== NOT EXECUTED
200c9c0: 81 e8 00 00 restore <== NOT EXECUTED
}
memset(&bdbuf_cache, 0, sizeof(bdbuf_cache));
200c9c4: 92 10 20 00 clr %o1
200c9c8: 94 10 20 90 mov 0x90, %o2
200c9cc: 40 00 27 01 call 20165d0 <memset>
200c9d0: 90 10 00 10 mov %l0, %o0
bdbuf_cache.initialised = true;
200c9d4: 82 10 20 01 mov 1, %g1
rtems_bdbuf_restore_preemption (prev_mode);
200c9d8: 90 10 00 15 mov %l5, %o0
200c9dc: 7f ff ff 99 call 200c840 <rtems_bdbuf_restore_preemption>
200c9e0: c2 2c 20 88 stb %g1, [ %l0 + 0x88 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200c9e4: 82 04 20 0c add %l0, 0xc, %g1
200c9e8: c2 24 20 08 st %g1, [ %l0 + 8 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200c9ec: 82 04 20 08 add %l0, 8, %g1
200c9f0: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200c9f4: 82 04 20 48 add %l0, 0x48, %g1
200c9f8: c2 24 20 44 st %g1, [ %l0 + 0x44 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200c9fc: 82 04 20 44 add %l0, 0x44, %g1
200ca00: c2 24 20 4c st %g1, [ %l0 + 0x4c ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200ca04: 82 04 20 54 add %l0, 0x54, %g1
200ca08: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200ca0c: 82 04 20 50 add %l0, 0x50, %g1
200ca10: c2 24 20 58 st %g1, [ %l0 + 0x58 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200ca14: 82 04 20 60 add %l0, 0x60, %g1
*/
cache_aligment = 32; /* FIXME rtems_cache_get_data_line_size() */
if (cache_aligment <= 0)
cache_aligment = CPU_ALIGNMENT;
bdbuf_cache.sync_device = BDBUF_INVALID_DEV;
200ca18: 05 3f ff ff sethi %hi(0xfffffc00), %g2
200ca1c: c2 24 20 5c st %g1, [ %l0 + 0x5c ]
200ca20: 84 10 a3 ff or %g2, 0x3ff, %g2
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200ca24: 82 04 20 5c add %l0, 0x5c, %g1
200ca28: 86 10 00 02 mov %g2, %g3
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
200ca2c: c0 24 20 0c clr [ %l0 + 0xc ]
200ca30: c0 24 20 48 clr [ %l0 + 0x48 ]
200ca34: c0 24 20 54 clr [ %l0 + 0x54 ]
200ca38: c0 24 20 60 clr [ %l0 + 0x60 ]
200ca3c: c4 3c 20 38 std %g2, [ %l0 + 0x38 ]
the_chain->last = _Chain_Head(the_chain);
200ca40: c2 24 20 64 st %g1, [ %l0 + 0x64 ]
rtems_chain_initialize_empty (&bdbuf_cache.sync);
/*
* Create the locks for the cache.
*/
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'C', 'l'),
200ca44: 2b 10 91 10 sethi %hi(0x42444000), %l5
200ca48: 92 10 20 01 mov 1, %o1
200ca4c: 90 15 63 6c or %l5, 0x36c, %o0
200ca50: 94 10 20 54 mov 0x54, %o2
200ca54: 96 10 20 00 clr %o3
200ca58: 7f ff eb fb call 2007a44 <rtems_semaphore_create>
200ca5c: 98 04 20 28 add %l0, 0x28, %o4
1, RTEMS_BDBUF_CACHE_LOCK_ATTRIBS, 0,
&bdbuf_cache.lock);
if (sc != RTEMS_SUCCESSFUL)
200ca60: 80 a2 20 00 cmp %o0, 0
200ca64: 02 80 00 25 be 200caf8 <rtems_bdbuf_init+0x1ac> <== ALWAYS TAKEN
200ca68: 01 00 00 00 nop
return RTEMS_SUCCESSFUL;
error:
if (bdbuf_cache.swapout != 0)
200ca6c: d0 04 63 78 ld [ %l1 + 0x378 ], %o0 <== NOT EXECUTED
200ca70: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ca74: 12 80 00 1e bne 200caec <rtems_bdbuf_init+0x1a0> <== NOT EXECUTED
200ca78: 01 00 00 00 nop <== NOT EXECUTED
rtems_task_delete (bdbuf_cache.swapout);
free (bdbuf_cache.buffers);
200ca7c: 7f ff dc c5 call 2003d90 <free> <== NOT EXECUTED
200ca80: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 <== NOT EXECUTED
free (bdbuf_cache.groups);
200ca84: 7f ff dc c3 call 2003d90 <free> <== NOT EXECUTED
200ca88: d0 04 20 84 ld [ %l0 + 0x84 ], %o0 <== NOT EXECUTED
free (bdbuf_cache.bds);
200ca8c: 7f ff dc c1 call 2003d90 <free> <== NOT EXECUTED
200ca90: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.buffer_waiters.sema);
200ca94: 7f ff ec 60 call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
200ca98: d0 04 20 7c ld [ %l0 + 0x7c ], %o0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.access_waiters.sema);
200ca9c: 7f ff ec 5e call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
200caa0: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.transfer_waiters.sema);
200caa4: 7f ff ec 5c call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
200caa8: d0 04 20 74 ld [ %l0 + 0x74 ], %o0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.sync_lock);
200caac: 7f ff ec 5a call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
200cab0: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
if (bdbuf_cache.lock != 0)
200cab4: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
200cab8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200cabc: 12 80 00 05 bne 200cad0 <rtems_bdbuf_init+0x184> <== NOT EXECUTED
200cac0: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_bdbuf_unlock_cache ();
rtems_semaphore_delete (bdbuf_cache.lock);
}
bdbuf_cache.initialised = false;
200cac4: c0 2c 20 88 clrb [ %l0 + 0x88 ] <== NOT EXECUTED
return RTEMS_UNSATISFIED;
}
200cac8: 81 c7 e0 08 ret <== NOT EXECUTED
200cacc: 91 e8 20 0d restore %g0, 0xd, %o0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.transfer_waiters.sema);
rtems_semaphore_delete (bdbuf_cache.sync_lock);
if (bdbuf_cache.lock != 0)
{
rtems_bdbuf_unlock_cache ();
200cad0: 7f ff fe 59 call 200c434 <rtems_bdbuf_unlock_cache> <== NOT EXECUTED
200cad4: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED
rtems_semaphore_delete (bdbuf_cache.lock);
200cad8: 7f ff ec 4f call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
200cadc: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
200cae0: c0 2c 20 88 clrb [ %l0 + 0x88 ] <== NOT EXECUTED
200cae4: 81 c7 e0 08 ret <== NOT EXECUTED
200cae8: 81 e8 00 00 restore <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
error:
if (bdbuf_cache.swapout != 0)
rtems_task_delete (bdbuf_cache.swapout);
200caec: 7f ff ed 35 call 2007fc0 <rtems_task_delete> <== NOT EXECUTED
200caf0: 01 00 00 00 nop <== NOT EXECUTED
200caf4: 30 bf ff e2 b,a 200ca7c <rtems_bdbuf_init+0x130> <== NOT EXECUTED
1, RTEMS_BDBUF_CACHE_LOCK_ATTRIBS, 0,
&bdbuf_cache.lock);
if (sc != RTEMS_SUCCESSFUL)
goto error;
rtems_bdbuf_lock_cache ();
200caf8: 7f ff fd c1 call 200c1fc <rtems_bdbuf_lock_cache>
200cafc: 01 00 00 00 nop
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'C', 's'),
200cb00: 90 15 63 73 or %l5, 0x373, %o0
200cb04: 92 10 20 01 mov 1, %o1
200cb08: 94 10 20 54 mov 0x54, %o2
200cb0c: 96 10 20 00 clr %o3
200cb10: 7f ff eb cd call 2007a44 <rtems_semaphore_create>
200cb14: 98 04 20 2c add %l0, 0x2c, %o4
1, RTEMS_BDBUF_CACHE_LOCK_ATTRIBS, 0,
&bdbuf_cache.sync_lock);
if (sc != RTEMS_SUCCESSFUL)
200cb18: 80 a2 20 00 cmp %o0, 0
200cb1c: 12 bf ff d5 bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cb20: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
goto error;
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'C', 'a'),
200cb24: 90 15 63 61 or %l5, 0x361, %o0
200cb28: 92 10 20 00 clr %o1
200cb2c: 94 10 20 24 mov 0x24, %o2
200cb30: 96 10 20 00 clr %o3
200cb34: 7f ff eb c4 call 2007a44 <rtems_semaphore_create>
200cb38: 98 04 20 6c add %l0, 0x6c, %o4
0, RTEMS_BDBUF_CACHE_WAITER_ATTRIBS, 0,
&bdbuf_cache.access_waiters.sema);
if (sc != RTEMS_SUCCESSFUL)
200cb3c: 80 a2 20 00 cmp %o0, 0
200cb40: 12 bf ff cc bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cb44: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
goto error;
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'C', 't'),
200cb48: 90 15 63 74 or %l5, 0x374, %o0
200cb4c: 92 10 20 00 clr %o1
200cb50: 94 10 20 24 mov 0x24, %o2
200cb54: 96 10 20 00 clr %o3
200cb58: 7f ff eb bb call 2007a44 <rtems_semaphore_create>
200cb5c: 98 04 20 74 add %l0, 0x74, %o4
0, RTEMS_BDBUF_CACHE_WAITER_ATTRIBS, 0,
&bdbuf_cache.transfer_waiters.sema);
if (sc != RTEMS_SUCCESSFUL)
200cb60: 80 a2 20 00 cmp %o0, 0
200cb64: 12 bf ff c3 bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cb68: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
goto error;
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'C', 'b'),
200cb6c: 90 15 63 62 or %l5, 0x362, %o0
200cb70: 92 10 20 00 clr %o1
200cb74: 94 10 20 24 mov 0x24, %o2
200cb78: 96 10 20 00 clr %o3
200cb7c: 7f ff eb b2 call 2007a44 <rtems_semaphore_create>
200cb80: 98 04 20 7c add %l0, 0x7c, %o4
0, RTEMS_BDBUF_CACHE_WAITER_ATTRIBS, 0,
&bdbuf_cache.buffer_waiters.sema);
if (sc != RTEMS_SUCCESSFUL)
200cb84: 80 a2 20 00 cmp %o0, 0
200cb88: 32 bf ff ba bne,a 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cb8c: d0 04 63 78 ld [ %l1 + 0x378 ], %o0 <== NOT EXECUTED
/*
* Compute the various number of elements in the cache.
*/
bdbuf_cache.buffer_min_count =
bdbuf_config.size / bdbuf_config.buffer_min;
200cb90: d0 04 a0 1c ld [ %l2 + 0x1c ], %o0
200cb94: 40 00 48 f6 call 201ef6c <.udiv>
200cb98: 92 10 00 13 mov %l3, %o1
bdbuf_cache.max_bds_per_group =
bdbuf_config.buffer_max / bdbuf_config.buffer_min;
200cb9c: 92 10 00 13 mov %l3, %o1
/*
* Compute the various number of elements in the cache.
*/
bdbuf_cache.buffer_min_count =
bdbuf_config.size / bdbuf_config.buffer_min;
200cba0: aa 10 00 08 mov %o0, %l5
bdbuf_cache.max_bds_per_group =
bdbuf_config.buffer_max / bdbuf_config.buffer_min;
200cba4: 90 10 00 14 mov %l4, %o0
200cba8: 40 00 48 f1 call 201ef6c <.udiv>
200cbac: ea 24 20 1c st %l5, [ %l0 + 0x1c ]
bdbuf_cache.group_count =
200cbb0: 92 10 00 08 mov %o0, %o1
/*
* Compute the various number of elements in the cache.
*/
bdbuf_cache.buffer_min_count =
bdbuf_config.size / bdbuf_config.buffer_min;
bdbuf_cache.max_bds_per_group =
200cbb4: d0 24 20 20 st %o0, [ %l0 + 0x20 ]
bdbuf_config.buffer_max / bdbuf_config.buffer_min;
bdbuf_cache.group_count =
200cbb8: 40 00 48 ed call 201ef6c <.udiv>
200cbbc: 90 10 00 15 mov %l5, %o0
bdbuf_cache.buffer_min_count / bdbuf_cache.max_bds_per_group;
/*
* Allocate the memory for the buffer descriptors.
*/
bdbuf_cache.bds = calloc (sizeof (rtems_bdbuf_buffer),
200cbc0: 92 10 00 15 mov %l5, %o1
*/
bdbuf_cache.buffer_min_count =
bdbuf_config.size / bdbuf_config.buffer_min;
bdbuf_cache.max_bds_per_group =
bdbuf_config.buffer_max / bdbuf_config.buffer_min;
bdbuf_cache.group_count =
200cbc4: d0 24 20 80 st %o0, [ %l0 + 0x80 ]
bdbuf_cache.buffer_min_count / bdbuf_cache.max_bds_per_group;
/*
* Allocate the memory for the buffer descriptors.
*/
bdbuf_cache.bds = calloc (sizeof (rtems_bdbuf_buffer),
200cbc8: 7f ff db cf call 2003b04 <calloc>
200cbcc: 90 10 20 40 mov 0x40, %o0
bdbuf_cache.buffer_min_count);
if (!bdbuf_cache.bds)
200cbd0: 80 a2 20 00 cmp %o0, 0
200cbd4: 02 bf ff a6 be 200ca6c <rtems_bdbuf_init+0x120> <== NEVER TAKEN
200cbd8: d0 24 20 14 st %o0, [ %l0 + 0x14 ]
goto error;
/*
* Allocate the memory for the buffer descriptors.
*/
bdbuf_cache.groups = calloc (sizeof (rtems_bdbuf_group),
200cbdc: d2 04 20 80 ld [ %l0 + 0x80 ], %o1
200cbe0: 7f ff db c9 call 2003b04 <calloc>
200cbe4: 90 10 20 14 mov 0x14, %o0
bdbuf_cache.group_count);
if (!bdbuf_cache.groups)
200cbe8: 80 a2 20 00 cmp %o0, 0
200cbec: 02 bf ff a0 be 200ca6c <rtems_bdbuf_init+0x120> <== NEVER TAKEN
200cbf0: d0 24 20 84 st %o0, [ %l0 + 0x84 ]
* aligned. It is possible to free the memory allocated by rtems_memalign()
* with free(). Return 0 if allocated.
*
* The memory allocate allows a
*/
if (rtems_memalign ((void **) &bdbuf_cache.buffers,
200cbf4: d2 04 20 1c ld [ %l0 + 0x1c ], %o1
200cbf8: 40 00 48 a3 call 201ee84 <.umul>
200cbfc: 90 10 00 13 mov %l3, %o0
200cc00: 92 10 20 20 mov 0x20, %o1
200cc04: 94 10 00 08 mov %o0, %o2
200cc08: 40 00 11 d1 call 201134c <rtems_memalign>
200cc0c: 90 04 20 18 add %l0, 0x18, %o0
200cc10: 80 a2 20 00 cmp %o0, 0
200cc14: 12 bf ff 97 bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cc18: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
/*
* The cache is empty after opening so we need to add all the buffers to it
* and initialise the groups.
*/
for (b = 0, group = bdbuf_cache.groups,
200cc1c: fa 04 20 84 ld [ %l0 + 0x84 ], %i5
bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;
200cc20: e8 04 20 14 ld [ %l0 + 0x14 ], %l4
200cc24: ee 04 20 18 ld [ %l0 + 0x18 ], %l7
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
{
bd->dev = BDBUF_INVALID_DEV;
200cc28: 31 3f ff ff sethi %hi(0xfffffc00), %i0
/*
* The cache is empty after opening so we need to add all the buffers to it
* and initialise the groups.
*/
for (b = 0, group = bdbuf_cache.groups,
bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;
200cc2c: ac 10 20 00 clr %l6
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
{
bd->dev = BDBUF_INVALID_DEV;
200cc30: b0 16 23 ff or %i0, 0x3ff, %i0
/*
* The cache is empty after opening so we need to add all the buffers to it
* and initialise the groups.
*/
for (b = 0, group = bdbuf_cache.groups,
200cc34: aa 10 00 10 mov %l0, %l5
bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
{
bd->dev = BDBUF_INVALID_DEV;
200cc38: b2 10 00 18 mov %i0, %i1
200cc3c: b6 04 20 44 add %l0, 0x44, %i3
/*
* The cache is empty after opening so we need to add all the buffers to it
* and initialise the groups.
*/
for (b = 0, group = bdbuf_cache.groups,
200cc40: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200cc44: 92 10 00 14 mov %l4, %o1
200cc48: 80 a5 80 01 cmp %l6, %g1
200cc4c: 1a 80 00 12 bcc 200cc94 <rtems_bdbuf_init+0x348>
200cc50: 90 10 00 1b mov %i3, %o0
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
{
bd->dev = BDBUF_INVALID_DEV;
bd->group = group;
bd->buffer = buffer;
200cc54: ee 25 20 24 st %l7, [ %l4 + 0x24 ]
bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
{
bd->dev = BDBUF_INVALID_DEV;
bd->group = group;
200cc58: fa 25 20 30 st %i5, [ %l4 + 0x30 ]
200cc5c: 7f ff ef 15 call 20088b0 <_Chain_Append>
200cc60: f0 3d 20 18 std %i0, [ %l4 + 0x18 ]
bd->buffer = buffer;
rtems_chain_append (&bdbuf_cache.lru, &bd->link);
if ((b % bdbuf_cache.max_bds_per_group) ==
200cc64: f8 05 60 20 ld [ %l5 + 0x20 ], %i4
200cc68: 90 10 00 16 mov %l6, %o0
200cc6c: 92 10 00 1c mov %i4, %o1
200cc70: 40 00 49 6b call 201f21c <.urem>
200cc74: a8 05 20 40 add %l4, 0x40, %l4
200cc78: b8 07 3f ff add %i4, -1, %i4
* and initialise the groups.
*/
for (b = 0, group = bdbuf_cache.groups,
bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;
b < bdbuf_cache.buffer_min_count;
b++, bd++, buffer += bdbuf_config.buffer_min)
200cc7c: ae 05 c0 13 add %l7, %l3, %l7
bd->group = group;
bd->buffer = buffer;
rtems_chain_append (&bdbuf_cache.lru, &bd->link);
if ((b % bdbuf_cache.max_bds_per_group) ==
200cc80: 80 a2 00 1c cmp %o0, %i4
200cc84: 12 bf ff ef bne 200cc40 <rtems_bdbuf_init+0x2f4>
200cc88: ac 05 a0 01 inc %l6
(bdbuf_cache.max_bds_per_group - 1))
group++;
200cc8c: 10 bf ff ed b 200cc40 <rtems_bdbuf_init+0x2f4>
200cc90: ba 07 60 14 add %i5, 0x14, %i5
b < bdbuf_cache.group_count;
b++,
group++,
bd += bdbuf_cache.max_bds_per_group)
{
group->bds_per_group = bdbuf_cache.max_bds_per_group;
200cc94: c8 05 60 20 ld [ %l5 + 0x20 ], %g4
(bdbuf_cache.max_bds_per_group - 1))
group++;
}
for (b = 0,
group = bdbuf_cache.groups,
200cc98: c2 05 60 84 ld [ %l5 + 0x84 ], %g1
bd = bdbuf_cache.bds;
200cc9c: c6 05 60 14 ld [ %l5 + 0x14 ], %g3
200cca0: d8 05 60 80 ld [ %l5 + 0x80 ], %o4
b < bdbuf_cache.group_count;
b++,
group++,
bd += bdbuf_cache.max_bds_per_group)
200cca4: 9b 29 20 06 sll %g4, 6, %o5
200cca8: 84 10 20 00 clr %g2
if ((b % bdbuf_cache.max_bds_per_group) ==
(bdbuf_cache.max_bds_per_group - 1))
group++;
}
for (b = 0,
200ccac: 80 a0 80 0c cmp %g2, %o4
200ccb0: 1a 80 00 07 bcc 200cccc <rtems_bdbuf_init+0x380>
200ccb4: 84 00 a0 01 inc %g2
b++,
group++,
bd += bdbuf_cache.max_bds_per_group)
{
group->bds_per_group = bdbuf_cache.max_bds_per_group;
group->bdbuf = bd;
200ccb8: c6 20 60 10 st %g3, [ %g1 + 0x10 ]
b < bdbuf_cache.group_count;
b++,
group++,
bd += bdbuf_cache.max_bds_per_group)
{
group->bds_per_group = bdbuf_cache.max_bds_per_group;
200ccbc: c8 20 60 08 st %g4, [ %g1 + 8 ]
for (b = 0,
group = bdbuf_cache.groups,
bd = bdbuf_cache.bds;
b < bdbuf_cache.group_count;
b++,
group++,
200ccc0: 82 00 60 14 add %g1, 0x14, %g1
bd += bdbuf_cache.max_bds_per_group)
200ccc4: 10 bf ff fa b 200ccac <rtems_bdbuf_init+0x360>
200ccc8: 86 00 c0 0d add %g3, %o5, %g3
* threads.
*/
bdbuf_cache.swapout_enabled = true;
sc = rtems_task_create (rtems_build_name('B', 'S', 'W', 'P'),
bdbuf_config.swapout_priority ?
200cccc: d2 04 a0 08 ld [ %l2 + 8 ], %o1
/*
* Create and start swapout task. This task will create and manage the worker
* threads.
*/
bdbuf_cache.swapout_enabled = true;
200ccd0: 82 10 20 01 mov 1, %g1
200ccd4: c2 2c 20 04 stb %g1, [ %l0 + 4 ]
sc = rtems_task_create (rtems_build_name('B', 'S', 'W', 'P'),
200ccd8: 80 a2 60 00 cmp %o1, 0
200ccdc: 22 80 00 02 be,a 200cce4 <rtems_bdbuf_init+0x398> <== NEVER TAKEN
200cce0: 92 10 20 0f mov 0xf, %o1 <== NOT EXECUTED
200cce4: 11 10 94 d5 sethi %hi(0x42535400), %o0
200cce8: 15 00 00 08 sethi %hi(0x2000), %o2
200ccec: 90 12 23 50 or %o0, 0x350, %o0
200ccf0: 96 10 24 00 mov 0x400, %o3
200ccf4: 98 10 20 00 clr %o4
200ccf8: 7f ff ec 67 call 2007e94 <rtems_task_create>
200ccfc: 9a 14 63 78 or %l1, 0x378, %o5
RTEMS_BDBUF_SWAPOUT_TASK_PRIORITY_DEFAULT,
SWAPOUT_TASK_STACK_SIZE,
RTEMS_PREEMPT | RTEMS_NO_TIMESLICE | RTEMS_NO_ASR,
RTEMS_LOCAL | RTEMS_NO_FLOATING_POINT,
&bdbuf_cache.swapout);
if (sc != RTEMS_SUCCESSFUL)
200cd00: 80 a2 20 00 cmp %o0, 0
200cd04: 12 bf ff 5b bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cd08: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
goto error;
sc = rtems_task_start (bdbuf_cache.swapout,
200cd0c: 03 00 80 8b sethi %hi(0x2022c00), %g1
200cd10: d0 00 63 78 ld [ %g1 + 0x378 ], %o0 ! 2022f78 <bdbuf_cache>
200cd14: 13 00 80 36 sethi %hi(0x200d800), %o1
200cd18: 94 10 00 10 mov %l0, %o2
200cd1c: 7f ff ec ee call 20080d4 <rtems_task_start>
200cd20: 92 12 61 40 or %o1, 0x140, %o1
rtems_bdbuf_swapout_task,
(rtems_task_argument) &bdbuf_cache);
if (sc != RTEMS_SUCCESSFUL)
200cd24: 80 a2 20 00 cmp %o0, 0
200cd28: 12 bf ff 52 bne 200ca70 <rtems_bdbuf_init+0x124> <== NEVER TAKEN
200cd2c: d0 04 63 78 ld [ %l1 + 0x378 ], %o0
goto error;
rtems_bdbuf_unlock_cache ();
200cd30: 7f ff fd c1 call 200c434 <rtems_bdbuf_unlock_cache>
200cd34: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
200cd38: 81 c7 e0 08 ret
200cd3c: 81 e8 00 00 restore
0200c1c8 <rtems_bdbuf_lock>:
* @param lock The mutex to lock.
* @param fatal_error_code The error code if the call fails.
*/
static void
rtems_bdbuf_lock (rtems_id lock, uint32_t fatal_error_code)
{
200c1c8: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = rtems_semaphore_obtain (lock,
200c1cc: 92 10 20 00 clr %o1
200c1d0: 90 10 00 18 mov %i0, %o0
200c1d4: 7f ff ee bd call 2007cc8 <rtems_semaphore_obtain>
200c1d8: 94 10 20 00 clr %o2
RTEMS_WAIT,
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
200c1dc: 80 a2 20 00 cmp %o0, 0
200c1e0: 12 80 00 04 bne 200c1f0 <rtems_bdbuf_lock+0x28> <== NEVER TAKEN
200c1e4: 01 00 00 00 nop
200c1e8: 81 c7 e0 08 ret
200c1ec: 81 e8 00 00 restore
rtems_fatal_error_occurred (fatal_error_code);
200c1f0: 7f ff f0 3f call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c1f4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
0200c494 <rtems_bdbuf_obtain_disk>:
rtems_bdbuf_obtain_disk (dev_t dev,
rtems_blkdev_bnum block,
rtems_disk_device **dd_ptr,
rtems_blkdev_bnum *media_block_ptr,
size_t *bds_per_group_ptr)
{
200c494: 9d e3 bf a0 save %sp, -96, %sp
rtems_disk_device *dd = NULL;
if (!bdbuf_cache.initialised)
200c498: 21 00 80 8b sethi %hi(0x2022c00), %l0
200c49c: a0 14 23 78 or %l0, 0x378, %l0 ! 2022f78 <bdbuf_cache>
200c4a0: c2 0c 20 88 ldub [ %l0 + 0x88 ], %g1
rtems_bdbuf_obtain_disk (dev_t dev,
rtems_blkdev_bnum block,
rtems_disk_device **dd_ptr,
rtems_blkdev_bnum *media_block_ptr,
size_t *bds_per_group_ptr)
{
200c4a4: 90 10 00 18 mov %i0, %o0
rtems_disk_device *dd = NULL;
if (!bdbuf_cache.initialised)
200c4a8: 80 a0 60 00 cmp %g1, 0
rtems_bdbuf_obtain_disk (dev_t dev,
rtems_blkdev_bnum block,
rtems_disk_device **dd_ptr,
rtems_blkdev_bnum *media_block_ptr,
size_t *bds_per_group_ptr)
{
200c4ac: 92 10 00 19 mov %i1, %o1
rtems_disk_device *dd = NULL;
if (!bdbuf_cache.initialised)
200c4b0: 02 80 00 37 be 200c58c <rtems_bdbuf_obtain_disk+0xf8> <== NEVER TAKEN
200c4b4: b0 10 20 16 mov 0x16, %i0
return RTEMS_NOT_CONFIGURED;
/*
* Do not hold the cache lock when obtaining the disk table.
*/
dd = rtems_disk_obtain (dev);
200c4b8: 7f ff da 82 call 2002ec0 <rtems_disk_obtain>
200c4bc: b0 10 20 04 mov 4, %i0
if (dd == NULL)
200c4c0: a2 92 20 00 orcc %o0, 0, %l1
200c4c4: 02 80 00 32 be 200c58c <rtems_bdbuf_obtain_disk+0xf8> <== NEVER TAKEN
200c4c8: 80 a7 20 00 cmp %i4, 0
return RTEMS_INVALID_ID;
*dd_ptr = dd;
if (media_block_ptr != NULL)
200c4cc: 02 80 00 11 be 200c510 <rtems_bdbuf_obtain_disk+0x7c>
200c4d0: e2 26 c0 00 st %l1, [ %i3 ]
static rtems_blkdev_bnum
rtems_bdbuf_media_block (rtems_blkdev_bnum block,
size_t block_size,
size_t media_block_size)
{
return (rtems_blkdev_bnum)
200c4d4: d6 04 60 20 ld [ %l1 + 0x20 ], %o3
200c4d8: 94 10 20 00 clr %o2
200c4dc: 92 10 00 1a mov %i2, %o1
200c4e0: 40 00 4b fb call 201f4cc <__muldi3>
200c4e4: 90 10 20 00 clr %o0
200c4e8: d6 04 60 24 ld [ %l1 + 0x24 ], %o3
200c4ec: 40 00 4e 0a call 201fd14 <__udivdi3>
200c4f0: 94 10 20 00 clr %o2
* the user.
*/
rtems_blkdev_bnum mb = rtems_bdbuf_media_block (block,
dd->block_size,
dd->media_block_size);
if (mb >= dd->size)
200c4f4: c2 04 60 1c ld [ %l1 + 0x1c ], %g1
200c4f8: 80 a0 40 09 cmp %g1, %o1
200c4fc: 08 80 00 22 bleu 200c584 <rtems_bdbuf_obtain_disk+0xf0> <== NEVER TAKEN
200c500: 90 10 00 11 mov %l1, %o0
{
rtems_disk_release(dd);
return RTEMS_INVALID_NUMBER;
}
*media_block_ptr = mb + dd->start;
200c504: c2 04 60 18 ld [ %l1 + 0x18 ], %g1
200c508: 92 02 40 01 add %o1, %g1, %o1
200c50c: d2 27 00 00 st %o1, [ %i4 ]
}
if (bds_per_group_ptr != NULL)
200c510: 80 a7 60 00 cmp %i5, 0
200c514: 02 80 00 1e be 200c58c <rtems_bdbuf_obtain_disk+0xf8>
200c518: b0 10 20 00 clr %i0
{
size_t bds_per_group = rtems_bdbuf_bds_per_group (dd->block_size);
200c51c: d0 04 60 20 ld [ %l1 + 0x20 ], %o0
rtems_bdbuf_bds_per_group (size_t size)
{
size_t bufs_per_size;
size_t bds_per_size;
if (size > bdbuf_config.buffer_max)
200c520: 03 00 80 83 sethi %hi(0x2020c00), %g1
200c524: 82 10 63 ac or %g1, 0x3ac, %g1 ! 2020fac <rtems_bdbuf_configuration>
200c528: c4 00 60 24 ld [ %g1 + 0x24 ], %g2
200c52c: 80 a2 00 02 cmp %o0, %g2
200c530: 38 80 00 15 bgu,a 200c584 <rtems_bdbuf_obtain_disk+0xf0> <== NEVER TAKEN
200c534: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return 0;
bufs_per_size = ((size - 1) / bdbuf_config.buffer_min) + 1;
200c538: d2 00 60 20 ld [ %g1 + 0x20 ], %o1
200c53c: 40 00 4a 8c call 201ef6c <.udiv>
200c540: 90 02 3f ff add %o0, -1, %o0
200c544: 90 02 20 01 inc %o0
for (bds_per_size = 1;
200c548: 80 a2 20 01 cmp %o0, 1
200c54c: 08 80 00 06 bleu 200c564 <rtems_bdbuf_obtain_disk+0xd0>
200c550: 92 10 20 01 mov 1, %o1
bds_per_size < bufs_per_size;
bds_per_size <<= 1)
200c554: 93 2a 60 01 sll %o1, 1, %o1
if (size > bdbuf_config.buffer_max)
return 0;
bufs_per_size = ((size - 1) / bdbuf_config.buffer_min) + 1;
for (bds_per_size = 1;
200c558: 80 a2 00 09 cmp %o0, %o1
200c55c: 38 bf ff ff bgu,a 200c558 <rtems_bdbuf_obtain_disk+0xc4> <== NEVER TAKEN
200c560: 93 2a 60 01 sll %o1, 1, %o1 <== NOT EXECUTED
bds_per_size < bufs_per_size;
bds_per_size <<= 1)
;
return bdbuf_cache.max_bds_per_group / bds_per_size;
200c564: 40 00 4a 82 call 201ef6c <.udiv>
200c568: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
if (bds_per_group_ptr != NULL)
{
size_t bds_per_group = rtems_bdbuf_bds_per_group (dd->block_size);
if (bds_per_group == 0)
200c56c: 80 a2 20 00 cmp %o0, 0
200c570: 22 80 00 05 be,a 200c584 <rtems_bdbuf_obtain_disk+0xf0> <== NEVER TAKEN
200c574: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
{
rtems_disk_release (dd);
return RTEMS_INVALID_NUMBER;
}
*bds_per_group_ptr = bds_per_group;
200c578: d0 27 40 00 st %o0, [ %i5 ]
}
return RTEMS_SUCCESSFUL;
}
200c57c: 81 c7 e0 08 ret
200c580: 91 e8 20 00 restore %g0, 0, %o0
{
size_t bds_per_group = rtems_bdbuf_bds_per_group (dd->block_size);
if (bds_per_group == 0)
{
rtems_disk_release (dd);
200c584: 7f ff da 3a call 2002e6c <rtems_disk_release> <== NOT EXECUTED
200c588: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
200c58c: 81 c7 e0 08 ret
200c590: 81 e8 00 00 restore
0200d3d0 <rtems_bdbuf_purge>:
}
}
static void
rtems_bdbuf_purge (rtems_bdbuf_purge_compare compare, dev_t dev)
{
200d3d0: 9d e3 bf 10 save %sp, -240, %sp
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200d3d4: 82 07 bf f8 add %fp, -8, %g1
the_chain->permanent_null = NULL;
200d3d8: c0 27 bf f8 clr [ %fp + -8 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200d3dc: a2 07 bf f4 add %fp, -12, %l1
200d3e0: c2 27 bf f4 st %g1, [ %fp + -12 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200d3e4: e2 27 bf fc st %l1, [ %fp + -4 ]
rtems_chain_control purge_list;
rtems_chain_initialize_empty (&purge_list);
rtems_bdbuf_lock_cache ();
200d3e8: 7f ff fb 85 call 200c1fc <rtems_bdbuf_lock_cache>
200d3ec: 3b 00 80 8b sethi %hi(0x2022c00), %i5
rtems_bdbuf_purge_compare compare,
dev_t dev)
{
rtems_bdbuf_buffer *stack [RTEMS_BDBUF_AVL_MAX_HEIGHT];
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
200d3f0: ba 17 63 78 or %i5, 0x378, %i5 ! 2022f78 <bdbuf_cache>
200d3f4: e0 07 60 40 ld [ %i5 + 0x40 ], %l0
*prev = NULL;
200d3f8: c0 27 bf 74 clr [ %fp + -140 ]
while (cur != NULL)
200d3fc: 80 a4 20 00 cmp %l0, 0
}
}
static void
rtems_bdbuf_purge (rtems_bdbuf_purge_compare compare, dev_t dev)
{
200d400: a8 10 00 19 mov %i1, %l4
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
*prev = NULL;
while (cur != NULL)
200d404: 02 80 00 3f be 200d500 <rtems_bdbuf_purge+0x130> <== NEVER TAKEN
200d408: aa 10 00 1a mov %i2, %l5
{
if ((*compare) (cur->dev, dev))
{
switch (cur->state)
200d40c: 27 00 80 30 sethi %hi(0x200c000), %l3
case RTEMS_BDBUF_STATE_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
break;
case RTEMS_BDBUF_STATE_SYNC:
rtems_bdbuf_wake (&bdbuf_cache.transfer_waiters);
200d410: ba 07 60 70 add %i5, 0x70, %i5
while (cur != NULL)
{
if ((*compare) (cur->dev, dev))
{
switch (cur->state)
200d414: a6 14 e1 04 or %l3, 0x104, %l3
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
*prev = NULL;
while (cur != NULL)
200d418: a4 07 bf 74 add %fp, -140, %l2
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d41c: ae 10 20 06 mov 6, %l7
200d420: ac 10 20 0a mov 0xa, %l6
*prev = NULL;
while (cur != NULL)
{
if ((*compare) (cur->dev, dev))
200d424: d0 1c 20 18 ldd [ %l0 + 0x18 ], %o0
200d428: 94 10 00 14 mov %l4, %o2
200d42c: 9f c6 00 00 call %i0
200d430: 96 10 00 15 mov %l5, %o3
200d434: 80 8a 20 ff btst 0xff, %o0
200d438: 22 80 00 0b be,a 200d464 <rtems_bdbuf_purge+0x94> <== NEVER TAKEN
200d43c: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
{
switch (cur->state)
200d440: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
200d444: 80 a0 60 0a cmp %g1, 0xa
200d448: 08 80 00 12 bleu 200d490 <rtems_bdbuf_purge+0xc0> <== ALWAYS TAKEN
200d44c: 83 28 60 02 sll %g1, 2, %g1
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_set_state (cur, RTEMS_BDBUF_STATE_ACCESS_PURGED);
break;
default:
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_STATE_11);
200d450: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200d454: 7f ff eb a6 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200d458: 90 12 20 01 or %o0, 1, %o0 ! 42000001 <RAM_END+0x3fc00001><== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d45c: ec 24 20 28 st %l6, [ %l0 + 0x28 ]
default:
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_STATE_11);
}
}
if (cur->avl.left != NULL)
200d460: c2 04 20 08 ld [ %l0 + 8 ], %g1
200d464: 80 a0 60 00 cmp %g1, 0
200d468: 22 80 00 1d be,a 200d4dc <rtems_bdbuf_purge+0x10c> <== ALWAYS TAKEN
200d46c: c2 04 20 0c ld [ %l0 + 0xc ], %g1
{
/* Left */
++prev;
200d470: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
*prev = cur;
200d474: e0 24 80 00 st %l0, [ %l2 ] <== NOT EXECUTED
cur = cur->avl.left;
200d478: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
*prev = NULL;
while (cur != NULL)
200d47c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200d480: 02 80 00 21 be 200d504 <rtems_bdbuf_purge+0x134> <== NOT EXECUTED
200d484: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200d488: 10 bf ff e7 b 200d424 <rtems_bdbuf_purge+0x54> <== NOT EXECUTED
200d48c: a0 10 00 01 mov %g1, %l0 <== NOT EXECUTED
{
if ((*compare) (cur->dev, dev))
{
switch (cur->state)
200d490: c2 04 c0 01 ld [ %l3 + %g1 ], %g1
200d494: 81 c0 40 00 jmp %g1
200d498: 01 00 00 00 nop
case RTEMS_BDBUF_STATE_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
break;
case RTEMS_BDBUF_STATE_SYNC:
rtems_bdbuf_wake (&bdbuf_cache.transfer_waiters);
200d49c: 7f ff fb 60 call 200c21c <rtems_bdbuf_wake>
200d4a0: 90 10 00 1d mov %i5, %o0
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d4a4: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
200d4a8: c4 00 60 0c ld [ %g1 + 0xc ], %g2
200d4ac: 84 00 bf ff add %g2, -1, %g2
200d4b0: c4 20 60 0c st %g2, [ %g1 + 0xc ]
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200d4b4: 7f ff ed 0b call 20088e0 <_Chain_Extract>
200d4b8: 90 10 00 10 mov %l0, %o0
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200d4bc: 90 10 00 11 mov %l1, %o0
200d4c0: 7f ff ec fc call 20088b0 <_Chain_Append>
200d4c4: 92 10 00 10 mov %l0, %o1
default:
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_STATE_11);
}
}
if (cur->avl.left != NULL)
200d4c8: c2 04 20 08 ld [ %l0 + 8 ], %g1
200d4cc: 80 a0 60 00 cmp %g1, 0
200d4d0: 32 bf ff e9 bne,a 200d474 <rtems_bdbuf_purge+0xa4> <== NEVER TAKEN
200d4d4: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
/* Left */
++prev;
*prev = cur;
cur = cur->avl.left;
}
else if (cur->avl.right != NULL)
200d4d8: c2 04 20 0c ld [ %l0 + 0xc ], %g1
200d4dc: 80 a0 60 00 cmp %g1, 0
200d4e0: 22 80 00 24 be,a 200d570 <rtems_bdbuf_purge+0x1a0> <== ALWAYS TAKEN
200d4e4: c6 04 80 00 ld [ %l2 ], %g3
{
/* Right */
++prev;
200d4e8: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
*prev = cur;
200d4ec: e0 24 80 00 st %l0, [ %l2 ] <== NOT EXECUTED
cur = cur->avl.right;
200d4f0: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
*prev = NULL;
while (cur != NULL)
200d4f4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200d4f8: 12 bf ff cb bne 200d424 <rtems_bdbuf_purge+0x54> <== NOT EXECUTED
200d4fc: a0 10 00 01 mov %g1, %l0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
200d500: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200d504: 7f ff ed 01 call 2008908 <_Chain_Get>
200d508: a0 10 20 00 clr %l0
rtems_bdbuf_purge_list (rtems_chain_control *purge_list)
{
bool wake_buffer_waiters = false;
rtems_chain_node *node = NULL;
while ((node = rtems_chain_get (purge_list)) != NULL)
200d50c: 80 a2 20 00 cmp %o0, 0
200d510: 02 80 00 0d be 200d544 <rtems_bdbuf_purge+0x174>
200d514: 80 8c 20 ff btst 0xff, %l0
{
rtems_bdbuf_buffer *bd = (rtems_bdbuf_buffer *) node;
if (bd->waiters == 0)
200d518: c2 02 20 2c ld [ %o0 + 0x2c ], %g1
200d51c: 80 a0 60 00 cmp %g1, 0
200d520: 22 80 00 02 be,a 200d528 <rtems_bdbuf_purge+0x158>
200d524: a0 10 20 01 mov 1, %l0
wake_buffer_waiters = true;
rtems_bdbuf_discard_buffer (bd);
200d528: 7f ff ff 2d call 200d1dc <rtems_bdbuf_discard_buffer>
200d52c: 01 00 00 00 nop
200d530: 7f ff ec f6 call 2008908 <_Chain_Get>
200d534: 90 10 00 11 mov %l1, %o0
rtems_bdbuf_purge_list (rtems_chain_control *purge_list)
{
bool wake_buffer_waiters = false;
rtems_chain_node *node = NULL;
while ((node = rtems_chain_get (purge_list)) != NULL)
200d538: 80 a2 20 00 cmp %o0, 0
200d53c: 12 bf ff f7 bne 200d518 <rtems_bdbuf_purge+0x148> <== NEVER TAKEN
200d540: 80 8c 20 ff btst 0xff, %l0
wake_buffer_waiters = true;
rtems_bdbuf_discard_buffer (bd);
}
if (wake_buffer_waiters)
200d544: 02 80 00 04 be 200d554 <rtems_bdbuf_purge+0x184>
200d548: 11 00 80 8b sethi %hi(0x2022c00), %o0
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200d54c: 7f ff fb 34 call 200c21c <rtems_bdbuf_wake>
200d550: 90 12 23 f0 or %o0, 0x3f0, %o0 ! 2022ff0 <bdbuf_cache+0x78>
rtems_chain_initialize_empty (&purge_list);
rtems_bdbuf_lock_cache ();
rtems_bdbuf_gather_for_purge (&purge_list, compare, dev);
rtems_bdbuf_purge_list (&purge_list);
rtems_bdbuf_unlock_cache ();
200d554: 7f ff fb b8 call 200c434 <rtems_bdbuf_unlock_cache>
200d558: 01 00 00 00 nop
}
200d55c: 81 c7 e0 08 ret
200d560: 81 e8 00 00 restore
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d564: ee 24 20 28 st %l7, [ %l0 + 0x28 ]
default:
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_STATE_11);
}
}
if (cur->avl.left != NULL)
200d568: 10 bf ff bf b 200d464 <rtems_bdbuf_purge+0x94>
200d56c: c2 04 20 08 ld [ %l0 + 8 ], %g1
*prev = cur;
cur = cur->avl.right;
}
else
{
while (*prev != NULL && cur == (*prev)->avl.right)
200d570: 80 a0 e0 00 cmp %g3, 0
200d574: 02 bf ff e4 be 200d504 <rtems_bdbuf_purge+0x134> <== ALWAYS TAKEN
200d578: 90 10 00 11 mov %l1, %o0
200d57c: c2 00 e0 0c ld [ %g3 + 0xc ], %g1 <== NOT EXECUTED
200d580: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
200d584: 22 80 00 08 be,a 200d5a4 <rtems_bdbuf_purge+0x1d4> <== NOT EXECUTED
200d588: a4 04 bf fc add %l2, -4, %l2 <== NOT EXECUTED
rtems_bdbuf_buffer **prev = stack;
rtems_bdbuf_buffer *cur = bdbuf_cache.tree;
*prev = NULL;
while (cur != NULL)
200d58c: 10 bf ff bd b 200d480 <rtems_bdbuf_purge+0xb0> <== NOT EXECUTED
200d590: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
*prev = cur;
cur = cur->avl.right;
}
else
{
while (*prev != NULL && cur == (*prev)->avl.right)
200d594: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
200d598: 12 bf ff b9 bne 200d47c <rtems_bdbuf_purge+0xac> <== NOT EXECUTED
200d59c: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
{
/* Up */
cur = *prev;
--prev;
200d5a0: a4 04 bf fc add %l2, -4, %l2 <== NOT EXECUTED
*prev = cur;
cur = cur->avl.right;
}
else
{
while (*prev != NULL && cur == (*prev)->avl.right)
200d5a4: c4 04 80 00 ld [ %l2 ], %g2 <== NOT EXECUTED
200d5a8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200d5ac: 32 bf ff fa bne,a 200d594 <rtems_bdbuf_purge+0x1c4> <== NOT EXECUTED
200d5b0: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 <== NOT EXECUTED
200d5b4: 10 bf ff d4 b 200d504 <rtems_bdbuf_purge+0x134> <== NOT EXECUTED
200d5b8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
0200c190 <rtems_bdbuf_purge_compare_dev>:
rtems_bdbuf_unlock_cache ();
}
static bool
rtems_bdbuf_purge_compare_dev (dev_t a, dev_t b)
{
200c190: 80 a2 00 0a cmp %o0, %o2
200c194: 02 80 00 04 be 200c1a4 <rtems_bdbuf_purge_compare_dev+0x14><== ALWAYS TAKEN
200c198: 90 10 20 00 clr %o0
return a == b;
}
200c19c: 81 c3 e0 08 retl <== NOT EXECUTED
200c1a0: 01 00 00 00 nop <== NOT EXECUTED
rtems_bdbuf_unlock_cache ();
}
static bool
rtems_bdbuf_purge_compare_dev (dev_t a, dev_t b)
{
200c1a4: 80 a2 40 0b cmp %o1, %o3
200c1a8: 12 bf ff fd bne 200c19c <rtems_bdbuf_purge_compare_dev+0xc><== NEVER TAKEN
200c1ac: 01 00 00 00 nop
return a == b;
}
200c1b0: 81 c3 e0 08 retl
200c1b4: 90 10 20 01 mov 1, %o0 ! 1 <PROM_START+0x1>
0200c1b8 <rtems_bdbuf_purge_compare_major>:
dev_t device
)
{
union __rtems_dev_t temp;
temp.device = device;
200c1b8: 90 1a 00 0a xor %o0, %o2, %o0 <== NOT EXECUTED
200c1bc: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
static bool
rtems_bdbuf_purge_compare_major (dev_t a, dev_t b)
{
return rtems_filesystem_dev_major_t (a) == rtems_filesystem_dev_major_t (b);
}
200c1c0: 81 c3 e0 08 retl <== NOT EXECUTED
200c1c4: 90 60 3f ff subx %g0, -1, %o0 <== NOT EXECUTED
0200d5bc <rtems_bdbuf_purge_major>:
void
rtems_bdbuf_purge_major (rtems_device_major_number major)
{
dev_t dev = rtems_filesystem_make_dev_t (major, 0);
rtems_bdbuf_purge (rtems_bdbuf_purge_compare_major, dev);
200d5bc: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
200d5c0: 94 10 20 00 clr %o2 <== NOT EXECUTED
200d5c4: 11 00 80 30 sethi %hi(0x200c000), %o0 <== NOT EXECUTED
200d5c8: 90 12 21 b8 or %o0, 0x1b8, %o0 ! 200c1b8 <rtems_bdbuf_purge_compare_major><== NOT EXECUTED
200d5cc: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
200d5d0: 7f ff ff 80 call 200d3d0 <rtems_bdbuf_purge> <== NOT EXECUTED
200d5d4: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200e658 <rtems_bdbuf_read>:
rtems_status_code
rtems_bdbuf_read (dev_t dev,
rtems_blkdev_bnum block,
rtems_bdbuf_buffer **bd_ptr)
{
200e658: 9d e3 bf 90 save %sp, -112, %sp
rtems_blkdev_request *req = NULL;
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block = 0;
size_t bds_per_group = 0;
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
200e65c: 90 10 00 18 mov %i0, %o0
rtems_bdbuf_read (dev_t dev,
rtems_blkdev_bnum block,
rtems_bdbuf_buffer **bd_ptr)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *dd = NULL;
200e660: c0 27 bf fc clr [ %fp + -4 ]
rtems_blkdev_request *req = NULL;
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block = 0;
200e664: c0 27 bf f8 clr [ %fp + -8 ]
size_t bds_per_group = 0;
200e668: c0 27 bf f4 clr [ %fp + -12 ]
sc = rtems_bdbuf_obtain_disk (dev, block, &dd, &media_block, &bds_per_group);
200e66c: 94 10 00 1a mov %i2, %o2
200e670: 92 10 00 19 mov %i1, %o1
200e674: 96 07 bf fc add %fp, -4, %o3
200e678: 98 07 bf f8 add %fp, -8, %o4
200e67c: 7f ff f7 86 call 200c494 <rtems_bdbuf_obtain_disk>
200e680: 9a 07 bf f4 add %fp, -12, %o5
if (sc != RTEMS_SUCCESSFUL)
200e684: b0 92 20 00 orcc %o0, 0, %i0
200e688: 12 80 00 98 bne 200e8e8 <rtems_bdbuf_read+0x290> <== NEVER TAKEN
200e68c: 03 00 80 83 sethi %hi(0x2020c00), %g1
/*
* TODO: This type of request structure is wrong and should be removed.
*/
#define bdbuf_alloc(size) __builtin_alloca (size)
req = bdbuf_alloc (sizeof (rtems_blkdev_request) +
200e690: ec 00 63 ac ld [ %g1 + 0x3ac ], %l6 ! 2020fac <rtems_bdbuf_configuration>
200e694: ac 05 a0 01 inc %l6
200e698: 83 2d a0 04 sll %l6, 4, %g1
200e69c: 82 00 60 18 add %g1, 0x18, %g1
if (rtems_bdbuf_tracer)
printf ("bdbuf:read: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n",
media_block + dd->start, block, (unsigned) dev);
rtems_bdbuf_lock_cache ();
200e6a0: 7f ff f6 d7 call 200c1fc <rtems_bdbuf_lock_cache>
200e6a4: 9c 23 80 01 sub %sp, %g1, %sp
rtems_bdbuf_create_read_request (dd, media_block, bds_per_group, req, &bd);
200e6a8: e8 07 bf fc ld [ %fp + -4 ], %l4
/*
* TODO: This type of request structure is wrong and should be removed.
*/
#define bdbuf_alloc(size) __builtin_alloca (size)
req = bdbuf_alloc (sizeof (rtems_blkdev_request) +
200e6ac: a6 03 a0 60 add %sp, 0x60, %l3
rtems_blkdev_request *req,
rtems_bdbuf_buffer **bd_ptr)
{
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block_end = dd->start + dd->size;
rtems_blkdev_bnum media_block_count = dd->block_size / dd->media_block_size;
200e6b0: ee 05 20 20 ld [ %l4 + 0x20 ], %l7
200e6b4: d2 05 20 24 ld [ %l4 + 0x24 ], %o1
200e6b8: 40 00 42 2d call 201ef6c <.udiv>
200e6bc: 90 10 00 17 mov %l7, %o0
if (media_block_end - media_block < transfer_count)
transfer_count = media_block_end - media_block;
req->req = RTEMS_BLKDEV_REQ_READ;
req->req_done = rtems_bdbuf_transfer_done;
200e6c0: 03 00 80 31 sethi %hi(0x200c400), %g1
200e6c4: 82 10 62 fc or %g1, 0x2fc, %g1 ! 200c6fc <rtems_bdbuf_transfer_done>
if (rtems_bdbuf_tracer)
printf ("bdbuf:read: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n",
media_block + dd->start, block, (unsigned) dev);
rtems_bdbuf_lock_cache ();
rtems_bdbuf_create_read_request (dd, media_block, bds_per_group, req, &bd);
200e6c8: e2 07 bf f8 ld [ %fp + -8 ], %l1
rtems_bdbuf_buffer **bd_ptr)
{
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block_end = dd->start + dd->size;
rtems_blkdev_bnum media_block_count = dd->block_size / dd->media_block_size;
dev_t dev = dd->dev;
200e6cc: e4 05 20 04 ld [ %l4 + 4 ], %l2
200e6d0: e0 05 00 00 ld [ %l4 ], %l0
if (rtems_bdbuf_tracer)
printf ("bdbuf:read: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n",
media_block + dd->start, block, (unsigned) dev);
rtems_bdbuf_lock_cache ();
rtems_bdbuf_create_read_request (dd, media_block, bds_per_group, req, &bd);
200e6d4: f8 07 bf f4 ld [ %fp + -12 ], %i4
size_t bds_per_group,
rtems_blkdev_request *req,
rtems_bdbuf_buffer **bd_ptr)
{
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block_end = dd->start + dd->size;
200e6d8: fa 05 20 18 ld [ %l4 + 0x18 ], %i5
200e6dc: f4 05 20 1c ld [ %l4 + 0x1c ], %i2
if (media_block_end - media_block < transfer_count)
transfer_count = media_block_end - media_block;
req->req = RTEMS_BLKDEV_REQ_READ;
req->req_done = rtems_bdbuf_transfer_done;
200e6e0: c2 24 e0 04 st %g1, [ %l3 + 4 ]
rtems_blkdev_request *req,
rtems_bdbuf_buffer **bd_ptr)
{
rtems_bdbuf_buffer *bd = NULL;
rtems_blkdev_bnum media_block_end = dd->start + dd->size;
rtems_blkdev_bnum media_block_count = dd->block_size / dd->media_block_size;
200e6e4: aa 10 00 08 mov %o0, %l5
uint32_t transfer_count = bdbuf_config.max_read_ahead_blocks + 1;
if (media_block_end - media_block < transfer_count)
transfer_count = media_block_end - media_block;
req->req = RTEMS_BLKDEV_REQ_READ;
200e6e8: c0 24 c0 00 clr [ %l3 ]
req->req_done = rtems_bdbuf_transfer_done;
req->done_arg = req;
req->io_task = rtems_task_self ();
200e6ec: 40 00 0e d1 call 2012230 <rtems_task_self>
200e6f0: e6 24 e0 08 st %l3, [ %l3 + 8 ]
req->status = RTEMS_RESOURCE_IN_USE;
200e6f4: 82 10 20 0c mov 0xc, %g1
transfer_count = media_block_end - media_block;
req->req = RTEMS_BLKDEV_REQ_READ;
req->req_done = rtems_bdbuf_transfer_done;
req->done_arg = req;
req->io_task = rtems_task_self ();
200e6f8: d0 24 e0 14 st %o0, [ %l3 + 0x14 ]
req->status = RTEMS_RESOURCE_IN_USE;
200e6fc: c2 24 e0 0c st %g1, [ %l3 + 0xc ]
req->bufnum = 0;
200e700: c0 24 e0 10 clr [ %l3 + 0x10 ]
bd = rtems_bdbuf_get_buffer_for_access (dev, media_block, bds_per_group);
200e704: 90 10 00 10 mov %l0, %o0
200e708: 92 10 00 12 mov %l2, %o1
200e70c: 94 10 00 11 mov %l1, %o2
200e710: 7f ff ff 08 call 200e330 <rtems_bdbuf_get_buffer_for_access>
200e714: 96 10 00 1c mov %i4, %o3
*bd_ptr = bd;
req->bufs [0].user = bd;
req->bufs [0].block = media_block;
req->bufs [0].length = block_size;
req->bufs [0].buffer = bd->buffer;
200e718: c4 02 20 24 ld [ %o0 + 0x24 ], %g2
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("read", bd);
switch (bd->state)
200e71c: c2 02 20 28 ld [ %o0 + 0x28 ], %g1
*bd_ptr = bd;
req->bufs [0].user = bd;
req->bufs [0].block = media_block;
req->bufs [0].length = block_size;
req->bufs [0].buffer = bd->buffer;
200e720: c4 24 e0 20 st %g2, [ %l3 + 0x20 ]
bd = rtems_bdbuf_get_buffer_for_access (dev, media_block, bds_per_group);
*bd_ptr = bd;
req->bufs [0].user = bd;
200e724: d0 24 e0 24 st %o0, [ %l3 + 0x24 ]
req->bufs [0].block = media_block;
200e728: e2 24 e0 18 st %l1, [ %l3 + 0x18 ]
req->bufs [0].length = block_size;
200e72c: ee 24 e0 1c st %l7, [ %l3 + 0x1c ]
req->bufs [0].buffer = bd->buffer;
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("read", bd);
switch (bd->state)
200e730: 80 a0 60 02 cmp %g1, 2
200e734: 02 80 00 60 be 200e8b4 <rtems_bdbuf_read+0x25c>
200e738: a8 10 00 08 mov %o0, %l4
200e73c: 80 a0 60 07 cmp %g1, 7
200e740: 02 80 00 5d be 200e8b4 <rtems_bdbuf_read+0x25c>
200e744: 80 a0 60 01 cmp %g1, 1
200e748: 22 80 00 08 be,a 200e768 <rtems_bdbuf_read+0x110> <== ALWAYS TAKEN
200e74c: ba 06 80 1d add %i2, %i5, %i5
return;
case RTEMS_BDBUF_STATE_EMPTY:
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_1);
200e750: d0 02 20 28 ld [ %o0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e754: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200e758: 82 10 60 1d or %g1, 0x1d, %g1 ! 4200001d <RAM_END+0x3fc0001d><== NOT EXECUTED
200e75c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200e760: 7f ff e6 e3 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e764: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
req->bufs [0].buffer = bd->buffer;
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("read", bd);
switch (bd->state)
200e768: b2 27 40 11 sub %i5, %l1, %i1
200e76c: 80 a6 40 16 cmp %i1, %l6
200e770: 38 80 00 02 bgu,a 200e778 <rtems_bdbuf_read+0x120>
200e774: b2 10 00 16 mov %l6, %i1
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e778: 82 10 20 09 mov 9, %g1
200e77c: c2 25 20 28 st %g1, [ %l4 + 0x28 ]
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_1);
break;
}
while (transfer_index < transfer_count)
200e780: 80 a6 60 01 cmp %i1, 1
200e784: 08 80 00 2c bleu 200e834 <rtems_bdbuf_read+0x1dc>
200e788: ba 10 20 01 mov 1, %i5
200e78c: 2d 00 80 8b sethi %hi(0x2022c00), %l6
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e790: b4 10 00 13 mov %l3, %i2
200e794: ac 15 a3 78 or %l6, 0x378, %l6
200e798: ba 10 20 01 mov 1, %i5
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e79c: b0 10 20 09 mov 9, %i0
static rtems_bdbuf_buffer *
rtems_bdbuf_avl_search (rtems_bdbuf_buffer** root,
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
200e7a0: c2 05 a0 40 ld [ %l6 + 0x40 ], %g1
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e7a4: 80 a0 60 00 cmp %g1, 0
200e7a8: 02 80 00 0d be 200e7dc <rtems_bdbuf_read+0x184> <== NEVER TAKEN
200e7ac: a2 04 40 15 add %l1, %l5, %l1
200e7b0: c4 18 60 18 ldd [ %g1 + 0x18 ], %g2
200e7b4: 80 a4 00 02 cmp %l0, %g2
200e7b8: 02 80 00 35 be 200e88c <rtems_bdbuf_read+0x234> <== ALWAYS TAKEN
200e7bc: 80 a4 80 03 cmp %l2, %g3
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e7c0: 80 a4 00 02 cmp %l0, %g2 <== NOT EXECUTED
200e7c4: 08 80 00 2c bleu 200e874 <rtems_bdbuf_read+0x21c> <== NOT EXECUTED
200e7c8: 01 00 00 00 nop <== NOT EXECUTED
{
p = p->avl.right;
200e7cc: c2 00 60 0c ld [ %g1 + 0xc ], %g1 <== NOT EXECUTED
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e7d0: 80 a0 60 00 cmp %g1, 0
200e7d4: 32 bf ff f8 bne,a 200e7b4 <rtems_bdbuf_read+0x15c> <== NEVER TAKEN
200e7d8: c4 18 60 18 ldd [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dev, block);
if (bd == NULL)
{
bd = rtems_bdbuf_get_buffer_from_lru_list (dev, block, bds_per_group);
200e7dc: 90 10 00 10 mov %l0, %o0
200e7e0: 92 10 00 12 mov %l2, %o1
200e7e4: 94 10 00 11 mov %l1, %o2
200e7e8: 7f ff fd c4 call 200def8 <rtems_bdbuf_get_buffer_from_lru_list>
200e7ec: 96 10 00 1c mov %i4, %o3
if (bd != NULL)
200e7f0: 80 a2 20 00 cmp %o0, 0
200e7f4: 22 80 00 11 be,a 200e838 <rtems_bdbuf_read+0x1e0> <== ALWAYS TAKEN
200e7f8: fa 24 e0 10 st %i5, [ %l3 + 0x10 ]
}
static void
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)
{
++bd->group->users;
200e7fc: c2 02 20 30 ld [ %o0 + 0x30 ], %g1 <== NOT EXECUTED
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);
req->bufs [transfer_index].user = bd;
req->bufs [transfer_index].block = media_block;
req->bufs [transfer_index].length = block_size;
req->bufs [transfer_index].buffer = bd->buffer;
200e800: c6 02 20 24 ld [ %o0 + 0x24 ], %g3 <== NOT EXECUTED
}
static void
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)
{
++bd->group->users;
200e804: c4 00 60 0c ld [ %g1 + 0xc ], %g2 <== NOT EXECUTED
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);
req->bufs [transfer_index].user = bd;
req->bufs [transfer_index].block = media_block;
req->bufs [transfer_index].length = block_size;
req->bufs [transfer_index].buffer = bd->buffer;
200e808: c6 26 a0 30 st %g3, [ %i2 + 0x30 ] <== NOT EXECUTED
}
static void
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)
{
++bd->group->users;
200e80c: 84 00 a0 01 inc %g2 <== NOT EXECUTED
200e810: c4 20 60 0c st %g2, [ %g1 + 0xc ] <== NOT EXECUTED
if (bd == NULL)
break;
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);
req->bufs [transfer_index].user = bd;
200e814: d0 26 a0 34 st %o0, [ %i2 + 0x34 ] <== NOT EXECUTED
req->bufs [transfer_index].block = media_block;
200e818: e2 26 a0 28 st %l1, [ %i2 + 0x28 ] <== NOT EXECUTED
req->bufs [transfer_index].length = block_size;
200e81c: ee 26 a0 2c st %l7, [ %i2 + 0x2c ] <== NOT EXECUTED
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e820: f0 22 20 28 st %i0, [ %o0 + 0x28 ] <== NOT EXECUTED
req->bufs [transfer_index].buffer = bd->buffer;
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("read-ahead", bd);
++transfer_index;
200e824: ba 07 60 01 inc %i5 <== NOT EXECUTED
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_1);
break;
}
while (transfer_index < transfer_count)
200e828: 80 a7 40 19 cmp %i5, %i1 <== NOT EXECUTED
200e82c: 0a bf ff dd bcs 200e7a0 <rtems_bdbuf_read+0x148> <== NOT EXECUTED
200e830: b4 06 a0 10 add %i2, 0x10, %i2 <== NOT EXECUTED
rtems_bdbuf_show_users ("read-ahead", bd);
++transfer_index;
}
req->bufnum = transfer_index;
200e834: fa 24 e0 10 st %i5, [ %l3 + 0x10 ]
media_block + dd->start, block, (unsigned) dev);
rtems_bdbuf_lock_cache ();
rtems_bdbuf_create_read_request (dd, media_block, bds_per_group, req, &bd);
if (req->bufnum > 0)
200e838: 80 a7 60 00 cmp %i5, 0
200e83c: 12 80 00 20 bne 200e8bc <rtems_bdbuf_read+0x264>
200e840: d0 07 bf fc ld [ %fp + -4 ], %o0
}
}
if (sc == RTEMS_SUCCESSFUL)
{
switch (bd->state)
200e844: c2 05 20 28 ld [ %l4 + 0x28 ], %g1
200e848: 80 a0 60 02 cmp %g1, 2
200e84c: 02 80 00 2d be 200e900 <rtems_bdbuf_read+0x2a8>
200e850: 80 a0 60 07 cmp %g1, 7
200e854: 02 80 00 27 be 200e8f0 <rtems_bdbuf_read+0x298> <== ALWAYS TAKEN
200e858: 82 10 20 04 mov 4, %g1
break;
case RTEMS_BDBUF_STATE_MODIFIED:
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_4);
200e85c: d0 05 20 28 ld [ %l4 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200e860: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200e864: 82 10 60 02 or %g1, 2, %g1 ! 42000002 <RAM_END+0x3fc00002><== NOT EXECUTED
200e868: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200e86c: 7f ff e6 a0 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200e870: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
{
rtems_bdbuf_buffer* p = *root;
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e874: 12 80 00 04 bne 200e884 <rtems_bdbuf_read+0x22c> <== NOT EXECUTED
200e878: 80 a4 80 03 cmp %l2, %g3 <== NOT EXECUTED
200e87c: 38 bf ff d5 bgu,a 200e7d0 <rtems_bdbuf_read+0x178> <== NOT EXECUTED
200e880: c2 00 60 0c ld [ %g1 + 0xc ], %g1 <== NOT EXECUTED
{
p = p->avl.right;
}
else
{
p = p->avl.left;
200e884: 10 bf ff d3 b 200e7d0 <rtems_bdbuf_read+0x178> <== NOT EXECUTED
200e888: c2 00 60 08 ld [ %g1 + 8 ], %g1 <== NOT EXECUTED
dev_t dev,
rtems_blkdev_bnum block)
{
rtems_bdbuf_buffer* p = *root;
while ((p != NULL) && ((p->dev != dev) || (p->block != block)))
200e88c: 12 bf ff ce bne 200e7c4 <rtems_bdbuf_read+0x16c> <== NEVER TAKEN
200e890: 80 a4 00 02 cmp %l0, %g2
200e894: c4 00 60 20 ld [ %g1 + 0x20 ], %g2
200e898: 80 a4 40 02 cmp %l1, %g2
200e89c: 22 bf ff e7 be,a 200e838 <rtems_bdbuf_read+0x1e0> <== NEVER TAKEN
200e8a0: fa 24 e0 10 st %i5, [ %l3 + 0x10 ] <== NOT EXECUTED
{
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200e8a4: 38 bf ff cb bgu,a 200e7d0 <rtems_bdbuf_read+0x178> <== ALWAYS TAKEN
200e8a8: c2 00 60 0c ld [ %g1 + 0xc ], %g1
{
p = p->avl.right;
}
else
{
p = p->avl.left;
200e8ac: 10 bf ff c9 b 200e7d0 <rtems_bdbuf_read+0x178> <== NOT EXECUTED
200e8b0: c2 00 60 08 ld [ %g1 + 8 ], %g1 <== NOT EXECUTED
req->bufs [0].buffer = bd->buffer;
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_users ("read", bd);
switch (bd->state)
200e8b4: 10 bf ff e1 b 200e838 <rtems_bdbuf_read+0x1e0>
200e8b8: fa 04 e0 10 ld [ %l3 + 0x10 ], %i5
rtems_bdbuf_lock_cache ();
rtems_bdbuf_create_read_request (dd, media_block, bds_per_group, req, &bd);
if (req->bufnum > 0)
{
sc = rtems_bdbuf_execute_transfer_request (dd, req, true);
200e8bc: 92 10 00 13 mov %l3, %o1
200e8c0: 7f ff fb 4f call 200d5fc <rtems_bdbuf_execute_transfer_request>
200e8c4: 94 10 20 01 mov 1, %o2
if (sc == RTEMS_SUCCESSFUL)
200e8c8: b0 92 20 00 orcc %o0, 0, %i0
200e8cc: 02 80 00 12 be 200e914 <rtems_bdbuf_read+0x2bc>
200e8d0: 01 00 00 00 nop
}
*bd_ptr = bd;
}
else
*bd_ptr = NULL;
200e8d4: c0 26 c0 00 clr [ %i3 ]
rtems_bdbuf_unlock_cache ();
200e8d8: 7f ff f6 d7 call 200c434 <rtems_bdbuf_unlock_cache>
200e8dc: 01 00 00 00 nop
rtems_bdbuf_release_disk (dd);
200e8e0: 7f ff f7 2d call 200c594 <rtems_bdbuf_release_disk>
200e8e4: d0 07 bf fc ld [ %fp + -4 ], %o0
return sc;
}
200e8e8: 81 c7 e0 08 ret
200e8ec: 81 e8 00 00 restore
{
rtems_bdbuf_show_users ("read", bd);
rtems_bdbuf_show_usage ();
}
*bd_ptr = bd;
200e8f0: e8 26 c0 00 st %l4, [ %i3 ]
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e8f4: c2 25 20 28 st %g1, [ %l4 + 0x28 ]
{
rtems_bdbuf_show_users ("read", bd);
rtems_bdbuf_show_usage ();
}
*bd_ptr = bd;
200e8f8: 10 bf ff f8 b 200e8d8 <rtems_bdbuf_read+0x280>
200e8fc: b0 10 20 00 clr %i0
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e900: 82 10 20 03 mov 3, %g1
{
rtems_bdbuf_show_users ("read", bd);
rtems_bdbuf_show_usage ();
}
*bd_ptr = bd;
200e904: e8 26 c0 00 st %l4, [ %i3 ]
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200e908: c2 25 20 28 st %g1, [ %l4 + 0x28 ]
{
rtems_bdbuf_show_users ("read", bd);
rtems_bdbuf_show_usage ();
}
*bd_ptr = bd;
200e90c: 10 bf ff f3 b 200e8d8 <rtems_bdbuf_read+0x280>
200e910: b0 10 20 00 clr %i0
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200e914: 7f ff e7 f3 call 20088e0 <_Chain_Extract>
200e918: 90 10 00 14 mov %l4, %o0
}
static void
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)
{
++bd->group->users;
200e91c: c2 05 20 30 ld [ %l4 + 0x30 ], %g1
200e920: c4 00 60 0c ld [ %g1 + 0xc ], %g2
200e924: 84 00 a0 01 inc %g2
200e928: 10 bf ff c7 b 200e844 <rtems_bdbuf_read+0x1ec>
200e92c: c4 20 60 0c st %g2, [ %g1 + 0xc ]
0200d2ec <rtems_bdbuf_release>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_bdbuf_release (rtems_bdbuf_buffer *bd)
{
200d2ec: 9d e3 bf a0 save %sp, -96, %sp
}
static rtems_status_code
rtems_bdbuf_check_bd_and_lock_cache (rtems_bdbuf_buffer *bd, const char *kind)
{
if (!bdbuf_cache.initialised)
200d2f0: 21 00 80 8b sethi %hi(0x2022c00), %l0
200d2f4: a0 14 23 78 or %l0, 0x378, %l0 ! 2022f78 <bdbuf_cache>
200d2f8: c2 0c 20 88 ldub [ %l0 + 0x88 ], %g1
200d2fc: 80 a0 60 00 cmp %g1, 0
200d300: 02 80 00 15 be 200d354 <rtems_bdbuf_release+0x68> <== NEVER TAKEN
200d304: 82 10 20 16 mov 0x16, %g1
return RTEMS_NOT_CONFIGURED;
if (bd == NULL)
200d308: 80 a6 20 00 cmp %i0, 0
200d30c: 02 80 00 12 be 200d354 <rtems_bdbuf_release+0x68> <== NEVER TAKEN
200d310: 82 10 20 09 mov 9, %g1
if (rtems_bdbuf_tracer)
{
printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);
rtems_bdbuf_show_users (kind, bd);
}
rtems_bdbuf_lock_cache();
200d314: 7f ff fb ba call 200c1fc <rtems_bdbuf_lock_cache>
200d318: 01 00 00 00 nop
sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "release");
if (sc != RTEMS_SUCCESSFUL)
return sc;
switch (bd->state)
200d31c: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200d320: 80 a0 60 04 cmp %g1, 4
200d324: 02 80 00 16 be 200d37c <rtems_bdbuf_release+0x90>
200d328: 01 00 00 00 nop
200d32c: 08 80 00 0c bleu 200d35c <rtems_bdbuf_release+0x70>
200d330: 80 a0 60 03 cmp %g1, 3
200d334: 80 a0 60 06 cmp %g1, 6
200d338: 18 80 00 0b bgu 200d364 <rtems_bdbuf_release+0x78> <== NEVER TAKEN
200d33c: 01 00 00 00 nop
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
rtems_bdbuf_add_to_lru_list_after_access (bd);
break;
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
200d340: 7f ff ff b7 call 200d21c <rtems_bdbuf_discard_buffer_after_access>
200d344: 90 10 00 18 mov %i0, %o0
}
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_usage ();
rtems_bdbuf_unlock_cache ();
200d348: 7f ff fc 3b call 200c434 <rtems_bdbuf_unlock_cache>
200d34c: 01 00 00 00 nop
200d350: 82 10 20 00 clr %g1 ! 0 <PROM_START>
return RTEMS_SUCCESSFUL;
}
200d354: 81 c7 e0 08 ret
200d358: 91 e8 00 01 restore %g0, %g1, %o0
sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "release");
if (sc != RTEMS_SUCCESSFUL)
return sc;
switch (bd->state)
200d35c: 22 80 00 0b be,a 200d388 <rtems_bdbuf_release+0x9c> <== ALWAYS TAKEN
200d360: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
break;
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_add_to_modified_list_after_access (bd);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_0);
200d364: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200d368: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200d36c: 82 10 60 1c or %g1, 0x1c, %g1 ! 4200001c <RAM_END+0x3fc0001c><== NOT EXECUTED
200d370: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200d374: 7f ff eb de call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200d378: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
break;
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_add_to_modified_list_after_access (bd);
200d37c: 7f ff fc 9e call 200c5f4 <rtems_bdbuf_add_to_modified_list_after_access>
200d380: 90 10 00 18 mov %i0, %o0
break;
200d384: 30 bf ff f1 b,a 200d348 <rtems_bdbuf_release+0x5c>
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d388: 86 10 20 02 mov 2, %g3
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d38c: c4 00 60 0c ld [ %g1 + 0xc ], %g2
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200d390: c6 26 20 28 st %g3, [ %i0 + 0x28 ]
}
static void
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)
{
--bd->group->users;
200d394: 84 00 bf ff add %g2, -1, %g2
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200d398: 90 04 20 44 add %l0, 0x44, %o0
200d39c: c4 20 60 0c st %g2, [ %g1 + 0xc ]
200d3a0: 7f ff ed 44 call 20088b0 <_Chain_Append>
200d3a4: 92 10 00 18 mov %i0, %o1
rtems_bdbuf_add_to_lru_list_after_access (rtems_bdbuf_buffer *bd)
{
rtems_bdbuf_group_release (bd);
rtems_bdbuf_make_cached_and_add_to_lru_list (bd);
if (bd->waiters)
200d3a8: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
200d3ac: 80 a0 60 00 cmp %g1, 0
200d3b0: 02 80 00 05 be 200d3c4 <rtems_bdbuf_release+0xd8>
200d3b4: 01 00 00 00 nop
rtems_bdbuf_wake (&bdbuf_cache.access_waiters);
200d3b8: 7f ff fb 99 call 200c21c <rtems_bdbuf_wake>
200d3bc: 90 04 20 68 add %l0, 0x68, %o0
200d3c0: 30 bf ff e2 b,a 200d348 <rtems_bdbuf_release+0x5c>
else
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200d3c4: 7f ff fb 96 call 200c21c <rtems_bdbuf_wake>
200d3c8: 90 04 20 78 add %l0, 0x78, %o0
200d3cc: 30 bf ff df b,a 200d348 <rtems_bdbuf_release+0x5c>
0200c594 <rtems_bdbuf_release_disk>:
return RTEMS_SUCCESSFUL;
}
static void
rtems_bdbuf_release_disk (rtems_disk_device *dd)
{
200c594: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
sc = rtems_disk_release (dd);
200c598: 7f ff da 35 call 2002e6c <rtems_disk_release>
200c59c: 90 10 00 18 mov %i0, %o0
if (sc != RTEMS_SUCCESSFUL)
200c5a0: 80 a2 20 00 cmp %o0, 0
200c5a4: 12 80 00 04 bne 200c5b4 <rtems_bdbuf_release_disk+0x20> <== NEVER TAKEN
200c5a8: 11 10 80 00 sethi %hi(0x42000000), %o0
200c5ac: 81 c7 e0 08 ret
200c5b0: 81 e8 00 00 restore
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_DISK_REL);
200c5b4: 7f ff ef 4e call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c5b8: 90 12 20 1f or %o0, 0x1f, %o0 <== NOT EXECUTED
0200d260 <rtems_bdbuf_release_modified>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_bdbuf_release_modified (rtems_bdbuf_buffer *bd)
{
200d260: 9d e3 bf a0 save %sp, -96, %sp
}
static rtems_status_code
rtems_bdbuf_check_bd_and_lock_cache (rtems_bdbuf_buffer *bd, const char *kind)
{
if (!bdbuf_cache.initialised)
200d264: 03 00 80 8c sethi %hi(0x2023000), %g1
200d268: c2 08 60 00 ldub [ %g1 ], %g1
200d26c: 80 a0 60 00 cmp %g1, 0
200d270: 02 80 00 1a be 200d2d8 <rtems_bdbuf_release_modified+0x78><== NEVER TAKEN
200d274: 82 10 20 16 mov 0x16, %g1
return RTEMS_NOT_CONFIGURED;
if (bd == NULL)
200d278: 80 a6 20 00 cmp %i0, 0
200d27c: 02 80 00 17 be 200d2d8 <rtems_bdbuf_release_modified+0x78><== NEVER TAKEN
200d280: 82 10 20 09 mov 9, %g1
if (rtems_bdbuf_tracer)
{
printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);
rtems_bdbuf_show_users (kind, bd);
}
rtems_bdbuf_lock_cache();
200d284: 7f ff fb de call 200c1fc <rtems_bdbuf_lock_cache>
200d288: 01 00 00 00 nop
sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "release modified");
if (sc != RTEMS_SUCCESSFUL)
return sc;
switch (bd->state)
200d28c: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200d290: 80 a0 60 03 cmp %g1, 3
200d294: 0a 80 00 06 bcs 200d2ac <rtems_bdbuf_release_modified+0x4c><== NEVER TAKEN
200d298: 80 a0 60 05 cmp %g1, 5
200d29c: 08 80 00 11 bleu 200d2e0 <rtems_bdbuf_release_modified+0x80>
200d2a0: 80 a0 60 06 cmp %g1, 6
200d2a4: 02 80 00 08 be 200d2c4 <rtems_bdbuf_release_modified+0x64><== ALWAYS TAKEN
200d2a8: 01 00 00 00 nop
break;
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_6);
200d2ac: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200d2b0: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200d2b4: 82 10 60 04 or %g1, 4, %g1 ! 42000004 <RAM_END+0x3fc00004><== NOT EXECUTED
200d2b8: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200d2bc: 7f ff ec 0c call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200d2c0: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_add_to_modified_list_after_access (bd);
break;
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
200d2c4: 7f ff ff d6 call 200d21c <rtems_bdbuf_discard_buffer_after_access>
200d2c8: 90 10 00 18 mov %i0, %o0
}
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_usage ();
rtems_bdbuf_unlock_cache ();
200d2cc: 7f ff fc 5a call 200c434 <rtems_bdbuf_unlock_cache>
200d2d0: 01 00 00 00 nop
200d2d4: 82 10 20 00 clr %g1 ! 0 <PROM_START>
return RTEMS_SUCCESSFUL;
}
200d2d8: 81 c7 e0 08 ret
200d2dc: 91 e8 00 01 restore %g0, %g1, %o0
switch (bd->state)
{
case RTEMS_BDBUF_STATE_ACCESS_CACHED:
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_add_to_modified_list_after_access (bd);
200d2e0: 7f ff fc c5 call 200c5f4 <rtems_bdbuf_add_to_modified_list_after_access>
200d2e4: 90 10 00 18 mov %i0, %o0
break;
200d2e8: 30 bf ff f9 b,a 200d2cc <rtems_bdbuf_release_modified+0x6c>
0200cd9c <rtems_bdbuf_remove_from_tree>:
return bdbuf_cache.buffer_waiters.count;
}
static void
rtems_bdbuf_remove_from_tree (rtems_bdbuf_buffer *bd)
{
200cd9c: 9d e3 bf 20 save %sp, -224, %sp
const rtems_bdbuf_buffer* node)
{
dev_t dev = node->dev;
rtems_blkdev_bnum block = node->block;
rtems_bdbuf_buffer* p = *root;
200cda0: 23 00 80 8b sethi %hi(0x2022c00), %l1
200cda4: a2 14 63 78 or %l1, 0x378, %l1 ! 2022f78 <bdbuf_cache>
200cda8: e0 04 60 40 ld [ %l1 + 0x40 ], %l0
rtems_bdbuf_buffer* buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];
rtems_bdbuf_buffer** buf_prev = buf_stack;
bool modified = false;
memset (buf_stack, 0, sizeof(buf_stack));
200cdac: a6 07 bf 80 add %fp, -128, %l3
*/
static int
rtems_bdbuf_avl_remove(rtems_bdbuf_buffer** root,
const rtems_bdbuf_buffer* node)
{
dev_t dev = node->dev;
200cdb0: e4 06 20 18 ld [ %i0 + 0x18 ], %l2
200cdb4: e8 06 20 1c ld [ %i0 + 0x1c ], %l4
rtems_blkdev_bnum block = node->block;
200cdb8: ea 06 20 20 ld [ %i0 + 0x20 ], %l5
rtems_bdbuf_buffer* buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];
rtems_bdbuf_buffer** buf_prev = buf_stack;
bool modified = false;
memset (buf_stack, 0, sizeof(buf_stack));
200cdbc: 90 10 00 13 mov %l3, %o0
200cdc0: 92 10 20 00 clr %o1
200cdc4: 40 00 26 03 call 20165d0 <memset>
200cdc8: 94 10 20 80 mov 0x80, %o2
while (p != NULL)
200cdcc: 80 a4 20 00 cmp %l0, 0
200cdd0: 02 80 00 24 be 200ce60 <rtems_bdbuf_remove_from_tree+0xc4><== NEVER TAKEN
200cdd4: 84 10 00 13 mov %l3, %g2
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200cdd8: c6 04 20 18 ld [ %l0 + 0x18 ], %g3
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
{
*buf_prev++ = p;
200cddc: e0 20 80 00 st %l0, [ %g2 ]
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
{
p->avl.cache = 1;
200cde0: 9a 10 20 01 mov 1, %o5
p = p->avl.right;
}
else if ((p->dev != dev) || (p->block != block))
{
p->avl.cache = -1;
200cde4: 98 10 3f ff mov -1, %o4
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200cde8: 80 a4 80 03 cmp %l2, %g3
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
{
*buf_prev++ = p;
200cdec: 82 00 a0 04 add %g2, 4, %g1
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200cdf0: 18 80 00 17 bgu 200ce4c <rtems_bdbuf_remove_from_tree+0xb0><== NEVER TAKEN
200cdf4: c8 04 20 1c ld [ %l0 + 0x1c ], %g4
200cdf8: 80 a4 80 03 cmp %l2, %g3
200cdfc: 32 80 00 09 bne,a 200ce20 <rtems_bdbuf_remove_from_tree+0x84><== NEVER TAKEN
200ce00: d8 2c 20 10 stb %o4, [ %l0 + 0x10 ] <== NOT EXECUTED
200ce04: 80 a5 00 04 cmp %l4, %g4
200ce08: 38 80 00 12 bgu,a 200ce50 <rtems_bdbuf_remove_from_tree+0xb4><== NEVER TAKEN
200ce0c: da 2c 20 10 stb %o5, [ %l0 + 0x10 ] <== NOT EXECUTED
200ce10: 80 a5 00 04 cmp %l4, %g4
200ce14: 22 80 00 19 be,a 200ce78 <rtems_bdbuf_remove_from_tree+0xdc><== ALWAYS TAKEN
200ce18: c6 04 20 20 ld [ %l0 + 0x20 ], %g3
p->avl.cache = 1;
p = p->avl.right;
}
else if ((p->dev != dev) || (p->block != block))
{
p->avl.cache = -1;
200ce1c: d8 2c 20 10 stb %o4, [ %l0 + 0x10 ] <== NOT EXECUTED
p = p->avl.left;
200ce20: e0 04 20 08 ld [ %l0 + 8 ], %l0
bool modified = false;
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
200ce24: 80 a4 20 00 cmp %l0, 0
200ce28: 02 80 00 0e be 200ce60 <rtems_bdbuf_remove_from_tree+0xc4><== NEVER TAKEN
200ce2c: 01 00 00 00 nop
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200ce30: c6 04 20 18 ld [ %l0 + 0x18 ], %g3
bool modified = false;
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
200ce34: 84 10 00 01 mov %g1, %g2
{
*buf_prev++ = p;
200ce38: e0 20 80 00 st %l0, [ %g2 ]
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200ce3c: 80 a4 80 03 cmp %l2, %g3
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
{
*buf_prev++ = p;
200ce40: 82 00 a0 04 add %g2, 4, %g1
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200ce44: 08 bf ff ee bleu 200cdfc <rtems_bdbuf_remove_from_tree+0x60><== ALWAYS TAKEN
200ce48: c8 04 20 1c ld [ %l0 + 0x1c ], %g4
{
p->avl.cache = 1;
200ce4c: da 2c 20 10 stb %o5, [ %l0 + 0x10 ] <== NOT EXECUTED
p = p->avl.right;
200ce50: e0 04 20 0c ld [ %l0 + 0xc ], %l0
bool modified = false;
memset (buf_stack, 0, sizeof(buf_stack));
while (p != NULL)
200ce54: 80 a4 20 00 cmp %l0, 0
200ce58: 32 bf ff f7 bne,a 200ce34 <rtems_bdbuf_remove_from_tree+0x98><== ALWAYS TAKEN
200ce5c: c6 04 20 18 ld [ %l0 + 0x18 ], %g3
static void
rtems_bdbuf_remove_from_tree (rtems_bdbuf_buffer *bd)
{
if (rtems_bdbuf_avl_remove (&bdbuf_cache.tree, bd) != 0)
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_TREE_RM);
200ce60: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200ce64: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200ce68: 82 10 60 09 or %g1, 9, %g1 ! 42000009 <RAM_END+0x3fc00009><== NOT EXECUTED
200ce6c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200ce70: 7f ff ed 1f call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200ce74: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
while (p != NULL)
{
*buf_prev++ = p;
if ((p->dev < dev) || ((p->dev == dev) && (p->block < block)))
200ce78: 80 a5 40 03 cmp %l5, %g3
200ce7c: 38 bf ff f5 bgu,a 200ce50 <rtems_bdbuf_remove_from_tree+0xb4>
200ce80: da 2c 20 10 stb %o5, [ %l0 + 0x10 ]
{
p->avl.cache = 1;
p = p->avl.right;
}
else if ((p->dev != dev) || (p->block != block))
200ce84: 80 a5 40 03 cmp %l5, %g3
200ce88: 32 bf ff e6 bne,a 200ce20 <rtems_bdbuf_remove_from_tree+0x84>
200ce8c: d8 2c 20 10 stb %o4, [ %l0 + 0x10 ]
}
q = p;
buf_prev--;
if (buf_prev > buf_stack)
200ce90: 80 a0 80 13 cmp %g2, %l3
200ce94: 08 80 00 03 bleu 200cea0 <rtems_bdbuf_remove_from_tree+0x104>
200ce98: 96 10 20 00 clr %o3
{
p = *(buf_prev - 1);
200ce9c: d6 00 bf fc ld [ %g2 + -4 ], %o3
{
p = NULL;
}
/* at this moment q - is a node to delete, p is q's parent */
if (q->avl.right == NULL)
200cea0: c6 04 20 0c ld [ %l0 + 0xc ], %g3
200cea4: 80 a0 e0 00 cmp %g3, 0
200cea8: 22 80 00 a7 be,a 200d144 <rtems_bdbuf_remove_from_tree+0x3a8>
200ceac: c6 04 20 08 ld [ %l0 + 8 ], %g3
{
rtems_bdbuf_buffer **t;
r = q->avl.right;
if (r->avl.left == NULL)
200ceb0: c8 00 e0 08 ld [ %g3 + 8 ], %g4
200ceb4: 80 a1 20 00 cmp %g4, 0
200ceb8: 02 80 00 a8 be 200d158 <rtems_bdbuf_remove_from_tree+0x3bc><== ALWAYS TAKEN
200cebc: 98 10 3f ff mov -1, %o4
t = buf_prev++;
s = r;
while (s->avl.left != NULL)
{
*buf_prev++ = r = s;
200cec0: c6 20 40 00 st %g3, [ %g1 ] <== NOT EXECUTED
if (r->avl.left == NULL)
{
r->avl.left = q->avl.left;
r->avl.bal = q->avl.bal;
r->avl.cache = 1;
*buf_prev++ = q = r;
200cec4: 88 10 00 03 mov %g3, %g4 <== NOT EXECUTED
s = r;
while (s->avl.left != NULL)
{
*buf_prev++ = r = s;
s = r->avl.left;
200cec8: c6 00 e0 08 ld [ %g3 + 8 ], %g3 <== NOT EXECUTED
r->avl.cache = -1;
200cecc: d8 29 20 10 stb %o4, [ %g4 + 0x10 ] <== NOT EXECUTED
else
{
t = buf_prev++;
s = r;
while (s->avl.left != NULL)
200ced0: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED
200ced4: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
200ced8: 12 bf ff fa bne 200cec0 <rtems_bdbuf_remove_from_tree+0x124><== NOT EXECUTED
200cedc: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
*buf_prev++ = r = s;
s = r->avl.left;
r->avl.cache = -1;
}
s->avl.left = q->avl.left;
200cee0: d2 04 20 08 ld [ %l0 + 8 ], %o1 <== NOT EXECUTED
r->avl.left = s->avl.right;
200cee4: d4 00 e0 0c ld [ %g3 + 0xc ], %o2 <== NOT EXECUTED
s->avl.right = q->avl.right;
s->avl.bal = q->avl.bal;
200cee8: da 0c 20 11 ldub [ %l0 + 0x11 ], %o5 <== NOT EXECUTED
r->avl.cache = -1;
}
s->avl.left = q->avl.left;
r->avl.left = s->avl.right;
s->avl.right = q->avl.right;
200ceec: d8 04 20 0c ld [ %l0 + 0xc ], %o4 <== NOT EXECUTED
*buf_prev++ = r = s;
s = r->avl.left;
r->avl.cache = -1;
}
s->avl.left = q->avl.left;
200cef0: d2 20 e0 08 st %o1, [ %g3 + 8 ] <== NOT EXECUTED
r->avl.left = s->avl.right;
200cef4: d4 21 20 08 st %o2, [ %g4 + 8 ] <== NOT EXECUTED
s->avl.right = q->avl.right;
200cef8: d8 20 e0 0c st %o4, [ %g3 + 0xc ] <== NOT EXECUTED
s->avl.bal = q->avl.bal;
200cefc: da 28 e0 11 stb %o5, [ %g3 + 0x11 ] <== NOT EXECUTED
s->avl.cache = 1;
200cf00: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
200cf04: c8 28 e0 10 stb %g4, [ %g3 + 0x10 ] <== NOT EXECUTED
*t = q = s;
200cf08: c6 20 80 00 st %g3, [ %g2 ] <== NOT EXECUTED
}
}
if (p != NULL)
200cf0c: 80 a2 e0 00 cmp %o3, 0
200cf10: 22 80 00 07 be,a 200cf2c <rtems_bdbuf_remove_from_tree+0x190>
200cf14: c6 24 60 40 st %g3, [ %l1 + 0x40 ]
{
if (p->avl.cache == -1)
200cf18: c4 4a e0 10 ldsb [ %o3 + 0x10 ], %g2
200cf1c: 80 a0 bf ff cmp %g2, -1
200cf20: 22 80 00 03 be,a 200cf2c <rtems_bdbuf_remove_from_tree+0x190>
200cf24: c6 22 e0 08 st %g3, [ %o3 + 8 ]
{
p->avl.left = q;
}
else
{
p->avl.right = q;
200cf28: c6 22 e0 0c st %g3, [ %o3 + 0xc ]
modified = true;
while (modified)
{
if (buf_prev > buf_stack)
200cf2c: 80 a0 40 13 cmp %g1, %l3
{
case -1:
p->avl.bal = 0;
break;
case 0:
p->avl.bal = 1;
200cf30: 94 10 20 01 mov 1, %o2
modified = true;
while (modified)
{
if (buf_prev > buf_stack)
200cf34: 18 80 00 0f bgu 200cf70 <rtems_bdbuf_remove_from_tree+0x1d4>
200cf38: 98 10 3f ff mov -1, %o4
200cf3c: 30 80 00 94 b,a 200d18c <rtems_bdbuf_remove_from_tree+0x3f0>
case +1:
p->avl.bal = 0;
break;
case 0:
p->avl.bal = -1;
200cf40: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
200cf44: 88 10 20 00 clr %g4 <== NOT EXECUTED
default:
break;
}
}
if (buf_prev > buf_stack)
200cf48: 80 a0 40 13 cmp %g1, %l3
200cf4c: 28 80 00 1c bleu,a 200cfbc <rtems_bdbuf_remove_from_tree+0x220>
200cf50: c6 24 60 40 st %g3, [ %l1 + 0x40 ]
{
q = *(buf_prev - 1);
200cf54: c4 00 7f fc ld [ %g1 + -4 ], %g2
if (q->avl.cache == -1)
200cf58: da 48 a0 10 ldsb [ %g2 + 0x10 ], %o5
200cf5c: 80 a3 7f ff cmp %o5, -1
200cf60: 02 80 00 38 be 200d040 <rtems_bdbuf_remove_from_tree+0x2a4><== ALWAYS TAKEN
200cf64: 80 89 20 ff btst 0xff, %g4
*root = q;
}
modified = true;
while (modified)
200cf68: 02 80 00 15 be 200cfbc <rtems_bdbuf_remove_from_tree+0x220><== NOT EXECUTED
200cf6c: c6 20 a0 0c st %g3, [ %g2 + 0xc ] <== NOT EXECUTED
{
if (buf_prev > buf_stack)
{
p = *--buf_prev;
200cf70: 82 00 7f fc add %g1, -4, %g1
200cf74: c4 00 40 00 ld [ %g1 ], %g2
else
{
break;
}
if (p->avl.cache == -1)
200cf78: c8 48 a0 10 ldsb [ %g2 + 0x10 ], %g4
200cf7c: 80 a1 3f ff cmp %g4, -1
200cf80: 02 80 00 29 be 200d024 <rtems_bdbuf_remove_from_tree+0x288>
200cf84: c6 48 a0 11 ldsb [ %g2 + 0x11 ], %g3
}
}
else
{
/* rebalance right branch */
switch (p->avl.bal)
200cf88: 80 a0 e0 00 cmp %g3, 0
200cf8c: 22 bf ff ed be,a 200cf40 <rtems_bdbuf_remove_from_tree+0x1a4><== NEVER TAKEN
200cf90: d8 28 a0 11 stb %o4, [ %g2 + 0x11 ] <== NOT EXECUTED
200cf94: 80 a0 e0 01 cmp %g3, 1
200cf98: 02 80 00 32 be 200d060 <rtems_bdbuf_remove_from_tree+0x2c4><== ALWAYS TAKEN
200cf9c: 80 a0 ff ff cmp %g3, -1
200cfa0: 22 80 00 09 be,a 200cfc4 <rtems_bdbuf_remove_from_tree+0x228><== NOT EXECUTED
200cfa4: c6 00 a0 08 ld [ %g2 + 8 ], %g3 <== NOT EXECUTED
if (p2->avl.bal == -1) p->avl.bal = 1; else p->avl.bal = 0;
if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
p = p2;
p2->avl.bal = 0;
200cfa8: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
default:
break;
}
}
if (buf_prev > buf_stack)
200cfac: 80 a0 40 13 cmp %g1, %l3 <== NOT EXECUTED
200cfb0: 18 bf ff e9 bgu 200cf54 <rtems_bdbuf_remove_from_tree+0x1b8><== NOT EXECUTED
200cfb4: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
q->avl.right = p;
}
}
else
{
*root = p;
200cfb8: c6 24 60 40 st %g3, [ %l1 + 0x40 ] <== NOT EXECUTED
200cfbc: 81 c7 e0 08 ret
200cfc0: 81 e8 00 00 restore
break;
case -1:
p1 = p->avl.left;
if (p1->avl.bal <= 0) /* simple LL-turn */
200cfc4: c8 48 e0 11 ldsb [ %g3 + 0x11 ], %g4 <== NOT EXECUTED
200cfc8: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
200cfcc: 24 80 00 36 ble,a 200d0a4 <rtems_bdbuf_remove_from_tree+0x308><== NOT EXECUTED
200cfd0: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
}
p = p1;
}
else /* double LR-turn */
{
p2 = p1->avl.right;
200cfd4: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
p1->avl.right = p2->avl.left;
200cfd8: da 01 20 08 ld [ %g4 + 8 ], %o5 <== NOT EXECUTED
p2->avl.left = p1;
200cfdc: c6 21 20 08 st %g3, [ %g4 + 8 ] <== NOT EXECUTED
}
else /* double LR-turn */
{
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
200cfe0: da 20 e0 0c st %o5, [ %g3 + 0xc ] <== NOT EXECUTED
p2->avl.left = p1;
p->avl.left = p2->avl.right;
200cfe4: d6 01 20 0c ld [ %g4 + 0xc ], %o3 <== NOT EXECUTED
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = 1; else p->avl.bal = 0;
200cfe8: da 49 20 11 ldsb [ %g4 + 0x11 ], %o5 <== NOT EXECUTED
{
p2 = p1->avl.right;
p1->avl.right = p2->avl.left;
p2->avl.left = p1;
p->avl.left = p2->avl.right;
200cfec: d6 20 a0 08 st %o3, [ %g2 + 8 ] <== NOT EXECUTED
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = 1; else p->avl.bal = 0;
200cff0: 80 a3 7f ff cmp %o5, -1 <== NOT EXECUTED
200cff4: 02 80 00 32 be 200d0bc <rtems_bdbuf_remove_from_tree+0x320><== NOT EXECUTED
200cff8: c4 21 20 0c st %g2, [ %g4 + 0xc ] <== NOT EXECUTED
200cffc: c0 28 a0 11 clrb [ %g2 + 0x11 ] <== NOT EXECUTED
if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
200d000: c4 49 20 11 ldsb [ %g4 + 0x11 ], %g2 <== NOT EXECUTED
200d004: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
200d008: 22 80 00 03 be,a 200d014 <rtems_bdbuf_remove_from_tree+0x278><== NOT EXECUTED
200d00c: d8 28 e0 11 stb %o4, [ %g3 + 0x11 ] <== NOT EXECUTED
200d010: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
p = p2;
p2->avl.bal = 0;
200d014: c0 29 20 11 clrb [ %g4 + 0x11 ] <== NOT EXECUTED
200d018: 86 10 00 04 mov %g4, %g3 <== NOT EXECUTED
200d01c: 10 bf ff cb b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d020: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
}
if (p->avl.cache == -1)
{
/* rebalance left branch */
switch (p->avl.bal)
200d024: 80 a0 e0 00 cmp %g3, 0
200d028: 12 80 00 0a bne 200d050 <rtems_bdbuf_remove_from_tree+0x2b4>
200d02c: 80 a0 e0 01 cmp %g3, 1
{
case -1:
p->avl.bal = 0;
break;
case 0:
p->avl.bal = 1;
200d030: d4 28 a0 11 stb %o2, [ %g2 + 0x11 ]
200d034: 86 10 00 02 mov %g2, %g3
200d038: 10 bf ff c4 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac>
200d03c: 88 10 20 00 clr %g4
*root = q;
}
modified = true;
while (modified)
200d040: 12 bf ff cc bne 200cf70 <rtems_bdbuf_remove_from_tree+0x1d4><== ALWAYS TAKEN
200d044: c6 20 a0 08 st %g3, [ %g2 + 8 ]
200d048: 81 c7 e0 08 ret <== NOT EXECUTED
200d04c: 81 e8 00 00 restore <== NOT EXECUTED
}
if (p->avl.cache == -1)
{
/* rebalance left branch */
switch (p->avl.bal)
200d050: 02 80 00 08 be 200d070 <rtems_bdbuf_remove_from_tree+0x2d4>
200d054: 80 a0 ff ff cmp %g3, -1
200d058: 32 bf ff d5 bne,a 200cfac <rtems_bdbuf_remove_from_tree+0x210><== NEVER TAKEN
200d05c: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
{
/* rebalance right branch */
switch (p->avl.bal)
{
case +1:
p->avl.bal = 0;
200d060: c0 28 a0 11 clrb [ %g2 + 0x11 ]
200d064: 86 10 00 02 mov %g2, %g3
200d068: 10 bf ff b8 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac>
200d06c: 88 10 20 01 mov 1, %g4
p->avl.bal = 1;
modified = false;
break;
case +1:
p1 = p->avl.right;
200d070: da 00 a0 0c ld [ %g2 + 0xc ], %o5
if (p1->avl.bal >= 0) /* simple RR-turn */
200d074: c6 4b 60 11 ldsb [ %o5 + 0x11 ], %g3
200d078: 80 a0 e0 00 cmp %g3, 0
200d07c: 26 80 00 20 bl,a 200d0fc <rtems_bdbuf_remove_from_tree+0x360><== NEVER TAKEN
200d080: c6 03 60 08 ld [ %o5 + 8 ], %g3 <== NOT EXECUTED
{
p->avl.right = p1->avl.left;
200d084: d6 03 60 08 ld [ %o5 + 8 ], %o3
p1->avl.left = p;
200d088: c4 23 60 08 st %g2, [ %o5 + 8 ]
if (p1->avl.bal == 0)
200d08c: 12 80 00 13 bne 200d0d8 <rtems_bdbuf_remove_from_tree+0x33c><== NEVER TAKEN
200d090: d6 20 a0 0c st %o3, [ %g2 + 0xc ]
{
p1->avl.bal = -1;
200d094: c8 2b 60 11 stb %g4, [ %o5 + 0x11 ]
200d098: 86 10 00 0d mov %o5, %g3
200d09c: 10 bf ff ab b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac>
200d0a0: 88 10 20 00 clr %g4
p1 = p->avl.left;
if (p1->avl.bal <= 0) /* simple LL-turn */
{
p->avl.left = p1->avl.right;
p1->avl.right = p;
200d0a4: c4 20 e0 0c st %g2, [ %g3 + 0xc ] <== NOT EXECUTED
if (p1->avl.bal == 0)
200d0a8: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
200d0ac: 12 80 00 10 bne 200d0ec <rtems_bdbuf_remove_from_tree+0x350><== NOT EXECUTED
200d0b0: da 20 a0 08 st %o5, [ %g2 + 8 ] <== NOT EXECUTED
{
p1->avl.bal = 1;
200d0b4: 10 bf ff a5 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d0b8: d4 28 e0 11 stb %o2, [ %g3 + 0x11 ] <== NOT EXECUTED
p1->avl.right = p2->avl.left;
p2->avl.left = p1;
p->avl.left = p2->avl.right;
p2->avl.right = p;
if (p2->avl.bal == -1) p->avl.bal = 1; else p->avl.bal = 0;
200d0bc: d4 28 a0 11 stb %o2, [ %g2 + 0x11 ] <== NOT EXECUTED
if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
200d0c0: c4 49 20 11 ldsb [ %g4 + 0x11 ], %g2 <== NOT EXECUTED
200d0c4: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED
200d0c8: 32 bf ff d3 bne,a 200d014 <rtems_bdbuf_remove_from_tree+0x278><== NOT EXECUTED
200d0cc: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
200d0d0: 10 bf ff d1 b 200d014 <rtems_bdbuf_remove_from_tree+0x278><== NOT EXECUTED
200d0d4: d8 28 e0 11 stb %o4, [ %g3 + 0x11 ] <== NOT EXECUTED
p1->avl.bal = -1;
modified = false;
}
else
{
p->avl.bal = 0;
200d0d8: c0 28 a0 11 clrb [ %g2 + 0x11 ] <== NOT EXECUTED
p1->avl.bal = 0;
200d0dc: c0 2b 60 11 clrb [ %o5 + 0x11 ] <== NOT EXECUTED
200d0e0: 86 10 00 0d mov %o5, %g3 <== NOT EXECUTED
200d0e4: 10 bf ff 99 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d0e8: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
p1->avl.bal = 1;
modified = false;
}
else
{
p->avl.bal = 0;
200d0ec: c0 28 a0 11 clrb [ %g2 + 0x11 ] <== NOT EXECUTED
p1->avl.bal = 0;
200d0f0: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
200d0f4: 10 bf ff 95 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d0f8: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
}
else /* double RL-turn */
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
200d0fc: d6 00 e0 0c ld [ %g3 + 0xc ], %o3 <== NOT EXECUTED
p2->avl.right = p1;
200d100: da 20 e0 0c st %o5, [ %g3 + 0xc ] <== NOT EXECUTED
}
else /* double RL-turn */
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
200d104: d6 23 60 08 st %o3, [ %o5 + 8 ] <== NOT EXECUTED
p2->avl.right = p1;
p->avl.right = p2->avl.left;
200d108: d2 00 e0 08 ld [ %g3 + 8 ], %o1 <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200d10c: d6 48 e0 11 ldsb [ %g3 + 0x11 ], %o3 <== NOT EXECUTED
{
p2 = p1->avl.left;
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
200d110: d2 20 a0 0c st %o1, [ %g2 + 0xc ] <== NOT EXECUTED
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200d114: 80 a2 e0 01 cmp %o3, 1 <== NOT EXECUTED
200d118: 02 80 00 1b be 200d184 <rtems_bdbuf_remove_from_tree+0x3e8><== NOT EXECUTED
200d11c: c4 20 e0 08 st %g2, [ %g3 + 8 ] <== NOT EXECUTED
200d120: c0 28 a0 11 clrb [ %g2 + 0x11 ] <== NOT EXECUTED
if (p2->avl.bal == -1) p1->avl.bal = 1; else p1->avl.bal = 0;
200d124: c4 48 e0 11 ldsb [ %g3 + 0x11 ], %g2 <== NOT EXECUTED
200d128: 80 a0 bf ff cmp %g2, -1 <== NOT EXECUTED
200d12c: 22 80 00 13 be,a 200d178 <rtems_bdbuf_remove_from_tree+0x3dc><== NOT EXECUTED
200d130: d4 2b 60 11 stb %o2, [ %o5 + 0x11 ] <== NOT EXECUTED
200d134: c0 2b 60 11 clrb [ %o5 + 0x11 ] <== NOT EXECUTED
modified = false;
}
else
{
p->avl.bal = 0;
p1->avl.bal = 0;
200d138: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
200d13c: 10 bf ff 83 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d140: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
/* at this moment q - is a node to delete, p is q's parent */
if (q->avl.right == NULL)
{
r = q->avl.left;
if (r != NULL)
200d144: 80 a0 e0 00 cmp %g3, 0
200d148: 02 bf ff 71 be 200cf0c <rtems_bdbuf_remove_from_tree+0x170>
200d14c: 82 10 00 02 mov %g2, %g1
{
r->avl.bal = 0;
200d150: 10 bf ff 6f b 200cf0c <rtems_bdbuf_remove_from_tree+0x170>
200d154: c0 28 e0 11 clrb [ %g3 + 0x11 ]
r = q->avl.right;
if (r->avl.left == NULL)
{
r->avl.left = q->avl.left;
200d158: c8 04 20 08 ld [ %l0 + 8 ], %g4
r->avl.bal = q->avl.bal;
200d15c: da 0c 20 11 ldub [ %l0 + 0x11 ], %o5
r = q->avl.right;
if (r->avl.left == NULL)
{
r->avl.left = q->avl.left;
200d160: c8 20 e0 08 st %g4, [ %g3 + 8 ]
r->avl.bal = q->avl.bal;
200d164: da 28 e0 11 stb %o5, [ %g3 + 0x11 ]
r->avl.cache = 1;
200d168: 88 10 20 01 mov 1, %g4
200d16c: c8 28 e0 10 stb %g4, [ %g3 + 0x10 ]
*buf_prev++ = q = r;
200d170: 10 bf ff 67 b 200cf0c <rtems_bdbuf_remove_from_tree+0x170>
200d174: c6 20 80 00 st %g3, [ %g2 ]
modified = false;
}
else
{
p->avl.bal = 0;
p1->avl.bal = 0;
200d178: c0 28 e0 11 clrb [ %g3 + 0x11 ] <== NOT EXECUTED
200d17c: 10 bf ff 73 b 200cf48 <rtems_bdbuf_remove_from_tree+0x1ac><== NOT EXECUTED
200d180: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
p1->avl.left = p2->avl.right;
p2->avl.right = p1;
p->avl.right = p2->avl.left;
p2->avl.left = p;
if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
200d184: 10 bf ff e8 b 200d124 <rtems_bdbuf_remove_from_tree+0x388><== NOT EXECUTED
200d188: c8 28 a0 11 stb %g4, [ %g2 + 0x11 ] <== NOT EXECUTED
200d18c: 81 c7 e0 08 ret
200d190: 81 e8 00 00 restore
0200d194 <rtems_bdbuf_remove_from_tree_and_lru_list>:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_TREE_RM);
}
static void
rtems_bdbuf_remove_from_tree_and_lru_list (rtems_bdbuf_buffer *bd)
{
200d194: 9d e3 bf a0 save %sp, -96, %sp
switch (bd->state)
200d198: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200d19c: 80 a0 60 00 cmp %g1, 0
200d1a0: 02 80 00 0c be 200d1d0 <rtems_bdbuf_remove_from_tree_and_lru_list+0x3c>
200d1a4: 80 a0 60 02 cmp %g1, 2
200d1a8: 02 80 00 08 be 200d1c8 <rtems_bdbuf_remove_from_tree_and_lru_list+0x34><== ALWAYS TAKEN
200d1ac: 01 00 00 00 nop
break;
case RTEMS_BDBUF_STATE_CACHED:
rtems_bdbuf_remove_from_tree (bd);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_10);
200d1b0: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200d1b4: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200d1b8: 82 10 60 08 or %g1, 8, %g1 ! 42000008 <RAM_END+0x3fc00008><== NOT EXECUTED
200d1bc: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200d1c0: 7f ff ec 4b call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200d1c4: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
switch (bd->state)
{
case RTEMS_BDBUF_STATE_FREE:
break;
case RTEMS_BDBUF_STATE_CACHED:
rtems_bdbuf_remove_from_tree (bd);
200d1c8: 7f ff fe f5 call 200cd9c <rtems_bdbuf_remove_from_tree>
200d1cc: 90 10 00 18 mov %i0, %o0
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200d1d0: 7f ff ed c4 call 20088e0 <_Chain_Extract>
200d1d4: 81 e8 00 00 restore
0200c840 <rtems_bdbuf_restore_preemption>:
return prev_mode;
}
static void
rtems_bdbuf_restore_preemption (rtems_mode prev_mode)
{
200c840: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
sc = rtems_task_mode (prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode);
200c844: 13 00 00 3f sethi %hi(0xfc00), %o1
return prev_mode;
}
static void
rtems_bdbuf_restore_preemption (rtems_mode prev_mode)
{
200c848: f0 27 a0 44 st %i0, [ %fp + 0x44 ]
rtems_status_code sc = RTEMS_SUCCESSFUL;
sc = rtems_task_mode (prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode);
200c84c: 90 10 00 18 mov %i0, %o0
200c850: 92 12 63 ff or %o1, 0x3ff, %o1
200c854: 40 00 16 0e call 201208c <rtems_task_mode>
200c858: 94 07 a0 44 add %fp, 0x44, %o2
if (sc != RTEMS_SUCCESSFUL)
200c85c: 80 a2 20 00 cmp %o0, 0
200c860: 12 80 00 04 bne 200c870 <rtems_bdbuf_restore_preemption+0x30><== NEVER TAKEN
200c864: 11 10 80 00 sethi %hi(0x42000000), %o0
200c868: 81 c7 e0 08 ret
200c86c: 81 e8 00 00 restore
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_PREEMPT_RST);
200c870: 7f ff ee 9f call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c874: 90 12 20 11 or %o0, 0x11, %o0 <== NOT EXECUTED
0200c258 <rtems_bdbuf_swapout_modified_processing>:
rtems_chain_control* chain,
rtems_chain_control* transfer,
bool sync_active,
bool update_timers,
uint32_t timer_delta)
{
200c258: 9d e3 bf a0 save %sp, -96, %sp
if (!rtems_chain_is_empty (chain))
200c25c: c2 06 40 00 ld [ %i1 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200c260: b2 06 60 04 add %i1, 4, %i1
200c264: 80 a0 40 19 cmp %g1, %i1
200c268: 02 80 00 39 be 200c34c <rtems_bdbuf_swapout_modified_processing+0xf4>
200c26c: b6 8e e0 ff andcc %i3, 0xff, %i3
node = node->next;
/*
* A sync active with no valid dev means sync all.
*/
if (sync_active && (*dev == BDBUF_INVALID_DEV))
200c270: 12 80 00 59 bne 200c3d4 <rtems_bdbuf_swapout_modified_processing+0x17c>
200c274: a0 10 00 01 mov %g1, %l0
200c278: a2 10 20 00 clr %l1
sync_all = true;
else
sync_all = false;
while (!rtems_chain_is_tail (chain, node))
200c27c: 80 a0 40 19 cmp %g1, %i1
200c280: 02 80 00 33 be 200c34c <rtems_bdbuf_swapout_modified_processing+0xf4><== NEVER TAKEN
200c284: 25 00 80 8b sethi %hi(0x2022c00), %l2
200c288: a2 0c 60 ff and %l1, 0xff, %l1
|| rtems_bdbuf_has_buffer_waiters ())
bd->hold_timer = 0;
if (bd->hold_timer)
{
if (update_timers)
200c28c: b8 0f 20 ff and %i4, 0xff, %i4
}
static bool
rtems_bdbuf_has_buffer_waiters (void)
{
return bdbuf_cache.buffer_waiters.count;
200c290: a4 14 a3 78 or %l2, 0x378, %l2
200c294: aa 06 a0 04 add %i2, 4, %l5
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200c298: a8 10 20 09 mov 9, %l4
* or someone waits for a buffer written force all the timers to 0.
*
* @note Lots of sync requests will skew this timer. It should be based
* on TOD to be accurate. Does it matter ?
*/
if (sync_all || (sync_active && (*dev == bd->dev))
200c29c: 80 a4 60 00 cmp %l1, 0
200c2a0: 12 80 00 31 bne 200c364 <rtems_bdbuf_swapout_modified_processing+0x10c>
200c2a4: 80 a6 e0 00 cmp %i3, 0
200c2a8: 02 80 00 07 be 200c2c4 <rtems_bdbuf_swapout_modified_processing+0x6c>
200c2ac: 01 00 00 00 nop
200c2b0: c4 06 00 00 ld [ %i0 ], %g2
200c2b4: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
200c2b8: 80 a0 80 01 cmp %g2, %g1
200c2bc: 22 80 00 26 be,a 200c354 <rtems_bdbuf_swapout_modified_processing+0xfc>
200c2c0: c4 06 20 04 ld [ %i0 + 4 ], %g2
}
static bool
rtems_bdbuf_has_buffer_waiters (void)
{
return bdbuf_cache.buffer_waiters.count;
200c2c4: c2 04 a0 78 ld [ %l2 + 0x78 ], %g1
* or someone waits for a buffer written force all the timers to 0.
*
* @note Lots of sync requests will skew this timer. It should be based
* on TOD to be accurate. Does it matter ?
*/
if (sync_all || (sync_active && (*dev == bd->dev))
200c2c8: 80 a0 60 00 cmp %g1, 0
200c2cc: 12 80 00 26 bne 200c364 <rtems_bdbuf_swapout_modified_processing+0x10c>
200c2d0: 01 00 00 00 nop
|| rtems_bdbuf_has_buffer_waiters ())
bd->hold_timer = 0;
if (bd->hold_timer)
200c2d4: c2 04 20 34 ld [ %l0 + 0x34 ], %g1
200c2d8: 80 a0 60 00 cmp %g1, 0
200c2dc: 22 80 00 11 be,a 200c320 <rtems_bdbuf_swapout_modified_processing+0xc8>
200c2e0: c2 06 00 00 ld [ %i0 ], %g1
{
if (update_timers)
200c2e4: 80 a7 20 00 cmp %i4, 0
200c2e8: 02 80 00 09 be 200c30c <rtems_bdbuf_swapout_modified_processing+0xb4>
200c2ec: 01 00 00 00 nop
{
if (bd->hold_timer > timer_delta)
200c2f0: c2 04 20 34 ld [ %l0 + 0x34 ], %g1
200c2f4: 80 a0 40 1d cmp %g1, %i5
200c2f8: 08 80 00 4d bleu 200c42c <rtems_bdbuf_swapout_modified_processing+0x1d4>
200c2fc: 01 00 00 00 nop
bd->hold_timer -= timer_delta;
200c300: c2 04 20 34 ld [ %l0 + 0x34 ], %g1
200c304: 82 20 40 1d sub %g1, %i5, %g1
200c308: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
else
bd->hold_timer = 0;
}
if (bd->hold_timer)
200c30c: c2 04 20 34 ld [ %l0 + 0x34 ], %g1
200c310: 80 a0 60 00 cmp %g1, 0
200c314: 32 80 00 0b bne,a 200c340 <rtems_bdbuf_swapout_modified_processing+0xe8>
200c318: e0 04 00 00 ld [ %l0 ], %l0
/*
* This assumes we can set dev_t to BDBUF_INVALID_DEV which is just an
* assumption. Cannot use the transfer list being empty the sync dev
* calls sets the dev to use.
*/
if (*dev == BDBUF_INVALID_DEV)
200c31c: c2 06 00 00 ld [ %i0 ], %g1
200c320: 80 a0 7f ff cmp %g1, -1
200c324: 02 80 00 3a be 200c40c <rtems_bdbuf_swapout_modified_processing+0x1b4>
200c328: c6 06 20 04 ld [ %i0 + 4 ], %g3
*dev = bd->dev;
if (bd->dev == *dev)
200c32c: c4 04 20 18 ld [ %l0 + 0x18 ], %g2
200c330: 80 a0 80 01 cmp %g2, %g1
200c334: 22 80 00 0e be,a 200c36c <rtems_bdbuf_swapout_modified_processing+0x114><== ALWAYS TAKEN
200c338: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
node = next_node;
}
else
{
node = node->next;
200c33c: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED
if (sync_active && (*dev == BDBUF_INVALID_DEV))
sync_all = true;
else
sync_all = false;
while (!rtems_chain_is_tail (chain, node))
200c340: 80 a6 40 10 cmp %i1, %l0
200c344: 12 bf ff d7 bne 200c2a0 <rtems_bdbuf_swapout_modified_processing+0x48>
200c348: 80 a4 60 00 cmp %l1, 0
200c34c: 81 c7 e0 08 ret
200c350: 81 e8 00 00 restore
* or someone waits for a buffer written force all the timers to 0.
*
* @note Lots of sync requests will skew this timer. It should be based
* on TOD to be accurate. Does it matter ?
*/
if (sync_all || (sync_active && (*dev == bd->dev))
200c354: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200c358: 80 a0 80 01 cmp %g2, %g1
200c35c: 12 bf ff da bne 200c2c4 <rtems_bdbuf_swapout_modified_processing+0x6c><== NEVER TAKEN
200c360: 01 00 00 00 nop
|| rtems_bdbuf_has_buffer_waiters ())
bd->hold_timer = 0;
200c364: c0 24 20 34 clr [ %l0 + 0x34 ]
200c368: 30 bf ff db b,a 200c2d4 <rtems_bdbuf_swapout_modified_processing+0x7c>
* calls sets the dev to use.
*/
if (*dev == BDBUF_INVALID_DEV)
*dev = bd->dev;
if (bd->dev == *dev)
200c36c: 80 a0 40 03 cmp %g1, %g3
200c370: 32 bf ff f4 bne,a 200c340 <rtems_bdbuf_swapout_modified_processing+0xe8><== NEVER TAKEN
200c374: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200c378: 90 10 00 10 mov %l0, %o0
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200c37c: e8 24 20 28 st %l4, [ %l0 + 0x28 ]
200c380: 7f ff f1 58 call 20088e0 <_Chain_Extract>
200c384: e6 04 00 00 ld [ %l0 ], %l3
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);
rtems_chain_extract (node);
tnode = tnode->previous;
200c388: d0 05 60 04 ld [ %l5 + 4 ], %o0
while (node && !rtems_chain_is_head (transfer, tnode))
200c38c: 80 a2 00 1a cmp %o0, %i2
200c390: 02 80 00 0c be 200c3c0 <rtems_bdbuf_swapout_modified_processing+0x168>
200c394: 92 10 00 10 mov %l0, %o1
200c398: c4 04 20 20 ld [ %l0 + 0x20 ], %g2
{
rtems_bdbuf_buffer* tbd = (rtems_bdbuf_buffer*) tnode;
if (bd->block > tbd->block)
200c39c: c2 02 20 20 ld [ %o0 + 0x20 ], %g1
200c3a0: 80 a0 40 02 cmp %g1, %g2
200c3a4: 0a 80 00 16 bcs 200c3fc <rtems_bdbuf_swapout_modified_processing+0x1a4>
200c3a8: 92 10 00 10 mov %l0, %o1
{
rtems_chain_insert (tnode, node);
node = NULL;
}
else
tnode = tnode->previous;
200c3ac: d0 02 20 04 ld [ %o0 + 4 ], %o0
rtems_chain_extract (node);
tnode = tnode->previous;
while (node && !rtems_chain_is_head (transfer, tnode))
200c3b0: 80 a2 00 1a cmp %o0, %i2
200c3b4: 32 bf ff fb bne,a 200c3a0 <rtems_bdbuf_swapout_modified_processing+0x148>
200c3b8: c2 02 20 20 ld [ %o0 + 0x20 ], %g1
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200c3bc: 92 10 00 10 mov %l0, %o1
200c3c0: 90 10 00 1a mov %i2, %o0
200c3c4: 40 00 18 6d call 2012578 <_Chain_Insert>
200c3c8: a0 10 00 13 mov %l3, %l0
if (sync_active && (*dev == BDBUF_INVALID_DEV))
sync_all = true;
else
sync_all = false;
while (!rtems_chain_is_tail (chain, node))
200c3cc: 10 bf ff de b 200c344 <rtems_bdbuf_swapout_modified_processing+0xec>
200c3d0: 80 a6 40 10 cmp %i1, %l0
* @param update_timers If true update the timers.
* @param timer_delta It update_timers is true update the timers by this
* amount.
*/
static void
rtems_bdbuf_swapout_modified_processing (dev_t* dev,
200c3d4: c4 06 00 00 ld [ %i0 ], %g2
200c3d8: 80 a0 bf ff cmp %g2, -1
200c3dc: 12 bf ff a8 bne 200c27c <rtems_bdbuf_swapout_modified_processing+0x24>
200c3e0: a2 10 20 00 clr %l1
200c3e4: c4 06 20 04 ld [ %i0 + 4 ], %g2
200c3e8: 80 a0 bf ff cmp %g2, -1
200c3ec: 22 bf ff a4 be,a 200c27c <rtems_bdbuf_swapout_modified_processing+0x24><== ALWAYS TAKEN
200c3f0: a2 10 20 01 mov 1, %l1
if (sync_active && (*dev == BDBUF_INVALID_DEV))
sync_all = true;
else
sync_all = false;
while (!rtems_chain_is_tail (chain, node))
200c3f4: 10 bf ff a3 b 200c280 <rtems_bdbuf_swapout_modified_processing+0x28><== NOT EXECUTED
200c3f8: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void rtems_chain_insert(
rtems_chain_node *after_node,
rtems_chain_node *the_node
)
{
_Chain_Insert( after_node, the_node );
200c3fc: 40 00 18 5f call 2012578 <_Chain_Insert>
200c400: a0 10 00 13 mov %l3, %l0
200c404: 10 bf ff d0 b 200c344 <rtems_bdbuf_swapout_modified_processing+0xec>
200c408: 80 a6 40 10 cmp %i1, %l0
/*
* This assumes we can set dev_t to BDBUF_INVALID_DEV which is just an
* assumption. Cannot use the transfer list being empty the sync dev
* calls sets the dev to use.
*/
if (*dev == BDBUF_INVALID_DEV)
200c40c: 80 a0 ff ff cmp %g3, -1
200c410: 32 bf ff c8 bne,a 200c330 <rtems_bdbuf_swapout_modified_processing+0xd8><== NEVER TAKEN
200c414: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 <== NOT EXECUTED
*dev = bd->dev;
200c418: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
200c41c: c6 04 20 1c ld [ %l0 + 0x1c ], %g3
200c420: c2 26 00 00 st %g1, [ %i0 ]
200c424: 10 bf ff c2 b 200c32c <rtems_bdbuf_swapout_modified_processing+0xd4>
200c428: c6 26 20 04 st %g3, [ %i0 + 4 ]
if (update_timers)
{
if (bd->hold_timer > timer_delta)
bd->hold_timer -= timer_delta;
else
bd->hold_timer = 0;
200c42c: c0 24 20 34 clr [ %l0 + 0x34 ]
200c430: 30 bf ff b7 b,a 200c30c <rtems_bdbuf_swapout_modified_processing+0xb4>
0200d940 <rtems_bdbuf_swapout_task>:
* not this.
* @return rtems_task Not used.
*/
static rtems_task
rtems_bdbuf_swapout_task (rtems_task_argument arg)
{
200d940: 9d e3 bf 68 save %sp, -152, %sp
rtems_bdbuf_swapout_transfer transfer;
uint32_t period_in_ticks;
const uint32_t period_in_msecs = bdbuf_config.swapout_period;;
200d944: 21 00 80 83 sethi %hi(0x2020c00), %l0
200d948: a0 14 23 ac or %l0, 0x3ac, %l0 ! 2020fac <rtems_bdbuf_configuration>
uint32_t timer_delta;
transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
200d94c: 7f ff fc fd call 200cd40 <rtems_bdbuf_swapout_writereq_alloc>
200d950: ec 04 20 0c ld [ %l0 + 0xc ], %l6
transfer.syncing = false;
/*
* Localise the period.
*/
period_in_ticks = RTEMS_MICROSECONDS_TO_TICKS (period_in_msecs * 1000);
200d954: 03 00 80 89 sethi %hi(0x2022400), %g1
200d958: d2 00 63 4c ld [ %g1 + 0x34c ], %o1 ! 202274c <Configuration+0xc>
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200d95c: 82 07 bf d4 add %fp, -44, %g1
const uint32_t period_in_msecs = bdbuf_config.swapout_period;;
uint32_t timer_delta;
transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
rtems_chain_initialize_empty (&transfer.bds);
transfer.dev = BDBUF_INVALID_DEV;
200d960: 05 3f ff ff sethi %hi(0xfffffc00), %g2
200d964: c2 27 bf d0 st %g1, [ %fp + -48 ]
200d968: 84 10 a3 ff or %g2, 0x3ff, %g2
transfer.syncing = false;
/*
* Localise the period.
*/
period_in_ticks = RTEMS_MICROSECONDS_TO_TICKS (period_in_msecs * 1000);
200d96c: 83 2d a0 02 sll %l6, 2, %g1
const uint32_t period_in_msecs = bdbuf_config.swapout_period;;
uint32_t timer_delta;
transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
rtems_chain_initialize_empty (&transfer.bds);
transfer.dev = BDBUF_INVALID_DEV;
200d970: 86 10 00 02 mov %g2, %g3
rtems_bdbuf_swapout_transfer transfer;
uint32_t period_in_ticks;
const uint32_t period_in_msecs = bdbuf_config.swapout_period;;
uint32_t timer_delta;
transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
200d974: d0 27 bf ec st %o0, [ %fp + -20 ]
rtems_chain_initialize_empty (&transfer.bds);
transfer.dev = BDBUF_INVALID_DEV;
200d978: c4 3f bf e0 std %g2, [ %fp + -32 ]
the_chain->permanent_null = NULL;
200d97c: c0 27 bf d4 clr [ %fp + -44 ]
transfer.syncing = false;
200d980: c0 2f bf e8 clrb [ %fp + -24 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200d984: ae 07 bf d0 add %fp, -48, %l7
/*
* Localise the period.
*/
period_in_ticks = RTEMS_MICROSECONDS_TO_TICKS (period_in_msecs * 1000);
200d988: 91 2d a0 07 sll %l6, 7, %o0
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
200d98c: ee 27 bf d8 st %l7, [ %fp + -40 ]
200d990: 90 22 00 01 sub %o0, %g1, %o0
200d994: 90 02 00 16 add %o0, %l6, %o0
200d998: 40 00 45 75 call 201ef6c <.udiv>
200d99c: 91 2a 20 03 sll %o0, 3, %o0
rtems_bdbuf_swapout_workers_open (void)
{
rtems_status_code sc;
size_t w;
rtems_bdbuf_lock_cache ();
200d9a0: 7f ff fa 17 call 200c1fc <rtems_bdbuf_lock_cache>
200d9a4: d0 27 bf cc st %o0, [ %fp + -52 ]
for (w = 0; w < bdbuf_config.swapout_workers; w++)
200d9a8: e6 04 20 14 ld [ %l0 + 0x14 ], %l3
200d9ac: 80 a4 e0 00 cmp %l3, 0
200d9b0: 02 80 00 35 be 200da84 <rtems_bdbuf_swapout_task+0x144> <== ALWAYS TAKEN
200d9b4: 3b 00 80 8b sethi %hi(0x2022c00), %i5
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
sc = rtems_task_create (rtems_build_name('B', 'D', 'o', 'a' + w),
(bdbuf_config.swapout_priority ?
200d9b8: e4 04 20 08 ld [ %l0 + 8 ], %l2 <== NOT EXECUTED
worker->transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
sc = rtems_task_create (rtems_build_name('B', 'D', 'o', 'a' + w),
200d9bc: 2b 10 91 1b sethi %hi(0x42446c00), %l5 <== NOT EXECUTED
RTEMS_LOCAL | RTEMS_NO_FLOATING_POINT,
&worker->id);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_CREATE);
sc = rtems_task_start (worker->id,
200d9c0: 39 00 80 37 sethi %hi(0x200dc00), %i4 <== NOT EXECUTED
rtems_chain_append (&bdbuf_cache.swapout_workers, &worker->link);
worker->enabled = true;
worker->transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
200d9c4: 35 3f ff ff sethi %hi(0xfffffc00), %i2 <== 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 );
200d9c8: ba 17 63 80 or %i5, 0x380, %i5 <== NOT EXECUTED
200d9cc: b4 16 a3 ff or %i2, 0x3ff, %i2 <== NOT EXECUTED
sc = rtems_task_create (rtems_build_name('B', 'D', 'o', 'a' + w),
200d9d0: aa 15 63 00 or %l5, 0x300, %l5 <== NOT EXECUTED
RTEMS_LOCAL | RTEMS_NO_FLOATING_POINT,
&worker->id);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_CREATE);
sc = rtems_task_start (worker->id,
200d9d4: b8 17 20 e0 or %i4, 0xe0, %i4 <== NOT EXECUTED
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
sc = rtems_task_create (rtems_build_name('B', 'D', 'o', 'a' + w),
(bdbuf_config.swapout_priority ?
200d9d8: a2 10 20 00 clr %l1 <== NOT EXECUTED
worker = malloc (sizeof (rtems_bdbuf_swapout_worker));
if (!worker)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
rtems_chain_append (&bdbuf_cache.swapout_workers, &worker->link);
worker->enabled = true;
200d9dc: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
worker->transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
200d9e0: b6 10 00 1a mov %i2, %i3 <== NOT EXECUTED
for (w = 0; w < bdbuf_config.swapout_workers; w++)
{
rtems_bdbuf_swapout_worker* worker;
worker = malloc (sizeof (rtems_bdbuf_swapout_worker));
200d9e4: 7f ff d9 d3 call 2004130 <malloc> <== NOT EXECUTED
200d9e8: 90 10 20 38 mov 0x38, %o0 <== NOT EXECUTED
if (!worker)
200d9ec: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
200d9f0: 02 80 00 b8 be 200dcd0 <rtems_bdbuf_swapout_task+0x390> <== NOT EXECUTED
200d9f4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
200d9f8: 7f ff eb ae call 20088b0 <_Chain_Append> <== NOT EXECUTED
200d9fc: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
rtems_chain_append (&bdbuf_cache.swapout_workers, &worker->link);
worker->enabled = true;
200da00: e8 2c 20 0c stb %l4, [ %l0 + 0xc ] <== NOT EXECUTED
worker->transfer.write_req = rtems_bdbuf_swapout_writereq_alloc ();
200da04: 7f ff fc cf call 200cd40 <rtems_bdbuf_swapout_writereq_alloc><== NOT EXECUTED
200da08: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200da0c: 82 04 20 14 add %l0, 0x14, %g1 <== NOT EXECUTED
200da10: d0 24 20 2c st %o0, [ %l0 + 0x2c ] <== NOT EXECUTED
200da14: c2 24 20 10 st %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
200da18: c0 24 20 14 clr [ %l0 + 0x14 ] <== NOT EXECUTED
the_chain->last = _Chain_Head(the_chain);
200da1c: 82 04 20 10 add %l0, 0x10, %g1 <== NOT EXECUTED
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
200da20: f4 3c 20 20 std %i2, [ %l0 + 0x20 ] <== NOT EXECUTED
200da24: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
sc = rtems_task_create (rtems_build_name('B', 'D', 'o', 'a' + w),
200da28: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
200da2c: 12 80 00 03 bne 200da38 <rtems_bdbuf_swapout_task+0xf8> <== NOT EXECUTED
200da30: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
200da34: 92 10 20 0f mov 0xf, %o1 <== NOT EXECUTED
200da38: 90 04 60 61 add %l1, 0x61, %o0 <== NOT EXECUTED
200da3c: 15 00 00 08 sethi %hi(0x2000), %o2 <== NOT EXECUTED
200da40: 90 12 00 15 or %o0, %l5, %o0 <== NOT EXECUTED
200da44: 96 10 24 00 mov 0x400, %o3 <== NOT EXECUTED
200da48: 98 10 20 00 clr %o4 <== NOT EXECUTED
200da4c: 7f ff e9 12 call 2007e94 <rtems_task_create> <== NOT EXECUTED
200da50: 9a 04 20 08 add %l0, 8, %o5 <== NOT EXECUTED
RTEMS_BDBUF_SWAPOUT_TASK_PRIORITY_DEFAULT),
SWAPOUT_TASK_STACK_SIZE,
RTEMS_PREEMPT | RTEMS_NO_TIMESLICE | RTEMS_NO_ASR,
RTEMS_LOCAL | RTEMS_NO_FLOATING_POINT,
&worker->id);
if (sc != RTEMS_SUCCESSFUL)
200da54: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200da58: 12 80 00 9b bne 200dcc4 <rtems_bdbuf_swapout_task+0x384> <== NOT EXECUTED
200da5c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_CREATE);
sc = rtems_task_start (worker->id,
200da60: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
200da64: 7f ff e9 9c call 20080d4 <rtems_task_start> <== NOT EXECUTED
200da68: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
rtems_bdbuf_swapout_worker_task,
(rtems_task_argument) worker);
if (sc != RTEMS_SUCCESSFUL)
200da6c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200da70: 12 80 00 92 bne 200dcb8 <rtems_bdbuf_swapout_task+0x378> <== NOT EXECUTED
200da74: a2 04 60 01 inc %l1 <== NOT EXECUTED
rtems_status_code sc;
size_t w;
rtems_bdbuf_lock_cache ();
for (w = 0; w < bdbuf_config.swapout_workers; w++)
200da78: 80 a4 40 13 cmp %l1, %l3 <== NOT EXECUTED
200da7c: 0a bf ff da bcs 200d9e4 <rtems_bdbuf_swapout_task+0xa4> <== NOT EXECUTED
200da80: 01 00 00 00 nop <== NOT EXECUTED
if (worker)
transfer = &worker->transfer;
}
rtems_chain_initialize_empty (&transfer->bds);
transfer->dev = BDBUF_INVALID_DEV;
200da84: 31 3f ff ff sethi %hi(0xfffffc00), %i0
200da88: 23 00 80 8b sethi %hi(0x2022c00), %l1
200da8c: b0 16 23 ff or %i0, 0x3ff, %i0
(rtems_task_argument) worker);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_START);
}
rtems_bdbuf_unlock_cache ();
200da90: 7f ff fa 69 call 200c434 <rtems_bdbuf_unlock_cache>
200da94: a2 14 63 78 or %l1, 0x378, %l1
if (worker)
transfer = &worker->transfer;
}
rtems_chain_initialize_empty (&transfer->bds);
transfer->dev = BDBUF_INVALID_DEV;
200da98: b2 10 00 18 mov %i0, %i1
/*
* Create the worker threads.
*/
rtems_bdbuf_swapout_workers_open ();
while (bdbuf_cache.swapout_enabled)
200da9c: b6 10 00 11 mov %l1, %i3
/*
* If we have any buffers in the sync queue move them to the modified
* list. The first sync buffer will select the device we use.
*/
rtems_bdbuf_swapout_modified_processing (&transfer->dev,
200daa0: b8 04 60 5c add %l1, 0x5c, %i4
timer_delta);
/*
* Process the cache's modified list.
*/
rtems_bdbuf_swapout_modified_processing (&transfer->dev,
200daa4: ba 04 60 50 add %l1, 0x50, %i5
* here. We do not know the worker is the last in a sequence of sync writes
* until after we have it running so we do not know to tell it to release the
* lock. The simplest solution is to get the main swap out task perform all
* sync operations.
*/
if (bdbuf_cache.sync_active)
200daa8: b4 10 00 11 mov %l1, %i2
/*
* Create the worker threads.
*/
rtems_bdbuf_swapout_workers_open ();
while (bdbuf_cache.swapout_enabled)
200daac: c2 0c 60 04 ldub [ %l1 + 4 ], %g1
200dab0: 80 a0 60 00 cmp %g1, 0
200dab4: 02 80 00 67 be 200dc50 <rtems_bdbuf_swapout_task+0x310> <== NEVER TAKEN
200dab8: aa 10 20 01 mov 1, %l5
rtems_bdbuf_swapout_transfer* transfer)
{
rtems_bdbuf_swapout_worker* worker;
bool transfered_buffers = false;
rtems_bdbuf_lock_cache ();
200dabc: 7f ff f9 d0 call 200c1fc <rtems_bdbuf_lock_cache>
200dac0: 01 00 00 00 nop
* here. We do not know the worker is the last in a sequence of sync writes
* until after we have it running so we do not know to tell it to release the
* lock. The simplest solution is to get the main swap out task perform all
* sync operations.
*/
if (bdbuf_cache.sync_active)
200dac4: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1
200dac8: a4 10 20 00 clr %l2
200dacc: 80 a0 60 00 cmp %g1, 0
200dad0: 02 80 00 54 be 200dc20 <rtems_bdbuf_swapout_task+0x2e0>
200dad4: a0 10 00 17 mov %l7, %l0
transfer = &worker->transfer;
}
rtems_chain_initialize_empty (&transfer->bds);
transfer->dev = BDBUF_INVALID_DEV;
transfer->syncing = bdbuf_cache.sync_active;
200dad8: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200dadc: a6 04 20 04 add %l0, 4, %l3
200dae0: c2 2c 20 18 stb %g1, [ %l0 + 0x18 ]
/*
* When the sync is for a device limit the sync to that device. If the sync
* is for a buffer handle process the devices in the order on the sync
* list. This means the dev is BDBUF_INVALID_DEV.
*/
if (bdbuf_cache.sync_active)
200dae4: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
200dae8: c0 24 20 04 clr [ %l0 + 4 ]
the_chain->last = _Chain_Head(the_chain);
200daec: e0 24 20 08 st %l0, [ %l0 + 8 ]
if (worker)
transfer = &worker->transfer;
}
rtems_chain_initialize_empty (&transfer->bds);
transfer->dev = BDBUF_INVALID_DEV;
200daf0: f0 3c 20 10 std %i0, [ %l0 + 0x10 ]
/*
* When the sync is for a device limit the sync to that device. If the sync
* is for a buffer handle process the devices in the order on the sync
* list. This means the dev is BDBUF_INVALID_DEV.
*/
if (bdbuf_cache.sync_active)
200daf4: 80 a0 60 00 cmp %g1, 0
200daf8: 02 80 00 04 be 200db08 <rtems_bdbuf_swapout_task+0x1c8>
200dafc: e6 24 00 00 st %l3, [ %l0 ]
transfer->dev = bdbuf_cache.sync_device;
200db00: c4 1e e0 38 ldd [ %i3 + 0x38 ], %g2
200db04: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
/*
* If we have any buffers in the sync queue move them to the modified
* list. The first sync buffer will select the device we use.
*/
rtems_bdbuf_swapout_modified_processing (&transfer->dev,
200db08: a8 04 20 10 add %l0, 0x10, %l4
200db0c: 96 10 20 01 mov 1, %o3
200db10: 98 10 20 00 clr %o4
200db14: 9a 10 00 16 mov %l6, %o5
200db18: 90 10 00 14 mov %l4, %o0
200db1c: 92 10 00 1c mov %i4, %o1
200db20: 7f ff f9 ce call 200c258 <rtems_bdbuf_swapout_modified_processing>
200db24: 94 10 00 10 mov %l0, %o2
timer_delta);
/*
* Process the cache's modified list.
*/
rtems_bdbuf_swapout_modified_processing (&transfer->dev,
200db28: d6 0c 60 30 ldub [ %l1 + 0x30 ], %o3
200db2c: 90 10 00 14 mov %l4, %o0
200db30: 92 10 00 1d mov %i5, %o1
200db34: 94 10 00 10 mov %l0, %o2
200db38: 98 0d 60 01 and %l5, 1, %o4
200db3c: 7f ff f9 c7 call 200c258 <rtems_bdbuf_swapout_modified_processing>
200db40: 9a 10 00 16 mov %l6, %o5
/*
* We have all the buffers that have been modified for this device so the
* cache can be unlocked because the state of each buffer has been set to
* TRANSFER.
*/
rtems_bdbuf_unlock_cache ();
200db44: 7f ff fa 3c call 200c434 <rtems_bdbuf_unlock_cache>
200db48: 01 00 00 00 nop
/*
* If there are buffers to transfer to the media transfer them.
*/
if (!rtems_chain_is_empty (&transfer->bds))
200db4c: c4 04 00 00 ld [ %l0 ], %g2
200db50: 80 a4 c0 02 cmp %l3, %g2
200db54: 02 80 00 0b be 200db80 <rtems_bdbuf_swapout_task+0x240>
200db58: 82 10 20 00 clr %g1
{
if (worker)
200db5c: 80 a4 a0 00 cmp %l2, 0
200db60: 02 80 00 38 be 200dc40 <rtems_bdbuf_swapout_task+0x300> <== ALWAYS TAKEN
200db64: 01 00 00 00 nop
{
rtems_status_code sc = rtems_event_send (worker->id,
200db68: d0 04 a0 08 ld [ %l2 + 8 ], %o0 <== NOT EXECUTED
200db6c: 7f ff e7 1a call 20077d4 <rtems_event_send> <== NOT EXECUTED
200db70: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
RTEMS_BDBUF_SWAPOUT_SYNC);
if (sc != RTEMS_SUCCESSFUL)
200db74: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200db78: 12 80 00 4d bne 200dcac <rtems_bdbuf_swapout_task+0x36c> <== NOT EXECUTED
200db7c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
}
transfered_buffers = true;
}
if (bdbuf_cache.sync_active && !transfered_buffers)
200db80: c4 0c 60 30 ldub [ %l1 + 0x30 ], %g2
200db84: 80 a0 a0 00 cmp %g2, 0
200db88: 02 80 00 1d be 200dbfc <rtems_bdbuf_swapout_task+0x2bc>
200db8c: 80 88 60 ff btst 0xff, %g1
200db90: 12 bf ff cb bne 200dabc <rtems_bdbuf_swapout_task+0x17c>
200db94: aa 10 20 00 clr %l5
{
rtems_id sync_requester;
rtems_bdbuf_lock_cache ();
200db98: 7f ff f9 99 call 200c1fc <rtems_bdbuf_lock_cache>
200db9c: 01 00 00 00 nop
sync_requester = bdbuf_cache.sync_requester;
200dba0: e0 06 a0 34 ld [ %i2 + 0x34 ], %l0
bdbuf_cache.sync_active = false;
200dba4: c0 2e a0 30 clrb [ %i2 + 0x30 ]
bdbuf_cache.sync_requester = 0;
200dba8: c0 26 a0 34 clr [ %i2 + 0x34 ]
rtems_bdbuf_unlock_cache ();
200dbac: 7f ff fa 22 call 200c434 <rtems_bdbuf_unlock_cache>
200dbb0: 01 00 00 00 nop
if (sync_requester)
200dbb4: 80 a4 20 00 cmp %l0, 0
200dbb8: 02 80 00 06 be 200dbd0 <rtems_bdbuf_swapout_task+0x290> <== NEVER TAKEN
200dbbc: d4 07 bf cc ld [ %fp + -52 ], %o2
rtems_event_send (sync_requester, RTEMS_BDBUF_TRANSFER_SYNC);
200dbc0: 90 10 00 10 mov %l0, %o0
200dbc4: 7f ff e7 04 call 20077d4 <rtems_event_send>
200dbc8: 92 10 20 02 mov 2, %o1
*/
update_timers = false;
}
while (transfered_buffers);
sc = rtems_event_receive (RTEMS_BDBUF_SWAPOUT_SYNC,
200dbcc: d4 07 bf cc ld [ %fp + -52 ], %o2
200dbd0: 90 10 20 04 mov 4, %o0
200dbd4: 92 10 20 00 clr %o1
200dbd8: 7f ff e6 9e call 2007650 <rtems_event_receive>
200dbdc: 96 07 bf fc add %fp, -4, %o3
RTEMS_EVENT_ALL | RTEMS_WAIT,
period_in_ticks,
&out);
if ((sc != RTEMS_SUCCESSFUL) && (sc != RTEMS_TIMEOUT))
200dbe0: 80 a2 20 06 cmp %o0, 6
200dbe4: 02 bf ff b2 be 200daac <rtems_bdbuf_swapout_task+0x16c>
200dbe8: 80 a2 20 00 cmp %o0, 0
200dbec: 02 bf ff b0 be 200daac <rtems_bdbuf_swapout_task+0x16c> <== ALWAYS TAKEN
200dbf0: 11 10 80 00 sethi %hi(0x42000000), %o0
rtems_fatal_error_occurred (BLKDEV_FATAL_BDBUF_SWAPOUT_RE);
200dbf4: 7f ff e9 be call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dbf8: 90 12 20 18 or %o0, 0x18, %o0 ! 42000018 <RAM_END+0x3fc00018><== NOT EXECUTED
/*
* Extact all the buffers we find for a specific device. The device is
* the first one we find on a modified list. Process the sync queue of
* buffers first.
*/
if (rtems_bdbuf_swapout_processing (timer_delta,
200dbfc: 02 bf ff f4 be 200dbcc <rtems_bdbuf_swapout_task+0x28c>
200dc00: aa 10 20 00 clr %l5
rtems_bdbuf_swapout_transfer* transfer)
{
rtems_bdbuf_swapout_worker* worker;
bool transfered_buffers = false;
rtems_bdbuf_lock_cache ();
200dc04: 7f ff f9 7e call 200c1fc <rtems_bdbuf_lock_cache>
200dc08: 01 00 00 00 nop
* here. We do not know the worker is the last in a sequence of sync writes
* until after we have it running so we do not know to tell it to release the
* lock. The simplest solution is to get the main swap out task perform all
* sync operations.
*/
if (bdbuf_cache.sync_active)
200dc0c: c2 0c 60 30 ldub [ %l1 + 0x30 ], %g1
200dc10: a4 10 20 00 clr %l2
200dc14: 80 a0 60 00 cmp %g1, 0
200dc18: 12 bf ff b0 bne 200dad8 <rtems_bdbuf_swapout_task+0x198> <== NEVER TAKEN
200dc1c: a0 10 00 17 mov %l7, %l0
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
200dc20: 11 00 80 8b sethi %hi(0x2022c00), %o0
200dc24: 7f ff eb 39 call 2008908 <_Chain_Get>
200dc28: 90 12 23 80 or %o0, 0x380, %o0 ! 2022f80 <bdbuf_cache+0x8>
worker = NULL;
else
{
worker = (rtems_bdbuf_swapout_worker*)
rtems_chain_get (&bdbuf_cache.swapout_workers);
if (worker)
200dc2c: a4 92 20 00 orcc %o0, 0, %l2
200dc30: 12 bf ff aa bne 200dad8 <rtems_bdbuf_swapout_task+0x198> <== NEVER TAKEN
200dc34: a0 04 a0 10 add %l2, 0x10, %l0
200dc38: 10 bf ff a8 b 200dad8 <rtems_bdbuf_swapout_task+0x198>
200dc3c: a0 10 00 17 mov %l7, %l0
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WAKE);
}
else
{
rtems_bdbuf_swapout_write (transfer);
200dc40: 7f ff fe d0 call 200d780 <rtems_bdbuf_swapout_write>
200dc44: 90 10 00 10 mov %l0, %o0
200dc48: 10 bf ff ce b 200db80 <rtems_bdbuf_swapout_task+0x240>
200dc4c: 82 10 20 01 mov 1, %g1
static void
rtems_bdbuf_swapout_workers_close (void)
{
rtems_chain_node* node;
rtems_bdbuf_lock_cache ();
200dc50: 7f ff f9 6b call 200c1fc <rtems_bdbuf_lock_cache> <== NOT EXECUTED
200dc54: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
200dc58: e0 06 e0 08 ld [ %i3 + 8 ], %l0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200dc5c: b6 06 e0 0c add %i3, 0xc, %i3 <== NOT EXECUTED
node = rtems_chain_first (&bdbuf_cache.swapout_workers);
while (!rtems_chain_is_tail (&bdbuf_cache.swapout_workers, node))
200dc60: 80 a4 00 1b cmp %l0, %i3 <== NOT EXECUTED
200dc64: 02 80 00 0a be 200dc8c <rtems_bdbuf_swapout_task+0x34c> <== NOT EXECUTED
200dc68: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) node;
worker->enabled = false;
rtems_event_send (worker->id, RTEMS_BDBUF_SWAPOUT_SYNC);
200dc6c: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
node = rtems_chain_first (&bdbuf_cache.swapout_workers);
while (!rtems_chain_is_tail (&bdbuf_cache.swapout_workers, node))
{
rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) node;
worker->enabled = false;
200dc70: c0 2c 20 0c clrb [ %l0 + 0xc ] <== NOT EXECUTED
rtems_event_send (worker->id, RTEMS_BDBUF_SWAPOUT_SYNC);
200dc74: 7f ff e6 d8 call 20077d4 <rtems_event_send> <== NOT EXECUTED
200dc78: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
200dc7c: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED
rtems_chain_node* node;
rtems_bdbuf_lock_cache ();
node = rtems_chain_first (&bdbuf_cache.swapout_workers);
while (!rtems_chain_is_tail (&bdbuf_cache.swapout_workers, node))
200dc80: 80 a4 00 1b cmp %l0, %i3 <== NOT EXECUTED
200dc84: 32 bf ff fb bne,a 200dc70 <rtems_bdbuf_swapout_task+0x330><== NOT EXECUTED
200dc88: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
worker->enabled = false;
rtems_event_send (worker->id, RTEMS_BDBUF_SWAPOUT_SYNC);
node = rtems_chain_next (node);
}
rtems_bdbuf_unlock_cache ();
200dc8c: 7f ff f9 ea call 200c434 <rtems_bdbuf_unlock_cache> <== NOT EXECUTED
200dc90: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (BLKDEV_FATAL_BDBUF_SWAPOUT_RE);
}
rtems_bdbuf_swapout_workers_close ();
free (transfer.write_req);
200dc94: 7f ff d8 3f call 2003d90 <free> <== NOT EXECUTED
200dc98: d0 07 bf ec ld [ %fp + -20 ], %o0 <== NOT EXECUTED
rtems_task_delete (RTEMS_SELF);
200dc9c: 7f ff e8 c9 call 2007fc0 <rtems_task_delete> <== NOT EXECUTED
200dca0: 90 10 20 00 clr %o0 <== NOT EXECUTED
}
200dca4: 81 c7 e0 08 ret <== NOT EXECUTED
200dca8: 81 e8 00 00 restore <== NOT EXECUTED
if (worker)
{
rtems_status_code sc = rtems_event_send (worker->id,
RTEMS_BDBUF_SWAPOUT_SYNC);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WAKE);
200dcac: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200dcb0: 7f ff e9 8f call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dcb4: 90 12 20 14 or %o0, 0x14, %o0 ! 42000014 <RAM_END+0x3fc00014><== NOT EXECUTED
sc = rtems_task_start (worker->id,
rtems_bdbuf_swapout_worker_task,
(rtems_task_argument) worker);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_START);
200dcb8: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200dcbc: 7f ff e9 8c call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dcc0: 90 12 20 17 or %o0, 0x17, %o0 ! 42000017 <RAM_END+0x3fc00017><== NOT EXECUTED
SWAPOUT_TASK_STACK_SIZE,
RTEMS_PREEMPT | RTEMS_NO_TIMESLICE | RTEMS_NO_ASR,
RTEMS_LOCAL | RTEMS_NO_FLOATING_POINT,
&worker->id);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WK_CREATE);
200dcc4: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200dcc8: 7f ff e9 89 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dccc: 90 12 20 16 or %o0, 0x16, %o0 ! 42000016 <RAM_END+0x3fc00016><== NOT EXECUTED
{
rtems_bdbuf_swapout_worker* worker;
worker = malloc (sizeof (rtems_bdbuf_swapout_worker));
if (!worker)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
200dcd0: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200dcd4: 7f ff e9 86 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dcd8: 90 12 20 15 or %o0, 0x15, %o0 ! 42000015 <RAM_END+0x3fc00015><== NOT EXECUTED
0200dce0 <rtems_bdbuf_swapout_worker_task>:
* @param arg A pointer to the worker thread's private data.
* @return rtems_task Not used.
*/
static rtems_task
rtems_bdbuf_swapout_worker_task (rtems_task_argument arg)
{
200dce0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) arg;
while (worker->enabled)
200dce4: c2 0e 20 0c ldub [ %i0 + 0xc ], %g1 <== NOT EXECUTED
200dce8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200dcec: 02 80 00 1c be 200dd5c <rtems_bdbuf_swapout_worker_task+0x7c><== NOT EXECUTED
200dcf0: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
200dcf4: 2b 00 80 8b sethi %hi(0x2022c00), %l5 <== NOT EXECUTED
rtems_bdbuf_swapout_write (&worker->transfer);
rtems_bdbuf_lock_cache ();
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
200dcf8: 25 3f ff ff sethi %hi(0xfffffc00), %l2 <== 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 );
200dcfc: aa 15 63 80 or %l5, 0x380, %l5 <== NOT EXECUTED
200dd00: a4 14 a3 ff or %l2, 0x3ff, %l2 <== NOT EXECUTED
while (worker->enabled)
{
rtems_bdbuf_wait_for_event (RTEMS_BDBUF_SWAPOUT_SYNC);
rtems_bdbuf_swapout_write (&worker->transfer);
200dd04: a2 06 20 10 add %i0, 0x10, %l1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200dd08: a8 06 20 14 add %i0, 0x14, %l4 <== NOT EXECUTED
rtems_bdbuf_lock_cache ();
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
200dd0c: a6 10 00 12 mov %l2, %l3 <== NOT EXECUTED
{
rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) arg;
while (worker->enabled)
{
rtems_bdbuf_wait_for_event (RTEMS_BDBUF_SWAPOUT_SYNC);
200dd10: 7f ff fa 83 call 200c71c <rtems_bdbuf_wait_for_event> <== NOT EXECUTED
200dd14: 90 10 20 04 mov 4, %o0 <== NOT EXECUTED
rtems_bdbuf_swapout_write (&worker->transfer);
200dd18: 7f ff fe 9a call 200d780 <rtems_bdbuf_swapout_write> <== NOT EXECUTED
200dd1c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_bdbuf_lock_cache ();
200dd20: 7f ff f9 37 call 200c1fc <rtems_bdbuf_lock_cache> <== NOT EXECUTED
200dd24: 01 00 00 00 nop <== NOT EXECUTED
200dd28: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
200dd2c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200dd30: e8 24 20 10 st %l4, [ %l0 + 0x10 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
200dd34: c0 24 20 14 clr [ %l0 + 0x14 ] <== NOT EXECUTED
the_chain->last = _Chain_Head(the_chain);
200dd38: e2 24 20 18 st %l1, [ %l0 + 0x18 ] <== NOT EXECUTED
200dd3c: 7f ff ea dd call 20088b0 <_Chain_Append> <== NOT EXECUTED
200dd40: e4 3c 20 20 std %l2, [ %l0 + 0x20 ] <== NOT EXECUTED
rtems_chain_initialize_empty (&worker->transfer.bds);
worker->transfer.dev = BDBUF_INVALID_DEV;
rtems_chain_append (&bdbuf_cache.swapout_workers, &worker->link);
rtems_bdbuf_unlock_cache ();
200dd44: 7f ff f9 bc call 200c434 <rtems_bdbuf_unlock_cache> <== NOT EXECUTED
200dd48: 01 00 00 00 nop <== NOT EXECUTED
static rtems_task
rtems_bdbuf_swapout_worker_task (rtems_task_argument arg)
{
rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) arg;
while (worker->enabled)
200dd4c: c2 0c 20 0c ldub [ %l0 + 0xc ], %g1 <== NOT EXECUTED
200dd50: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200dd54: 12 bf ff ef bne 200dd10 <rtems_bdbuf_swapout_worker_task+0x30><== NOT EXECUTED
200dd58: 01 00 00 00 nop <== NOT EXECUTED
rtems_chain_append (&bdbuf_cache.swapout_workers, &worker->link);
rtems_bdbuf_unlock_cache ();
}
free (worker->transfer.write_req);
200dd5c: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED
200dd60: 7f ff d8 0c call 2003d90 <free> <== NOT EXECUTED
200dd64: b0 10 20 00 clr %i0 <== NOT EXECUTED
free (worker);
200dd68: 7f ff d8 0a call 2003d90 <free> <== NOT EXECUTED
200dd6c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_task_delete (RTEMS_SELF);
200dd70: 7f ff e8 94 call 2007fc0 <rtems_task_delete> <== NOT EXECUTED
200dd74: 81 e8 00 00 restore <== NOT EXECUTED
0200d780 <rtems_bdbuf_swapout_write>:
*
* @param transfer The transfer transaction.
*/
static void
rtems_bdbuf_swapout_write (rtems_bdbuf_swapout_transfer* transfer)
{
200d780: 9d e3 bf a0 save %sp, -96, %sp
printf ("bdbuf:swapout transfer: %08x\n", (unsigned) transfer->dev);
/*
* If there are buffers to transfer to the media transfer them.
*/
if (!rtems_chain_is_empty (&transfer->bds))
200d784: c2 06 00 00 ld [ %i0 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200d788: a2 06 20 04 add %i0, 4, %l1
200d78c: 80 a0 40 11 cmp %g1, %l1
200d790: 02 80 00 63 be 200d91c <rtems_bdbuf_swapout_write+0x19c> <== NEVER TAKEN
200d794: 01 00 00 00 nop
/*
* Obtain the disk device. The cache's mutex has been released to avoid a
* dead lock.
*/
rtems_disk_device *dd = rtems_disk_obtain (transfer->dev);
200d798: d0 1e 20 10 ldd [ %i0 + 0x10 ], %o0
200d79c: 7f ff d5 c9 call 2002ec0 <rtems_disk_obtain>
200d7a0: 2d 00 80 8a sethi %hi(0x2022800), %l6
if (dd == NULL)
200d7a4: a0 92 20 00 orcc %o0, 0, %l0
200d7a8: 02 80 00 64 be 200d938 <rtems_bdbuf_swapout_write+0x1b8>
200d7ac: ac 15 a0 60 or %l6, 0x60, %l6
dd = &null_disk;
bufs_per_bd = dd->block_size / bdbuf_config.buffer_min;
200d7b0: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
200d7b4: 27 00 80 83 sethi %hi(0x2020c00), %l3
200d7b8: a6 14 e3 ac or %l3, 0x3ac, %l3 ! 2020fac <rtems_bdbuf_configuration>
200d7bc: d2 04 e0 20 ld [ %l3 + 0x20 ], %o1
200d7c0: 40 00 45 eb call 201ef6c <.udiv>
200d7c4: a4 10 20 00 clr %l2
* should be possible to make this change with little effect in this
* code. The array that is passed is broken in design and should be
* removed. Merging members of a struct into the first member is
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
200d7c8: c2 06 20 1c ld [ %i0 + 0x1c ], %g1
* Perform the transfer if there are no more buffers, or the transfer
* size has reached the configured max. value.
*/
if (rtems_chain_is_empty (&transfer->bds) ||
(transfer->write_req->bufnum >= bdbuf_config.max_write_blocks))
200d7cc: e6 04 e0 04 ld [ %l3 + 4 ], %l3
* should be possible to make this change with little effect in this
* code. The array that is passed is broken in design and should be
* removed. Merging members of a struct into the first member is
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
200d7d0: 84 10 20 0c mov 0xc, %g2
rtems_disk_device *dd = rtems_disk_obtain (transfer->dev);
if (dd == NULL)
dd = &null_disk;
bufs_per_bd = dd->block_size / bdbuf_config.buffer_min;
200d7d4: aa 10 00 08 mov %o0, %l5
* code. The array that is passed is broken in design and should be
* removed. Merging members of a struct into the first member is
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
transfer->write_req->bufnum = 0;
200d7d8: c0 20 60 10 clr [ %g1 + 0x10 ]
* should be possible to make this change with little effect in this
* code. The array that is passed is broken in design and should be
* removed. Merging members of a struct into the first member is
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
200d7dc: c4 20 60 0c st %g2, [ %g1 + 0xc ]
if (write)
{
rtems_bdbuf_execute_transfer_request (dd, transfer->write_req, false);
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
200d7e0: a8 10 20 0c mov 0xc, %l4
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
200d7e4: 7f ff ec 49 call 2008908 <_Chain_Get>
200d7e8: 90 10 00 18 mov %i0, %o0
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
transfer->write_req->bufnum = 0;
while ((node = rtems_chain_get(&transfer->bds)) != NULL)
200d7ec: 80 a2 20 00 cmp %o0, 0
200d7f0: 02 80 00 29 be 200d894 <rtems_bdbuf_swapout_write+0x114> <== NEVER TAKEN
200d7f4: 80 a4 00 16 cmp %l0, %l6
printf ("bdbuf:swapout write: bd:%" PRIu32 ", bufnum:%" PRIu32 " mode:%s\n",
bd->block, transfer->write_req->bufnum,
dd->phys_dev->capabilities &
RTEMS_BLKDEV_CAP_MULTISECTOR_CONT ? "MULIT" : "SCAT");
if ((dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) &&
200d7f8: c2 04 20 08 ld [ %l0 + 8 ], %g1
200d7fc: c2 00 60 0c ld [ %g1 + 0xc ], %g1
200d800: 80 88 60 01 btst 1, %g1
200d804: 02 80 00 31 be 200d8c8 <rtems_bdbuf_swapout_write+0x148> <== ALWAYS TAKEN
200d808: d2 06 20 1c ld [ %i0 + 0x1c ], %o1
transfer->write_req->bufnum &&
200d80c: c2 02 60 10 ld [ %o1 + 0x10 ], %g1 <== NOT EXECUTED
printf ("bdbuf:swapout write: bd:%" PRIu32 ", bufnum:%" PRIu32 " mode:%s\n",
bd->block, transfer->write_req->bufnum,
dd->phys_dev->capabilities &
RTEMS_BLKDEV_CAP_MULTISECTOR_CONT ? "MULIT" : "SCAT");
if ((dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) &&
200d810: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200d814: 02 80 00 2f be 200d8d0 <rtems_bdbuf_swapout_write+0x150> <== NOT EXECUTED
200d818: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
transfer->write_req->bufnum &&
(bd->block != (last_block + bufs_per_bd)))
200d81c: c6 02 20 20 ld [ %o0 + 0x20 ], %g3 <== NOT EXECUTED
200d820: 84 04 80 15 add %l2, %l5, %g2 <== NOT EXECUTED
200d824: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
200d828: 02 80 00 2a be 200d8d0 <rtems_bdbuf_swapout_write+0x150> <== NOT EXECUTED
200d82c: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200d830: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
200d834: 40 00 13 51 call 2012578 <_Chain_Insert> <== NOT EXECUTED
200d838: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
200d83c: d2 06 20 1c ld [ %i0 + 0x1c ], %o1 <== NOT EXECUTED
200d840: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
/*
* Perform the transfer if there are no more buffers, or the transfer
* size has reached the configured max. value.
*/
if (rtems_chain_is_empty (&transfer->bds) ||
200d844: c2 06 00 00 ld [ %i0 ], %g1
200d848: 80 a4 40 01 cmp %l1, %g1
200d84c: 02 80 00 07 be 200d868 <rtems_bdbuf_swapout_write+0xe8>
200d850: 94 10 20 00 clr %o2
200d854: c2 02 60 10 ld [ %o1 + 0x10 ], %g1
200d858: 80 a0 40 13 cmp %g1, %l3
200d85c: 0a 80 00 2d bcs 200d910 <rtems_bdbuf_swapout_write+0x190>
200d860: 80 88 a0 ff btst 0xff, %g2
(transfer->write_req->bufnum >= bdbuf_config.max_write_blocks))
write = true;
if (write)
{
rtems_bdbuf_execute_transfer_request (dd, transfer->write_req, false);
200d864: 94 10 20 00 clr %o2
200d868: 7f ff ff 65 call 200d5fc <rtems_bdbuf_execute_transfer_request>
200d86c: 90 10 00 10 mov %l0, %o0
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
200d870: c2 06 20 1c ld [ %i0 + 0x1c ], %g1
200d874: 90 10 00 18 mov %i0, %o0
transfer->write_req->bufnum = 0;
200d878: c0 20 60 10 clr [ %g1 + 0x10 ]
200d87c: 7f ff ec 23 call 2008908 <_Chain_Get>
200d880: e8 20 60 0c st %l4, [ %g1 + 0xc ]
* trouble waiting to happen.
*/
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
transfer->write_req->bufnum = 0;
while ((node = rtems_chain_get(&transfer->bds)) != NULL)
200d884: 80 a2 20 00 cmp %o0, 0
200d888: 32 bf ff dd bne,a 200d7fc <rtems_bdbuf_swapout_write+0x7c>
200d88c: c2 04 20 08 ld [ %l0 + 8 ], %g1
transfer->write_req->status = RTEMS_RESOURCE_IN_USE;
transfer->write_req->bufnum = 0;
}
}
if (dd != &null_disk)
200d890: 80 a4 00 16 cmp %l0, %l6
200d894: 02 80 00 22 be 200d91c <rtems_bdbuf_swapout_write+0x19c> <== NEVER TAKEN
200d898: 01 00 00 00 nop
{
/*
* If sync'ing and the deivce is capability of handling a sync IO control
* call perform the call.
*/
if (transfer->syncing &&
200d89c: c2 0e 20 18 ldub [ %i0 + 0x18 ], %g1
200d8a0: 80 a0 60 00 cmp %g1, 0
200d8a4: 02 80 00 07 be 200d8c0 <rtems_bdbuf_swapout_write+0x140>
200d8a8: 01 00 00 00 nop
(dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_SYNC))
200d8ac: d0 04 20 08 ld [ %l0 + 8 ], %o0
{
/*
* If sync'ing and the deivce is capability of handling a sync IO control
* call perform the call.
*/
if (transfer->syncing &&
200d8b0: c2 02 20 0c ld [ %o0 + 0xc ], %g1
200d8b4: 80 88 60 02 btst 2, %g1
200d8b8: 32 80 00 1b bne,a 200d924 <rtems_bdbuf_swapout_write+0x1a4><== NEVER TAKEN
200d8bc: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
{
/* int result = */ dd->ioctl (dd->phys_dev, RTEMS_BLKDEV_REQ_SYNC, NULL);
/* How should the error be handled ? */
}
rtems_disk_release (dd);
200d8c0: 7f ff d5 6b call 2002e6c <rtems_disk_release>
200d8c4: 91 e8 00 10 restore %g0, %l0, %o0
printf ("bdbuf:swapout write: bd:%" PRIu32 ", bufnum:%" PRIu32 " mode:%s\n",
bd->block, transfer->write_req->bufnum,
dd->phys_dev->capabilities &
RTEMS_BLKDEV_CAP_MULTISECTOR_CONT ? "MULIT" : "SCAT");
if ((dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) &&
200d8c8: c2 02 60 10 ld [ %o1 + 0x10 ], %g1
}
else
{
rtems_blkdev_sg_buffer* buf;
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
200d8cc: 84 00 60 01 add %g1, 1, %g2
200d8d0: c4 22 60 10 st %g2, [ %o1 + 0x10 ]
buf->user = bd;
buf->block = bd->block;
200d8d4: c6 02 20 20 ld [ %o0 + 0x20 ], %g3
200d8d8: 85 28 60 04 sll %g1, 4, %g2
200d8dc: 84 02 40 02 add %o1, %g2, %g2
200d8e0: c6 20 a0 18 st %g3, [ %g2 + 0x18 ]
buf->length = dd->block_size;
buf->buffer = bd->buffer;
200d8e4: c6 02 20 24 ld [ %o0 + 0x24 ], %g3
rtems_blkdev_sg_buffer* buf;
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
buf->user = bd;
buf->block = bd->block;
buf->length = dd->block_size;
200d8e8: c8 04 20 20 ld [ %l0 + 0x20 ], %g4
else
{
rtems_blkdev_sg_buffer* buf;
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
buf->user = bd;
200d8ec: 82 00 60 02 add %g1, 2, %g1
buf->block = bd->block;
buf->length = dd->block_size;
200d8f0: c8 20 a0 1c st %g4, [ %g2 + 0x1c ]
else
{
rtems_blkdev_sg_buffer* buf;
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
buf->user = bd;
200d8f4: 83 28 60 04 sll %g1, 4, %g1
buf->block = bd->block;
buf->length = dd->block_size;
buf->buffer = bd->buffer;
last_block = bd->block;
200d8f8: e4 02 20 20 ld [ %o0 + 0x20 ], %l2
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
buf->user = bd;
buf->block = bd->block;
buf->length = dd->block_size;
buf->buffer = bd->buffer;
200d8fc: c6 22 40 01 st %g3, [ %o1 + %g1 ]
last_block = bd->block;
200d900: 84 10 20 00 clr %g2
else
{
rtems_blkdev_sg_buffer* buf;
buf = &transfer->write_req->bufs[transfer->write_req->bufnum];
transfer->write_req->bufnum++;
buf->user = bd;
200d904: 82 02 40 01 add %o1, %g1, %g1
200d908: 10 bf ff cf b 200d844 <rtems_bdbuf_swapout_write+0xc4>
200d90c: d0 20 60 04 st %o0, [ %g1 + 4 ]
if (rtems_chain_is_empty (&transfer->bds) ||
(transfer->write_req->bufnum >= bdbuf_config.max_write_blocks))
write = true;
if (write)
200d910: 02 bf ff b5 be 200d7e4 <rtems_bdbuf_swapout_write+0x64> <== ALWAYS TAKEN
200d914: 94 10 20 00 clr %o2
200d918: 30 bf ff d4 b,a 200d868 <rtems_bdbuf_swapout_write+0xe8> <== NOT EXECUTED
200d91c: 81 c7 e0 08 ret <== NOT EXECUTED
200d920: 81 e8 00 00 restore <== NOT EXECUTED
* call perform the call.
*/
if (transfer->syncing &&
(dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_SYNC))
{
/* int result = */ dd->ioctl (dd->phys_dev, RTEMS_BLKDEV_REQ_SYNC, NULL);
200d924: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
200d928: 9f c0 40 00 call %g1 <== NOT EXECUTED
200d92c: 94 10 20 00 clr %o2 <== NOT EXECUTED
/* How should the error be handled ? */
}
rtems_disk_release (dd);
200d930: 7f ff d5 4f call 2002e6c <rtems_disk_release> <== NOT EXECUTED
200d934: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
* Obtain the disk device. The cache's mutex has been released to avoid a
* dead lock.
*/
rtems_disk_device *dd = rtems_disk_obtain (transfer->dev);
if (dd == NULL)
200d938: 10 bf ff 9e b 200d7b0 <rtems_bdbuf_swapout_write+0x30>
200d93c: a0 10 00 16 mov %l6, %l0
0200cd40 <rtems_bdbuf_swapout_writereq_alloc>:
*
* @return rtems_blkdev_request* The write reference memory.
*/
static rtems_blkdev_request*
rtems_bdbuf_swapout_writereq_alloc (void)
{
200cd40: 9d e3 bf a0 save %sp, -96, %sp
* I am disappointment at finding code like this in RTEMS. The request should
* have been a rtems_chain_control. Simple, fast and less storage as the node
* is already part of the buffer structure.
*/
rtems_blkdev_request* write_req =
malloc (sizeof (rtems_blkdev_request) +
200cd44: 03 00 80 83 sethi %hi(0x2020c00), %g1
200cd48: d0 00 63 b0 ld [ %g1 + 0x3b0 ], %o0 ! 2020fb0 <rtems_bdbuf_configuration+0x4>
200cd4c: 91 2a 20 04 sll %o0, 4, %o0
200cd50: 7f ff dc f8 call 2004130 <malloc>
200cd54: 90 02 20 18 add %o0, 0x18, %o0
(bdbuf_config.max_write_blocks * sizeof (rtems_blkdev_sg_buffer)));
if (!write_req)
200cd58: a0 92 20 00 orcc %o0, 0, %l0
200cd5c: 02 80 00 0c be 200cd8c <rtems_bdbuf_swapout_writereq_alloc+0x4c><== NEVER TAKEN
200cd60: 82 10 20 01 mov 1, %g1
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
write_req->req = RTEMS_BLKDEV_REQ_WRITE;
200cd64: c2 24 00 00 st %g1, [ %l0 ]
write_req->req_done = rtems_bdbuf_transfer_done;
200cd68: 03 00 80 31 sethi %hi(0x200c400), %g1
200cd6c: 82 10 62 fc or %g1, 0x2fc, %g1 ! 200c6fc <rtems_bdbuf_transfer_done>
write_req->done_arg = write_req;
200cd70: e0 24 20 08 st %l0, [ %l0 + 8 ]
if (!write_req)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
write_req->req = RTEMS_BLKDEV_REQ_WRITE;
write_req->req_done = rtems_bdbuf_transfer_done;
200cd74: c2 24 20 04 st %g1, [ %l0 + 4 ]
write_req->done_arg = write_req;
write_req->io_task = rtems_task_self ();
200cd78: 40 00 15 2e call 2012230 <rtems_task_self>
200cd7c: b0 10 00 10 mov %l0, %i0
200cd80: d0 24 20 14 st %o0, [ %l0 + 0x14 ]
return write_req;
}
200cd84: 81 c7 e0 08 ret
200cd88: 81 e8 00 00 restore
rtems_blkdev_request* write_req =
malloc (sizeof (rtems_blkdev_request) +
(bdbuf_config.max_write_blocks * sizeof (rtems_blkdev_sg_buffer)));
if (!write_req)
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_NOMEM);
200cd8c: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200cd90: 7f ff ed 57 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200cd94: 90 12 20 15 or %o0, 0x15, %o0 ! 42000015 <RAM_END+0x3fc00015><== NOT EXECUTED
0200dd7c <rtems_bdbuf_sync>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_bdbuf_sync (rtems_bdbuf_buffer *bd)
{
200dd7c: 9d e3 bf a0 save %sp, -96, %sp
}
static rtems_status_code
rtems_bdbuf_check_bd_and_lock_cache (rtems_bdbuf_buffer *bd, const char *kind)
{
if (!bdbuf_cache.initialised)
200dd80: 21 00 80 8b sethi %hi(0x2022c00), %l0
200dd84: a0 14 23 78 or %l0, 0x378, %l0 ! 2022f78 <bdbuf_cache>
200dd88: c2 0c 20 88 ldub [ %l0 + 0x88 ], %g1
200dd8c: 80 a0 60 00 cmp %g1, 0
200dd90: 02 80 00 1b be 200ddfc <rtems_bdbuf_sync+0x80> <== NEVER TAKEN
200dd94: 82 10 20 16 mov 0x16, %g1
return RTEMS_NOT_CONFIGURED;
if (bd == NULL)
200dd98: 80 a6 20 00 cmp %i0, 0
200dd9c: 02 80 00 18 be 200ddfc <rtems_bdbuf_sync+0x80> <== NEVER TAKEN
200dda0: 82 10 20 09 mov 9, %g1
if (rtems_bdbuf_tracer)
{
printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);
rtems_bdbuf_show_users (kind, bd);
}
rtems_bdbuf_lock_cache();
200dda4: 7f ff f9 16 call 200c1fc <rtems_bdbuf_lock_cache>
200dda8: 01 00 00 00 nop
sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "sync");
if (sc != RTEMS_SUCCESSFUL)
return sc;
switch (bd->state)
200ddac: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200ddb0: 80 a0 60 03 cmp %g1, 3
200ddb4: 0a 80 00 07 bcs 200ddd0 <rtems_bdbuf_sync+0x54> <== NEVER TAKEN
200ddb8: 80 a0 60 05 cmp %g1, 5
200ddbc: 28 80 00 12 bleu,a 200de04 <rtems_bdbuf_sync+0x88>
200ddc0: 82 10 20 08 mov 8, %g1
200ddc4: 80 a0 60 06 cmp %g1, 6
200ddc8: 02 80 00 08 be 200dde8 <rtems_bdbuf_sync+0x6c> <== ALWAYS TAKEN
200ddcc: 01 00 00 00 nop
break;
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_5);
200ddd0: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200ddd4: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200ddd8: 82 10 60 03 or %g1, 3, %g1 ! 42000003 <RAM_END+0x3fc00003><== NOT EXECUTED
200dddc: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200dde0: 7f ff e9 43 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200dde4: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
case RTEMS_BDBUF_STATE_ACCESS_EMPTY:
case RTEMS_BDBUF_STATE_ACCESS_MODIFIED:
rtems_bdbuf_sync_after_access (bd);
break;
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
rtems_bdbuf_discard_buffer_after_access (bd);
200dde8: 7f ff fd 0d call 200d21c <rtems_bdbuf_discard_buffer_after_access>
200ddec: 90 10 00 18 mov %i0, %o0
}
if (rtems_bdbuf_tracer)
rtems_bdbuf_show_usage ();
rtems_bdbuf_unlock_cache ();
200ddf0: 7f ff f9 91 call 200c434 <rtems_bdbuf_unlock_cache>
200ddf4: 01 00 00 00 nop
200ddf8: 82 10 20 00 clr %g1 ! 0 <PROM_START>
return RTEMS_SUCCESSFUL;
}
200ddfc: 81 c7 e0 08 ret
200de00: 91 e8 00 01 restore %g0, %g1, %o0
200de04: 90 04 20 5c add %l0, 0x5c, %o0
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200de08: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
200de0c: 7f ff ea a9 call 20088b0 <_Chain_Append>
200de10: 92 10 00 18 mov %i0, %o1
{
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_SYNC);
rtems_chain_append (&bdbuf_cache.sync, &bd->link);
if (bd->waiters)
200de14: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
200de18: 80 a0 60 00 cmp %g1, 0
200de1c: 12 80 00 2b bne 200dec8 <rtems_bdbuf_sync+0x14c>
200de20: 01 00 00 00 nop
rtems_bdbuf_wake (&bdbuf_cache.access_waiters);
rtems_bdbuf_wake_swapper ();
200de24: 7f ff f9 e7 call 200c5c0 <rtems_bdbuf_wake_swapper>
200de28: 21 00 80 8b sethi %hi(0x2022c00), %l0
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
return;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200de2c: a0 14 23 e8 or %l0, 0x3e8, %l0 ! 2022fe8 <bdbuf_cache+0x70>
static void
rtems_bdbuf_wait_for_sync_done (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200de30: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200de34: 80 a0 60 01 cmp %g1, 1
200de38: 1a 80 00 08 bcc 200de58 <rtems_bdbuf_sync+0xdc> <== ALWAYS TAKEN
200de3c: 80 a0 60 07 cmp %g1, 7
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
break;
default:
rtems_bdbuf_fatal (bd->state, RTEMS_BLKDEV_FATAL_BDBUF_STATE_9);
200de40: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
#endif
static void
rtems_bdbuf_fatal (rtems_bdbuf_buf_state state, uint32_t error)
{
rtems_fatal_error_occurred ((((uint32_t) state) << 16) | error);
200de44: 03 10 80 00 sethi %hi(0x42000000), %g1 <== NOT EXECUTED
200de48: 82 10 60 07 or %g1, 7, %g1 ! 42000007 <RAM_END+0x3fc00007><== NOT EXECUTED
200de4c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
200de50: 7f ff e9 27 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200de54: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
static void
rtems_bdbuf_wait_for_sync_done (rtems_bdbuf_buffer *bd)
{
while (true)
{
switch (bd->state)
200de58: 08 80 00 08 bleu 200de78 <rtems_bdbuf_sync+0xfc>
200de5c: 80 a0 60 0a cmp %g1, 0xa
200de60: 18 bf ff f8 bgu 200de40 <rtems_bdbuf_sync+0xc4> <== NEVER TAKEN
200de64: 01 00 00 00 nop
case RTEMS_BDBUF_STATE_ACCESS_PURGED:
return;
case RTEMS_BDBUF_STATE_SYNC:
case RTEMS_BDBUF_STATE_TRANSFER:
case RTEMS_BDBUF_STATE_TRANSFER_PURGED:
rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);
200de68: 90 10 00 18 mov %i0, %o0
200de6c: 7f ff fa a4 call 200c8fc <rtems_bdbuf_wait>
200de70: 92 10 00 10 mov %l0, %o1
200de74: 30 bf ff ef b,a 200de30 <rtems_bdbuf_sync+0xb4>
/*
* We may have created a cached or empty buffer which may be recycled.
*/
if (bd->waiters == 0
&& (bd->state == RTEMS_BDBUF_STATE_CACHED
200de78: c2 06 20 2c ld [ %i0 + 0x2c ], %g1
rtems_bdbuf_wait_for_sync_done (bd);
/*
* We may have created a cached or empty buffer which may be recycled.
*/
if (bd->waiters == 0
200de7c: 80 a0 60 00 cmp %g1, 0
200de80: 12 bf ff dc bne 200ddf0 <rtems_bdbuf_sync+0x74>
200de84: 01 00 00 00 nop
&& (bd->state == RTEMS_BDBUF_STATE_CACHED
|| bd->state == RTEMS_BDBUF_STATE_EMPTY))
200de88: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
rtems_bdbuf_wait_for_sync_done (bd);
/*
* We may have created a cached or empty buffer which may be recycled.
*/
if (bd->waiters == 0
200de8c: 80 a0 60 02 cmp %g1, 2
200de90: 02 80 00 06 be 200dea8 <rtems_bdbuf_sync+0x12c>
200de94: 01 00 00 00 nop
&& (bd->state == RTEMS_BDBUF_STATE_CACHED
|| bd->state == RTEMS_BDBUF_STATE_EMPTY))
200de98: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
rtems_bdbuf_wait_for_sync_done (bd);
/*
* We may have created a cached or empty buffer which may be recycled.
*/
if (bd->waiters == 0
200de9c: 80 a0 60 01 cmp %g1, 1
200dea0: 12 bf ff d4 bne 200ddf0 <rtems_bdbuf_sync+0x74> <== NEVER TAKEN
200dea4: 01 00 00 00 nop
&& (bd->state == RTEMS_BDBUF_STATE_CACHED
|| bd->state == RTEMS_BDBUF_STATE_EMPTY))
{
if (bd->state == RTEMS_BDBUF_STATE_EMPTY)
200dea8: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
200deac: 80 a0 60 01 cmp %g1, 1
200deb0: 02 80 00 09 be 200ded4 <rtems_bdbuf_sync+0x158>
200deb4: 01 00 00 00 nop
{
rtems_bdbuf_remove_from_tree (bd);
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
}
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200deb8: 11 00 80 8b sethi %hi(0x2022c00), %o0
200debc: 7f ff f8 d8 call 200c21c <rtems_bdbuf_wake>
200dec0: 90 12 23 f0 or %o0, 0x3f0, %o0 ! 2022ff0 <bdbuf_cache+0x78>
200dec4: 30 bf ff cb b,a 200ddf0 <rtems_bdbuf_sync+0x74>
rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_SYNC);
rtems_chain_append (&bdbuf_cache.sync, &bd->link);
if (bd->waiters)
rtems_bdbuf_wake (&bdbuf_cache.access_waiters);
200dec8: 7f ff f8 d5 call 200c21c <rtems_bdbuf_wake>
200decc: 90 04 20 68 add %l0, 0x68, %o0
200ded0: 30 bf ff d5 b,a 200de24 <rtems_bdbuf_sync+0xa8>
&& (bd->state == RTEMS_BDBUF_STATE_CACHED
|| bd->state == RTEMS_BDBUF_STATE_EMPTY))
{
if (bd->state == RTEMS_BDBUF_STATE_EMPTY)
{
rtems_bdbuf_remove_from_tree (bd);
200ded4: 7f ff fb b2 call 200cd9c <rtems_bdbuf_remove_from_tree>
200ded8: 90 10 00 18 mov %i0, %o0
RTEMS_INLINE_ROUTINE void _Chain_Prepend(
Chain_Control *the_chain,
Chain_Node *the_node
)
{
_Chain_Insert(_Chain_Head(the_chain), the_node);
200dedc: 92 10 00 18 mov %i0, %o1
}
static void
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{
bd->state = state;
200dee0: c0 26 20 28 clr [ %i0 + 0x28 ]
200dee4: 11 00 80 8b sethi %hi(0x2022c00), %o0
200dee8: 40 00 11 a4 call 2012578 <_Chain_Insert>
200deec: 90 12 23 bc or %o0, 0x3bc, %o0 ! 2022fbc <bdbuf_cache+0x44>
if (bd->state == RTEMS_BDBUF_STATE_EMPTY)
{
rtems_bdbuf_remove_from_tree (bd);
rtems_bdbuf_make_free_and_add_to_lru_list (bd);
}
rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);
200def0: 10 bf ff f3 b 200debc <rtems_bdbuf_sync+0x140>
200def4: 11 00 80 8b sethi %hi(0x2022c00), %o0
0200c768 <rtems_bdbuf_syncdev>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_bdbuf_syncdev (dev_t dev)
{
200c768: 9d e3 bf 98 save %sp, -104, %sp
rtems_disk_device *dd = NULL;
if (rtems_bdbuf_tracer)
printf ("bdbuf:syncdev: %08x\n", (unsigned) dev);
sc = rtems_bdbuf_obtain_disk (dev, 0, &dd, NULL, NULL);
200c76c: 94 10 20 00 clr %o2
200c770: 90 10 00 18 mov %i0, %o0
rtems_status_code
rtems_bdbuf_syncdev (dev_t dev)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *dd = NULL;
200c774: c0 27 bf fc clr [ %fp + -4 ]
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_bdbuf_syncdev (dev_t dev)
{
200c778: a0 10 00 18 mov %i0, %l0
rtems_disk_device *dd = NULL;
if (rtems_bdbuf_tracer)
printf ("bdbuf:syncdev: %08x\n", (unsigned) dev);
sc = rtems_bdbuf_obtain_disk (dev, 0, &dd, NULL, NULL);
200c77c: 92 10 00 19 mov %i1, %o1
200c780: 96 07 bf fc add %fp, -4, %o3
200c784: 98 10 20 00 clr %o4
200c788: 9a 10 20 00 clr %o5
200c78c: 7f ff ff 42 call 200c494 <rtems_bdbuf_obtain_disk>
200c790: a2 10 00 19 mov %i1, %l1
if (sc != RTEMS_SUCCESSFUL)
200c794: b0 92 20 00 orcc %o0, 0, %i0
200c798: 12 80 00 19 bne 200c7fc <rtems_bdbuf_syncdev+0x94> <== NEVER TAKEN
200c79c: 25 00 80 8b sethi %hi(0x2022c00), %l2
* Lock the cache's sync. A single task can nest calls.
*/
static void
rtems_bdbuf_lock_sync (void)
{
rtems_bdbuf_lock (bdbuf_cache.sync_lock, RTEMS_BLKDEV_FATAL_BDBUF_SYNC_LOCK);
200c7a0: a4 14 a3 78 or %l2, 0x378, %l2 ! 2022f78 <bdbuf_cache>
200c7a4: d0 04 a0 2c ld [ %l2 + 0x2c ], %o0
200c7a8: 13 10 80 00 sethi %hi(0x42000000), %o1
200c7ac: 7f ff fe 87 call 200c1c8 <rtems_bdbuf_lock>
200c7b0: 92 12 60 0b or %o1, 0xb, %o1 ! 4200000b <RAM_END+0x3fc0000b>
* can lock the cache. If another thread has the sync lock it will cause this
* thread to block until it owns the sync lock then it can own the cache. The
* sync lock can only be obtained with the cache unlocked.
*/
rtems_bdbuf_lock_sync ();
rtems_bdbuf_lock_cache ();
200c7b4: 7f ff fe 92 call 200c1fc <rtems_bdbuf_lock_cache>
200c7b8: 01 00 00 00 nop
* out task know the id of the requester to wake when done.
*
* The swap out task will negate the sync active flag when no more buffers
* for the device are held on the "modified for sync" queues.
*/
bdbuf_cache.sync_active = true;
200c7bc: 82 10 20 01 mov 1, %g1 ! 1 <PROM_START+0x1>
200c7c0: c2 2c a0 30 stb %g1, [ %l2 + 0x30 ]
bdbuf_cache.sync_requester = rtems_task_self ();
200c7c4: 40 00 16 9b call 2012230 <rtems_task_self>
200c7c8: 01 00 00 00 nop
200c7cc: d0 24 a0 34 st %o0, [ %l2 + 0x34 ]
bdbuf_cache.sync_device = dev;
200c7d0: e0 3c a0 38 std %l0, [ %l2 + 0x38 ]
rtems_bdbuf_wake_swapper ();
200c7d4: 7f ff ff 7b call 200c5c0 <rtems_bdbuf_wake_swapper>
200c7d8: 01 00 00 00 nop
rtems_bdbuf_unlock_cache ();
200c7dc: 7f ff ff 16 call 200c434 <rtems_bdbuf_unlock_cache>
200c7e0: 01 00 00 00 nop
rtems_bdbuf_wait_for_event (RTEMS_BDBUF_TRANSFER_SYNC);
200c7e4: 7f ff ff ce call 200c71c <rtems_bdbuf_wait_for_event>
200c7e8: 90 10 20 02 mov 2, %o0 ! 2 <PROM_START+0x2>
rtems_bdbuf_unlock_sync ();
200c7ec: 7f ff ff 1e call 200c464 <rtems_bdbuf_unlock_sync>
200c7f0: 01 00 00 00 nop
rtems_bdbuf_release_disk (dd);
200c7f4: 7f ff ff 68 call 200c594 <rtems_bdbuf_release_disk>
200c7f8: d0 07 bf fc ld [ %fp + -4 ], %o0
return RTEMS_SUCCESSFUL;
}
200c7fc: 81 c7 e0 08 ret
200c800: 81 e8 00 00 restore
0200c434 <rtems_bdbuf_unlock_cache>:
/**
* Unlock the cache.
*/
static void
rtems_bdbuf_unlock_cache (void)
{
200c434: 9d e3 bf a0 save %sp, -96, %sp
* @param fatal_error_code The error code if the call fails.
*/
static void
rtems_bdbuf_unlock (rtems_id lock, uint32_t fatal_error_code)
{
rtems_status_code sc = rtems_semaphore_release (lock);
200c438: 03 00 80 8b sethi %hi(0x2022c00), %g1
200c43c: 7f ff ee 6a call 2007de4 <rtems_semaphore_release>
200c440: d0 00 63 a0 ld [ %g1 + 0x3a0 ], %o0 ! 2022fa0 <bdbuf_cache+0x28>
if (sc != RTEMS_SUCCESSFUL)
200c444: 80 a2 20 00 cmp %o0, 0
200c448: 12 80 00 04 bne 200c458 <rtems_bdbuf_unlock_cache+0x24> <== NEVER TAKEN
200c44c: 11 10 80 00 sethi %hi(0x42000000), %o0
200c450: 81 c7 e0 08 ret
200c454: 81 e8 00 00 restore
rtems_fatal_error_occurred (fatal_error_code);
200c458: 7f ff ef a5 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c45c: 90 12 20 0e or %o0, 0xe, %o0 <== NOT EXECUTED
0200c464 <rtems_bdbuf_unlock_sync>:
/**
* Unlock the cache's sync lock. Any blocked writers are woken.
*/
static void
rtems_bdbuf_unlock_sync (void)
{
200c464: 9d e3 bf a0 save %sp, -96, %sp
* @param fatal_error_code The error code if the call fails.
*/
static void
rtems_bdbuf_unlock (rtems_id lock, uint32_t fatal_error_code)
{
rtems_status_code sc = rtems_semaphore_release (lock);
200c468: 03 00 80 8b sethi %hi(0x2022c00), %g1
200c46c: 7f ff ee 5e call 2007de4 <rtems_semaphore_release>
200c470: d0 00 63 a4 ld [ %g1 + 0x3a4 ], %o0 ! 2022fa4 <bdbuf_cache+0x2c>
if (sc != RTEMS_SUCCESSFUL)
200c474: 80 a2 20 00 cmp %o0, 0
200c478: 12 80 00 04 bne 200c488 <rtems_bdbuf_unlock_sync+0x24> <== NEVER TAKEN
200c47c: 11 10 80 00 sethi %hi(0x42000000), %o0
200c480: 81 c7 e0 08 ret
200c484: 81 e8 00 00 restore
rtems_fatal_error_occurred (fatal_error_code);
200c488: 7f ff ef 99 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c48c: 90 12 20 0c or %o0, 0xc, %o0 <== NOT EXECUTED
0200c71c <rtems_bdbuf_wait_for_event>:
return RTEMS_UNSATISFIED;
}
static void
rtems_bdbuf_wait_for_event (rtems_event_set event)
{
200c71c: 9d e3 bf 98 save %sp, -104, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_event_set out = 0;
sc = rtems_event_receive (event,
200c720: 92 10 20 00 clr %o1
static void
rtems_bdbuf_wait_for_event (rtems_event_set event)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_event_set out = 0;
200c724: c0 27 bf fc clr [ %fp + -4 ]
sc = rtems_event_receive (event,
200c728: 90 10 00 18 mov %i0, %o0
200c72c: 94 10 20 00 clr %o2
200c730: 7f ff eb c8 call 2007650 <rtems_event_receive>
200c734: 96 07 bf fc add %fp, -4, %o3
RTEMS_EVENT_ALL | RTEMS_WAIT,
RTEMS_NO_TIMEOUT,
&out);
if (sc != RTEMS_SUCCESSFUL || out != event)
200c738: 80 a2 20 00 cmp %o0, 0
200c73c: 12 80 00 07 bne 200c758 <rtems_bdbuf_wait_for_event+0x3c> <== NEVER TAKEN
200c740: c2 07 bf fc ld [ %fp + -4 ], %g1
200c744: 80 a0 40 18 cmp %g1, %i0
200c748: 12 80 00 05 bne 200c75c <rtems_bdbuf_wait_for_event+0x40> <== NEVER TAKEN
200c74c: 11 10 80 00 sethi %hi(0x42000000), %o0
200c750: 81 c7 e0 08 ret
200c754: 81 e8 00 00 restore
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_WAIT_EVNT);
200c758: 11 10 80 00 sethi %hi(0x42000000), %o0 <== NOT EXECUTED
200c75c: 7f ff ee e4 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c760: 90 12 20 1a or %o0, 0x1a, %o0 ! 4200001a <RAM_END+0x3fc0001a><== NOT EXECUTED
0200c21c <rtems_bdbuf_wake>:
* Wake a blocked resource. The resource has a counter that lets us know if
* there are any waiters.
*/
static void
rtems_bdbuf_wake (const rtems_bdbuf_waiters *waiters)
{
200c21c: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
if (waiters->count > 0)
200c220: c2 06 00 00 ld [ %i0 ], %g1
200c224: 80 a0 60 00 cmp %g1, 0
200c228: 12 80 00 04 bne 200c238 <rtems_bdbuf_wake+0x1c>
200c22c: 01 00 00 00 nop
200c230: 81 c7 e0 08 ret
200c234: 81 e8 00 00 restore
{
sc = rtems_semaphore_flush (waiters->sema);
200c238: 40 00 17 6e call 2011ff0 <rtems_semaphore_flush>
200c23c: d0 06 20 04 ld [ %i0 + 4 ], %o0
if (sc != RTEMS_SUCCESSFUL)
200c240: 80 a2 20 00 cmp %o0, 0
200c244: 02 bf ff fb be 200c230 <rtems_bdbuf_wake+0x14> <== ALWAYS TAKEN
200c248: 11 10 80 00 sethi %hi(0x42000000), %o0
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_CACHE_WAKE);
200c24c: 7f ff f0 28 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c250: 90 12 20 13 or %o0, 0x13, %o0 ! 42000013 <RAM_END+0x3fc00013><== NOT EXECUTED
0200c5c0 <rtems_bdbuf_wake_swapper>:
}
}
static void
rtems_bdbuf_wake_swapper (void)
{
200c5c0: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = rtems_event_send (bdbuf_cache.swapout,
200c5c4: 03 00 80 8b sethi %hi(0x2022c00), %g1
200c5c8: d0 00 63 78 ld [ %g1 + 0x378 ], %o0 ! 2022f78 <bdbuf_cache>
200c5cc: 7f ff ec 82 call 20077d4 <rtems_event_send>
200c5d0: 92 10 20 04 mov 4, %o1
RTEMS_BDBUF_SWAPOUT_SYNC);
if (sc != RTEMS_SUCCESSFUL)
200c5d4: 80 a2 20 00 cmp %o0, 0
200c5d8: 12 80 00 04 bne 200c5e8 <rtems_bdbuf_wake_swapper+0x28> <== NEVER TAKEN
200c5dc: 11 10 80 00 sethi %hi(0x42000000), %o0
200c5e0: 81 c7 e0 08 ret
200c5e4: 81 e8 00 00 restore
rtems_fatal_error_occurred (RTEMS_BLKDEV_FATAL_BDBUF_SO_WAKE);
200c5e8: 7f ff ef 41 call 20082ec <rtems_fatal_error_occurred> <== NOT EXECUTED
200c5ec: 90 12 20 14 or %o0, 0x14, %o0 <== NOT EXECUTED
020270b8 <rtems_bdpart_create>:
const rtems_bdpart_format *format,
rtems_bdpart_partition *pt,
const unsigned *dist,
size_t count
)
{
20270b8: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
20270bc: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20270c0: 22 80 00 07 be,a 20270dc <rtems_bdpart_create+0x24> <== NOT EXECUTED
20270c4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
&& format->type == RTEMS_BDPART_FORMAT_MBR
20270c8: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
20270cc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20270d0: 22 80 00 7b be,a 20272bc <rtems_bdpart_create+0x204> <== NOT EXECUTED
20270d4: c2 0e 60 08 ldub [ %i1 + 8 ], %g1 <== NOT EXECUTED
&& format->mbr.dos_compatibility;
rtems_blkdev_bnum disk_end = 0;
20270d8: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
20270dc: a2 10 20 00 clr %l1 <== NOT EXECUTED
20270e0: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
rtems_blkdev_bnum free_space = 0;
dev_t disk = 0;
size_t i = 0;
/* Check if we have something to do */
if (count == 0) {
20270e4: 80 a7 20 00 cmp %i4, 0 <== NOT EXECUTED
20270e8: 02 80 00 73 be 20272b4 <rtems_bdpart_create+0x1fc> <== NOT EXECUTED
20270ec: a6 10 20 00 clr %l3 <== NOT EXECUTED
/* Nothing to do */
return RTEMS_SUCCESSFUL;
}
/* Check parameter */
if (format == NULL || pt == NULL || dist == NULL) {
20270f0: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
20270f4: 02 80 00 78 be 20272d4 <rtems_bdpart_create+0x21c> <== NOT EXECUTED
20270f8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20270fc: 02 80 00 76 be 20272d4 <rtems_bdpart_create+0x21c> <== NOT EXECUTED
2027100: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2027104: 02 80 00 74 be 20272d4 <rtems_bdpart_create+0x21c> <== NOT EXECUTED
2027108: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_blkdev_bnum dist_sum = 0;
rtems_blkdev_bnum record_space =
dos_compatibility ? RTEMS_BDPART_MBR_CYLINDER_SIZE : 1;
rtems_blkdev_bnum overhead = 0;
rtems_blkdev_bnum free_space = 0;
dev_t disk = 0;
202710c: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
2027110: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
if (format == NULL || pt == NULL || dist == NULL) {
return RTEMS_INVALID_ADDRESS;
}
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
2027114: 92 07 bf f0 add %fp, -16, %o1 <== NOT EXECUTED
2027118: 40 00 01 b1 call 20277dc <rtems_bdpart_get_disk_data> <== NOT EXECUTED
202711c: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027120: a6 92 20 00 orcc %o0, 0, %l3 <== NOT EXECUTED
2027124: 12 80 00 64 bne 20272b4 <rtems_bdpart_create+0x1fc> <== NOT EXECUTED
2027128: 82 10 20 00 clr %g1 <== NOT EXECUTED
/* Get distribution sum and check for overflow */
for (i = 0; i < count; ++i) {
unsigned prev_sum = dist_sum;
dist_sum += dist [i];
202712c: e8 06 c0 00 ld [ %i3 ], %l4 <== NOT EXECUTED
if (dist_sum < prev_sum) {
return RTEMS_INVALID_NUMBER;
}
if (dist [i] == 0) {
2027130: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
2027134: 12 80 00 0b bne 2027160 <rtems_bdpart_create+0xa8> <== NOT EXECUTED
2027138: a4 10 00 14 mov %l4, %l2 <== NOT EXECUTED
}
/* Expand the last partition to the disk end */
pt [count - 1].end = disk_end;
return RTEMS_SUCCESSFUL;
202713c: 10 80 00 6a b 20272e4 <rtems_bdpart_create+0x22c> <== NOT EXECUTED
2027140: a6 10 20 0a mov 0xa, %l3 <== NOT EXECUTED
/* Get distribution sum and check for overflow */
for (i = 0; i < count; ++i) {
unsigned prev_sum = dist_sum;
dist_sum += dist [i];
2027144: c4 06 c0 02 ld [ %i3 + %g2 ], %g2 <== NOT EXECUTED
2027148: 86 04 80 02 add %l2, %g2, %g3 <== NOT EXECUTED
if (dist_sum < prev_sum) {
202714c: 80 a0 c0 12 cmp %g3, %l2 <== NOT EXECUTED
2027150: 0a 80 00 64 bcs 20272e0 <rtems_bdpart_create+0x228> <== NOT EXECUTED
2027154: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
}
if (dist [i] == 0) {
2027158: 02 80 00 62 be 20272e0 <rtems_bdpart_create+0x228> <== NOT EXECUTED
202715c: a4 10 00 03 mov %g3, %l2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
return sc;
}
/* Get distribution sum and check for overflow */
for (i = 0; i < count; ++i) {
2027160: 82 00 60 01 inc %g1 <== NOT EXECUTED
2027164: 80 a7 00 01 cmp %i4, %g1 <== NOT EXECUTED
2027168: 18 bf ff f7 bgu 2027144 <rtems_bdpart_create+0x8c> <== NOT EXECUTED
202716c: 85 28 60 02 sll %g1, 2, %g2 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
}
}
/* Check format */
if (format->type != RTEMS_BDPART_FORMAT_MBR) {
2027170: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
2027174: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2027178: 12 80 00 5d bne 20272ec <rtems_bdpart_create+0x234> <== NOT EXECUTED
202717c: a2 8c 60 ff andcc %l1, 0xff, %l1 <== NOT EXECUTED
return RTEMS_NOT_IMPLEMENTED;
}
/* Align end of disk on cylinder boundary if necessary */
if (dos_compatibility) {
2027180: 12 80 00 5d bne 20272f4 <rtems_bdpart_create+0x23c> <== NOT EXECUTED
2027184: fa 07 bf fc ld [ %fp + -4 ], %i5 <== NOT EXECUTED
/*
* In case we need an extended partition and logical partitions we have to
* account for the space of each EBR.
*/
if (count > 4) {
2027188: 80 a7 20 04 cmp %i4, 4 <== NOT EXECUTED
202718c: 08 80 00 06 bleu 20271a4 <rtems_bdpart_create+0xec> <== NOT EXECUTED
2027190: ac 10 00 10 mov %l0, %l6 <== NOT EXECUTED
overhead += (count - 3) * record_space;
2027194: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2027198: 7f ff 6e 7d call 2002b8c <.umul> <== NOT EXECUTED
202719c: 92 07 3f fd add %i4, -3, %o1 <== NOT EXECUTED
20271a0: ac 02 00 10 add %o0, %l0, %l6 <== NOT EXECUTED
/*
* Account space to align every partition on cylinder boundaries if
* necessary.
*/
if (dos_compatibility) {
20271a4: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
20271a8: 02 80 00 07 be 20271c4 <rtems_bdpart_create+0x10c> <== NOT EXECUTED
20271ac: 82 05 80 1c add %l6, %i4, %g1 <== NOT EXECUTED
overhead += (count - 1) * record_space;
20271b0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20271b4: 7f ff 6e 76 call 2002b8c <.umul> <== NOT EXECUTED
20271b8: 92 07 3f ff add %i4, -1, %o1 <== NOT EXECUTED
20271bc: ac 05 80 08 add %l6, %o0, %l6 <== NOT EXECUTED
}
/* Check disk space */
if ((overhead + count) > disk_end) {
20271c0: 82 05 80 1c add %l6, %i4, %g1 <== NOT EXECUTED
20271c4: 80 a0 40 1d cmp %g1, %i5 <== NOT EXECUTED
20271c8: 18 80 00 50 bgu 2027308 <rtems_bdpart_create+0x250> <== NOT EXECUTED
20271cc: ac 27 40 16 sub %i5, %l6, %l6 <== NOT EXECUTED
for (i = 0; i < count; ++i) {
rtems_bdpart_partition *p = pt + i;
/* Partition size */
rtems_blkdev_bnum s = free_space * dist [i];
20271d0: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20271d4: 7f ff 6e 6e call 2002b8c <.umul> <== NOT EXECUTED
20271d8: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
if (s < free_space || s < dist [i]) {
20271dc: 80 a5 80 08 cmp %l6, %o0 <== NOT EXECUTED
20271e0: 18 80 00 40 bgu 20272e0 <rtems_bdpart_create+0x228> <== NOT EXECUTED
20271e4: 80 a2 00 14 cmp %o0, %l4 <== NOT EXECUTED
20271e8: 0a 80 00 3e bcs 20272e0 <rtems_bdpart_create+0x228> <== NOT EXECUTED
20271ec: 80 a7 20 04 cmp %i4, 4 <== NOT EXECUTED
20271f0: 18 80 00 03 bgu 20271fc <rtems_bdpart_create+0x144> <== NOT EXECUTED
20271f4: ae 10 20 01 mov 1, %l7 <== NOT EXECUTED
20271f8: ae 10 20 00 clr %l7 <== NOT EXECUTED
p->begin = pos;
pos += s;
p->end = pos;
/* Reserve space for the EBR if necessary */
if (count > 4 && i > 2) {
20271fc: ae 0d e0 ff and %l7, 0xff, %l7 <== NOT EXECUTED
for (i = 0; i < count; ++i) {
rtems_bdpart_partition *p = pt + i;
/* Partition size */
rtems_blkdev_bnum s = free_space * dist [i];
if (s < free_space || s < dist [i]) {
2027200: a8 10 00 1a mov %i2, %l4 <== NOT EXECUTED
2027204: b0 10 00 1a mov %i2, %i0 <== NOT EXECUTED
2027208: b2 10 00 10 mov %l0, %i1 <== NOT EXECUTED
202720c: 10 80 00 0c b 202723c <rtems_bdpart_create+0x184> <== NOT EXECUTED
2027210: a2 10 20 00 clr %l1 <== NOT EXECUTED
for (i = 0; i < count; ++i) {
rtems_bdpart_partition *p = pt + i;
/* Partition size */
rtems_blkdev_bnum s = free_space * dist [i];
2027214: f0 06 c0 01 ld [ %i3 + %g1 ], %i0 <== NOT EXECUTED
if (s < free_space || s < dist [i]) {
2027218: a8 05 20 30 add %l4, 0x30, %l4 <== NOT EXECUTED
for (i = 0; i < count; ++i) {
rtems_bdpart_partition *p = pt + i;
/* Partition size */
rtems_blkdev_bnum s = free_space * dist [i];
202721c: 7f ff 6e 5c call 2002b8c <.umul> <== NOT EXECUTED
2027220: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
if (s < free_space || s < dist [i]) {
2027224: 80 a5 80 08 cmp %l6, %o0 <== NOT EXECUTED
2027228: 18 80 00 2e bgu 20272e0 <rtems_bdpart_create+0x228> <== NOT EXECUTED
202722c: 80 a6 00 08 cmp %i0, %o0 <== NOT EXECUTED
2027230: 38 80 00 2d bgu,a 20272e4 <rtems_bdpart_create+0x22c> <== NOT EXECUTED
2027234: a6 10 20 0a mov 0xa, %l3 <== NOT EXECUTED
2027238: b0 10 00 14 mov %l4, %i0 <== NOT EXECUTED
/* TODO: Calculate without overflow */
return RTEMS_INVALID_NUMBER;
}
s /= dist_sum;
202723c: 40 00 ed d2 call 2062984 <.udiv> <== NOT EXECUTED
2027240: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
if (s == 0) {
s = 1;
}
/* Align partition upwards */
s += record_space - (s % record_space);
2027244: aa 06 40 10 add %i1, %l0, %l5 <== NOT EXECUTED
rtems_blkdev_bnum s = free_space * dist [i];
if (s < free_space || s < dist [i]) {
/* TODO: Calculate without overflow */
return RTEMS_INVALID_NUMBER;
}
s /= dist_sum;
2027248: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
/* Ensure that the partition is not empty */
if (s == 0) {
202724c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027250: 12 80 00 03 bne 202725c <rtems_bdpart_create+0x1a4> <== NOT EXECUTED
2027254: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2027258: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
/* Align partition upwards */
s += record_space - (s % record_space);
/* Partition begin and end */
p->begin = pos;
202725c: f2 26 00 00 st %i1, [ %i0 ] <== NOT EXECUTED
pos += s;
2027260: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
2027264: 40 00 ee 74 call 2062c34 <.urem> <== NOT EXECUTED
2027268: b2 00 40 15 add %g1, %l5, %i1 <== NOT EXECUTED
202726c: b2 26 40 08 sub %i1, %o0, %i1 <== NOT EXECUTED
p->end = pos;
2027270: f2 26 20 04 st %i1, [ %i0 + 4 ] <== NOT EXECUTED
/* Reserve space for the EBR if necessary */
if (count > 4 && i > 2) {
2027274: 80 a4 60 02 cmp %l1, 2 <== NOT EXECUTED
2027278: 08 80 00 05 bleu 202728c <rtems_bdpart_create+0x1d4> <== NOT EXECUTED
202727c: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
2027280: 80 a5 e0 00 cmp %l7, 0 <== NOT EXECUTED
2027284: 32 80 00 02 bne,a 202728c <rtems_bdpart_create+0x1d4> <== NOT EXECUTED
2027288: ea 26 00 00 st %l5, [ %i0 ] <== NOT EXECUTED
pos = record_space;
/* Space for partitions */
free_space = disk_end - overhead;
for (i = 0; i < count; ++i) {
202728c: a2 04 60 01 inc %l1 <== NOT EXECUTED
2027290: 80 a7 00 11 cmp %i4, %l1 <== NOT EXECUTED
2027294: 18 bf ff e0 bgu 2027214 <rtems_bdpart_create+0x15c> <== NOT EXECUTED
2027298: 83 2c 60 02 sll %l1, 2, %g1 <== NOT EXECUTED
p->begin += record_space;
}
}
/* Expand the last partition to the disk end */
pt [count - 1].end = disk_end;
202729c: b8 07 3f ff add %i4, -1, %i4 <== NOT EXECUTED
20272a0: 83 2f 20 06 sll %i4, 6, %g1 <== NOT EXECUTED
20272a4: b9 2f 20 04 sll %i4, 4, %i4 <== NOT EXECUTED
20272a8: 82 20 40 1c sub %g1, %i4, %g1 <== NOT EXECUTED
20272ac: b4 06 80 01 add %i2, %g1, %i2 <== NOT EXECUTED
20272b0: fa 26 a0 04 st %i5, [ %i2 + 4 ] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
20272b4: 81 c7 e0 08 ret <== NOT EXECUTED
20272b8: 91 e8 00 13 restore %g0, %l3, %o0 <== NOT EXECUTED
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
&& format->type == RTEMS_BDPART_FORMAT_MBR
&& format->mbr.dos_compatibility;
20272bc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20272c0: 02 bf ff 87 be 20270dc <rtems_bdpart_create+0x24> <== NOT EXECUTED
20272c4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_blkdev_bnum disk_end = 0;
20272c8: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
20272cc: 10 bf ff 86 b 20270e4 <rtems_bdpart_create+0x2c> <== NOT EXECUTED
20272d0: a0 10 20 3f mov 0x3f, %l0 <== NOT EXECUTED
}
/* Expand the last partition to the disk end */
pt [count - 1].end = disk_end;
return RTEMS_SUCCESSFUL;
20272d4: a6 10 20 09 mov 9, %l3 <== NOT EXECUTED
}
20272d8: 81 c7 e0 08 ret <== NOT EXECUTED
20272dc: 91 e8 00 13 restore %g0, %l3, %o0 <== NOT EXECUTED
}
/* Expand the last partition to the disk end */
pt [count - 1].end = disk_end;
return RTEMS_SUCCESSFUL;
20272e0: a6 10 20 0a mov 0xa, %l3 <== NOT EXECUTED
}
20272e4: 81 c7 e0 08 ret <== NOT EXECUTED
20272e8: 91 e8 00 13 restore %g0, %l3, %o0 <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
}
}
/* Check format */
if (format->type != RTEMS_BDPART_FORMAT_MBR) {
20272ec: 10 bf ff f2 b 20272b4 <rtems_bdpart_create+0x1fc> <== NOT EXECUTED
20272f0: a6 10 20 18 mov 0x18, %l3 <== NOT EXECUTED
return RTEMS_NOT_IMPLEMENTED;
}
/* Align end of disk on cylinder boundary if necessary */
if (dos_compatibility) {
disk_end -= (disk_end % record_space);
20272f4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20272f8: 40 00 ee 4f call 2062c34 <.urem> <== NOT EXECUTED
20272fc: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
2027300: 10 bf ff a2 b 2027188 <rtems_bdpart_create+0xd0> <== NOT EXECUTED
2027304: ba 27 40 08 sub %i5, %o0, %i5 <== NOT EXECUTED
if (dos_compatibility) {
overhead += (count - 1) * record_space;
}
/* Check disk space */
if ((overhead + count) > disk_end) {
2027308: 10 bf ff eb b 20272b4 <rtems_bdpart_create+0x1fc> <== NOT EXECUTED
202730c: a6 10 20 1b mov 0x1b, %l3 <== NOT EXECUTED
02027310 <rtems_bdpart_dump>:
{
uuid_unparse_lower( type, str);
}
void rtems_bdpart_dump( const rtems_bdpart_partition *pt, size_t count)
{
2027310: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
size_t i = 0;
printf(
2027314: 11 00 81 a9 sethi %hi(0x206a400), %o0 <== NOT EXECUTED
2027318: 40 00 9f 01 call 204ef1c <puts> <== NOT EXECUTED
202731c: 90 12 21 a0 or %o0, 0x1a0, %o0 ! 206a5a0 <C.51.7970+0x40> <== NOT EXECUTED
"------------+------------+-----------------------------------------------------\n"
" BEGIN | END | TYPE\n"
"------------+------------+-----------------------------------------------------\n"
);
for (i = 0; i < count; ++i) {
2027320: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2027324: 02 80 00 45 be 2027438 <rtems_bdpart_dump+0x128> <== NOT EXECUTED
2027328: 11 00 81 a9 sethi %hi(0x206a400), %o0 <== NOT EXECUTED
202732c: 25 00 81 a9 sethi %hi(0x206a400), %l2 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_16:
type = "FAT 16";
break;
case RTEMS_BDPART_MBR_FAT_16_LBA:
type = "FAT 16 LBA";
break;
2027330: 29 00 81 a9 sethi %hi(0x206a400), %l4 <== NOT EXECUTED
break;
case RTEMS_BDPART_MBR_DATA:
type = "DATA";
break;
default:
snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
2027334: 37 00 81 a9 sethi %hi(0x206a400), %i3 <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
2027338: 2d 00 81 a9 sethi %hi(0x206a400), %l6 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_32:
type = "FAT 32";
break;
case RTEMS_BDPART_MBR_FAT_32_LBA:
type = "FAT 32 LBA";
break;
202733c: 3b 00 81 a9 sethi %hi(0x206a400), %i5 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_16_LBA:
type = "FAT 16 LBA";
break;
case RTEMS_BDPART_MBR_FAT_32:
type = "FAT 32";
break;
2027340: 39 00 81 a9 sethi %hi(0x206a400), %i4 <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
2027344: 2b 00 81 a9 sethi %hi(0x206a400), %l5 <== NOT EXECUTED
2027348: 2f 00 81 a9 sethi %hi(0x206a400), %l7 <== NOT EXECUTED
} else {
rtems_bdpart_type_to_string( p->type, type_buffer);
type = type_buffer;
}
printf(
202734c: a4 14 a3 28 or %l2, 0x328, %l2 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_16:
type = "FAT 16";
break;
case RTEMS_BDPART_MBR_FAT_16_LBA:
type = "FAT 16 LBA";
break;
2027350: a8 15 23 00 or %l4, 0x300, %l4 <== NOT EXECUTED
break;
case RTEMS_BDPART_MBR_DATA:
type = "DATA";
break;
default:
snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
2027354: b6 16 e3 20 or %i3, 0x320, %i3 <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
2027358: ac 15 a2 f0 or %l6, 0x2f0, %l6 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_32:
type = "FAT 32";
break;
case RTEMS_BDPART_MBR_FAT_32_LBA:
type = "FAT 32 LBA";
break;
202735c: ba 17 63 18 or %i5, 0x318, %i5 <== NOT EXECUTED
case RTEMS_BDPART_MBR_FAT_16_LBA:
type = "FAT 16 LBA";
break;
case RTEMS_BDPART_MBR_FAT_32:
type = "FAT 32";
break;
2027360: b8 17 23 08 or %i4, 0x308, %i4 <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
2027364: aa 15 62 e8 or %l5, 0x2e8, %l5 <== NOT EXECUTED
2027368: ae 15 e2 e0 or %l7, 0x2e0, %l7 <== NOT EXECUTED
"------------+------------+-----------------------------------------------------\n"
" BEGIN | END | TYPE\n"
"------------+------------+-----------------------------------------------------\n"
);
for (i = 0; i < count; ++i) {
202736c: a0 10 20 00 clr %l0 <== NOT EXECUTED
2027370: a2 07 bf ff add %fp, -1, %l1 <== NOT EXECUTED
static void rtems_bdpart_type_to_string(
const uuid_t type,
char str [37]
)
{
uuid_unparse_lower( type, str);
2027374: 10 80 00 1c b 20273e4 <rtems_bdpart_dump+0xd4> <== NOT EXECUTED
2027378: a6 07 bf c8 add %fp, -56, %l3 <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
202737c: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
2027380: 02 80 00 11 be 20273c4 <rtems_bdpart_dump+0xb4> <== NOT EXECUTED
2027384: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
2027388: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
202738c: 18 80 00 2f bgu 2027448 <rtems_bdpart_dump+0x138> <== NOT EXECUTED
2027390: 80 a0 60 0e cmp %g1, 0xe <== NOT EXECUTED
2027394: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2027398: 02 80 00 0b be 20273c4 <rtems_bdpart_dump+0xb4> <== NOT EXECUTED
202739c: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
20273a0: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED
20273a4: 02 80 00 08 be 20273c4 <rtems_bdpart_dump+0xb4> <== NOT EXECUTED
20273a8: 96 10 00 17 mov %l7, %o3 <== NOT EXECUTED
break;
case RTEMS_BDPART_MBR_DATA:
type = "DATA";
break;
default:
snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
20273ac: 96 10 00 01 mov %g1, %o3 <== NOT EXECUTED
20273b0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
20273b4: 92 10 20 34 mov 0x34, %o1 <== NOT EXECUTED
20273b8: 40 00 a4 25 call 205044c <snprintf> <== NOT EXECUTED
20273bc: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
20273c0: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
} else {
rtems_bdpart_type_to_string( p->type, type_buffer);
type = type_buffer;
}
printf(
20273c4: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
20273c8: d4 06 20 04 ld [ %i0 + 4 ], %o2 <== NOT EXECUTED
20273cc: 40 00 9e 28 call 204ec6c <printf> <== NOT EXECUTED
20273d0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
"------------+------------+-----------------------------------------------------\n"
" BEGIN | END | TYPE\n"
"------------+------------+-----------------------------------------------------\n"
);
for (i = 0; i < count; ++i) {
20273d4: a0 04 20 01 inc %l0 <== NOT EXECUTED
20273d8: 80 a6 40 10 cmp %i1, %l0 <== NOT EXECUTED
20273dc: 08 80 00 16 bleu 2027434 <rtems_bdpart_dump+0x124> <== NOT EXECUTED
20273e0: b0 06 20 30 add %i0, 0x30, %i0 <== NOT EXECUTED
const rtems_bdpart_partition *p = pt + i;
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
20273e4: c0 2f bf ff clrb [ %fp + -1 ] <== NOT EXECUTED
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
20273e8: b4 06 20 08 add %i0, 8, %i2 <== NOT EXECUTED
20273ec: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20273f0: 40 00 01 19 call 2027854 <rtems_bdpart_to_mbr_partition_type><== NOT EXECUTED
20273f4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
20273f8: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
20273fc: 12 bf ff e0 bne 202737c <rtems_bdpart_dump+0x6c> <== NOT EXECUTED
2027400: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
static void rtems_bdpart_type_to_string(
const uuid_t type,
char str [37]
)
{
uuid_unparse_lower( type, str);
2027404: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2027408: 40 00 76 3d call 2044cfc <uuid_unparse_lower> <== NOT EXECUTED
202740c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
} else {
rtems_bdpart_type_to_string( p->type, type_buffer);
type = type_buffer;
}
printf(
2027410: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
2027414: d4 06 20 04 ld [ %i0 + 4 ], %o2 <== NOT EXECUTED
static void rtems_bdpart_type_to_string(
const uuid_t type,
char str [37]
)
{
uuid_unparse_lower( type, str);
2027418: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
} else {
rtems_bdpart_type_to_string( p->type, type_buffer);
type = type_buffer;
}
printf(
202741c: 40 00 9e 14 call 204ec6c <printf> <== NOT EXECUTED
2027420: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
"------------+------------+-----------------------------------------------------\n"
" BEGIN | END | TYPE\n"
"------------+------------+-----------------------------------------------------\n"
);
for (i = 0; i < count; ++i) {
2027424: a0 04 20 01 inc %l0 <== NOT EXECUTED
2027428: 80 a6 40 10 cmp %i1, %l0 <== NOT EXECUTED
202742c: 18 bf ff ee bgu 20273e4 <rtems_bdpart_dump+0xd4> <== NOT EXECUTED
2027430: b0 06 20 30 add %i0, 0x30, %i0 <== NOT EXECUTED
p->end,
type
);
}
puts( "------------+------------+-----------------------------------------------------");
2027434: 11 00 81 a9 sethi %hi(0x206a400), %o0 <== NOT EXECUTED
2027438: 40 00 9e b9 call 204ef1c <puts> <== NOT EXECUTED
202743c: 90 12 23 40 or %o0, 0x340, %o0 ! 206a740 <C.51.7970+0x1e0><== NOT EXECUTED
}
2027440: 81 c7 e0 08 ret <== NOT EXECUTED
2027444: 81 e8 00 00 restore <== NOT EXECUTED
const char *type = NULL;
char type_buffer [52];
uint8_t type_mbr = 0;
if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {
switch (type_mbr) {
2027448: 02 bf ff df be 20273c4 <rtems_bdpart_dump+0xb4> <== NOT EXECUTED
202744c: 96 10 00 16 mov %l6, %o3 <== NOT EXECUTED
2027450: 80 a0 60 da cmp %g1, 0xda <== NOT EXECUTED
2027454: 02 bf ff dc be 20273c4 <rtems_bdpart_dump+0xb4> <== NOT EXECUTED
2027458: 96 10 00 1d mov %i5, %o3 <== NOT EXECUTED
202745c: 80 a0 60 0c cmp %g1, 0xc <== NOT EXECUTED
2027460: 12 bf ff d3 bne 20273ac <rtems_bdpart_dump+0x9c> <== NOT EXECUTED
2027464: 96 10 00 1c mov %i4, %o3 <== NOT EXECUTED
} else {
rtems_bdpart_type_to_string( p->type, type_buffer);
type = type_buffer;
}
printf(
2027468: 10 bf ff d8 b 20273c8 <rtems_bdpart_dump+0xb8> <== NOT EXECUTED
202746c: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
020277dc <rtems_bdpart_get_disk_data>:
rtems_status_code rtems_bdpart_get_disk_data(
const char *disk_name,
dev_t *disk,
rtems_blkdev_bnum *disk_end
)
{
20277dc: 9d e3 bf 58 save %sp, -168, %sp <== NOT EXECUTED
rtems_blkdev_bnum block_size = 0;
rtems_disk_device *dd = NULL;
struct stat st;
/* Get disk handle */
rv = stat( disk_name, &st);
20277e0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20277e4: 7f ff 8a ef call 200a3a0 <stat> <== NOT EXECUTED
20277e8: 92 07 bf b8 add %fp, -72, %o1 <== NOT EXECUTED
if (rv != 0) {
20277ec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20277f0: 02 80 00 04 be 2027800 <rtems_bdpart_get_disk_data+0x24> <== NOT EXECUTED
20277f4: d0 1f bf d0 ldd [ %fp + -48 ], %o0 <== NOT EXECUTED
if (block_size < RTEMS_BDPART_BLOCK_SIZE) {
return RTEMS_IO_ERROR;
}
/* Check that we have do not have a logical disk */
if (disk_begin != 0) {
20277f8: 81 c7 e0 08 ret <== NOT EXECUTED
20277fc: 91 e8 20 03 restore %g0, 3, %o0 <== NOT EXECUTED
return RTEMS_INVALID_NAME;
}
*disk = st.st_rdev;
/* Get disk begin, end and block size */
dd = rtems_disk_obtain( *disk);
2027800: 7f ff 7f 24 call 2007490 <rtems_disk_obtain> <== NOT EXECUTED
2027804: d0 3e 40 00 std %o0, [ %i1 ] <== NOT EXECUTED
if (dd == NULL) {
2027808: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
202780c: 02 bf ff fb be 20277f8 <rtems_bdpart_get_disk_data+0x1c> <== NOT EXECUTED
2027810: 01 00 00 00 nop <== NOT EXECUTED
return RTEMS_INVALID_NAME;
}
disk_begin = dd->start;
*disk_end = dd->size;
2027814: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 <== NOT EXECUTED
/* Get disk begin, end and block size */
dd = rtems_disk_obtain( *disk);
if (dd == NULL) {
return RTEMS_INVALID_NAME;
}
disk_begin = dd->start;
2027818: f2 00 60 18 ld [ %g1 + 0x18 ], %i1 <== NOT EXECUTED
*disk_end = dd->size;
202781c: c4 26 80 00 st %g2, [ %i2 ] <== NOT EXECUTED
block_size = dd->block_size;
sc = rtems_disk_release( dd);
2027820: 7f ff 7f 07 call 200743c <rtems_disk_release> <== NOT EXECUTED
2027824: f4 00 60 20 ld [ %g1 + 0x20 ], %i2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027828: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
202782c: 12 80 00 06 bne 2027844 <rtems_bdpart_get_disk_data+0x68> <== NOT EXECUTED
2027830: 80 a6 a1 ff cmp %i2, 0x1ff <== NOT EXECUTED
return sc;
}
/* Check block size */
if (block_size < RTEMS_BDPART_BLOCK_SIZE) {
2027834: 08 80 00 06 bleu 202784c <rtems_bdpart_get_disk_data+0x70><== NOT EXECUTED
2027838: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
return RTEMS_IO_ERROR;
}
/* Check that we have do not have a logical disk */
if (disk_begin != 0) {
202783c: 12 80 00 04 bne 202784c <rtems_bdpart_get_disk_data+0x70> <== NOT EXECUTED
2027840: 01 00 00 00 nop <== NOT EXECUTED
return RTEMS_IO_ERROR;
}
return RTEMS_SUCCESSFUL;
}
2027844: 81 c7 e0 08 ret <== NOT EXECUTED
2027848: 81 e8 00 00 restore <== NOT EXECUTED
202784c: 81 c7 e0 08 ret <== NOT EXECUTED
2027850: 91 e8 20 1b restore %g0, 0x1b, %o0 <== NOT EXECUTED
020275a4 <rtems_bdpart_mount>:
const char *disk_name,
const rtems_bdpart_partition *pt __attribute__((unused)),
size_t count,
const char *mount_base
)
{
20275a4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code esc = RTEMS_SUCCESSFUL;
const char *disk_file_name = strrchr( disk_name, '/');
20275a8: 92 10 20 2f mov 0x2f, %o1 <== NOT EXECUTED
20275ac: 40 00 ab 0f call 20521e8 <strrchr> <== NOT EXECUTED
20275b0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20275b4: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
char *logical_disk_name = NULL;
char *logical_disk_marker = NULL;
char *mount_point = NULL;
char *mount_marker = NULL;
size_t disk_file_name_size = 0;
size_t disk_name_size = strlen( disk_name);
20275b8: 40 00 a7 6e call 2051370 <strlen> <== NOT EXECUTED
20275bc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20275c0: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
size_t mount_base_size = strlen( mount_base);
20275c4: 40 00 a7 6b call 2051370 <strlen> <== NOT EXECUTED
20275c8: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
const char *disk_name,
const rtems_bdpart_partition *pt __attribute__((unused)),
size_t count,
const char *mount_base
)
{
20275cc: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
char *logical_disk_marker = NULL;
char *mount_point = NULL;
char *mount_marker = NULL;
size_t disk_file_name_size = 0;
size_t disk_name_size = strlen( disk_name);
size_t mount_base_size = strlen( mount_base);
20275d0: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
size_t i = 0;
/* Create logical disk name base */
logical_disk_name = malloc( disk_name_size + RTEMS_BDPART_NUMBER_SIZE);
if (logical_disk_name == NULL) {
20275d4: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED
size_t disk_name_size = strlen( disk_name);
size_t mount_base_size = strlen( mount_base);
size_t i = 0;
/* Create logical disk name base */
logical_disk_name = malloc( disk_name_size + RTEMS_BDPART_NUMBER_SIZE);
20275d8: 7f ff 86 a2 call 2009060 <malloc> <== NOT EXECUTED
20275dc: 90 04 e0 04 add %l3, 4, %o0 <== NOT EXECUTED
if (logical_disk_name == NULL) {
20275e0: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
20275e4: 02 80 00 4d be 2027718 <rtems_bdpart_mount+0x174> <== NOT EXECUTED
20275e8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
}
strncpy( logical_disk_name, disk_name, disk_name_size);
20275ec: 40 00 a8 25 call 2051680 <strncpy> <== NOT EXECUTED
20275f0: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
/* Get disk file name */
if (disk_file_name != NULL) {
20275f4: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
20275f8: 02 80 00 06 be 2027610 <rtems_bdpart_mount+0x6c> <== NOT EXECUTED
20275fc: ac 10 00 13 mov %l3, %l6 <== NOT EXECUTED
disk_file_name += 1;
2027600: a2 04 a0 01 add %l2, 1, %l1 <== NOT EXECUTED
disk_file_name_size = strlen( disk_file_name);
2027604: 40 00 a7 5b call 2051370 <strlen> <== NOT EXECUTED
2027608: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202760c: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
disk_file_name = disk_name;
disk_file_name_size = disk_name_size;
}
/* Create mount point base */
mount_point = malloc( mount_base_size + 1 + disk_file_name_size + RTEMS_BDPART_NUMBER_SIZE);
2027610: a8 05 80 15 add %l6, %l5, %l4 <== NOT EXECUTED
if (mount_point == NULL) {
2027614: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED
disk_file_name = disk_name;
disk_file_name_size = disk_name_size;
}
/* Create mount point base */
mount_point = malloc( mount_base_size + 1 + disk_file_name_size + RTEMS_BDPART_NUMBER_SIZE);
2027618: 7f ff 86 92 call 2009060 <malloc> <== NOT EXECUTED
202761c: 90 05 20 05 add %l4, 5, %o0 <== NOT EXECUTED
if (mount_point == NULL) {
2027620: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2027624: 02 80 00 39 be 2027708 <rtems_bdpart_mount+0x164> <== NOT EXECUTED
2027628: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
esc = RTEMS_NO_MEMORY;
goto cleanup;
}
strncpy( mount_point, mount_base, mount_base_size);
202762c: 40 00 a8 15 call 2051680 <strncpy> <== NOT EXECUTED
2027630: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
mount_point [mount_base_size] = '/';
2027634: 82 10 20 2f mov 0x2f, %g1 <== NOT EXECUTED
strncpy( mount_point + mount_base_size + 1, disk_file_name, disk_file_name_size);
2027638: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202763c: 90 05 60 01 add %l5, 1, %o0 <== NOT EXECUTED
2027640: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
2027644: 90 04 80 08 add %l2, %o0, %o0 <== NOT EXECUTED
2027648: 40 00 a8 0e call 2051680 <strncpy> <== NOT EXECUTED
202764c: c2 2c 80 15 stb %g1, [ %l2 + %l5 ] <== NOT EXECUTED
/* Markers */
logical_disk_marker = logical_disk_name + disk_name_size;
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
2027650: a8 05 20 01 inc %l4 <== NOT EXECUTED
strncpy( mount_point, mount_base, mount_base_size);
mount_point [mount_base_size] = '/';
strncpy( mount_point + mount_base_size + 1, disk_file_name, disk_file_name_size);
/* Markers */
logical_disk_marker = logical_disk_name + disk_name_size;
2027654: a6 04 00 13 add %l0, %l3, %l3 <== NOT EXECUTED
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
2027658: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
202765c: 02 80 00 2a be 2027704 <rtems_bdpart_mount+0x160> <== NOT EXECUTED
2027660: a8 04 80 14 add %l2, %l4, %l4 <== NOT EXECUTED
2027664: 2b 00 81 a9 sethi %hi(0x206a400), %l5 <== NOT EXECUTED
esc = RTEMS_IO_ERROR;
goto cleanup;
}
/* Mount */
rv = mount(
2027668: 2d 00 81 a9 sethi %hi(0x206a400), %l6 <== NOT EXECUTED
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
/* Create logical disk name */
int rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
202766c: aa 15 63 90 or %l5, 0x390, %l5 <== NOT EXECUTED
esc = RTEMS_IO_ERROR;
goto cleanup;
}
/* Mount */
rv = mount(
2027670: ac 15 a3 98 or %l6, 0x398, %l6 <== NOT EXECUTED
/* Markers */
logical_disk_marker = logical_disk_name + disk_name_size;
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
2027674: 10 80 00 04 b 2027684 <rtems_bdpart_mount+0xe0> <== NOT EXECUTED
2027678: a2 10 20 00 clr %l1 <== NOT EXECUTED
202767c: 08 80 00 23 bleu 2027708 <rtems_bdpart_mount+0x164> <== NOT EXECUTED
2027680: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* Create logical disk name */
int rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
2027684: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
2027688: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
202768c: a2 04 60 01 inc %l1 <== NOT EXECUTED
2027690: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2027694: 40 00 a3 6e call 205044c <snprintf> <== NOT EXECUTED
2027698: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Create mount point */
strncpy( mount_marker, logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE);
202769c: 94 10 20 04 mov 4, %o2 <== NOT EXECUTED
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
/* Create logical disk name */
int rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
if (rv >= RTEMS_BDPART_NUMBER_SIZE) {
20276a0: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Create mount point */
strncpy( mount_marker, logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE);
20276a4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
/* Create logical disk name */
int rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
if (rv >= RTEMS_BDPART_NUMBER_SIZE) {
20276a8: 14 80 00 1e bg 2027720 <rtems_bdpart_mount+0x17c> <== NOT EXECUTED
20276ac: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Create mount point */
strncpy( mount_marker, logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE);
20276b0: 40 00 a7 f4 call 2051680 <strncpy> <== NOT EXECUTED
20276b4: 01 00 00 00 nop <== NOT EXECUTED
rv = rtems_mkdir( mount_point, S_IRWXU | S_IRWXG | S_IRWXO);
20276b8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20276bc: 7f ff 8a b9 call 200a1a0 <rtems_mkdir> <== NOT EXECUTED
20276c0: 92 10 21 ff mov 0x1ff, %o1 <== NOT EXECUTED
if (rv != 0) {
20276c4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20276c8: 12 80 00 1c bne 2027738 <rtems_bdpart_mount+0x194> <== NOT EXECUTED
20276cc: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
esc = RTEMS_IO_ERROR;
goto cleanup;
}
/* Mount */
rv = mount(
20276d0: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
20276d4: 96 10 20 00 clr %o3 <== NOT EXECUTED
20276d8: 98 10 20 00 clr %o4 <== NOT EXECUTED
20276dc: 7f ff 87 52 call 2009424 <mount> <== NOT EXECUTED
20276e0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
mount_point,
"msdos",
0,
NULL
);
if (rv != 0) {
20276e4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20276e8: 02 bf ff e5 be 202767c <rtems_bdpart_mount+0xd8> <== NOT EXECUTED
20276ec: 80 a6 80 11 cmp %i2, %l1 <== NOT EXECUTED
rmdir( mount_point);
20276f0: 40 00 1b 64 call 202e480 <rmdir> <== NOT EXECUTED
20276f4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
/* Markers */
logical_disk_marker = logical_disk_name + disk_name_size;
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
20276f8: 80 a6 80 11 cmp %i2, %l1 <== NOT EXECUTED
20276fc: 18 bf ff e3 bgu 2027688 <rtems_bdpart_mount+0xe4> <== NOT EXECUTED
2027700: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
2027704: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
}
cleanup:
free( logical_disk_name);
2027708: 7f ff 84 75 call 20088dc <free> <== NOT EXECUTED
202770c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
free( mount_point);
2027710: 7f ff 84 73 call 20088dc <free> <== NOT EXECUTED
2027714: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
return esc;
}
2027718: 81 c7 e0 08 ret <== NOT EXECUTED
202771c: 81 e8 00 00 restore <== NOT EXECUTED
}
}
cleanup:
free( logical_disk_name);
2027720: 7f ff 84 6f call 20088dc <free> <== NOT EXECUTED
2027724: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
/* Create logical disk name */
int rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
if (rv >= RTEMS_BDPART_NUMBER_SIZE) {
2027728: b0 10 20 03 mov 3, %i0 <== NOT EXECUTED
}
cleanup:
free( logical_disk_name);
free( mount_point);
202772c: 7f ff 84 6c call 20088dc <free> <== NOT EXECUTED
2027730: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2027734: 30 bf ff f9 b,a 2027718 <rtems_bdpart_mount+0x174> <== NOT EXECUTED
}
}
cleanup:
free( logical_disk_name);
2027738: 7f ff 84 69 call 20088dc <free> <== NOT EXECUTED
202773c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
/* Create mount point */
strncpy( mount_marker, logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE);
rv = rtems_mkdir( mount_point, S_IRWXU | S_IRWXG | S_IRWXO);
if (rv != 0) {
2027740: b0 10 20 1b mov 0x1b, %i0 <== NOT EXECUTED
}
cleanup:
free( logical_disk_name);
free( mount_point);
2027744: 7f ff 84 66 call 20088dc <free> <== NOT EXECUTED
2027748: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
202774c: 30 bf ff f3 b,a 2027718 <rtems_bdpart_mount+0x174> <== NOT EXECUTED
02027c8c <rtems_bdpart_new_record>:
static rtems_status_code rtems_bdpart_new_record(
dev_t disk,
rtems_blkdev_bnum index,
rtems_bdbuf_buffer **block
)
{
2027c8c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
/* Synchronize previous block if necessary */
if (*block != NULL) {
2027c90: d0 06 c0 00 ld [ %i3 ], %o0 <== NOT EXECUTED
static rtems_status_code rtems_bdpart_new_record(
dev_t disk,
rtems_blkdev_bnum index,
rtems_bdbuf_buffer **block
)
{
2027c94: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
/* Synchronize previous block if necessary */
if (*block != NULL) {
2027c98: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027c9c: 02 80 00 07 be 2027cb8 <rtems_bdpart_new_record+0x2c> <== NOT EXECUTED
2027ca0: a2 10 00 19 mov %i1, %l1 <== NOT EXECUTED
sc = rtems_bdbuf_sync( *block);
2027ca4: 7f ff 76 d2 call 20057ec <rtems_bdbuf_sync> <== NOT EXECUTED
2027ca8: 01 00 00 00 nop <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027cac: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2027cb0: 12 80 00 19 bne 2027d14 <rtems_bdpart_new_record+0x88> <== NOT EXECUTED
2027cb4: 01 00 00 00 nop <== NOT EXECUTED
return sc;
}
}
/* Read the new record block (this accounts for disk block sizes > 512) */
sc = rtems_bdbuf_read( disk, index, block);
2027cb8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2027cbc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2027cc0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2027cc4: 7f ff 79 01 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
2027cc8: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027ccc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2027cd0: 12 80 00 11 bne 2027d14 <rtems_bdpart_new_record+0x88> <== NOT EXECUTED
2027cd4: 01 00 00 00 nop <== NOT EXECUTED
return sc;
}
/* just in case block did not get filled in */
if ( *block == NULL ) {
2027cd8: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
2027cdc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2027ce0: 02 80 00 0f be 2027d1c <rtems_bdpart_new_record+0x90> <== NOT EXECUTED
2027ce4: 92 10 20 00 clr %o1 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
}
/* Clear record */
memset( (*block)->buffer, 0, RTEMS_BDPART_BLOCK_SIZE);
2027ce8: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
2027cec: 40 00 97 c4 call 204dbfc <memset> <== NOT EXECUTED
2027cf0: 94 10 22 00 mov 0x200, %o2 <== NOT EXECUTED
/* Write signature */
(*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0] =
2027cf4: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
2027cf8: 84 10 20 55 mov 0x55, %g2 <== NOT EXECUTED
2027cfc: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
2027d00: c4 28 61 fe stb %g2, [ %g1 + 0x1fe ] <== NOT EXECUTED
RTEMS_BDPART_MBR_SIGNATURE_0;
(*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1] =
2027d04: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
2027d08: 84 10 3f aa mov -86, %g2 <== NOT EXECUTED
2027d0c: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
2027d10: c4 28 61 ff stb %g2, [ %g1 + 0x1ff ] <== NOT EXECUTED
RTEMS_BDPART_MBR_SIGNATURE_1;
return RTEMS_SUCCESSFUL;
}
2027d14: 81 c7 e0 08 ret <== NOT EXECUTED
2027d18: 81 e8 00 00 restore <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
return sc;
}
/* just in case block did not get filled in */
if ( *block == NULL ) {
2027d1c: 81 c7 e0 08 ret <== NOT EXECUTED
2027d20: 91 e8 20 09 restore %g0, 9, %o0 <== NOT EXECUTED
020279c8 <rtems_bdpart_read>:
const char *disk_name,
rtems_bdpart_format *format,
rtems_bdpart_partition *pt,
size_t *count
)
{
20279c8: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *block = NULL;
rtems_bdpart_partition *p = pt - 1;
const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
20279cc: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
20279d0: 02 80 00 06 be 20279e8 <rtems_bdpart_read+0x20> <== NOT EXECUTED
20279d4: a0 10 20 00 clr %l0 <== NOT EXECUTED
20279d8: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
20279dc: a1 28 60 06 sll %g1, 6, %l0 <== NOT EXECUTED
20279e0: 83 28 60 04 sll %g1, 4, %g1 <== NOT EXECUTED
20279e4: a0 24 00 01 sub %l0, %g1, %l0 <== NOT EXECUTED
dev_t disk = 0;
size_t i = 0;
const uint8_t *data = NULL;
/* Check parameter */
if (format == NULL || pt == NULL || count == NULL) {
20279e8: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
20279ec: 02 80 00 16 be 2027a44 <rtems_bdpart_read+0x7c> <== NOT EXECUTED
20279f0: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20279f4: 02 80 00 14 be 2027a44 <rtems_bdpart_read+0x7c> <== NOT EXECUTED
20279f8: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
20279fc: 02 80 00 12 be 2027a44 <rtems_bdpart_read+0x7c> <== NOT EXECUTED
2027a00: 82 06 bf d0 add %i2, -48, %g1 <== NOT EXECUTED
/* Set count to a save value */
*count = 0;
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
2027a04: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (format == NULL || pt == NULL || count == NULL) {
return RTEMS_INVALID_ADDRESS;
}
/* Set count to a save value */
*count = 0;
2027a08: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
rtems_bdpart_partition *p = pt - 1;
const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
rtems_blkdev_bnum ep_begin = 0; /* Extended partition begin */
rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */
rtems_blkdev_bnum disk_end = 0;
dev_t disk = 0;
2027a0c: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
2027a10: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
rtems_bdpart_partition *p = pt - 1;
const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
rtems_blkdev_bnum ep_begin = 0; /* Extended partition begin */
rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */
rtems_blkdev_bnum disk_end = 0;
2027a14: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *block = NULL;
rtems_bdpart_partition *p = pt - 1;
const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
rtems_blkdev_bnum ep_begin = 0; /* Extended partition begin */
2027a18: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
size_t *count
)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *block = NULL;
2027a1c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_bdpart_partition *p = pt - 1;
2027a20: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
/* Set count to a save value */
*count = 0;
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
2027a24: 92 07 bf e8 add %fp, -24, %o1 <== NOT EXECUTED
2027a28: 7f ff ff 6d call 20277dc <rtems_bdpart_get_disk_data> <== NOT EXECUTED
2027a2c: 94 07 bf f0 add %fp, -16, %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027a30: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2027a34: 02 80 00 06 be 2027a4c <rtems_bdpart_read+0x84> <== NOT EXECUTED
2027a38: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
if (block != NULL) {
rtems_bdbuf_release( block);
}
return esc;
}
2027a3c: 81 c7 e0 08 ret <== NOT EXECUTED
2027a40: 81 e8 00 00 restore <== NOT EXECUTED
2027a44: 81 c7 e0 08 ret <== NOT EXECUTED
2027a48: 91 e8 20 09 restore %g0, 9, %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
return sc;
}
/* Read MBR */
sc = rtems_bdpart_read_record( disk, 0, &block);
2027a4c: a2 07 bf fc add %fp, -4, %l1 <== NOT EXECUTED
2027a50: 94 10 20 00 clr %o2 <== NOT EXECUTED
2027a54: 7f ff ff 3f call 2027750 <rtems_bdpart_read_record> <== NOT EXECUTED
2027a58: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027a5c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027a60: 02 80 00 0b be 2027a8c <rtems_bdpart_read+0xc4> <== NOT EXECUTED
2027a64: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0,
&p,
p_end,
NULL
);
if (sc != RTEMS_SUCCESSFUL) {
2027a68: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
2027a6c: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
/* Return partition count */
*count = (size_t) (p - pt + 1);
cleanup:
if (block != NULL) {
2027a70: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027a74: 02 bf ff f2 be 2027a3c <rtems_bdpart_read+0x74> <== NOT EXECUTED
2027a78: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
rtems_bdbuf_release( block);
2027a7c: 7f ff 74 b8 call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
2027a80: 01 00 00 00 nop <== NOT EXECUTED
2027a84: 81 c7 e0 08 ret <== NOT EXECUTED
2027a88: 81 e8 00 00 restore <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *block = NULL;
rtems_bdpart_partition *p = pt - 1;
const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
2027a8c: a0 06 80 10 add %i2, %l0, %l0 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Read the first partition entry */
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
2027a90: ea 00 60 24 ld [ %g1 + 0x24 ], %l5 <== NOT EXECUTED
sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);
2027a94: a6 07 bf f8 add %fp, -8, %l3 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Read the first partition entry */
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
2027a98: a4 05 61 be add %l5, 0x1be, %l2 <== NOT EXECUTED
sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);
2027a9c: a8 07 bf f4 add %fp, -12, %l4 <== NOT EXECUTED
2027aa0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2027aa4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2027aa8: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2027aac: 7f ff ff 7f call 20278a8 <rtems_bdpart_read_mbr_partition><== NOT EXECUTED
2027ab0: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027ab4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027ab8: 32 bf ff ed bne,a 2027a6c <rtems_bdpart_read+0xa4> <== NOT EXECUTED
2027abc: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Determine if we have a MBR or GPT format */
if (rtems_bdpart_mbr_partition_type( p->type) == RTEMS_BDPART_MBR_GPT) {
2027ac0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2027ac4: c2 08 60 08 ldub [ %g1 + 8 ], %g1 <== NOT EXECUTED
2027ac8: 80 a0 60 ee cmp %g1, 0xee <== NOT EXECUTED
2027acc: 02 80 00 68 be 2027c6c <rtems_bdpart_read+0x2a4> <== NOT EXECUTED
2027ad0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
esc = RTEMS_NOT_IMPLEMENTED;
goto cleanup;
}
/* Set format */
format->type = RTEMS_BDPART_FORMAT_MBR;
2027ad4: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
format->mbr.disk_id = rtems_uint32_from_little_endian(
2027ad8: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
}
return RTEMS_SUCCESSFUL;
}
rtems_status_code rtems_bdpart_read(
2027adc: aa 05 61 ee add %l5, 0x1ee, %l5 <== NOT EXECUTED
goto cleanup;
}
/* Set format */
format->type = RTEMS_BDPART_FORMAT_MBR;
format->mbr.disk_id = rtems_uint32_from_little_endian(
2027ae0: c4 08 61 b8 ldub [ %g1 + 0x1b8 ], %g2 <== NOT EXECUTED
2027ae4: 82 00 61 b8 add %g1, 0x1b8, %g1 <== NOT EXECUTED
2027ae8: c6 08 60 01 ldub [ %g1 + 1 ], %g3 <== NOT EXECUTED
2027aec: c8 08 60 02 ldub [ %g1 + 2 ], %g4 <== NOT EXECUTED
2027af0: da 08 60 03 ldub [ %g1 + 3 ], %o5 <== NOT EXECUTED
2027af4: 83 2b 60 08 sll %o5, 8, %g1 <== NOT EXECUTED
2027af8: 82 00 40 04 add %g1, %g4, %g1 <== NOT EXECUTED
2027afc: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2027b00: 82 00 40 03 add %g1, %g3, %g1 <== NOT EXECUTED
2027b04: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2027b08: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2027b0c: c2 26 60 04 st %g1, [ %i1 + 4 ] <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID
);
format->mbr.dos_compatibility = true;
2027b10: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2027b14: c2 2e 60 08 stb %g1, [ %i1 + 8 ] <== NOT EXECUTED
/* Iterate through the rest of the primary partition table */
for (i = 1; i < 4; ++i) {
data += RTEMS_BDPART_MBR_TABLE_ENTRY_SIZE;
2027b18: a4 04 a0 10 add %l2, 0x10, %l2 <== NOT EXECUTED
sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);
2027b1c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2027b20: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2027b24: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2027b28: 7f ff ff 60 call 20278a8 <rtems_bdpart_read_mbr_partition><== NOT EXECUTED
2027b2c: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027b30: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027b34: 12 bf ff cd bne 2027a68 <rtems_bdpart_read+0xa0> <== NOT EXECUTED
2027b38: 80 a4 80 15 cmp %l2, %l5 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID
);
format->mbr.dos_compatibility = true;
/* Iterate through the rest of the primary partition table */
for (i = 1; i < 4; ++i) {
2027b3c: 32 bf ff f8 bne,a 2027b1c <rtems_bdpart_read+0x154> <== NOT EXECUTED
2027b40: a4 04 a0 10 add %l2, 0x10, %l2 <== NOT EXECUTED
goto cleanup;
}
}
/* Iterate through the logical partitions within the extended partition */
ebr = ep_begin;
2027b44: f2 07 bf f4 ld [ %fp + -12 ], %i1 <== NOT EXECUTED
while (ebr != 0) {
2027b48: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2027b4c: 02 80 00 4e be 2027c84 <rtems_bdpart_read+0x2bc> <== NOT EXECUTED
2027b50: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rtems_blkdev_bnum tmp = 0;
/* Read EBR */
sc = rtems_bdpart_read_record( disk, ebr, &block);
2027b54: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
2027b58: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
2027b5c: 7f ff fe fd call 2027750 <rtems_bdpart_read_record> <== NOT EXECUTED
2027b60: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Read first partition entry */
sc = rtems_bdpart_read_mbr_partition(
2027b64: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2027b68: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
while (ebr != 0) {
rtems_blkdev_bnum tmp = 0;
/* Read EBR */
sc = rtems_bdpart_read_record( disk, ebr, &block);
if (sc != RTEMS_SUCCESSFUL) {
2027b6c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027b70: 12 bf ff be bne 2027a68 <rtems_bdpart_read+0xa0> <== NOT EXECUTED
2027b74: 96 10 20 00 clr %o3 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Read first partition entry */
sc = rtems_bdpart_read_mbr_partition(
2027b78: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2027b7c: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
2027b80: 7f ff ff 4a call 20278a8 <rtems_bdpart_read_mbr_partition><== NOT EXECUTED
2027b84: 90 02 21 be add %o0, 0x1be, %o0 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0,
&p,
p_end,
NULL
);
if (sc != RTEMS_SUCCESSFUL) {
2027b88: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027b8c: 12 bf ff b7 bne 2027a68 <rtems_bdpart_read+0xa0> <== NOT EXECUTED
2027b90: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Adjust partition begin */
tmp = p->begin + ebr;
2027b94: c4 00 40 00 ld [ %g1 ], %g2 <== NOT EXECUTED
2027b98: 86 06 40 02 add %i1, %g2, %g3 <== NOT EXECUTED
if (tmp > p->begin) {
2027b9c: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2027ba0: 1a 80 00 37 bcc 2027c7c <rtems_bdpart_read+0x2b4> <== NOT EXECUTED
2027ba4: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
esc = RTEMS_IO_ERROR;
goto cleanup;
}
/* Adjust partition end */
tmp = p->end + ebr;
2027ba8: c4 00 60 04 ld [ %g1 + 4 ], %g2 <== NOT EXECUTED
2027bac: b2 06 40 02 add %i1, %g2, %i1 <== NOT EXECUTED
if (tmp > p->end) {
2027bb0: 80 a0 80 19 cmp %g2, %i1 <== NOT EXECUTED
2027bb4: 1a 80 00 31 bcc 2027c78 <rtems_bdpart_read+0x2b0> <== NOT EXECUTED
2027bb8: c6 20 40 00 st %g3, [ %g1 ] <== NOT EXECUTED
goto cleanup;
}
/* Read second partition entry for next EBR block */
ebr = rtems_bdpart_next_ebr(
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_1
2027bbc: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
}
/* Adjust partition end */
tmp = p->end + ebr;
if (tmp > p->end) {
p->end = tmp;
2027bc0: f2 20 60 04 st %i1, [ %g1 + 4 ] <== NOT EXECUTED
esc = RTEMS_IO_ERROR;
goto cleanup;
}
/* Read second partition entry for next EBR block */
ebr = rtems_bdpart_next_ebr(
2027bc4: c4 02 20 24 ld [ %o0 + 0x24 ], %g2 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_1
2027bc8: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
}
static rtems_blkdev_bnum rtems_bdpart_next_ebr( const uint8_t *data)
{
rtems_blkdev_bnum begin =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
2027bcc: 86 00 a1 d6 add %g2, 0x1d6, %g3 <== NOT EXECUTED
uint8_t type = data [RTEMS_BDPART_MBR_OFFSET_TYPE];
if (type == RTEMS_BDPART_MBR_EXTENDED) {
2027bd0: d6 08 a1 d2 ldub [ %g2 + 0x1d2 ], %o3 <== NOT EXECUTED
2027bd4: c8 08 e0 01 ldub [ %g3 + 1 ], %g4 <== NOT EXECUTED
2027bd8: da 08 e0 02 ldub [ %g3 + 2 ], %o5 <== NOT EXECUTED
2027bdc: d8 08 e0 03 ldub [ %g3 + 3 ], %o4 <== NOT EXECUTED
2027be0: c4 08 a1 d6 ldub [ %g2 + 0x1d6 ], %g2 <== NOT EXECUTED
2027be4: 87 2b 20 08 sll %o4, 8, %g3 <== NOT EXECUTED
2027be8: 80 a2 e0 05 cmp %o3, 5 <== NOT EXECUTED
2027bec: 86 00 c0 0d add %g3, %o5, %g3 <== NOT EXECUTED
2027bf0: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
2027bf4: 86 00 c0 04 add %g3, %g4, %g3 <== NOT EXECUTED
2027bf8: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
2027bfc: 02 80 00 12 be 2027c44 <rtems_bdpart_read+0x27c> <== NOT EXECUTED
2027c00: 84 00 c0 02 add %g3, %g2, %g2 <== NOT EXECUTED
}
}
}
/* Return partition count */
*count = (size_t) (p - pt + 1);
2027c04: 82 20 40 1a sub %g1, %i2, %g1 <== NOT EXECUTED
2027c08: 83 38 60 04 sra %g1, 4, %g1 <== NOT EXECUTED
2027c0c: 85 28 60 02 sll %g1, 2, %g2 <== NOT EXECUTED
2027c10: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2027c14: 85 28 60 04 sll %g1, 4, %g2 <== NOT EXECUTED
2027c18: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2027c1c: 85 28 60 08 sll %g1, 8, %g2 <== NOT EXECUTED
2027c20: 90 10 00 0a mov %o2, %o0 <== NOT EXECUTED
2027c24: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2027c28: a0 10 20 00 clr %l0 <== NOT EXECUTED
2027c2c: 85 28 60 10 sll %g1, 0x10, %g2 <== NOT EXECUTED
2027c30: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2027c34: 82 20 00 01 neg %g1 <== NOT EXECUTED
2027c38: 82 00 60 01 inc %g1 <== NOT EXECUTED
2027c3c: 10 bf ff 8d b 2027a70 <rtems_bdpart_read+0xa8> <== NOT EXECUTED
2027c40: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
/* Read second partition entry for next EBR block */
ebr = rtems_bdpart_next_ebr(
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_1
);
if (ebr != 0) {
2027c44: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2027c48: 22 bf ff f0 be,a 2027c08 <rtems_bdpart_read+0x240> <== NOT EXECUTED
2027c4c: 82 20 40 1a sub %g1, %i2, %g1 <== NOT EXECUTED
/* Adjust partition EBR block index */
tmp = ebr + ep_begin;
2027c50: f2 07 bf f4 ld [ %fp + -12 ], %i1 <== NOT EXECUTED
2027c54: b2 00 80 19 add %g2, %i1, %i1 <== NOT EXECUTED
if (tmp > ebr) {
2027c58: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
2027c5c: 38 bf ff bf bgu,a 2027b58 <rtems_bdpart_read+0x190> <== NOT EXECUTED
2027c60: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
2027c64: 10 bf ff 83 b 2027a70 <rtems_bdpart_read+0xa8> <== NOT EXECUTED
2027c68: a0 10 20 1b mov 0x1b, %l0 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Determine if we have a MBR or GPT format */
if (rtems_bdpart_mbr_partition_type( p->type) == RTEMS_BDPART_MBR_GPT) {
2027c6c: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
2027c70: 10 bf ff 80 b 2027a70 <rtems_bdpart_read+0xa8> <== NOT EXECUTED
2027c74: a0 10 20 18 mov 0x18, %l0 <== NOT EXECUTED
goto cleanup;
}
/* Adjust partition end */
tmp = p->end + ebr;
if (tmp > p->end) {
2027c78: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
2027c7c: 10 bf ff 7d b 2027a70 <rtems_bdpart_read+0xa8> <== NOT EXECUTED
2027c80: a0 10 20 1b mov 0x1b, %l0 <== NOT EXECUTED
2027c84: 10 bf ff e0 b 2027c04 <rtems_bdpart_read+0x23c> <== NOT EXECUTED
2027c88: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
020278a8 <rtems_bdpart_read_mbr_partition>:
const uint8_t *data,
rtems_bdpart_partition **p,
const rtems_bdpart_partition *p_end,
rtems_blkdev_bnum *ep_begin
)
{
20278a8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_blkdev_bnum begin =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
20278ac: 86 06 20 08 add %i0, 8, %g3 <== NOT EXECUTED
rtems_blkdev_bnum size =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_SIZE);
20278b0: 84 06 20 0c add %i0, 0xc, %g2 <== NOT EXECUTED
{
uint32_t value = 0;
ssize_t i = 0;
for (i = 3; i >= 0; --i) {
value = (value << 8) + data [i];
20278b4: d8 08 e0 01 ldub [ %g3 + 1 ], %o4 <== NOT EXECUTED
20278b8: da 08 a0 01 ldub [ %g2 + 1 ], %o5 <== NOT EXECUTED
20278bc: c2 08 e0 03 ldub [ %g3 + 3 ], %g1 <== NOT EXECUTED
20278c0: d4 08 e0 02 ldub [ %g3 + 2 ], %o2 <== NOT EXECUTED
20278c4: d6 08 a0 02 ldub [ %g2 + 2 ], %o3 <== NOT EXECUTED
20278c8: c6 08 a0 03 ldub [ %g2 + 3 ], %g3 <== NOT EXECUTED
20278cc: c8 0e 20 08 ldub [ %i0 + 8 ], %g4 <== NOT EXECUTED
20278d0: c4 0e 20 0c ldub [ %i0 + 0xc ], %g2 <== NOT EXECUTED
rtems_blkdev_bnum end = begin + size;
uint8_t type = data [RTEMS_BDPART_MBR_OFFSET_TYPE];
if (type == RTEMS_BDPART_MBR_EMPTY) {
20278d4: d0 0e 20 04 ldub [ %i0 + 4 ], %o0 <== NOT EXECUTED
20278d8: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20278dc: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
20278e0: 82 00 40 0a add %g1, %o2, %g1 <== NOT EXECUTED
20278e4: 86 00 c0 0b add %g3, %o3, %g3 <== NOT EXECUTED
20278e8: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20278ec: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
20278f0: 82 00 40 0c add %g1, %o4, %g1 <== NOT EXECUTED
20278f4: 86 00 c0 0d add %g3, %o5, %g3 <== NOT EXECUTED
20278f8: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20278fc: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
const uint8_t *data,
rtems_bdpart_partition **p,
const rtems_bdpart_partition *p_end,
rtems_blkdev_bnum *ep_begin
)
{
2027900: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
2027904: 82 00 40 04 add %g1, %g4, %g1 <== NOT EXECUTED
rtems_blkdev_bnum size =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_SIZE);
rtems_blkdev_bnum end = begin + size;
uint8_t type = data [RTEMS_BDPART_MBR_OFFSET_TYPE];
if (type == RTEMS_BDPART_MBR_EMPTY) {
2027908: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202790c: 02 80 00 26 be 20279a4 <rtems_bdpart_read_mbr_partition+0xfc><== NOT EXECUTED
2027910: 84 00 c0 02 add %g3, %g2, %g2 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
} else if (*p == p_end) {
2027914: c6 06 40 00 ld [ %i1 ], %g3 <== NOT EXECUTED
2027918: 80 a0 c0 1a cmp %g3, %i2 <== NOT EXECUTED
202791c: 02 80 00 20 be 202799c <rtems_bdpart_read_mbr_partition+0xf4><== NOT EXECUTED
2027920: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
{
rtems_blkdev_bnum begin =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_blkdev_bnum size =
rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_SIZE);
rtems_blkdev_bnum end = begin + size;
2027924: 84 00 40 02 add %g1, %g2, %g2 <== NOT EXECUTED
if (type == RTEMS_BDPART_MBR_EMPTY) {
return RTEMS_SUCCESSFUL;
} else if (*p == p_end) {
return RTEMS_TOO_MANY;
} else if (begin >= end) {
2027928: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
202792c: 08 80 00 1c bleu 202799c <rtems_bdpart_read_mbr_partition+0xf4><== NOT EXECUTED
2027930: b0 10 20 1b mov 0x1b, %i0 <== NOT EXECUTED
return RTEMS_IO_ERROR;
} else if (type == RTEMS_BDPART_MBR_EXTENDED) {
2027934: 80 a2 20 05 cmp %o0, 5 <== NOT EXECUTED
2027938: 02 80 00 1e be 20279b0 <rtems_bdpart_read_mbr_partition+0x108><== NOT EXECUTED
202793c: 88 00 e0 30 add %g3, 0x30, %g4 <== NOT EXECUTED
if (ep_begin != NULL) {
*ep_begin = begin;
}
} else {
/* Increment partition index */
++(*p);
2027940: c8 26 40 00 st %g4, [ %i1 ] <== NOT EXECUTED
/* Clear partition */
memset( *p, 0, sizeof( rtems_bdpart_partition));
2027944: c0 20 e0 30 clr [ %g3 + 0x30 ] <== NOT EXECUTED
2027948: c0 20 e0 34 clr [ %g3 + 0x34 ] <== NOT EXECUTED
202794c: c0 21 20 28 clr [ %g4 + 0x28 ] <== NOT EXECUTED
2027950: c0 21 20 2c clr [ %g4 + 0x2c ] <== NOT EXECUTED
2027954: c0 21 20 08 clr [ %g4 + 8 ] <== NOT EXECUTED
2027958: c0 21 20 0c clr [ %g4 + 0xc ] <== NOT EXECUTED
202795c: c0 21 20 10 clr [ %g4 + 0x10 ] <== NOT EXECUTED
2027960: c0 21 20 14 clr [ %g4 + 0x14 ] <== NOT EXECUTED
2027964: c0 21 20 18 clr [ %g4 + 0x18 ] <== NOT EXECUTED
2027968: c0 21 20 1c clr [ %g4 + 0x1c ] <== NOT EXECUTED
202796c: c0 21 20 20 clr [ %g4 + 0x20 ] <== NOT EXECUTED
2027970: c0 21 20 24 clr [ %g4 + 0x24 ] <== NOT EXECUTED
/* Set values */
(*p)->begin = begin;
2027974: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
(*p)->end = end;
rtems_bdpart_to_partition_type( type, (*p)->type);
(*p)->flags = data [RTEMS_BDPART_MBR_OFFSET_FLAGS];
2027978: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* Clear partition */
memset( *p, 0, sizeof( rtems_bdpart_partition));
/* Set values */
(*p)->begin = begin;
202797c: c2 22 40 00 st %g1, [ %o1 ] <== NOT EXECUTED
(*p)->end = end;
2027980: c4 22 60 04 st %g2, [ %o1 + 4 ] <== NOT EXECUTED
rtems_bdpart_to_partition_type( type, (*p)->type);
2027984: 7f ff ff c0 call 2027884 <rtems_bdpart_to_partition_type> <== NOT EXECUTED
2027988: 92 02 60 08 add %o1, 8, %o1 <== NOT EXECUTED
(*p)->flags = data [RTEMS_BDPART_MBR_OFFSET_FLAGS];
202798c: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
2027990: c4 0c 00 00 ldub [ %l0 ], %g2 <== NOT EXECUTED
2027994: c0 20 60 28 clr [ %g1 + 0x28 ] <== NOT EXECUTED
2027998: c4 20 60 2c st %g2, [ %g1 + 0x2c ] <== NOT EXECUTED
202799c: 81 c7 e0 08 ret <== NOT EXECUTED
20279a0: 81 e8 00 00 restore <== NOT EXECUTED
20279a4: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
return RTEMS_SUCCESSFUL;
}
20279a8: 81 c7 e0 08 ret <== NOT EXECUTED
20279ac: 81 e8 00 00 restore <== NOT EXECUTED
} else if (*p == p_end) {
return RTEMS_TOO_MANY;
} else if (begin >= end) {
return RTEMS_IO_ERROR;
} else if (type == RTEMS_BDPART_MBR_EXTENDED) {
if (ep_begin != NULL) {
20279b0: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
20279b4: 02 bf ff fa be 202799c <rtems_bdpart_read_mbr_partition+0xf4><== NOT EXECUTED
20279b8: b0 10 20 00 clr %i0 <== NOT EXECUTED
*ep_begin = begin;
20279bc: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
20279c0: 81 c7 e0 08 ret <== NOT EXECUTED
20279c4: 81 e8 00 00 restore <== NOT EXECUTED
02027750 <rtems_bdpart_read_record>:
static rtems_status_code rtems_bdpart_read_record(
dev_t disk,
rtems_blkdev_bnum index,
rtems_bdbuf_buffer **block
)
{
2027750: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
/* Release previous block if necessary */
if (*block != NULL) {
2027754: d0 06 c0 00 ld [ %i3 ], %o0 <== NOT EXECUTED
static rtems_status_code rtems_bdpart_read_record(
dev_t disk,
rtems_blkdev_bnum index,
rtems_bdbuf_buffer **block
)
{
2027758: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
/* Release previous block if necessary */
if (*block != NULL) {
202775c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027760: 02 80 00 07 be 202777c <rtems_bdpart_read_record+0x2c> <== NOT EXECUTED
2027764: a2 10 00 19 mov %i1, %l1 <== NOT EXECUTED
sc = rtems_bdbuf_release( *block);
2027768: 7f ff 75 7d call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
202776c: 01 00 00 00 nop <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027770: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027774: 12 80 00 14 bne 20277c4 <rtems_bdpart_read_record+0x74> <== NOT EXECUTED
2027778: 01 00 00 00 nop <== NOT EXECUTED
return sc;
}
}
/* Read the record block */
sc = rtems_bdbuf_read( disk, index, block);
202777c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2027780: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2027784: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2027788: 7f ff 7a 50 call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
202778c: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027790: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027794: 12 80 00 0c bne 20277c4 <rtems_bdpart_read_record+0x74> <== NOT EXECUTED
2027798: 01 00 00 00 nop <== NOT EXECUTED
return sc;
}
/* just in case block did not get filled in */
if ( *block == NULL ) {
202779c: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
20277a0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20277a4: 22 80 00 08 be,a 20277c4 <rtems_bdpart_read_record+0x74> <== NOT EXECUTED
20277a8: 90 10 20 09 mov 9, %o0 <== NOT EXECUTED
return RTEMS_INVALID_ADDRESS;
}
/* Check MBR signature */
if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {
20277ac: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
static bool rtems_bdpart_is_valid_record( const uint8_t *data)
{
return data [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0]
20277b0: c4 08 61 fe ldub [ %g1 + 0x1fe ], %g2 <== NOT EXECUTED
20277b4: 80 a0 a0 55 cmp %g2, 0x55 <== NOT EXECUTED
20277b8: 22 80 00 05 be,a 20277cc <rtems_bdpart_read_record+0x7c> <== NOT EXECUTED
20277bc: c2 08 61 ff ldub [ %g1 + 0x1ff ], %g1 <== NOT EXECUTED
20277c0: 90 10 20 1b mov 0x1b, %o0 <== NOT EXECUTED
if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {
return RTEMS_IO_ERROR;
}
return RTEMS_SUCCESSFUL;
}
20277c4: 81 c7 e0 08 ret <== NOT EXECUTED
20277c8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
static bool rtems_bdpart_is_valid_record( const uint8_t *data)
{
return data [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0]
20277cc: 80 a0 60 aa cmp %g1, 0xaa <== NOT EXECUTED
20277d0: 32 bf ff fd bne,a 20277c4 <rtems_bdpart_read_record+0x74><== NOT EXECUTED
20277d4: 90 10 20 1b mov 0x1b, %o0 <== NOT EXECUTED
20277d8: 30 bf ff fb b,a 20277c4 <rtems_bdpart_read_record+0x74> <== NOT EXECUTED
02006414 <rtems_bdpart_register>:
rtems_status_code rtems_bdpart_register(
const char *disk_name,
const rtems_bdpart_partition *pt,
size_t count
)
{
2006414: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
rtems_blkdev_bnum disk_end = 0;
dev_t disk = 0;
dev_t logical_disk = 0;
char *logical_disk_name = NULL;
char *logical_disk_marker = NULL;
size_t disk_name_size = strlen( disk_name);
2006418: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
rtems_blkdev_bnum disk_end = 0;
200641c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
dev_t disk = 0;
2006420: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
dev_t logical_disk = 0;
char *logical_disk_name = NULL;
char *logical_disk_marker = NULL;
size_t disk_name_size = strlen( disk_name);
2006424: 40 01 2b d3 call 2051370 <strlen> <== NOT EXECUTED
2006428: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
rtems_status_code rtems_bdpart_register(
const char *disk_name,
const rtems_bdpart_partition *pt,
size_t count
)
{
200642c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
rtems_blkdev_bnum disk_end = 0;
dev_t disk = 0;
dev_t logical_disk = 0;
char *logical_disk_name = NULL;
char *logical_disk_marker = NULL;
size_t disk_name_size = strlen( disk_name);
2006430: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
size_t i = 0;
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
2006434: 92 07 bf f0 add %fp, -16, %o1 <== NOT EXECUTED
2006438: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
200643c: 40 00 84 e8 call 20277dc <rtems_bdpart_get_disk_data> <== NOT EXECUTED
2006440: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2006444: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2006448: 12 80 00 2d bne 20064fc <rtems_bdpart_register+0xe8> <== NOT EXECUTED
200644c: e6 07 bf f0 ld [ %fp + -16 ], %l3 <== NOT EXECUTED
return sc;
}
/* Get the disk device identifier */
rtems_filesystem_split_dev_t( disk, major, minor);
2006450: e2 07 bf f4 ld [ %fp + -12 ], %l1 <== NOT EXECUTED
/* Create logical disk name */
logical_disk_name = malloc( disk_name_size + RTEMS_BDPART_NUMBER_SIZE);
2006454: 90 05 20 04 add %l4, 4, %o0 <== NOT EXECUTED
2006458: 40 00 0b 02 call 2009060 <malloc> <== NOT EXECUTED
200645c: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED
if (logical_disk_name == NULL) {
2006460: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2006464: 02 80 00 26 be 20064fc <rtems_bdpart_register+0xe8> <== NOT EXECUTED
2006468: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
}
strncpy( logical_disk_name, disk_name, disk_name_size);
200646c: 40 01 2c 85 call 2051680 <strncpy> <== NOT EXECUTED
2006470: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
logical_disk_marker = logical_disk_name + disk_name_size;
/* Create a logical disk for each partition */
for (i = 0; i < count; ++i) {
2006474: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2006478: 02 80 00 23 be 2006504 <rtems_bdpart_register+0xf0> <== NOT EXECUTED
200647c: a8 04 80 14 add %l2, %l4, %l4 <== NOT EXECUTED
2006480: 2b 00 81 96 sethi %hi(0x2065800), %l5 <== NOT EXECUTED
2006484: a0 10 20 00 clr %l0 <== NOT EXECUTED
/* Create a new device identifier */
logical_disk = rtems_filesystem_make_dev_t( major, minor);
/* Set partition number for logical disk name */
rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
2006488: 10 80 00 0c b 20064b8 <rtems_bdpart_register+0xa4> <== NOT EXECUTED
200648c: aa 15 62 d0 or %l5, 0x2d0, %l5 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Create logical disk */
sc = rtems_disk_create_log(
2006490: d8 1e 40 00 ldd [ %i1 ], %o4 <== NOT EXECUTED
2006494: d4 1f bf f0 ldd [ %fp + -16 ], %o2 <== NOT EXECUTED
2006498: e4 23 a0 5c st %l2, [ %sp + 0x5c ] <== NOT EXECUTED
200649c: 40 00 04 8b call 20076c8 <rtems_disk_create_log> <== NOT EXECUTED
20064a0: 9a 23 40 0c sub %o5, %o4, %o5 <== NOT EXECUTED
disk,
p->begin,
p->end - p->begin,
logical_disk_name
);
if (sc != RTEMS_SUCCESSFUL) {
20064a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20064a8: 12 80 00 19 bne 200650c <rtems_bdpart_register+0xf8> <== NOT EXECUTED
20064ac: 80 a6 80 10 cmp %i2, %l0 <== NOT EXECUTED
}
strncpy( logical_disk_name, disk_name, disk_name_size);
logical_disk_marker = logical_disk_name + disk_name_size;
/* Create a logical disk for each partition */
for (i = 0; i < count; ++i) {
20064b0: 08 80 00 15 bleu 2006504 <rtems_bdpart_register+0xf0> <== NOT EXECUTED
20064b4: b2 06 60 30 add %i1, 0x30, %i1 <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
20064b8: e6 27 bf e8 st %l3, [ %fp + -24 ] <== NOT EXECUTED
const rtems_bdpart_partition *p = pt + i;
int rv = 0;
/* New minor number */
++minor;
20064bc: a2 04 60 01 inc %l1 <== NOT EXECUTED
temp.__overlay.minor = _minor;
20064c0: e2 27 bf ec st %l1, [ %fp + -20 ] <== NOT EXECUTED
return temp.device;
20064c4: ec 1f bf e8 ldd [ %fp + -24 ], %l6 <== NOT EXECUTED
/* Create a new device identifier */
logical_disk = rtems_filesystem_make_dev_t( major, minor);
/* Set partition number for logical disk name */
rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
20064c8: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
20064cc: a0 04 20 01 inc %l0 <== NOT EXECUTED
20064d0: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
20064d4: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
20064d8: 40 01 27 dd call 205044c <snprintf> <== NOT EXECUTED
20064dc: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Create logical disk */
sc = rtems_disk_create_log(
20064e0: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
/* Create a new device identifier */
logical_disk = rtems_filesystem_make_dev_t( major, minor);
/* Set partition number for logical disk name */
rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
if (rv >= RTEMS_BDPART_NUMBER_SIZE) {
20064e4: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
20064e8: 04 bf ff ea ble 2006490 <rtems_bdpart_register+0x7c> <== NOT EXECUTED
20064ec: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
20064f0: b0 10 20 03 mov 3, %i0 <== NOT EXECUTED
}
}
cleanup:
free( logical_disk_name);
20064f4: 40 00 08 fa call 20088dc <free> <== NOT EXECUTED
20064f8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
return esc;
}
20064fc: 81 c7 e0 08 ret <== NOT EXECUTED
2006500: 81 e8 00 00 restore <== NOT EXECUTED
}
strncpy( logical_disk_name, disk_name, disk_name_size);
logical_disk_marker = logical_disk_name + disk_name_size;
/* Create a logical disk for each partition */
for (i = 0; i < count; ++i) {
2006504: 10 bf ff fc b 20064f4 <rtems_bdpart_register+0xe0> <== NOT EXECUTED
2006508: b0 10 20 00 clr %i0 <== NOT EXECUTED
disk,
p->begin,
p->end - p->begin,
logical_disk_name
);
if (sc != RTEMS_SUCCESSFUL) {
200650c: 10 bf ff fa b 20064f4 <rtems_bdpart_register+0xe0> <== NOT EXECUTED
2006510: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
02006514 <rtems_bdpart_register_from_disk>:
return esc;
}
rtems_status_code rtems_bdpart_register_from_disk( const char *disk_name)
{
2006514: 9d e3 bc 88 save %sp, -888, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdpart_format format;
rtems_bdpart_partition pt [RTEMS_BDPART_PARTITION_NUMBER_HINT];
size_t count = RTEMS_BDPART_PARTITION_NUMBER_HINT;
2006518: 82 10 20 10 mov 0x10, %g1 <== NOT EXECUTED
/* Read partitions */
sc = rtems_bdpart_read( disk_name, &format, pt, &count);
200651c: a0 07 bc e8 add %fp, -792, %l0 <== NOT EXECUTED
rtems_status_code rtems_bdpart_register_from_disk( const char *disk_name)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdpart_format format;
rtems_bdpart_partition pt [RTEMS_BDPART_PARTITION_NUMBER_HINT];
size_t count = RTEMS_BDPART_PARTITION_NUMBER_HINT;
2006520: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
/* Read partitions */
sc = rtems_bdpart_read( disk_name, &format, pt, &count);
2006524: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2006528: 92 07 bf e8 add %fp, -24, %o1 <== NOT EXECUTED
200652c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2006530: 40 00 85 26 call 20279c8 <rtems_bdpart_read> <== NOT EXECUTED
2006534: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2006538: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200653c: 12 80 00 05 bne 2006550 <rtems_bdpart_register_from_disk+0x3c><== NOT EXECUTED
2006540: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
return sc;
}
/* Register partitions */
return rtems_bdpart_register( disk_name, pt, count);
2006544: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2006548: 7f ff ff b3 call 2006414 <rtems_bdpart_register> <== NOT EXECUTED
200654c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
}
2006550: 81 c7 e0 08 ret <== NOT EXECUTED
2006554: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02027854 <rtems_bdpart_to_mbr_partition_type>:
bool rtems_bdpart_to_mbr_partition_type(
const uuid_t type,
uint8_t *mbr_type
)
{
2027854: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
*mbr_type = rtems_bdpart_mbr_partition_type( type);
2027858: c2 0e 00 00 ldub [ %i0 ], %g1 <== NOT EXECUTED
return memcmp(
202785c: 90 06 20 01 add %i0, 1, %o0 <== NOT EXECUTED
bool rtems_bdpart_to_mbr_partition_type(
const uuid_t type,
uint8_t *mbr_type
)
{
*mbr_type = rtems_bdpart_mbr_partition_type( type);
2027860: c2 2e 40 00 stb %g1, [ %i1 ] <== NOT EXECUTED
return memcmp(
2027864: 94 10 20 0f mov 0xf, %o2 <== NOT EXECUTED
2027868: 13 00 81 a9 sethi %hi(0x206a400), %o1 <== NOT EXECUTED
202786c: 40 00 98 20 call 204d8ec <memcmp> <== NOT EXECUTED
2027870: 92 12 63 a1 or %o1, 0x3a1, %o1 ! 206a7a1 <RTEMS_BDPART_MBR_MASTER_TYPE+0x1><== NOT EXECUTED
2027874: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2027878: b0 60 3f ff subx %g0, -1, %i0 <== NOT EXECUTED
type + 1,
RTEMS_BDPART_MBR_MASTER_TYPE + 1,
sizeof( uuid_t) - 1
) == 0;
}
202787c: 81 c7 e0 08 ret <== NOT EXECUTED
2027880: 81 e8 00 00 restore <== NOT EXECUTED
02027884 <rtems_bdpart_to_partition_type>:
static const uuid_t RTEMS_BDPART_MBR_MASTER_TYPE =
RTEMS_BDPART_MBR_PARTITION_TYPE( RTEMS_BDPART_MBR_EMPTY);
void rtems_bdpart_to_partition_type( uint8_t mbr_type, uuid_t type)
{
type [0] = mbr_type;
2027884: d0 2a 40 00 stb %o0, [ %o1 ] <== NOT EXECUTED
memcpy( type + 1, RTEMS_BDPART_MBR_MASTER_TYPE + 1, sizeof( uuid_t) - 1);
2027888: 94 10 20 0f mov 0xf, %o2 <== NOT EXECUTED
202788c: 90 02 60 01 add %o1, 1, %o0 <== NOT EXECUTED
2027890: 13 00 81 a9 sethi %hi(0x206a400), %o1 <== NOT EXECUTED
2027894: 92 12 63 a1 or %o1, 0x3a1, %o1 ! 206a7a1 <RTEMS_BDPART_MBR_MASTER_TYPE+0x1><== NOT EXECUTED
2027898: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
202789c: 40 00 98 45 call 204d9b0 <memcpy> <== NOT EXECUTED
20278a0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02027470 <rtems_bdpart_unmount>:
const char *disk_name,
const rtems_bdpart_partition *pt __attribute__((unused)),
size_t count,
const char *mount_base
)
{
2027470: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code esc = RTEMS_SUCCESSFUL;
const char *disk_file_name = strrchr( disk_name, '/');
2027474: 92 10 20 2f mov 0x2f, %o1 <== NOT EXECUTED
2027478: 40 00 ab 5c call 20521e8 <strrchr> <== NOT EXECUTED
202747c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2027480: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
char *mount_point = NULL;
char *mount_marker = NULL;
size_t disk_file_name_size = 0;
size_t disk_name_size = strlen( disk_name);
2027484: 40 00 a7 bb call 2051370 <strlen> <== NOT EXECUTED
2027488: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202748c: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
size_t mount_base_size = strlen( mount_base);
2027490: 40 00 a7 b8 call 2051370 <strlen> <== NOT EXECUTED
2027494: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
size_t i = 0;
/* Get disk file name */
if (disk_file_name != NULL) {
2027498: a4 10 00 18 mov %i0, %l2 <== NOT EXECUTED
202749c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
20274a0: 02 80 00 06 be 20274b8 <rtems_bdpart_unmount+0x48> <== NOT EXECUTED
20274a4: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
disk_file_name += 1;
20274a8: a4 04 60 01 add %l1, 1, %l2 <== NOT EXECUTED
disk_file_name_size = strlen( disk_file_name);
20274ac: 40 00 a7 b1 call 2051370 <strlen> <== NOT EXECUTED
20274b0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20274b4: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
disk_file_name = disk_name;
disk_file_name_size = disk_name_size;
}
/* Create mount point base */
mount_point = malloc( mount_base_size + 1 + disk_file_name_size + RTEMS_BDPART_NUMBER_SIZE);
20274b8: a8 04 c0 10 add %l3, %l0, %l4 <== NOT EXECUTED
if (mount_point == NULL) {
20274bc: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED
disk_file_name = disk_name;
disk_file_name_size = disk_name_size;
}
/* Create mount point base */
mount_point = malloc( mount_base_size + 1 + disk_file_name_size + RTEMS_BDPART_NUMBER_SIZE);
20274c0: 7f ff 86 e8 call 2009060 <malloc> <== NOT EXECUTED
20274c4: 90 05 20 05 add %l4, 5, %o0 <== NOT EXECUTED
if (mount_point == NULL) {
20274c8: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20274cc: 02 80 00 29 be 2027570 <rtems_bdpart_unmount+0x100> <== NOT EXECUTED
20274d0: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
esc = RTEMS_NO_MEMORY;
goto cleanup;
}
strncpy( mount_point, mount_base, mount_base_size);
20274d4: 40 00 a8 6b call 2051680 <strncpy> <== NOT EXECUTED
20274d8: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
mount_point [mount_base_size] = '/';
20274dc: 82 10 20 2f mov 0x2f, %g1 <== NOT EXECUTED
strncpy( mount_point + mount_base_size + 1, disk_file_name, disk_file_name_size);
20274e0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20274e4: 90 04 20 01 add %l0, 1, %o0 <== NOT EXECUTED
20274e8: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
20274ec: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
20274f0: 40 00 a8 64 call 2051680 <strncpy> <== NOT EXECUTED
20274f4: c2 2c 40 10 stb %g1, [ %l1 + %l0 ] <== NOT EXECUTED
/* Marker */
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
20274f8: a4 05 20 01 add %l4, 1, %l2 <== NOT EXECUTED
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
20274fc: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2027500: 02 80 00 20 be 2027580 <rtems_bdpart_unmount+0x110> <== NOT EXECUTED
2027504: a4 04 40 12 add %l1, %l2, %l2 <== NOT EXECUTED
2027508: 27 00 81 a9 sethi %hi(0x206a400), %l3 <== NOT EXECUTED
202750c: a0 10 20 00 clr %l0 <== NOT EXECUTED
/* Create mount point */
int rv = snprintf( mount_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
2027510: 10 80 00 04 b 2027520 <rtems_bdpart_unmount+0xb0> <== NOT EXECUTED
2027514: a6 14 e3 90 or %l3, 0x390, %l3 <== NOT EXECUTED
/* Marker */
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
2027518: 08 80 00 1b bleu 2027584 <rtems_bdpart_unmount+0x114> <== NOT EXECUTED
202751c: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* Create mount point */
int rv = snprintf( mount_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
2027520: a0 04 20 01 inc %l0 <== NOT EXECUTED
2027524: 92 10 20 04 mov 4, %o1 <== NOT EXECUTED
2027528: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
202752c: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2027530: 40 00 a3 c7 call 205044c <snprintf> <== NOT EXECUTED
2027534: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (rv >= RTEMS_BDPART_NUMBER_SIZE) {
2027538: 80 a2 20 03 cmp %o0, 3 <== NOT EXECUTED
202753c: 14 80 00 16 bg 2027594 <rtems_bdpart_unmount+0x124> <== NOT EXECUTED
2027540: b0 10 20 03 mov 3, %i0 <== NOT EXECUTED
esc = RTEMS_INVALID_NAME;
goto cleanup;
}
/* Unmount */
rv = unmount( mount_point);
2027544: 40 00 1d 8c call 202eb74 <unmount> <== NOT EXECUTED
2027548: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
if (rv == 0) {
202754c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027550: 12 bf ff f2 bne 2027518 <rtems_bdpart_unmount+0xa8> <== NOT EXECUTED
2027554: 80 a6 80 10 cmp %i2, %l0 <== NOT EXECUTED
/* Remove mount point */
rv = rmdir( mount_point);
2027558: 40 00 1b ca call 202e480 <rmdir> <== NOT EXECUTED
202755c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
if (rv != 0) {
2027560: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027564: 02 bf ff ed be 2027518 <rtems_bdpart_unmount+0xa8> <== NOT EXECUTED
2027568: 80 a6 80 10 cmp %i2, %l0 <== NOT EXECUTED
202756c: b0 10 20 1b mov 0x1b, %i0 <== NOT EXECUTED
}
}
cleanup:
free( mount_point);
2027570: 7f ff 84 db call 20088dc <free> <== NOT EXECUTED
2027574: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return esc;
}
2027578: 81 c7 e0 08 ret <== NOT EXECUTED
202757c: 81 e8 00 00 restore <== NOT EXECUTED
/* Marker */
mount_marker = mount_point + mount_base_size + 1 + disk_file_name_size;
/* Mount supported file systems for each partition */
for (i = 0; i < count; ++i) {
2027580: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
}
cleanup:
free( mount_point);
2027584: 7f ff 84 d6 call 20088dc <free> <== NOT EXECUTED
2027588: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return esc;
}
202758c: 81 c7 e0 08 ret <== NOT EXECUTED
2027590: 81 e8 00 00 restore <== NOT EXECUTED
}
}
cleanup:
free( mount_point);
2027594: 7f ff 84 d2 call 20088dc <free> <== NOT EXECUTED
2027598: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return esc;
}
202759c: 81 c7 e0 08 ret <== NOT EXECUTED
20275a0: 81 e8 00 00 restore <== NOT EXECUTED
020063a0 <rtems_bdpart_unregister>:
rtems_status_code rtems_bdpart_unregister(
const char *disk_name,
const rtems_bdpart_partition *pt __attribute__((unused)),
size_t count
)
{
20063a0: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
rtems_blkdev_bnum disk_end = 0;
20063a4: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
dev_t disk = 0;
20063a8: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
20063ac: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
dev_t logical_disk = 0;
size_t i = 0;
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
20063b0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20063b4: 92 07 bf f0 add %fp, -16, %o1 <== NOT EXECUTED
20063b8: 40 00 85 09 call 20277dc <rtems_bdpart_get_disk_data> <== NOT EXECUTED
20063bc: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
20063c0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20063c4: 12 80 00 12 bne 200640c <rtems_bdpart_unregister+0x6c> <== NOT EXECUTED
20063c8: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
return sc;
}
/* Get the disk device identifier */
rtems_filesystem_split_dev_t( disk, major, minor);
20063cc: e4 07 bf f0 ld [ %fp + -16 ], %l2 <== NOT EXECUTED
/* Create a logical disk for each partition */
for (i = 0; i < count; ++i) {
20063d0: 02 80 00 0f be 200640c <rtems_bdpart_unregister+0x6c> <== NOT EXECUTED
20063d4: e0 07 bf f4 ld [ %fp + -12 ], %l0 <== NOT EXECUTED
20063d8: 10 80 00 04 b 20063e8 <rtems_bdpart_unregister+0x48> <== NOT EXECUTED
20063dc: a2 10 20 00 clr %l1 <== NOT EXECUTED
20063e0: 08 80 00 0b bleu 200640c <rtems_bdpart_unregister+0x6c> <== NOT EXECUTED
20063e4: 01 00 00 00 nop <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
20063e8: e4 27 bf e8 st %l2, [ %fp + -24 ] <== NOT EXECUTED
/* New minor number */
++minor;
20063ec: a0 04 20 01 inc %l0 <== NOT EXECUTED
temp.__overlay.minor = _minor;
20063f0: e0 27 bf ec st %l0, [ %fp + -20 ] <== NOT EXECUTED
/* Get the device identifier */
logical_disk = rtems_filesystem_make_dev_t( major, minor);
/* Delete logical disk */
sc = rtems_disk_delete( logical_disk);
20063f4: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
20063f8: 40 00 03 9c call 2007268 <rtems_disk_delete> <== NOT EXECUTED
20063fc: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2006400: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2006404: 02 bf ff f7 be 20063e0 <rtems_bdpart_unregister+0x40> <== NOT EXECUTED
2006408: 80 a6 80 11 cmp %i2, %l1 <== NOT EXECUTED
return sc;
}
}
return RTEMS_SUCCESSFUL;
}
200640c: 81 c7 e0 08 ret <== NOT EXECUTED
2006410: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02027d24 <rtems_bdpart_write>:
const char *disk_name,
const rtems_bdpart_format *format,
const rtems_bdpart_partition *pt,
size_t count
)
{
2027d24: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
2027d28: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2027d2c: 02 80 00 06 be 2027d44 <rtems_bdpart_write+0x20> <== NOT EXECUTED
2027d30: 82 10 00 18 mov %i0, %g1 <== NOT EXECUTED
&& format->type == RTEMS_BDPART_FORMAT_MBR
2027d34: c4 06 40 00 ld [ %i1 ], %g2 <== NOT EXECUTED
2027d38: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2027d3c: 22 80 00 43 be,a 2027e48 <rtems_bdpart_write+0x124> <== NOT EXECUTED
2027d40: c4 0e 60 08 ldub [ %i1 + 8 ], %g2 <== NOT EXECUTED
&& format->mbr.dos_compatibility;
rtems_bdbuf_buffer *block = NULL;
2027d44: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
rtems_blkdev_bnum disk_end = 0;
2027d48: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2027d4c: a2 10 20 00 clr %l1 <== NOT EXECUTED
2027d50: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
size_t ppc = 0; /* Primary partition count */
size_t i = 0;
uint8_t *data = NULL;
/* Check if we have something to do */
if (count == 0) {
2027d54: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2027d58: 02 80 00 3a be 2027e40 <rtems_bdpart_write+0x11c> <== NOT EXECUTED
2027d5c: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* Nothing to do */
return RTEMS_SUCCESSFUL;
}
/* Check parameter */
if (format == NULL || pt == NULL) {
2027d60: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2027d64: 12 80 00 04 bne 2027d74 <rtems_bdpart_write+0x50> <== NOT EXECUTED
2027d68: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2027d6c: 81 c7 e0 08 ret <== NOT EXECUTED
2027d70: 91 e8 20 09 restore %g0, 9, %o0 <== NOT EXECUTED
2027d74: 02 bf ff fe be 2027d6c <rtems_bdpart_write+0x48> <== NOT EXECUTED
2027d78: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
&& format->mbr.dos_compatibility;
rtems_bdbuf_buffer *block = NULL;
rtems_blkdev_bnum disk_end = 0;
rtems_blkdev_bnum record_space =
dos_compatibility ? RTEMS_BDPART_MBR_CYLINDER_SIZE : 1;
dev_t disk = 0;
2027d7c: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
2027d80: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
if (format == NULL || pt == NULL) {
return RTEMS_INVALID_ADDRESS;
}
/* Get disk data */
sc = rtems_bdpart_get_disk_data( disk_name, &disk, &disk_end);
2027d84: 92 07 bf e8 add %fp, -24, %o1 <== NOT EXECUTED
2027d88: 7f ff fe 95 call 20277dc <rtems_bdpart_get_disk_data> <== NOT EXECUTED
2027d8c: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027d90: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2027d94: 12 80 00 2b bne 2027e40 <rtems_bdpart_write+0x11c> <== NOT EXECUTED
2027d98: a6 8c 60 ff andcc %l1, 0xff, %l3 <== NOT EXECUTED
return sc;
}
/* Align end of disk on cylinder boundary if necessary */
if (dos_compatibility) {
2027d9c: 12 80 00 32 bne 2027e64 <rtems_bdpart_write+0x140> <== NOT EXECUTED
2027da0: e4 07 bf f4 ld [ %fp + -12 ], %l2 <== NOT EXECUTED
2027da4: d0 07 bf f4 ld [ %fp + -12 ], %o0 <== NOT EXECUTED
/* Check that we have a consistent partition table */
for (i = 0; i < count; ++i) {
const rtems_bdpart_partition *p = pt + i;
/* Check that begin and end are proper within the disk */
if (p->begin >= disk_end || p->end > disk_end) {
2027da8: da 06 80 00 ld [ %i2 ], %o5 <== NOT EXECUTED
2027dac: 80 a3 40 08 cmp %o5, %o0 <== NOT EXECUTED
2027db0: 1a 80 00 1e bcc 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027db4: aa 10 20 0a mov 0xa, %l5 <== NOT EXECUTED
2027db8: c2 06 a0 04 ld [ %i2 + 4 ], %g1 <== NOT EXECUTED
2027dbc: 80 a0 40 08 cmp %g1, %o0 <== NOT EXECUTED
2027dc0: 18 80 00 1a bgu 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027dc4: 80 a0 40 0d cmp %g1, %o5 <== NOT EXECUTED
esc = RTEMS_INVALID_NUMBER;
goto cleanup;
}
/* Check that begin and end are valid */
if (p->begin >= p->end) {
2027dc8: 28 80 00 19 bleu,a 2027e2c <rtems_bdpart_write+0x108> <== NOT EXECUTED
2027dcc: d0 07 bf f8 ld [ %fp + -8 ], %o0 <== NOT EXECUTED
2027dd0: a2 10 00 1a mov %i2, %l1 <== NOT EXECUTED
2027dd4: 82 10 00 1a mov %i2, %g1 <== NOT EXECUTED
2027dd8: 86 10 20 00 clr %g3 <== NOT EXECUTED
if (dos_compatibility) {
disk_end -= (disk_end % record_space);
}
/* Check that we have a consistent partition table */
for (i = 0; i < count; ++i) {
2027ddc: 86 00 e0 01 inc %g3 <== NOT EXECUTED
2027de0: 80 a6 c0 03 cmp %i3, %g3 <== NOT EXECUTED
2027de4: 28 80 00 26 bleu,a 2027e7c <rtems_bdpart_write+0x158> <== NOT EXECUTED
2027de8: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
const rtems_bdpart_partition *p = pt + i;
/* Check that begin and end are proper within the disk */
if (p->begin >= disk_end || p->end > disk_end) {
2027dec: c4 00 60 30 ld [ %g1 + 0x30 ], %g2 <== NOT EXECUTED
2027df0: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
2027df4: 3a 80 00 0d bcc,a 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027df8: aa 10 20 0a mov 0xa, %l5 <== NOT EXECUTED
2027dfc: c8 00 60 34 ld [ %g1 + 0x34 ], %g4 <== NOT EXECUTED
2027e00: 80 a1 00 08 cmp %g4, %o0 <== NOT EXECUTED
2027e04: 18 80 00 08 bgu 2027e24 <rtems_bdpart_write+0x100> <== NOT EXECUTED
2027e08: 80 a0 80 04 cmp %g2, %g4 <== NOT EXECUTED
esc = RTEMS_INVALID_NUMBER;
goto cleanup;
}
/* Check that begin and end are valid */
if (p->begin >= p->end) {
2027e0c: 3a 80 00 07 bcc,a 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027e10: aa 10 20 0a mov 0xa, %l5 <== NOT EXECUTED
esc = RTEMS_INVALID_NUMBER;
goto cleanup;
}
/* Check that partitions do not overlap */
if (i > 0 && pt [i - 1].end > p->begin) {
2027e14: c8 00 60 04 ld [ %g1 + 4 ], %g4 <== NOT EXECUTED
2027e18: 80 a0 80 04 cmp %g2, %g4 <== NOT EXECUTED
2027e1c: 1a bf ff f0 bcc 2027ddc <rtems_bdpart_write+0xb8> <== NOT EXECUTED
2027e20: 82 00 60 30 add %g1, 0x30, %g1 <== NOT EXECUTED
RTEMS_BDPART_MBR_EXTENDED,
0
);
/* Write logical partitions */
for (i = ppc; i < count; ++i) {
2027e24: aa 10 20 0a mov 0xa, %l5 <== NOT EXECUTED
}
}
cleanup:
if (block != NULL) {
2027e28: d0 07 bf f8 ld [ %fp + -8 ], %o0 <== NOT EXECUTED
2027e2c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2027e30: 02 80 00 04 be 2027e40 <rtems_bdpart_write+0x11c> <== NOT EXECUTED
2027e34: b0 10 00 15 mov %l5, %i0 <== NOT EXECUTED
rtems_bdbuf_sync( block);
2027e38: 7f ff 76 6d call 20057ec <rtems_bdbuf_sync> <== NOT EXECUTED
2027e3c: 01 00 00 00 nop <== NOT EXECUTED
}
return esc;
}
2027e40: 81 c7 e0 08 ret <== NOT EXECUTED
2027e44: 81 e8 00 00 restore <== NOT EXECUTED
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_status_code esc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
&& format->type == RTEMS_BDPART_FORMAT_MBR
&& format->mbr.dos_compatibility;
2027e48: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2027e4c: 02 bf ff bf be 2027d48 <rtems_bdpart_write+0x24> <== NOT EXECUTED
2027e50: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
rtems_bdbuf_buffer *block = NULL;
rtems_blkdev_bnum disk_end = 0;
2027e54: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2027e58: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
2027e5c: 10 bf ff be b 2027d54 <rtems_bdpart_write+0x30> <== NOT EXECUTED
2027e60: a0 10 20 3f mov 0x3f, %l0 <== NOT EXECUTED
return sc;
}
/* Align end of disk on cylinder boundary if necessary */
if (dos_compatibility) {
disk_end -= (disk_end % record_space);
2027e64: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2027e68: 40 00 eb 73 call 2062c34 <.urem> <== NOT EXECUTED
2027e6c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2027e70: 90 24 80 08 sub %l2, %o0, %o0 <== NOT EXECUTED
2027e74: 10 bf ff cd b 2027da8 <rtems_bdpart_write+0x84> <== NOT EXECUTED
2027e78: d0 27 bf f4 st %o0, [ %fp + -12 ] <== NOT EXECUTED
goto cleanup;
}
}
/* Check format */
if (format->type != RTEMS_BDPART_FORMAT_MBR) {
2027e7c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2027e80: 12 bf ff ea bne 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027e84: aa 10 20 18 mov 0x18, %l5 <== NOT EXECUTED
* Set primary partition count. If we have more than four partitions we need
* an extended partition which will contain the partitions of number four and
* above as logical partitions. If we have four or less partitions we can
* use the primary partition table.
*/
ppc = count <= 4 ? count : 3;
2027e88: 80 a6 e0 04 cmp %i3, 4 <== NOT EXECUTED
2027e8c: 18 80 00 03 bgu 2027e98 <rtems_bdpart_write+0x174> <== NOT EXECUTED
2027e90: a4 10 20 03 mov 3, %l2 <== NOT EXECUTED
2027e94: a4 10 00 1b mov %i3, %l2 <== NOT EXECUTED
/*
* Check that the first primary partition starts at head one and sector one
* under the virtual one head and 63 sectors geometry if necessary.
*/
if (dos_compatibility && pt [0].begin != RTEMS_BDPART_MBR_CYLINDER_SIZE) {
2027e98: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2027e9c: 02 80 00 06 be 2027eb4 <rtems_bdpart_write+0x190> <== NOT EXECUTED
2027ea0: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2027ea4: 80 a3 60 3f cmp %o5, 0x3f <== NOT EXECUTED
2027ea8: 32 bf ff e0 bne,a 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027eac: aa 10 20 0a mov 0xa, %l5 <== NOT EXECUTED
* Each logical partition is described via one EBR preceding the partition.
* The space for the EBR and maybe some space which is needed for DOS
* compatibility resides between the partitions. So there have to be gaps of
* the appropriate size between the partitions.
*/
for (i = ppc; i < count; ++i) {
2027eb0: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2027eb4: 1a 80 00 21 bcc 2027f38 <rtems_bdpart_write+0x214> <== NOT EXECUTED
2027eb8: 89 2c a0 06 sll %l2, 6, %g4 <== NOT EXECUTED
if ((pt [i].begin - pt [i - 1].end) < record_space) {
2027ebc: 84 04 bf ff add %l2, -1, %g2 <== NOT EXECUTED
2027ec0: 83 2c a0 04 sll %l2, 4, %g1 <== NOT EXECUTED
2027ec4: 87 28 a0 06 sll %g2, 6, %g3 <== NOT EXECUTED
2027ec8: 82 21 00 01 sub %g4, %g1, %g1 <== NOT EXECUTED
2027ecc: 85 28 a0 04 sll %g2, 4, %g2 <== NOT EXECUTED
2027ed0: c8 06 80 01 ld [ %i2 + %g1 ], %g4 <== NOT EXECUTED
2027ed4: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
2027ed8: 84 06 80 02 add %i2, %g2, %g2 <== NOT EXECUTED
2027edc: c4 00 a0 04 ld [ %g2 + 4 ], %g2 <== NOT EXECUTED
2027ee0: 84 21 00 02 sub %g4, %g2, %g2 <== NOT EXECUTED
2027ee4: 80 a4 00 02 cmp %l0, %g2 <== NOT EXECUTED
2027ee8: 18 bf ff cf bgu 2027e24 <rtems_bdpart_write+0x100> <== NOT EXECUTED
2027eec: 82 06 80 01 add %i2, %g1, %g1 <== NOT EXECUTED
2027ef0: 86 00 60 04 add %g1, 4, %g3 <== NOT EXECUTED
2027ef4: 82 04 a0 01 add %l2, 1, %g1 <== NOT EXECUTED
2027ef8: 85 28 60 06 sll %g1, 6, %g2 <== NOT EXECUTED
2027efc: 83 28 60 04 sll %g1, 4, %g1 <== NOT EXECUTED
2027f00: 84 20 80 01 sub %g2, %g1, %g2 <== NOT EXECUTED
2027f04: 82 10 00 12 mov %l2, %g1 <== NOT EXECUTED
2027f08: 10 80 00 08 b 2027f28 <rtems_bdpart_write+0x204> <== NOT EXECUTED
2027f0c: 84 06 80 02 add %i2, %g2, %g2 <== NOT EXECUTED
2027f10: c8 00 c0 00 ld [ %g3 ], %g4 <== NOT EXECUTED
2027f14: 84 00 a0 30 add %g2, 0x30, %g2 <== NOT EXECUTED
2027f18: 88 23 40 04 sub %o5, %g4, %g4 <== NOT EXECUTED
2027f1c: 80 a4 00 04 cmp %l0, %g4 <== NOT EXECUTED
2027f20: 18 bf ff c1 bgu 2027e24 <rtems_bdpart_write+0x100> <== NOT EXECUTED
2027f24: 86 00 e0 30 add %g3, 0x30, %g3 <== NOT EXECUTED
* Each logical partition is described via one EBR preceding the partition.
* The space for the EBR and maybe some space which is needed for DOS
* compatibility resides between the partitions. So there have to be gaps of
* the appropriate size between the partitions.
*/
for (i = ppc; i < count; ++i) {
2027f28: 82 00 60 01 inc %g1 <== NOT EXECUTED
2027f2c: 80 a6 c0 01 cmp %i3, %g1 <== NOT EXECUTED
2027f30: 38 bf ff f8 bgu,a 2027f10 <rtems_bdpart_write+0x1ec> <== NOT EXECUTED
2027f34: da 00 80 00 ld [ %g2 ], %o5 <== NOT EXECUTED
2027f38: a6 10 00 1a mov %i2, %l3 <== NOT EXECUTED
2027f3c: a8 10 20 00 clr %l4 <== NOT EXECUTED
2027f40: 10 80 00 0c b 2027f70 <rtems_bdpart_write+0x24c> <== NOT EXECUTED
2027f44: aa 07 bf ff add %fp, -1, %l5 <== NOT EXECUTED
esc = RTEMS_INVALID_ID;
goto cleanup;
}
/* Check flags */
if (p->flags > 0xffU) {
2027f48: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2027f4c: 32 bf ff b7 bne,a 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027f50: aa 10 20 04 mov 4, %l5 <== NOT EXECUTED
2027f54: c2 04 e0 2c ld [ %l3 + 0x2c ], %g1 <== NOT EXECUTED
2027f58: 80 a0 60 ff cmp %g1, 0xff <== NOT EXECUTED
2027f5c: 18 80 00 0d bgu 2027f90 <rtems_bdpart_write+0x26c> <== NOT EXECUTED
2027f60: a6 04 e0 30 add %l3, 0x30, %l3 <== NOT EXECUTED
goto cleanup;
}
}
/* Check that we can convert the parition descriptions to the MBR format */
for (i = 0; i < count; ++i) {
2027f64: 80 a6 c0 14 cmp %i3, %l4 <== NOT EXECUTED
2027f68: 08 80 00 0c bleu 2027f98 <rtems_bdpart_write+0x274> <== NOT EXECUTED
2027f6c: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
uint8_t type = 0;
2027f70: c0 2f bf ff clrb [ %fp + -1 ] <== NOT EXECUTED
const rtems_bdpart_partition *p = pt + i;
/* Check type */
if (!rtems_bdpart_to_mbr_partition_type( p->type, &type)) {
2027f74: 90 04 e0 08 add %l3, 8, %o0 <== NOT EXECUTED
2027f78: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2027f7c: 7f ff fe 36 call 2027854 <rtems_bdpart_to_mbr_partition_type><== NOT EXECUTED
2027f80: a8 05 20 01 inc %l4 <== NOT EXECUTED
2027f84: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
2027f88: 32 bf ff f0 bne,a 2027f48 <rtems_bdpart_write+0x224> <== NOT EXECUTED
2027f8c: c2 04 e0 28 ld [ %l3 + 0x28 ], %g1 <== NOT EXECUTED
RTEMS_BDPART_MBR_EXTENDED,
0
);
/* Write logical partitions */
for (i = ppc; i < count; ++i) {
2027f90: 10 bf ff a6 b 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2027f94: aa 10 20 04 mov 4, %l5 <== NOT EXECUTED
/* Check ID */
/* TODO */
}
/* New MBR */
sc = rtems_bdpart_new_record( disk, 0, &block);
2027f98: a8 07 bf f8 add %fp, -8, %l4 <== NOT EXECUTED
2027f9c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2027fa0: 7f ff ff 3b call 2027c8c <rtems_bdpart_new_record> <== NOT EXECUTED
2027fa4: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2027fa8: aa 92 20 00 orcc %o0, 0, %l5 <== NOT EXECUTED
2027fac: 12 bf ff a0 bne 2027e2c <rtems_bdpart_write+0x108> <== NOT EXECUTED
2027fb0: d0 07 bf f8 ld [ %fp + -8 ], %o0 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Write disk ID */
rtems_uint32_to_little_endian(
2027fb4: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
2027fb8: c2 06 60 04 ld [ %i1 + 4 ], %g1 <== NOT EXECUTED
2027fbc: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2027fc0: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
2027fc4: c2 28 a1 b8 stb %g1, [ %g2 + 0x1b8 ] <== NOT EXECUTED
2027fc8: 84 00 a1 b8 add %g2, 0x1b8, %g2 <== NOT EXECUTED
2027fcc: c6 28 a0 03 stb %g3, [ %g2 + 3 ] <== NOT EXECUTED
value >>= 8;
2027fd0: 87 30 60 08 srl %g1, 8, %g3 <== NOT EXECUTED
2027fd4: 83 30 60 10 srl %g1, 0x10, %g1 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2027fd8: c6 28 a0 01 stb %g3, [ %g2 + 1 ] <== NOT EXECUTED
2027fdc: c2 28 a0 02 stb %g1, [ %g2 + 2 ] <== NOT EXECUTED
format->mbr.disk_id,
block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID
);
/* Write primary partition table */
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
2027fe0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2027fe4: 88 10 20 00 clr %g4 <== NOT EXECUTED
2027fe8: d6 00 60 24 ld [ %g1 + 0x24 ], %o3 <== NOT EXECUTED
2027fec: 96 02 e1 be add %o3, 0x1be, %o3 <== NOT EXECUTED
2027ff0: 82 10 00 0b mov %o3, %g1 <== NOT EXECUTED
for (i = 0; i < ppc; ++i) {
const rtems_bdpart_partition *p = pt + i;
/* Write partition entry */
rtems_bdpart_write_mbr_partition(
2027ff4: c4 1c 40 00 ldd [ %l1 ], %g2 <== NOT EXECUTED
data,
p->begin,
p->end - p->begin,
rtems_bdpart_mbr_partition_type( p->type),
(uint8_t) p->flags
2027ff8: da 04 60 2c ld [ %l1 + 0x2c ], %o5 <== NOT EXECUTED
static inline uint8_t rtems_bdpart_mbr_partition_type(
const uuid_t type
)
{
return type [0];
2027ffc: d8 0c 60 08 ldub [ %l1 + 8 ], %o4 <== NOT EXECUTED
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
for (i = 0; i < ppc; ++i) {
const rtems_bdpart_partition *p = pt + i;
/* Write partition entry */
rtems_bdpart_write_mbr_partition(
2028000: 86 20 c0 02 sub %g3, %g2, %g3 <== NOT EXECUTED
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
data [RTEMS_BDPART_MBR_OFFSET_FLAGS] = flags;
2028004: da 28 40 00 stb %o5, [ %g1 ] <== NOT EXECUTED
2028008: 9b 30 e0 18 srl %g3, 0x18, %o5 <== NOT EXECUTED
202800c: da 28 60 0f stb %o5, [ %g1 + 0xf ] <== NOT EXECUTED
value >>= 8;
2028010: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028014: c4 28 60 08 stb %g2, [ %g1 + 8 ] <== NOT EXECUTED
2028018: da 28 60 09 stb %o5, [ %g1 + 9 ] <== NOT EXECUTED
value >>= 8;
202801c: 9b 30 a0 10 srl %g2, 0x10, %o5 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028020: 85 30 a0 18 srl %g2, 0x18, %g2 <== NOT EXECUTED
2028024: c6 28 60 0c stb %g3, [ %g1 + 0xc ] <== NOT EXECUTED
2028028: c4 28 60 0b stb %g2, [ %g1 + 0xb ] <== NOT EXECUTED
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
202802c: d8 28 60 04 stb %o4, [ %g1 + 4 ] <== NOT EXECUTED
value >>= 8;
2028030: 85 30 e0 08 srl %g3, 8, %g2 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028034: da 28 60 0a stb %o5, [ %g1 + 0xa ] <== NOT EXECUTED
2028038: c4 28 60 0d stb %g2, [ %g1 + 0xd ] <== NOT EXECUTED
value >>= 8;
202803c: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028040: c6 28 60 0e stb %g3, [ %g1 + 0xe ] <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID
);
/* Write primary partition table */
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
for (i = 0; i < ppc; ++i) {
2028044: 88 01 20 01 inc %g4 <== NOT EXECUTED
p->end - p->begin,
rtems_bdpart_mbr_partition_type( p->type),
(uint8_t) p->flags
);
data += RTEMS_BDPART_MBR_TABLE_ENTRY_SIZE;
2028048: 82 00 60 10 add %g1, 0x10, %g1 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID
);
/* Write primary partition table */
data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;
for (i = 0; i < ppc; ++i) {
202804c: 80 a4 80 04 cmp %l2, %g4 <== NOT EXECUTED
2028050: 18 bf ff e9 bgu 2027ff4 <rtems_bdpart_write+0x2d0> <== NOT EXECUTED
2028054: a2 04 60 30 add %l1, 0x30, %l1 <== NOT EXECUTED
2028058: 87 2c a0 04 sll %l2, 4, %g3 <== NOT EXECUTED
data += RTEMS_BDPART_MBR_TABLE_ENTRY_SIZE;
}
/* Write extended partition with logical partitions if necessary */
if (ppc != count) {
202805c: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2028060: 02 80 00 67 be 20281fc <rtems_bdpart_write+0x4d8> <== NOT EXECUTED
2028064: 82 02 c0 03 add %o3, %g3, %g1 <== NOT EXECUTED
rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */
/* Begin of extended partition */
rtems_blkdev_bnum ep_begin = pt [ppc].begin - record_space;
2028068: a3 2c a0 06 sll %l2, 6, %l1 <== NOT EXECUTED
202806c: a2 24 40 03 sub %l1, %g3, %l1 <== NOT EXECUTED
2028070: e6 06 80 11 ld [ %i2 + %l1 ], %l3 <== NOT EXECUTED
/* Write extended partition */
rtems_bdpart_write_mbr_partition(
2028074: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
/* Write extended partition with logical partitions if necessary */
if (ppc != count) {
rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */
/* Begin of extended partition */
rtems_blkdev_bnum ep_begin = pt [ppc].begin - record_space;
2028078: a6 24 c0 10 sub %l3, %l0, %l3 <== NOT EXECUTED
202807c: e6 28 60 08 stb %l3, [ %g1 + 8 ] <== NOT EXECUTED
value >>= 8;
2028080: 9b 34 e0 08 srl %l3, 8, %o5 <== NOT EXECUTED
uint32_t size,
uint8_t type,
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
2028084: 88 00 60 08 add %g1, 8, %g4 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028088: da 29 20 01 stb %o5, [ %g4 + 1 ] <== NOT EXECUTED
value >>= 8;
202808c: 9b 34 e0 10 srl %l3, 0x10, %o5 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028090: da 29 20 02 stb %o5, [ %g4 + 2 ] <== NOT EXECUTED
2028094: 9b 34 e0 18 srl %l3, 0x18, %o5 <== NOT EXECUTED
2028098: da 29 20 03 stb %o5, [ %g4 + 3 ] <== NOT EXECUTED
/* Begin of extended partition */
rtems_blkdev_bnum ep_begin = pt [ppc].begin - record_space;
/* Write extended partition */
rtems_bdpart_write_mbr_partition(
202809c: 84 20 80 13 sub %g2, %l3, %g2 <== NOT EXECUTED
20280a0: c4 28 60 0c stb %g2, [ %g1 + 0xc ] <== NOT EXECUTED
20280a4: 9b 30 a0 18 srl %g2, 0x18, %o5 <== NOT EXECUTED
uint8_t type,
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
20280a8: 88 00 60 0c add %g1, 0xc, %g4 <== NOT EXECUTED
20280ac: da 29 20 03 stb %o5, [ %g4 + 3 ] <== NOT EXECUTED
value >>= 8;
20280b0: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
20280b4: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
20280b8: da 29 20 01 stb %o5, [ %g4 + 1 ] <== NOT EXECUTED
20280bc: c4 29 20 02 stb %g2, [ %g4 + 2 ] <== NOT EXECUTED
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
20280c0: 84 10 20 05 mov 5, %g2 <== NOT EXECUTED
20280c4: c4 28 60 04 stb %g2, [ %g1 + 4 ] <== NOT EXECUTED
data [RTEMS_BDPART_MBR_OFFSET_FLAGS] = flags;
20280c8: c0 2a c0 03 clrb [ %o3 + %g3 ] <== NOT EXECUTED
RTEMS_BDPART_MBR_EXTENDED,
0
);
/* Write logical partitions */
for (i = ppc; i < count; ++i) {
20280cc: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
20280d0: 1a 80 00 4b bcc 20281fc <rtems_bdpart_write+0x4d8> <== NOT EXECUTED
20280d4: a2 06 80 11 add %i2, %l1, %l1 <== NOT EXECUTED
rtems_status_code esc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
&& format->type == RTEMS_BDPART_FORMAT_MBR
&& format->mbr.dos_compatibility;
rtems_bdbuf_buffer *block = NULL;
rtems_blkdev_bnum disk_end = 0;
20280d8: 82 04 a0 01 add %l2, 1, %g1 <== NOT EXECUTED
20280dc: b2 10 00 12 mov %l2, %i1 <== NOT EXECUTED
20280e0: 85 28 60 06 sll %g1, 6, %g2 <== NOT EXECUTED
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
20280e4: aa 10 20 05 mov 5, %l5 <== NOT EXECUTED
rtems_status_code esc = RTEMS_SUCCESSFUL;
bool dos_compatibility = format != NULL
&& format->type == RTEMS_BDPART_FORMAT_MBR
&& format->mbr.dos_compatibility;
rtems_bdbuf_buffer *block = NULL;
rtems_blkdev_bnum disk_end = 0;
20280e8: 83 28 60 04 sll %g1, 4, %g1 <== NOT EXECUTED
20280ec: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
20280f0: b4 06 80 01 add %i2, %g1, %i2 <== NOT EXECUTED
);
}
/* New EBR */
ebr = p->begin - record_space;
sc = rtems_bdpart_new_record( disk, ebr, &block);
20280f4: d4 04 40 00 ld [ %l1 ], %o2 <== NOT EXECUTED
20280f8: d0 1f bf e8 ldd [ %fp + -24 ], %o0 <== NOT EXECUTED
20280fc: 94 22 80 10 sub %o2, %l0, %o2 <== NOT EXECUTED
2028100: 7f ff fe e3 call 2027c8c <rtems_bdpart_new_record> <== NOT EXECUTED
2028104: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) {
2028108: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202810c: 12 80 00 3e bne 2028204 <rtems_bdpart_write+0x4e0> <== NOT EXECUTED
2028110: 84 10 00 10 mov %l0, %g2 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Write first partition entry */
rtems_bdpart_write_mbr_partition(
2028114: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0,
record_space,
p->end - p->begin,
rtems_bdpart_mbr_partition_type( p->type),
(uint8_t) p->flags
2028118: d8 04 60 2c ld [ %l1 + 0x2c ], %o4 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Write first partition entry */
rtems_bdpart_write_mbr_partition(
202811c: c8 00 60 24 ld [ %g1 + 0x24 ], %g4 <== NOT EXECUTED
2028120: d2 04 60 04 ld [ %l1 + 4 ], %o1 <== NOT EXECUTED
2028124: d4 04 40 00 ld [ %l1 ], %o2 <== NOT EXECUTED
2028128: d6 0c 60 08 ldub [ %l1 + 8 ], %o3 <== NOT EXECUTED
block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0,
record_space,
p->end - p->begin,
rtems_bdpart_mbr_partition_type( p->type),
(uint8_t) p->flags
202812c: 82 10 00 04 mov %g4, %g1 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Write first partition entry */
rtems_bdpart_write_mbr_partition(
2028130: 9a 01 21 be add %g4, 0x1be, %o5 <== NOT EXECUTED
RTEMS_BDPART_MBR_SIGNATURE_1;
return RTEMS_SUCCESSFUL;
}
rtems_status_code rtems_bdpart_write(
2028134: 86 01 20 04 add %g4, 4, %g3 <== NOT EXECUTED
2028138: c4 28 61 c6 stb %g2, [ %g1 + 0x1c6 ] <== NOT EXECUTED
202813c: 82 00 60 01 inc %g1 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
2028140: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
2028144: 12 bf ff fd bne 2028138 <rtems_bdpart_write+0x414> <== NOT EXECUTED
2028148: 84 10 20 00 clr %g2 <== NOT EXECUTED
esc = sc;
goto cleanup;
}
/* Write first partition entry */
rtems_bdpart_write_mbr_partition(
202814c: 82 22 40 0a sub %o1, %o2, %g1 <== NOT EXECUTED
data [i] = (uint8_t) value;
2028150: c2 2b 60 0c stb %g1, [ %o5 + 0xc ] <== NOT EXECUTED
2028154: 87 30 60 18 srl %g1, 0x18, %g3 <== NOT EXECUTED
uint8_t type,
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
2028158: 84 03 60 0c add %o5, 0xc, %g2 <== NOT EXECUTED
202815c: c6 28 a0 03 stb %g3, [ %g2 + 3 ] <== NOT EXECUTED
value >>= 8;
2028160: 87 30 60 08 srl %g1, 8, %g3 <== NOT EXECUTED
2028164: 83 30 60 10 srl %g1, 0x10, %g1 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
2028168: c6 28 a0 01 stb %g3, [ %g2 + 1 ] <== NOT EXECUTED
202816c: c2 28 a0 02 stb %g1, [ %g2 + 2 ] <== NOT EXECUTED
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
2028170: d6 2b 60 04 stb %o3, [ %o5 + 4 ] <== NOT EXECUTED
RTEMS_BDPART_MBR_EXTENDED,
0
);
/* Write logical partitions */
for (i = ppc; i < count; ++i) {
2028174: b2 06 60 01 inc %i1 <== NOT EXECUTED
2028178: 80 a6 c0 19 cmp %i3, %i1 <== NOT EXECUTED
202817c: 08 80 00 20 bleu 20281fc <rtems_bdpart_write+0x4d8> <== NOT EXECUTED
2028180: d8 29 21 be stb %o4, [ %g4 + 0x1be ] <== NOT EXECUTED
const rtems_bdpart_partition *p = pt + i;
/* Write second partition entry */
if (i > ppc) {
2028184: 80 a4 80 19 cmp %l2, %i1 <== NOT EXECUTED
2028188: 1a 80 00 1b bcc 20281f4 <rtems_bdpart_write+0x4d0> <== NOT EXECUTED
202818c: a2 10 00 1a mov %i2, %l1 <== NOT EXECUTED
rtems_blkdev_bnum begin = p->begin - record_space;
rtems_bdpart_write_mbr_partition(
2028190: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
for (i = ppc; i < count; ++i) {
const rtems_bdpart_partition *p = pt + i;
/* Write second partition entry */
if (i > ppc) {
rtems_blkdev_bnum begin = p->begin - record_space;
2028194: c4 06 80 00 ld [ %i2 ], %g2 <== NOT EXECUTED
rtems_bdpart_write_mbr_partition(
2028198: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
202819c: da 07 bf f4 ld [ %fp + -12 ], %o5 <== NOT EXECUTED
for (i = ppc; i < count; ++i) {
const rtems_bdpart_partition *p = pt + i;
/* Write second partition entry */
if (i > ppc) {
rtems_blkdev_bnum begin = p->begin - record_space;
20281a0: 84 20 80 10 sub %g2, %l0, %g2 <== NOT EXECUTED
rtems_bdpart_write_mbr_partition(
20281a4: 86 20 80 13 sub %g2, %l3, %g3 <== NOT EXECUTED
20281a8: c6 28 61 d6 stb %g3, [ %g1 + 0x1d6 ] <== NOT EXECUTED
20281ac: 99 30 e0 18 srl %g3, 0x18, %o4 <== NOT EXECUTED
uint32_t size,
uint8_t type,
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
20281b0: 88 00 61 d6 add %g1, 0x1d6, %g4 <== NOT EXECUTED
20281b4: d8 29 20 03 stb %o4, [ %g4 + 3 ] <== NOT EXECUTED
value >>= 8;
20281b8: 99 30 e0 08 srl %g3, 8, %o4 <== NOT EXECUTED
20281bc: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
20281c0: d8 29 20 01 stb %o4, [ %g4 + 1 ] <== NOT EXECUTED
20281c4: c6 29 20 02 stb %g3, [ %g4 + 2 ] <== NOT EXECUTED
/* Write second partition entry */
if (i > ppc) {
rtems_blkdev_bnum begin = p->begin - record_space;
rtems_bdpart_write_mbr_partition(
20281c8: 84 23 40 02 sub %o5, %g2, %g2 <== NOT EXECUTED
20281cc: c4 28 61 da stb %g2, [ %g1 + 0x1da ] <== NOT EXECUTED
20281d0: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
uint8_t type,
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
20281d4: 86 00 61 da add %g1, 0x1da, %g3 <== NOT EXECUTED
20281d8: c8 28 e0 03 stb %g4, [ %g3 + 3 ] <== NOT EXECUTED
value >>= 8;
20281dc: 89 30 a0 08 srl %g2, 8, %g4 <== NOT EXECUTED
20281e0: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{
size_t i = 0;
for (i = 0; i < 4; ++i) {
data [i] = (uint8_t) value;
20281e4: c8 28 e0 01 stb %g4, [ %g3 + 1 ] <== NOT EXECUTED
20281e8: c4 28 e0 02 stb %g2, [ %g3 + 2 ] <== NOT EXECUTED
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
data [RTEMS_BDPART_MBR_OFFSET_FLAGS] = flags;
20281ec: c0 28 61 ce clrb [ %g1 + 0x1ce ] <== NOT EXECUTED
uint8_t flags
)
{
rtems_uint32_to_little_endian( begin, data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
rtems_uint32_to_little_endian( size, data + RTEMS_BDPART_MBR_OFFSET_SIZE);
data [RTEMS_BDPART_MBR_OFFSET_TYPE] = type;
20281f0: ea 28 61 d2 stb %l5, [ %g1 + 0x1d2 ] <== NOT EXECUTED
data [RTEMS_BDPART_MBR_OFFSET_FLAGS] = flags;
20281f4: 10 bf ff c0 b 20280f4 <rtems_bdpart_write+0x3d0> <== NOT EXECUTED
20281f8: b4 06 a0 30 add %i2, 0x30, %i2 <== NOT EXECUTED
RTEMS_BDPART_MBR_EXTENDED,
0
);
/* Write logical partitions */
for (i = ppc; i < count; ++i) {
20281fc: 10 bf ff 0b b 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2028200: aa 10 20 00 clr %l5 <== NOT EXECUTED
}
/* New EBR */
ebr = p->begin - record_space;
sc = rtems_bdpart_new_record( disk, ebr, &block);
if (sc != RTEMS_SUCCESSFUL) {
2028204: 10 bf ff 09 b 2027e28 <rtems_bdpart_write+0x104> <== NOT EXECUTED
2028208: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
0200e9d4 <rtems_blkdev_generic_ioctl>:
rtems_device_driver
rtems_blkdev_generic_ioctl(
rtems_device_major_number major __attribute__((unused)),
rtems_device_minor_number minor __attribute__((unused)),
void * arg)
{
200e9d4: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_ioctl_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
200e9d8: c2 06 80 00 ld [ %i2 ], %g1
int rc;
switch (args->command)
200e9dc: d2 06 a0 04 ld [ %i2 + 4 ], %o1
200e9e0: 07 10 01 10 sethi %hi(0x40044000), %g3
200e9e4: 84 10 e2 03 or %g3, 0x203, %g2 ! 40044203 <RAM_END+0x3dc44203>
200e9e8: 80 a2 40 02 cmp %o1, %g2
200e9ec: 02 80 00 3d be 200eae0 <rtems_blkdev_generic_ioctl+0x10c> <== NEVER TAKEN
200e9f0: c2 00 60 38 ld [ %g1 + 0x38 ], %g1
200e9f4: 80 a2 40 02 cmp %o1, %g2
200e9f8: 08 80 00 16 bleu 200ea50 <rtems_blkdev_generic_ioctl+0x7c><== NEVER TAKEN
200e9fc: 05 08 00 10 sethi %hi(0x20004000), %g2
200ea00: 05 20 01 10 sethi %hi(0x80044000), %g2
200ea04: 84 10 a2 04 or %g2, 0x204, %g2 ! 80044204 <RAM_END+0x7dc44204>
200ea08: 80 a2 40 02 cmp %o1, %g2
200ea0c: 02 80 00 22 be 200ea94 <rtems_blkdev_generic_ioctl+0xc0> <== ALWAYS TAKEN
200ea10: 05 30 06 10 sethi %hi(0xc0184000), %g2
200ea14: 84 10 a2 01 or %g2, 0x201, %g2 ! c0184201 <RAM_END+0xbdd84201><== NOT EXECUTED
200ea18: 80 a2 40 02 cmp %o1, %g2 <== NOT EXECUTED
200ea1c: 02 80 00 1a be 200ea84 <rtems_blkdev_generic_ioctl+0xb0> <== NOT EXECUTED
200ea20: 86 10 e2 05 or %g3, 0x205, %g3 <== NOT EXECUTED
200ea24: 80 a2 40 03 cmp %o1, %g3 <== NOT EXECUTED
200ea28: 22 80 00 21 be,a 200eaac <rtems_blkdev_generic_ioctl+0xd8><== NOT EXECUTED
200ea2c: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 <== NOT EXECUTED
*/
args->ioctl_return = (uint32_t) -1;
break;
default:
args->ioctl_return = (uint32_t) dd->ioctl(dd->phys_dev,
200ea30: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
200ea34: d4 06 a0 08 ld [ %i2 + 8 ], %o2 <== NOT EXECUTED
200ea38: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 <== NOT EXECUTED
200ea3c: 9f c0 40 00 call %g1 <== NOT EXECUTED
200ea40: b0 10 20 00 clr %i0 <== NOT EXECUTED
200ea44: d0 26 a0 0c st %o0, [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200ea48: 81 c7 e0 08 ret <== NOT EXECUTED
200ea4c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_libio_ioctl_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
int rc;
switch (args->command)
200ea50: 84 10 a2 06 or %g2, 0x206, %g2 <== NOT EXECUTED
200ea54: 80 a2 40 02 cmp %o1, %g2 <== NOT EXECUTED
200ea58: 02 80 00 1a be 200eac0 <rtems_blkdev_generic_ioctl+0xec> <== NOT EXECUTED
200ea5c: 86 10 e2 02 or %g3, 0x202, %g3 <== NOT EXECUTED
200ea60: 80 a2 40 03 cmp %o1, %g3 <== NOT EXECUTED
200ea64: 32 bf ff f4 bne,a 200ea34 <rtems_blkdev_generic_ioctl+0x60><== NOT EXECUTED
200ea68: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
{
case RTEMS_BLKIO_GETMEDIABLKSIZE:
*((uint32_t *) args->buffer) = dd->media_block_size;
200ea6c: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
200ea70: c2 06 a0 08 ld [ %i2 + 8 ], %g1 <== NOT EXECUTED
200ea74: c4 20 40 00 st %g2, [ %g1 ] <== NOT EXECUTED
args->ioctl_return = 0;
200ea78: c0 26 a0 0c clr [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200ea7c: 81 c7 e0 08 ret <== NOT EXECUTED
200ea80: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
case RTEMS_BLKIO_REQUEST:
/*
* It is not allowed to directly access the driver circumventing
* the cache.
*/
args->ioctl_return = (uint32_t) -1;
200ea84: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
200ea88: c2 26 a0 0c st %g1, [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200ea8c: 81 c7 e0 08 ret <== NOT EXECUTED
200ea90: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*((uint32_t *) args->buffer) = dd->block_size;
args->ioctl_return = 0;
break;
case RTEMS_BLKIO_SETBLKSIZE:
dd->block_size = *((uint32_t *) args->buffer);
200ea94: c4 06 a0 08 ld [ %i2 + 8 ], %g2
200ea98: c4 00 80 00 ld [ %g2 ], %g2
200ea9c: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
args->ioctl_return = 0;
200eaa0: c0 26 a0 0c clr [ %i2 + 0xc ]
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200eaa4: 81 c7 e0 08 ret
200eaa8: 91 e8 20 00 restore %g0, 0, %o0
dd->block_size = *((uint32_t *) args->buffer);
args->ioctl_return = 0;
break;
case RTEMS_BLKIO_GETSIZE:
*((rtems_blkdev_bnum *) args->buffer) = dd->size;
200eaac: c2 06 a0 08 ld [ %i2 + 8 ], %g1 <== NOT EXECUTED
200eab0: c4 20 40 00 st %g2, [ %g1 ] <== NOT EXECUTED
args->ioctl_return = 0;
200eab4: c0 26 a0 0c clr [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200eab8: 81 c7 e0 08 ret <== NOT EXECUTED
200eabc: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*((rtems_blkdev_bnum *) args->buffer) = dd->size;
args->ioctl_return = 0;
break;
case RTEMS_BLKIO_SYNCDEV:
rc = rtems_bdbuf_syncdev(dd->dev);
200eac0: d0 18 40 00 ldd [ %g1 ], %o0 <== NOT EXECUTED
200eac4: 7f ff f7 29 call 200c768 <rtems_bdbuf_syncdev> <== NOT EXECUTED
200eac8: b0 10 20 00 clr %i0 <== NOT EXECUTED
args->ioctl_return = (uint32_t) (rc == RTEMS_SUCCESSFUL ? 0 : -1);
200eacc: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
200ead0: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
200ead4: c2 26 a0 0c st %g1, [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200ead8: 81 c7 e0 08 ret <== NOT EXECUTED
200eadc: 81 e8 00 00 restore <== NOT EXECUTED
*((uint32_t *) args->buffer) = dd->media_block_size;
args->ioctl_return = 0;
break;
case RTEMS_BLKIO_GETBLKSIZE:
*((uint32_t *) args->buffer) = dd->block_size;
200eae0: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 <== NOT EXECUTED
200eae4: c2 06 a0 08 ld [ %i2 + 8 ], %g1 <== NOT EXECUTED
200eae8: c4 20 40 00 st %g2, [ %g1 ] <== NOT EXECUTED
args->ioctl_return = 0;
200eaec: c0 26 a0 0c clr [ %i2 + 0xc ] <== NOT EXECUTED
args->buffer);
break;
}
return RTEMS_SUCCESSFUL;
}
200eaf0: 81 c7 e0 08 ret <== NOT EXECUTED
200eaf4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0200ec54 <rtems_blkdev_generic_read>:
rtems_device_driver
rtems_blkdev_generic_read(
rtems_device_major_number major __attribute__((unused)),
rtems_device_minor_number minor __attribute__((unused)),
void * arg)
{
200ec54: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
200ec58: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
200ec5c: e0 06 a0 14 ld [ %i2 + 0x14 ], %l0 <== NOT EXECUTED
void * arg)
{
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
200ec60: c2 00 60 38 ld [ %g1 + 0x38 ], %g1 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200ec64: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
{
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
200ec68: e8 00 60 20 ld [ %g1 + 0x20 ], %l4 <== NOT EXECUTED
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
200ec6c: c0 26 a0 1c clr [ %i2 + 0x1c ] <== NOT EXECUTED
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
200ec70: ec 18 40 00 ldd [ %g1 ], %l6 <== NOT EXECUTED
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
200ec74: e2 06 a0 10 ld [ %i2 + 0x10 ], %l1 <== NOT EXECUTED
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200ec78: f8 1e a0 08 ldd [ %i2 + 8 ], %i4 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200ec7c: 02 80 00 2f be 200ed38 <rtems_blkdev_generic_read+0xe4> <== NOT EXECUTED
200ec80: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200ec84: 94 10 20 00 clr %o2 <== NOT EXECUTED
200ec88: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
200ec8c: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
200ec90: 40 00 42 42 call 201f598 <__divdi3> <== NOT EXECUTED
200ec94: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
200ec98: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200ec9c: a4 10 00 09 mov %o1, %l2 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
200eca0: 94 10 20 00 clr %o2 <== NOT EXECUTED
200eca4: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
200eca8: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
200ecac: 40 00 43 22 call 201f934 <__moddi3> <== NOT EXECUTED
200ecb0: aa 07 bf fc add %fp, -4, %l5 <== NOT EXECUTED
200ecb4: 10 80 00 18 b 200ed14 <rtems_blkdev_generic_read+0xc0> <== NOT EXECUTED
200ecb8: a6 10 00 09 mov %o1, %l3 <== NOT EXECUTED
uint32_t copy;
rc = rtems_bdbuf_read(dev, block, &diskbuf);
if (rc != RTEMS_SUCCESSFUL)
break;
copy = block_size - blkofs;
200ecbc: b8 25 00 13 sub %l4, %l3, %i4 <== NOT EXECUTED
if (copy > count)
copy = count;
memcpy(buf, (char *)diskbuf->buffer + blkofs, copy);
200ecc0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
uint32_t copy;
rc = rtems_bdbuf_read(dev, block, &diskbuf);
if (rc != RTEMS_SUCCESSFUL)
break;
copy = block_size - blkofs;
200ecc4: 80 a7 00 10 cmp %i4, %l0 <== NOT EXECUTED
200ecc8: 08 80 00 03 bleu 200ecd4 <rtems_blkdev_generic_read+0x80> <== NOT EXECUTED
200eccc: a4 04 a0 01 inc %l2 <== NOT EXECUTED
200ecd0: b8 10 00 10 mov %l0, %i4 <== NOT EXECUTED
if (copy > count)
copy = count;
memcpy(buf, (char *)diskbuf->buffer + blkofs, copy);
200ecd4: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
200ecd8: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
200ecdc: 40 00 1d fe call 20164d4 <memcpy> <== NOT EXECUTED
200ece0: 92 02 40 13 add %o1, %l3, %o1 <== NOT EXECUTED
rc = rtems_bdbuf_release(diskbuf);
200ece4: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
200ece8: 7f ff f9 81 call 200d2ec <rtems_bdbuf_release> <== NOT EXECUTED
200ecec: a2 04 40 1c add %l1, %i4, %l1 <== NOT EXECUTED
args->bytes_moved += copy;
200ecf0: c2 06 a0 1c ld [ %i2 + 0x1c ], %g1 <== NOT EXECUTED
break;
copy = block_size - blkofs;
if (copy > count)
copy = count;
memcpy(buf, (char *)diskbuf->buffer + blkofs, copy);
rc = rtems_bdbuf_release(diskbuf);
200ecf4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
args->bytes_moved += copy;
200ecf8: 82 00 40 1c add %g1, %i4, %g1 <== NOT EXECUTED
if (rc != RTEMS_SUCCESSFUL)
200ecfc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ed00: 12 80 00 0e bne 200ed38 <rtems_blkdev_generic_read+0xe4> <== NOT EXECUTED
200ed04: c2 26 a0 1c st %g1, [ %i2 + 0x1c ] <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200ed08: a0 a4 00 1c subcc %l0, %i4, %l0 <== NOT EXECUTED
200ed0c: 02 80 00 0b be 200ed38 <rtems_blkdev_generic_read+0xe4> <== NOT EXECUTED
200ed10: a6 10 20 00 clr %l3 <== NOT EXECUTED
{
rtems_bdbuf_buffer *diskbuf;
uint32_t copy;
rc = rtems_bdbuf_read(dev, block, &diskbuf);
200ed14: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
200ed18: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
200ed1c: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
200ed20: 7f ff fe 4e call 200e658 <rtems_bdbuf_read> <== NOT EXECUTED
200ed24: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
200ed28: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (rc != RTEMS_SUCCESSFUL)
200ed2c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200ed30: 02 bf ff e3 be 200ecbc <rtems_blkdev_generic_read+0x68> <== NOT EXECUTED
200ed34: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
blkofs = 0;
block++;
}
return rc;
}
200ed38: 81 c7 e0 08 ret <== NOT EXECUTED
200ed3c: 81 e8 00 00 restore <== NOT EXECUTED
0200eb40 <rtems_blkdev_generic_write>:
rtems_device_driver
rtems_blkdev_generic_write(
rtems_device_major_number major __attribute__((unused)),
rtems_device_minor_number minor __attribute__((unused)),
void * arg)
{
200eb40: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
200eb44: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
200eb48: e0 06 a0 14 ld [ %i2 + 0x14 ], %l0 <== NOT EXECUTED
void * arg)
{
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
200eb4c: c2 00 60 38 ld [ %g1 + 0x38 ], %g1 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200eb50: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
{
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
200eb54: e8 00 60 20 ld [ %g1 + 0x20 ], %l4 <== NOT EXECUTED
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
200eb58: c0 26 a0 1c clr [ %i2 + 0x1c ] <== NOT EXECUTED
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
200eb5c: ec 18 40 00 ldd [ %g1 ], %l6 <== NOT EXECUTED
rtems_status_code rc = RTEMS_SUCCESSFUL;
rtems_libio_rw_args_t *args = arg;
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
200eb60: e4 06 a0 10 ld [ %i2 + 0x10 ], %l2 <== NOT EXECUTED
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200eb64: f8 1e a0 08 ldd [ %i2 + 8 ], %i4 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200eb68: 02 80 00 39 be 200ec4c <rtems_blkdev_generic_write+0x10c> <== NOT EXECUTED
200eb6c: 90 10 20 00 clr %o0 <== NOT EXECUTED
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200eb70: 94 10 20 00 clr %o2 <== NOT EXECUTED
200eb74: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
200eb78: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
200eb7c: 40 00 42 87 call 201f598 <__divdi3> <== NOT EXECUTED
200eb80: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
200eb84: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
rtems_libio_t *iop = args->iop;
rtems_disk_device *dd = iop->data1;
uint32_t block_size = dd->block_size;
char *buf = args->buffer;
uint32_t count = args->count;
rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
200eb88: a6 10 00 09 mov %o1, %l3 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
200eb8c: 94 10 20 00 clr %o2 <== NOT EXECUTED
200eb90: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
200eb94: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
200eb98: 40 00 43 67 call 201f934 <__moddi3> <== NOT EXECUTED
200eb9c: aa 07 bf fc add %fp, -4, %l5 <== NOT EXECUTED
200eba0: 10 80 00 20 b 200ec20 <rtems_blkdev_generic_write+0xe0> <== NOT EXECUTED
200eba4: a2 10 00 09 mov %o1, %l1 <== NOT EXECUTED
while (count > 0)
{
rtems_bdbuf_buffer *diskbuf;
uint32_t copy;
if ((blkofs == 0) && (count >= block_size))
200eba8: 12 80 00 22 bne 200ec30 <rtems_blkdev_generic_write+0xf0> <== NOT EXECUTED
200ebac: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
rc = rtems_bdbuf_get(dev, block, &diskbuf);
200ebb0: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
200ebb4: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
200ebb8: 7f ff fe 73 call 200e584 <rtems_bdbuf_get> <== NOT EXECUTED
200ebbc: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
else
rc = rtems_bdbuf_read(dev, block, &diskbuf);
if (rc != RTEMS_SUCCESSFUL)
200ebc0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ebc4: 12 80 00 22 bne 200ec4c <rtems_blkdev_generic_write+0x10c><== NOT EXECUTED
200ebc8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
break;
copy = block_size - blkofs;
200ebcc: b8 25 00 11 sub %l4, %l1, %i4 <== NOT EXECUTED
if (copy > count)
copy = count;
memcpy((char *)diskbuf->buffer + blkofs, buf, copy);
200ebd0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
else
rc = rtems_bdbuf_read(dev, block, &diskbuf);
if (rc != RTEMS_SUCCESSFUL)
break;
copy = block_size - blkofs;
200ebd4: 80 a7 00 10 cmp %i4, %l0 <== NOT EXECUTED
200ebd8: 08 80 00 03 bleu 200ebe4 <rtems_blkdev_generic_write+0xa4><== NOT EXECUTED
200ebdc: a6 04 e0 01 inc %l3 <== NOT EXECUTED
200ebe0: b8 10 00 10 mov %l0, %i4 <== NOT EXECUTED
if (copy > count)
copy = count;
memcpy((char *)diskbuf->buffer + blkofs, buf, copy);
200ebe4: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
200ebe8: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
200ebec: 40 00 1e 3a call 20164d4 <memcpy> <== NOT EXECUTED
200ebf0: 90 02 00 11 add %o0, %l1, %o0 <== NOT EXECUTED
args->bytes_moved += copy;
200ebf4: c2 06 a0 1c ld [ %i2 + 0x1c ], %g1 <== NOT EXECUTED
rc = rtems_bdbuf_release_modified(diskbuf);
200ebf8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
copy = block_size - blkofs;
if (copy > count)
copy = count;
memcpy((char *)diskbuf->buffer + blkofs, buf, copy);
args->bytes_moved += copy;
200ebfc: 82 00 40 1c add %g1, %i4, %g1 <== NOT EXECUTED
rc = rtems_bdbuf_release_modified(diskbuf);
if (rc != RTEMS_SUCCESSFUL)
break;
count -= copy;
buf += copy;
200ec00: a4 04 80 1c add %l2, %i4, %l2 <== NOT EXECUTED
if (copy > count)
copy = count;
memcpy((char *)diskbuf->buffer + blkofs, buf, copy);
args->bytes_moved += copy;
rc = rtems_bdbuf_release_modified(diskbuf);
200ec04: 7f ff f9 97 call 200d260 <rtems_bdbuf_release_modified> <== NOT EXECUTED
200ec08: c2 26 a0 1c st %g1, [ %i2 + 0x1c ] <== NOT EXECUTED
if (rc != RTEMS_SUCCESSFUL)
200ec0c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ec10: 12 80 00 0f bne 200ec4c <rtems_blkdev_generic_write+0x10c><== NOT EXECUTED
200ec14: a0 a4 00 1c subcc %l0, %i4, %l0 <== NOT EXECUTED
uint32_t blkofs = (uint32_t) (args->offset % block_size);
dev_t dev = dd->dev;
args->bytes_moved = 0;
while (count > 0)
200ec18: 02 80 00 0d be 200ec4c <rtems_blkdev_generic_write+0x10c> <== NOT EXECUTED
200ec1c: a2 10 20 00 clr %l1 <== NOT EXECUTED
{
rtems_bdbuf_buffer *diskbuf;
uint32_t copy;
if ((blkofs == 0) && (count >= block_size))
200ec20: 80 a4 00 14 cmp %l0, %l4 <== NOT EXECUTED
200ec24: 1a bf ff e1 bcc 200eba8 <rtems_blkdev_generic_write+0x68> <== NOT EXECUTED
200ec28: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
rc = rtems_bdbuf_get(dev, block, &diskbuf);
else
rc = rtems_bdbuf_read(dev, block, &diskbuf);
200ec2c: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
200ec30: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
200ec34: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
200ec38: 7f ff fe 88 call 200e658 <rtems_bdbuf_read> <== NOT EXECUTED
200ec3c: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
if (rc != RTEMS_SUCCESSFUL)
200ec40: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ec44: 02 bf ff e2 be 200ebcc <rtems_blkdev_generic_write+0x8c> <== NOT EXECUTED
200ec48: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
blkofs = 0;
block++;
}
return rc;
}
200ec4c: 81 c7 e0 08 ret <== NOT EXECUTED
200ec50: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0200e930 <rtems_blkdev_ioctl>:
return RTEMS_SUCCESSFUL;
}
int
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)
{
200e930: 9d e3 bf a0 save %sp, -96, %sp
size_t *arg_size = argp;
int rc = 0;
switch (req)
200e934: 05 10 01 10 sethi %hi(0x40044000), %g2
200e938: 86 10 a2 03 or %g2, 0x203, %g3 ! 40044203 <RAM_END+0x3dc44203>
200e93c: 80 a6 40 03 cmp %i1, %g3
200e940: 02 80 00 1e be 200e9b8 <rtems_blkdev_ioctl+0x88> <== NEVER TAKEN
200e944: 82 10 00 18 mov %i0, %g1
200e948: 80 a6 40 03 cmp %i1, %g3
200e94c: 28 80 00 0e bleu,a 200e984 <rtems_blkdev_ioctl+0x54> <== ALWAYS TAKEN
200e950: 84 10 a2 02 or %g2, 0x202, %g2
200e954: 84 10 a2 05 or %g2, 0x205, %g2 <== NOT EXECUTED
200e958: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
200e95c: 02 80 00 13 be 200e9a8 <rtems_blkdev_ioctl+0x78> <== NOT EXECUTED
200e960: 05 20 01 10 sethi %hi(0x80044000), %g2 <== NOT EXECUTED
200e964: 84 10 a2 04 or %g2, 0x204, %g2 ! 80044204 <RAM_END+0x7dc44204><== NOT EXECUTED
200e968: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
200e96c: 12 80 00 09 bne 200e990 <rtems_blkdev_ioctl+0x60> <== NOT EXECUTED
200e970: 01 00 00 00 nop <== NOT EXECUTED
case RTEMS_BLKIO_GETBLKSIZE:
*arg_size = dd->block_size;
break;
case RTEMS_BLKIO_SETBLKSIZE:
dd->block_size = *arg_size;
200e974: c4 06 80 00 ld [ %i2 ], %g2 <== NOT EXECUTED
200e978: c4 20 60 20 st %g2, [ %g1 + 0x20 ] <== NOT EXECUTED
break;
200e97c: 81 c7 e0 08 ret <== NOT EXECUTED
200e980: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)
{
size_t *arg_size = argp;
int rc = 0;
switch (req)
200e984: 80 a6 40 02 cmp %i1, %g2
200e988: 22 80 00 10 be,a 200e9c8 <rtems_blkdev_ioctl+0x98> <== NEVER TAKEN
200e98c: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED
case RTEMS_BLKIO_GETSIZE:
*arg_size = dd->size;
break;
default:
errno = EINVAL;
200e990: 40 00 1c 95 call 2015be4 <__errno>
200e994: b0 10 3f ff mov -1, %i0
200e998: 82 10 20 16 mov 0x16, %g1
200e99c: c2 22 00 00 st %g1, [ %o0 ]
rc = -1;
break;
}
return rc;
}
200e9a0: 81 c7 e0 08 ret
200e9a4: 81 e8 00 00 restore
case RTEMS_BLKIO_SETBLKSIZE:
dd->block_size = *arg_size;
break;
case RTEMS_BLKIO_GETSIZE:
*arg_size = dd->size;
200e9a8: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
200e9ac: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
break;
200e9b0: 81 c7 e0 08 ret <== NOT EXECUTED
200e9b4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
case RTEMS_BLKIO_GETMEDIABLKSIZE:
*arg_size = dd->media_block_size;
break;
case RTEMS_BLKIO_GETBLKSIZE:
*arg_size = dd->block_size;
200e9b8: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
200e9bc: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
break;
200e9c0: 81 c7 e0 08 ret <== NOT EXECUTED
200e9c4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
int rc = 0;
switch (req)
{
case RTEMS_BLKIO_GETMEDIABLKSIZE:
*arg_size = dd->media_block_size;
200e9c8: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
break;
200e9cc: 81 c7 e0 08 ret <== NOT EXECUTED
200e9d0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02002574 <rtems_bsp_cmdline_get_param>:
const char *rtems_bsp_cmdline_get_param(
const char *name,
char *value,
size_t length
)
{
2002574: 9d e3 bf a0 save %sp, -96, %sp
const char *p;
if ( !name )
2002578: 80 a6 20 00 cmp %i0, 0
200257c: 12 80 00 05 bne 2002590 <rtems_bsp_cmdline_get_param+0x1c>
2002580: 80 a6 60 00 cmp %i1, 0
int i;
int quotes;
const char *p = start;
quotes=0;
for (i=0 ; *p && i<length-1; ) {
2002584: b2 10 20 00 clr %i1
return NULL;
copy_string( p, value, length );
return value;
}
2002588: 81 c7 e0 08 ret
200258c: 91 e8 00 19 restore %g0, %i1, %o0
const char *p;
if ( !name )
return NULL;
if ( !value )
2002590: 02 bf ff fe be 2002588 <rtems_bsp_cmdline_get_param+0x14>
2002594: 80 a6 a0 00 cmp %i2, 0
return NULL;
if ( !length )
2002598: 22 bf ff fc be,a 2002588 <rtems_bsp_cmdline_get_param+0x14>
200259c: b2 10 20 00 clr %i1
return NULL;
value[0] = '\0';
20025a0: c0 2e 40 00 clrb [ %i1 ]
p = rtems_bsp_cmdline_get_param_raw( name );
20025a4: 40 00 00 25 call 2002638 <rtems_bsp_cmdline_get_param_raw>
20025a8: 90 10 00 18 mov %i0, %o0
if ( !p )
20025ac: 80 a2 20 00 cmp %o0, 0
20025b0: 22 bf ff f6 be,a 2002588 <rtems_bsp_cmdline_get_param+0x14>
20025b4: b2 10 20 00 clr %i1
int i;
int quotes;
const char *p = start;
quotes=0;
for (i=0 ; *p && i<length-1; ) {
20025b8: c6 0a 00 00 ldub [ %o0 ], %g3
20025bc: 85 28 e0 18 sll %g3, 0x18, %g2
20025c0: 80 a0 a0 00 cmp %g2, 0
20025c4: 02 bf ff f1 be 2002588 <rtems_bsp_cmdline_get_param+0x14> <== NEVER TAKEN
20025c8: b4 86 bf ff addcc %i2, -1, %i2
20025cc: 02 bf ff ef be 2002588 <rtems_bsp_cmdline_get_param+0x14> <== NEVER TAKEN
20025d0: 88 10 20 00 clr %g4
20025d4: 82 10 20 00 clr %g1
20025d8: 10 80 00 12 b 2002620 <rtems_bsp_cmdline_get_param+0xac>
20025dc: 9a 10 20 00 clr %o5
if ( *p == '\"' ) {
quotes++;
} else if ( ((quotes % 2) == 0) && *p == ' ' )
20025e0: 32 80 00 06 bne,a 20025f8 <rtems_bsp_cmdline_get_param+0x84>
20025e4: c6 2e 40 04 stb %g3, [ %i1 + %g4 ]
20025e8: 80 a0 a0 20 cmp %g2, 0x20
20025ec: 02 bf ff e7 be 2002588 <rtems_bsp_cmdline_get_param+0x14>
20025f0: 01 00 00 00 nop
break;
value[i++] = *p++;
20025f4: c6 2e 40 04 stb %g3, [ %i1 + %g4 ]
20025f8: 82 00 60 01 inc %g1
value[i] = '\0';
20025fc: c0 2e 40 01 clrb [ %i1 + %g1 ]
int i;
int quotes;
const char *p = start;
quotes=0;
for (i=0 ; *p && i<length-1; ) {
2002600: c6 0a 00 01 ldub [ %o0 + %g1 ], %g3
2002604: 85 28 e0 18 sll %g3, 0x18, %g2
2002608: 80 a0 a0 00 cmp %g2, 0
200260c: 02 bf ff df be 2002588 <rtems_bsp_cmdline_get_param+0x14>
2002610: 88 10 00 01 mov %g1, %g4
2002614: 80 a0 40 1a cmp %g1, %i2
2002618: 1a bf ff dc bcc 2002588 <rtems_bsp_cmdline_get_param+0x14><== NEVER TAKEN
200261c: 01 00 00 00 nop
if ( *p == '\"' ) {
2002620: 85 38 a0 18 sra %g2, 0x18, %g2
2002624: 80 a0 a0 22 cmp %g2, 0x22
2002628: 12 bf ff ee bne 20025e0 <rtems_bsp_cmdline_get_param+0x6c>
200262c: 80 8b 60 01 btst 1, %o5
quotes++;
2002630: 10 bf ff f1 b 20025f4 <rtems_bsp_cmdline_get_param+0x80>
2002634: 9a 03 60 01 inc %o5
0200266c <rtems_bsp_cmdline_get_param_rhs>:
const char *rtems_bsp_cmdline_get_param_rhs(
const char *name,
char *value,
size_t length
)
{
200266c: 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 );
2002670: 94 10 00 1a mov %i2, %o2
2002674: 90 10 00 18 mov %i0, %o0
2002678: 7f ff ff bf call 2002574 <rtems_bsp_cmdline_get_param>
200267c: 92 10 00 19 mov %i1, %o1
if ( !p )
2002680: a2 92 20 00 orcc %o0, 0, %l1
2002684: 12 80 00 05 bne 2002698 <rtems_bsp_cmdline_get_param_rhs+0x2c>
2002688: 01 00 00 00 nop
*d++ = *rhs++;
if ( *(d-1) == '\"' )
d--;
*d = '\0';
return value;
200268c: b2 10 20 00 clr %i1 ! 0 <PROM_START>
}
2002690: 81 c7 e0 08 ret
2002694: 91 e8 00 19 restore %g0, %i1, %o0
p = rtems_bsp_cmdline_get_param( name, value, length );
if ( !p )
return NULL;
rhs = &p[strlen(name)];
2002698: 40 00 41 32 call 2012b60 <strlen>
200269c: 90 10 00 18 mov %i0, %o0
if ( *rhs != '=' )
20026a0: c2 4c 40 08 ldsb [ %l1 + %o0 ], %g1
20026a4: 80 a0 60 3d cmp %g1, 0x3d
20026a8: 12 bf ff f9 bne 200268c <rtems_bsp_cmdline_get_param_rhs+0x20><== NEVER TAKEN
20026ac: a2 04 40 08 add %l1, %o0, %l1
return NULL;
rhs++;
if ( *rhs == '\"' )
20026b0: c6 0c 60 01 ldub [ %l1 + 1 ], %g3
20026b4: 85 28 e0 18 sll %g3, 0x18, %g2
20026b8: 89 38 a0 18 sra %g2, 0x18, %g4
20026bc: 80 a1 20 22 cmp %g4, 0x22
20026c0: 02 80 00 14 be 2002710 <rtems_bsp_cmdline_get_param_rhs+0xa4>
20026c4: 82 04 60 01 add %l1, 1, %g1
rhs++;
for ( d=value ; *rhs ; )
20026c8: 80 a0 a0 00 cmp %g2, 0
20026cc: 02 80 00 09 be 20026f0 <rtems_bsp_cmdline_get_param_rhs+0x84>
20026d0: 84 10 00 19 mov %i1, %g2
*d++ = *rhs++;
20026d4: c6 28 80 00 stb %g3, [ %g2 ]
20026d8: 82 00 60 01 inc %g1
return NULL;
rhs++;
if ( *rhs == '\"' )
rhs++;
for ( d=value ; *rhs ; )
20026dc: c6 48 40 00 ldsb [ %g1 ], %g3
*d++ = *rhs++;
20026e0: 84 00 a0 01 inc %g2
return NULL;
rhs++;
if ( *rhs == '\"' )
rhs++;
for ( d=value ; *rhs ; )
20026e4: 80 a0 e0 00 cmp %g3, 0
20026e8: 12 bf ff fb bne 20026d4 <rtems_bsp_cmdline_get_param_rhs+0x68>
20026ec: c6 08 40 00 ldub [ %g1 ], %g3
*d++ = *rhs++;
if ( *(d-1) == '\"' )
20026f0: c6 48 bf ff ldsb [ %g2 + -1 ], %g3
20026f4: 80 a0 e0 22 cmp %g3, 0x22
20026f8: 02 80 00 03 be 2002704 <rtems_bsp_cmdline_get_param_rhs+0x98>
20026fc: 82 00 bf ff add %g2, -1, %g1
2002700: 82 10 00 02 mov %g2, %g1
d--;
*d = '\0';
2002704: c0 28 40 00 clrb [ %g1 ]
return value;
}
2002708: 81 c7 e0 08 ret
200270c: 91 e8 00 19 restore %g0, %i1, %o0
if ( *rhs != '=' )
return NULL;
rhs++;
if ( *rhs == '\"' )
rhs++;
2002710: c6 0c 60 02 ldub [ %l1 + 2 ], %g3
2002714: 82 04 60 02 add %l1, 2, %g1
2002718: 10 bf ff ec b 20026c8 <rtems_bsp_cmdline_get_param_rhs+0x5c>
200271c: 85 28 e0 18 sll %g3, 0x18, %g2
0200316c <rtems_cpu_usage_report_with_plugin>:
void rtems_cpu_usage_report_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
200316c: 9d e3 bf 60 save %sp, -160, %sp
Timestamp_Control uptime, total, ran;
#else
uint32_t total_units = 0;
#endif
if ( !print )
2003170: 80 a6 60 00 cmp %i1, 0
2003174: 02 80 00 72 be 200333c <rtems_cpu_usage_report_with_plugin+0x1d0><== NEVER TAKEN
2003178: 01 00 00 00 nop
* 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 );
200317c: 40 00 18 75 call 2009350 <_TOD_Get_uptime>
2003180: 90 07 bf f0 add %fp, -16, %o0
_Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total );
2003184: 92 07 bf f0 add %fp, -16, %o1
2003188: a8 07 bf e8 add %fp, -24, %l4
200318c: 11 00 80 99 sethi %hi(0x2026400), %o0
2003190: 94 10 00 14 mov %l4, %o2
2003194: 40 00 23 61 call 200bf18 <_Timespec_Subtract>
2003198: 90 12 21 88 or %o0, 0x188, %o0
}
}
}
#endif
(*print)(
200319c: 90 10 00 18 mov %i0, %o0
20031a0: 13 00 80 8b sethi %hi(0x2022c00), %o1
20031a4: 37 00 80 97 sethi %hi(0x2025c00), %i3
20031a8: 92 12 60 c8 or %o1, 0xc8, %o1
if ( !the_thread )
continue;
rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
(*print)(
20031ac: 3b 00 80 8b sethi %hi(0x2022c00), %i5
/*
* 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 ) {
20031b0: 2f 00 80 98 sethi %hi(0x2026000), %l7
}
}
}
#endif
(*print)(
20031b4: 9f c6 40 00 call %i1
20031b8: 2d 00 80 8b sethi %hi(0x2022c00), %l6
the_thread = (Thread_Control *)information->local_table[ i ];
if ( !the_thread )
continue;
rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
20031bc: a4 07 bf c8 add %fp, -56, %l2
}
}
}
#endif
(*print)(
20031c0: b6 16 e3 24 or %i3, 0x324, %i3
if ( !the_thread )
continue;
rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
(*print)(
20031c4: ba 17 62 40 or %i5, 0x240, %i5
/*
* 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 ) {
20031c8: ae 15 e0 80 or %l7, 0x80, %l7
/*
* Print the information
*/
(*print)( context,
20031cc: ac 15 a2 58 or %l6, 0x258, %l6
20031d0: a6 07 bf e0 add %fp, -32, %l3
_Timestamp_Subtract(
&_Thread_Time_of_last_context_switch, &uptime, &used
);
_Timestamp_Add_to( &ran, &used );
};
_Timestamp_Divide( &ran, &total, &ival, &fval );
20031d4: aa 07 bf fc add %fp, -4, %l5
20031d8: b8 07 bf f8 add %fp, -8, %i4
* 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(
20031dc: b4 07 bf d8 add %fp, -40, %i2
);
for ( api_index = 1 ;
api_index <= OBJECTS_APIS_LAST ;
api_index++ ) {
if ( !_Objects_Information_table[ api_index ] )
20031e0: c2 06 c0 00 ld [ %i3 ], %g1
20031e4: 80 a0 60 00 cmp %g1, 0
20031e8: 22 80 00 47 be,a 2003304 <rtems_cpu_usage_report_with_plugin+0x198>
20031ec: b6 06 e0 04 add %i3, 4, %i3
continue;
information = _Objects_Information_table[ api_index ][ 1 ];
20031f0: e2 00 60 04 ld [ %g1 + 4 ], %l1
if ( information ) {
20031f4: 80 a4 60 00 cmp %l1, 0
20031f8: 22 80 00 43 be,a 2003304 <rtems_cpu_usage_report_with_plugin+0x198><== NEVER TAKEN
20031fc: b6 06 e0 04 add %i3, 4, %i3 <== NOT EXECUTED
for ( i=1 ; i <= information->maximum ; i++ ) {
2003200: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1
2003204: 86 90 60 00 orcc %g1, 0, %g3
2003208: 02 80 00 3e be 2003300 <rtems_cpu_usage_report_with_plugin+0x194>
200320c: a0 10 20 01 mov 1, %l0
the_thread = (Thread_Control *)information->local_table[ i ];
2003210: 10 80 00 17 b 200326c <rtems_cpu_usage_report_with_plugin+0x100>
2003214: c4 04 60 1c ld [ %l1 + 0x1c ], %g2
_Timestamp_Subtract(
&_Thread_Time_of_last_context_switch, &uptime, &used
);
_Timestamp_Add_to( &ran, &used );
};
_Timestamp_Divide( &ran, &total, &ival, &fval );
2003218: 96 10 00 1c mov %i4, %o3
200321c: 90 10 00 13 mov %l3, %o0
2003220: 40 00 22 ae call 200bcd8 <_Timespec_Divide>
2003224: 92 10 00 14 mov %l4, %o1
/*
* Print the information
*/
(*print)( context,
2003228: d0 07 bf e4 ld [ %fp + -28 ], %o0
200322c: 40 00 74 83 call 2020438 <.udiv>
2003230: 92 10 23 e8 mov 0x3e8, %o1
2003234: d4 07 bf e0 ld [ %fp + -32 ], %o2
2003238: d8 07 bf fc ld [ %fp + -4 ], %o4
200323c: da 07 bf f8 ld [ %fp + -8 ], %o5
2003240: 96 10 00 08 mov %o0, %o3
2003244: 92 10 00 16 mov %l6, %o1
2003248: 9f c6 40 00 call %i1
200324c: 90 10 00 18 mov %i0, %o0
2003250: c6 14 60 10 lduh [ %l1 + 0x10 ], %g3
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++ ) {
2003254: 83 28 e0 10 sll %g3, 0x10, %g1
2003258: 83 30 60 10 srl %g1, 0x10, %g1
200325c: 80 a0 40 10 cmp %g1, %l0
2003260: 2a 80 00 29 bcs,a 2003304 <rtems_cpu_usage_report_with_plugin+0x198>
2003264: b6 06 e0 04 add %i3, 4, %i3
the_thread = (Thread_Control *)information->local_table[ i ];
2003268: c4 04 60 1c ld [ %l1 + 0x1c ], %g2
200326c: 83 2c 20 02 sll %l0, 2, %g1
2003270: c2 00 80 01 ld [ %g2 + %g1 ], %g1
if ( !the_thread )
continue;
rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
2003274: 94 10 00 12 mov %l2, %o2
2003278: 92 10 20 0d mov 0xd, %o1
information = _Objects_Information_table[ api_index ][ 1 ];
if ( information ) {
for ( i=1 ; i <= information->maximum ; i++ ) {
the_thread = (Thread_Control *)information->local_table[ i ];
if ( !the_thread )
200327c: 80 a0 60 00 cmp %g1, 0
2003280: 02 bf ff f5 be 2003254 <rtems_cpu_usage_report_with_plugin+0xe8><== NEVER TAKEN
2003284: a0 04 20 01 inc %l0
continue;
rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
2003288: d0 00 60 08 ld [ %g1 + 8 ], %o0
200328c: 40 00 12 e7 call 2007e28 <rtems_object_get_name>
2003290: c2 27 bf c4 st %g1, [ %fp + -60 ]
(*print)(
2003294: c2 07 bf c4 ld [ %fp + -60 ], %g1
2003298: 90 10 00 18 mov %i0, %o0
200329c: d4 00 60 08 ld [ %g1 + 8 ], %o2
20032a0: 92 10 00 1d mov %i5, %o1
20032a4: 9f c6 40 00 call %i1
20032a8: 96 10 00 12 mov %l2, %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;
20032ac: c2 07 bf c4 ld [ %fp + -60 ], %g1
if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
20032b0: c4 05 c0 00 ld [ %l7 ], %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;
20032b4: c6 00 60 84 ld [ %g1 + 0x84 ], %g3
20032b8: c6 27 bf e0 st %g3, [ %fp + -32 ]
20032bc: c6 00 60 88 ld [ %g1 + 0x88 ], %g3
20032c0: c6 27 bf e4 st %g3, [ %fp + -28 ]
if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
20032c4: c4 00 a0 08 ld [ %g2 + 8 ], %g2
20032c8: c2 00 60 08 ld [ %g1 + 8 ], %g1
20032cc: 80 a0 80 01 cmp %g2, %g1
20032d0: 32 bf ff d2 bne,a 2003218 <rtems_cpu_usage_report_with_plugin+0xac>
20032d4: 94 10 00 15 mov %l5, %o2
Timestamp_Control used;
_Timestamp_Subtract(
20032d8: 92 07 bf f0 add %fp, -16, %o1
20032dc: 94 10 00 1a mov %i2, %o2
20032e0: 11 00 80 98 sethi %hi(0x2026000), %o0
20032e4: 40 00 23 0d call 200bf18 <_Timespec_Subtract>
20032e8: 90 12 20 88 or %o0, 0x88, %o0 ! 2026088 <_Thread_Time_of_last_context_switch>
&_Thread_Time_of_last_context_switch, &uptime, &used
);
_Timestamp_Add_to( &ran, &used );
20032ec: 90 10 00 13 mov %l3, %o0
20032f0: 40 00 22 61 call 200bc74 <_Timespec_Add_to>
20032f4: 92 10 00 1a mov %i2, %o1
};
_Timestamp_Divide( &ran, &total, &ival, &fval );
20032f8: 10 bf ff c8 b 2003218 <rtems_cpu_usage_report_with_plugin+0xac>
20032fc: 94 10 00 15 mov %l5, %o2
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++ ) {
2003300: b6 06 e0 04 add %i3, 4, %i3
" ID | NAME | TICKS | PERCENT\n"
#endif
"------------+----------------------------------------+---------------+---------\n"
);
for ( api_index = 1 ;
2003304: 03 00 80 97 sethi %hi(0x2025c00), %g1
2003308: 82 10 63 34 or %g1, 0x334, %g1 ! 2025f34 <_Objects_Information_table+0x14>
200330c: 80 a6 c0 01 cmp %i3, %g1
2003310: 32 bf ff b5 bne,a 20031e4 <rtems_cpu_usage_report_with_plugin+0x78>
2003314: c2 06 c0 00 ld [ %i3 ], %g1
}
}
}
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
(*print)(
2003318: d0 07 bf ec ld [ %fp + -20 ], %o0
200331c: 40 00 74 47 call 2020438 <.udiv>
2003320: 92 10 23 e8 mov 0x3e8, %o1
2003324: d4 07 bf e8 ld [ %fp + -24 ], %o2
2003328: 96 10 00 08 mov %o0, %o3
200332c: 13 00 80 8b sethi %hi(0x2022c00), %o1
2003330: 90 10 00 18 mov %i0, %o0
2003334: 9f c6 40 00 call %i1
2003338: 92 12 62 70 or %o1, 0x270, %o1
200333c: 81 c7 e0 08 ret
2003340: 81 e8 00 00 restore
0201185c <rtems_deviceio_errno>:
{ 0, 0, 0 },
};
int
rtems_deviceio_errno(rtems_status_code code)
{
201185c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
if ((rc = rtems_assoc_remote_by_local(errno_assoc, (uint32_t ) code)))
2011860: 11 00 80 77 sethi %hi(0x201dc00), %o0 <== NOT EXECUTED
2011864: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2011868: 40 00 00 0a call 2011890 <rtems_assoc_remote_by_local> <== NOT EXECUTED
201186c: 90 12 23 b0 or %o0, 0x3b0, %o0 <== NOT EXECUTED
2011870: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2011874: 02 80 00 05 be 2011888 <rtems_deviceio_errno+0x2c> <== NOT EXECUTED
2011878: 01 00 00 00 nop <== NOT EXECUTED
{
errno = rc;
201187c: 40 00 00 60 call 20119fc <__errno> <== NOT EXECUTED
2011880: 01 00 00 00 nop <== NOT EXECUTED
2011884: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
return -1;
}
return -1;
}
2011888: 81 c7 e0 08 ret <== NOT EXECUTED
201188c: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
020030f8 <rtems_disk_create_log>:
dev_t phys,
rtems_blkdev_bnum begin_block,
rtems_blkdev_bnum block_count,
const char *name
)
{
20030f8: 9d e3 bf 90 save %sp, -112, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *physical_disk = NULL;
rtems_disk_device *dd = NULL;
rtems_blkdev_bnum end_block = begin_block + block_count;
sc = disk_lock();
20030fc: 7f ff fe 8b call 2002b28 <disk_lock>
2003100: c0 27 bf fc clr [ %fp + -4 ]
if (sc != RTEMS_SUCCESSFUL) {
2003104: 80 a2 20 00 cmp %o0, 0
2003108: 22 80 00 04 be,a 2003118 <rtems_disk_create_log+0x20> <== ALWAYS TAKEN
200310c: 90 10 00 1a mov %i2, %o0
++physical_disk->uses;
disk_unlock();
return RTEMS_SUCCESSFUL;
}
2003110: 81 c7 e0 08 ret
2003114: 91 e8 00 08 restore %g0, %o0, %o0
sc = disk_lock();
if (sc != RTEMS_SUCCESSFUL) {
return sc;
}
physical_disk = get_disk_entry(phys, true);
2003118: 92 10 00 1b mov %i3, %o1
200311c: 7f ff fd e1 call 20028a0 <get_disk_entry>
2003120: 94 10 20 01 mov 1, %o2
if (physical_disk == NULL || !is_physical_disk(physical_disk)) {
2003124: a0 92 20 00 orcc %o0, 0, %l0
2003128: 02 80 00 06 be 2003140 <rtems_disk_create_log+0x48>
200312c: 01 00 00 00 nop
2003130: c2 04 20 08 ld [ %l0 + 8 ], %g1
2003134: 80 a4 00 01 cmp %l0, %g1
2003138: 02 80 00 07 be 2003154 <rtems_disk_create_log+0x5c>
200313c: 82 07 40 1c add %i5, %i4, %g1
disk_unlock();
2003140: 7f ff fe 89 call 2002b64 <disk_unlock>
2003144: 01 00 00 00 nop
2003148: 90 10 20 04 mov 4, %o0 ! 4 <PROM_START+0x4>
++physical_disk->uses;
disk_unlock();
return RTEMS_SUCCESSFUL;
}
200314c: 81 c7 e0 08 ret
2003150: 91 e8 00 08 restore %g0, %o0, %o0
disk_unlock();
return RTEMS_INVALID_ID;
}
if (
2003154: 80 a0 40 1c cmp %g1, %i4
2003158: 08 80 00 07 bleu 2003174 <rtems_disk_create_log+0x7c>
200315c: c4 04 20 1c ld [ %l0 + 0x1c ], %g2
2003160: 80 a0 80 1c cmp %g2, %i4
2003164: 08 80 00 04 bleu 2003174 <rtems_disk_create_log+0x7c> <== NEVER TAKEN
2003168: 80 a0 40 02 cmp %g1, %g2
200316c: 08 80 00 06 bleu 2003184 <rtems_disk_create_log+0x8c>
2003170: d4 07 a0 5c ld [ %fp + 0x5c ], %o2
begin_block >= physical_disk->size
|| end_block <= begin_block
|| end_block > physical_disk->size
) {
disk_unlock();
2003174: 7f ff fe 7c call 2002b64 <disk_unlock>
2003178: 01 00 00 00 nop
return RTEMS_INVALID_NUMBER;
200317c: 10 bf ff e5 b 2003110 <rtems_disk_create_log+0x18>
2003180: 90 10 20 0a mov 0xa, %o0 ! a <PROM_START+0xa>
}
sc = create_disk(dev, name, &dd);
2003184: 90 10 00 18 mov %i0, %o0
2003188: 92 10 00 19 mov %i1, %o1
200318c: 7f ff ff 6c call 2002f3c <create_disk>
2003190: 96 07 bf fc add %fp, -4, %o3
if (sc != RTEMS_SUCCESSFUL) {
2003194: 80 a2 20 00 cmp %o0, 0
2003198: 12 80 00 0f bne 20031d4 <rtems_disk_create_log+0xdc>
200319c: c2 07 bf fc ld [ %fp + -4 ], %g1
}
dd->phys_dev = physical_disk;
dd->start = begin_block;
dd->size = block_count;
dd->block_size = dd->media_block_size = physical_disk->block_size;
20031a0: c4 04 20 20 ld [ %l0 + 0x20 ], %g2
dd->ioctl = physical_disk->ioctl;
dd->driver_data = physical_disk->driver_data;
++physical_disk->uses;
20031a4: c6 04 20 14 ld [ %l0 + 0x14 ], %g3
dd->phys_dev = physical_disk;
dd->start = begin_block;
dd->size = block_count;
dd->block_size = dd->media_block_size = physical_disk->block_size;
dd->ioctl = physical_disk->ioctl;
20031a8: c8 04 20 28 ld [ %l0 + 0x28 ], %g4
dd->driver_data = physical_disk->driver_data;
20031ac: da 04 20 2c ld [ %l0 + 0x2c ], %o5
++physical_disk->uses;
20031b0: 86 00 e0 01 inc %g3
return sc;
}
dd->phys_dev = physical_disk;
dd->start = begin_block;
20031b4: f8 20 60 18 st %i4, [ %g1 + 0x18 ]
dd->size = block_count;
dd->block_size = dd->media_block_size = physical_disk->block_size;
dd->ioctl = physical_disk->ioctl;
dd->driver_data = physical_disk->driver_data;
20031b8: da 20 60 2c st %o5, [ %g1 + 0x2c ]
return sc;
}
dd->phys_dev = physical_disk;
dd->start = begin_block;
dd->size = block_count;
20031bc: fa 20 60 1c st %i5, [ %g1 + 0x1c ]
dd->block_size = dd->media_block_size = physical_disk->block_size;
20031c0: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
dd->ioctl = physical_disk->ioctl;
20031c4: c8 20 60 28 st %g4, [ %g1 + 0x28 ]
dd->driver_data = physical_disk->driver_data;
++physical_disk->uses;
20031c8: c6 24 20 14 st %g3, [ %l0 + 0x14 ]
disk_unlock();
return sc;
}
dd->phys_dev = physical_disk;
20031cc: e0 20 60 08 st %l0, [ %g1 + 8 ]
dd->start = begin_block;
dd->size = block_count;
dd->block_size = dd->media_block_size = physical_disk->block_size;
20031d0: c4 20 60 24 st %g2, [ %g1 + 0x24 ]
dd->ioctl = physical_disk->ioctl;
dd->driver_data = physical_disk->driver_data;
++physical_disk->uses;
disk_unlock();
20031d4: 7f ff fe 64 call 2002b64 <disk_unlock>
20031d8: d0 27 bf f4 st %o0, [ %fp + -12 ]
return RTEMS_SUCCESSFUL;
20031dc: 10 bf ff cd b 2003110 <rtems_disk_create_log+0x18>
20031e0: d0 07 bf f4 ld [ %fp + -12 ], %o0
020031e4 <rtems_disk_create_phys>:
rtems_blkdev_bnum block_count,
rtems_block_device_ioctl handler,
void *driver_data,
const char *name
)
{
20031e4: 9d e3 bf 98 save %sp, -104, %sp
20031e8: a0 10 00 18 mov %i0, %l0
rtems_disk_device *dd = NULL;
rtems_status_code sc = RTEMS_SUCCESSFUL;
if (handler == NULL) {
20031ec: 80 a7 20 00 cmp %i4, 0
20031f0: 02 80 00 22 be 2003278 <rtems_disk_create_phys+0x94>
20031f4: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
}
if (block_size == 0) {
20031f8: 80 a6 a0 00 cmp %i2, 0
20031fc: 02 80 00 1f be 2003278 <rtems_disk_create_phys+0x94>
2003200: b0 10 20 0a mov 0xa, %i0
return RTEMS_INVALID_NUMBER;
}
sc = disk_lock();
2003204: 7f ff fe 49 call 2002b28 <disk_lock>
2003208: c0 27 bf fc clr [ %fp + -4 ]
if (sc != RTEMS_SUCCESSFUL) {
200320c: b0 92 20 00 orcc %o0, 0, %i0
2003210: 12 80 00 1a bne 2003278 <rtems_disk_create_phys+0x94> <== NEVER TAKEN
2003214: d4 07 a0 5c ld [ %fp + 0x5c ], %o2
return sc;
}
sc = create_disk(dev, name, &dd);
2003218: 90 10 00 10 mov %l0, %o0
200321c: 92 10 00 19 mov %i1, %o1
2003220: 7f ff ff 47 call 2002f3c <create_disk>
2003224: 96 07 bf fc add %fp, -4, %o3
if (sc != RTEMS_SUCCESSFUL) {
2003228: b0 92 20 00 orcc %o0, 0, %i0
200322c: 12 80 00 15 bne 2003280 <rtems_disk_create_phys+0x9c>
2003230: c2 07 bf fc ld [ %fp + -4 ], %g1
dd->size = block_count;
dd->block_size = dd->media_block_size = block_size;
dd->ioctl = handler;
dd->driver_data = driver_data;
if ((*handler)(dd, RTEMS_BLKIO_CAPABILITIES, &dd->capabilities) < 0) {
2003234: 13 08 00 10 sethi %hi(0x20004000), %o1
return sc;
}
dd->phys_dev = dd;
dd->start = 0;
dd->size = block_count;
2003238: f6 20 60 1c st %i3, [ %g1 + 0x1c ]
dd->block_size = dd->media_block_size = block_size;
200323c: f4 20 60 20 st %i2, [ %g1 + 0x20 ]
dd->ioctl = handler;
dd->driver_data = driver_data;
2003240: fa 20 60 2c st %i5, [ %g1 + 0x2c ]
if ((*handler)(dd, RTEMS_BLKIO_CAPABILITIES, &dd->capabilities) < 0) {
2003244: 90 10 00 01 mov %g1, %o0
disk_unlock();
return sc;
}
dd->phys_dev = dd;
2003248: c2 20 60 08 st %g1, [ %g1 + 8 ]
dd->start = 0;
200324c: c0 20 60 18 clr [ %g1 + 0x18 ]
dd->size = block_count;
dd->block_size = dd->media_block_size = block_size;
2003250: f4 20 60 24 st %i2, [ %g1 + 0x24 ]
dd->ioctl = handler;
2003254: f8 20 60 28 st %i4, [ %g1 + 0x28 ]
dd->driver_data = driver_data;
if ((*handler)(dd, RTEMS_BLKIO_CAPABILITIES, &dd->capabilities) < 0) {
2003258: 92 12 62 08 or %o1, 0x208, %o1
200325c: 9f c7 00 00 call %i4
2003260: 94 00 60 0c add %g1, 0xc, %o2
2003264: 80 a2 20 00 cmp %o0, 0
2003268: 06 80 00 0a bl 2003290 <rtems_disk_create_phys+0xac> <== ALWAYS TAKEN
200326c: c2 07 bf fc ld [ %fp + -4 ], %g1
dd->capabilities = 0;
}
disk_unlock();
2003270: 7f ff fe 3d call 2002b64 <disk_unlock> <== NOT EXECUTED
2003274: 01 00 00 00 nop <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
2003278: 81 c7 e0 08 ret
200327c: 81 e8 00 00 restore
return sc;
}
sc = create_disk(dev, name, &dd);
if (sc != RTEMS_SUCCESSFUL) {
disk_unlock();
2003280: 7f ff fe 39 call 2002b64 <disk_unlock>
2003284: 01 00 00 00 nop
return sc;
2003288: 81 c7 e0 08 ret
200328c: 81 e8 00 00 restore
if ((*handler)(dd, RTEMS_BLKIO_CAPABILITIES, &dd->capabilities) < 0) {
dd->capabilities = 0;
}
disk_unlock();
2003290: 7f ff fe 35 call 2002b64 <disk_unlock>
2003294: c0 20 60 0c clr [ %g1 + 0xc ]
2003298: 30 bf ff fc b,a 2003288 <rtems_disk_create_phys+0xa4>
02002c98 <rtems_disk_delete>:
}
}
rtems_status_code
rtems_disk_delete(dev_t dev)
{
2002c98: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *dd = NULL;
sc = disk_lock();
2002c9c: 7f ff ff a3 call 2002b28 <disk_lock>
2002ca0: 01 00 00 00 nop
if (sc != RTEMS_SUCCESSFUL) {
2002ca4: a0 92 20 00 orcc %o0, 0, %l0
2002ca8: 02 80 00 04 be 2002cb8 <rtems_disk_delete+0x20> <== ALWAYS TAKEN
2002cac: 90 10 00 18 mov %i0, %o0
rtems_disk_cleanup(dd);
disk_unlock();
return RTEMS_SUCCESSFUL;
}
2002cb0: 81 c7 e0 08 ret <== NOT EXECUTED
2002cb4: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
sc = disk_lock();
if (sc != RTEMS_SUCCESSFUL) {
return sc;
}
dd = get_disk_entry(dev, true);
2002cb8: 92 10 00 19 mov %i1, %o1
2002cbc: 7f ff fe f9 call 20028a0 <get_disk_entry>
2002cc0: 94 10 20 01 mov 1, %o2
if (dd == NULL) {
2002cc4: 82 92 20 00 orcc %o0, 0, %g1
2002cc8: 02 80 00 66 be 2002e60 <rtems_disk_delete+0x1c8> <== NEVER TAKEN
2002ccc: 84 10 20 01 mov 1, %g2
}
static void
rtems_disk_cleanup(rtems_disk_device *disk_to_remove)
{
rtems_disk_device *const physical_disk = disk_to_remove->phys_dev;
2002cd0: e6 00 60 08 ld [ %g1 + 8 ], %l3
disk_unlock();
return RTEMS_INVALID_ID;
}
dd->deleted = true;
2002cd4: c4 28 60 30 stb %g2, [ %g1 + 0x30 ]
{
rtems_disk_device *const physical_disk = disk_to_remove->phys_dev;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
if (physical_disk->deleted) {
2002cd8: c4 0c e0 30 ldub [ %l3 + 0x30 ], %g2
2002cdc: 80 a0 a0 00 cmp %g2, 0
2002ce0: 22 80 00 4f be,a 2002e1c <rtems_disk_delete+0x184>
2002ce4: c4 00 60 14 ld [ %g1 + 0x14 ], %g2
dev_t dev = physical_disk->dev;
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
2002ce8: 37 00 80 8b sethi %hi(0x2022c00), %i3
2002cec: c2 06 e2 5c ld [ %i3 + 0x25c ], %g1 ! 2022e5c <disktab_size>
rtems_disk_device *const physical_disk = disk_to_remove->phys_dev;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
if (physical_disk->deleted) {
dev_t dev = physical_disk->dev;
2002cf0: e8 04 c0 00 ld [ %l3 ], %l4
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
2002cf4: 80 a0 60 00 cmp %g1, 0
rtems_disk_device *const physical_disk = disk_to_remove->phys_dev;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
if (physical_disk->deleted) {
dev_t dev = physical_disk->dev;
2002cf8: fa 04 e0 04 ld [ %l3 + 4 ], %i5
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
2002cfc: 02 80 00 35 be 2002dd0 <rtems_disk_delete+0x138> <== NEVER TAKEN
2002d00: ae 10 20 00 clr %l7
2002d04: 39 00 80 8b sethi %hi(0x2022c00), %i4
2002d08: b6 16 e2 5c or %i3, 0x25c, %i3
2002d0c: b8 17 22 58 or %i4, 0x258, %i4
2002d10: aa 10 20 00 clr %l5
if (dd->uses == 0) {
++deleted_count;
dtab->minor [minor] = NULL;
free_disk_device(dd);
} else {
dd->deleted = true;
2002d14: ac 10 20 01 mov 1, %l6
if (physical_disk->deleted) {
dev_t dev = physical_disk->dev;
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
rtems_disk_device_table *dtab = disktab + major;
2002d18: e4 07 00 00 ld [ %i4 ], %l2
2002d1c: 83 2d 60 03 sll %l5, 3, %g1
2002d20: a4 04 80 01 add %l2, %g1, %l2
for (minor = 0; minor < dtab->size; ++minor) {
2002d24: c6 04 a0 04 ld [ %l2 + 4 ], %g3
2002d28: 80 a0 e0 00 cmp %g3, 0
2002d2c: 22 80 00 25 be,a 2002dc0 <rtems_disk_delete+0x128>
2002d30: c2 06 c0 00 ld [ %i3 ], %g1
2002d34: 10 80 00 06 b 2002d4c <rtems_disk_delete+0xb4>
2002d38: a2 10 20 00 clr %l1
2002d3c: a2 04 60 01 inc %l1
2002d40: 80 a4 40 03 cmp %l1, %g3
2002d44: 3a 80 00 1f bcc,a 2002dc0 <rtems_disk_delete+0x128>
2002d48: c2 06 c0 00 ld [ %i3 ], %g1
rtems_disk_device *dd = dtab->minor [minor];
2002d4c: c4 04 80 00 ld [ %l2 ], %g2
2002d50: 83 2c 60 02 sll %l1, 2, %g1
2002d54: d0 00 80 01 ld [ %g2 + %g1 ], %o0
if (dd != NULL && dd->phys_dev->dev == dev && dd != physical_disk) {
2002d58: 80 a2 20 00 cmp %o0, 0
2002d5c: 02 bf ff f8 be 2002d3c <rtems_disk_delete+0xa4>
2002d60: 80 a4 c0 08 cmp %l3, %o0
2002d64: 22 bf ff f7 be,a 2002d40 <rtems_disk_delete+0xa8>
2002d68: a2 04 60 01 inc %l1
2002d6c: c8 02 20 08 ld [ %o0 + 8 ], %g4
2002d70: da 01 00 00 ld [ %g4 ], %o5
2002d74: 80 a3 40 14 cmp %o5, %l4
2002d78: 32 bf ff f2 bne,a 2002d40 <rtems_disk_delete+0xa8> <== NEVER TAKEN
2002d7c: a2 04 60 01 inc %l1 <== NOT EXECUTED
2002d80: c8 01 20 04 ld [ %g4 + 4 ], %g4
2002d84: 80 a1 00 1d cmp %g4, %i5
2002d88: 32 bf ff ee bne,a 2002d40 <rtems_disk_delete+0xa8> <== NEVER TAKEN
2002d8c: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (dd->uses == 0) {
2002d90: c8 02 20 14 ld [ %o0 + 0x14 ], %g4
2002d94: 80 a1 20 00 cmp %g4, 0
2002d98: 32 bf ff e9 bne,a 2002d3c <rtems_disk_delete+0xa4>
2002d9c: ec 2a 20 30 stb %l6, [ %o0 + 0x30 ]
++deleted_count;
dtab->minor [minor] = NULL;
free_disk_device(dd);
2002da0: 7f ff fe e5 call 2002934 <free_disk_device>
2002da4: c0 20 80 01 clr [ %g2 + %g1 ]
2002da8: c6 04 a0 04 ld [ %l2 + 4 ], %g3
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
rtems_disk_device_table *dtab = disktab + major;
for (minor = 0; minor < dtab->size; ++minor) {
2002dac: a2 04 60 01 inc %l1
2002db0: 80 a4 40 03 cmp %l1, %g3
2002db4: 0a bf ff e6 bcs 2002d4c <rtems_disk_delete+0xb4> <== ALWAYS TAKEN
2002db8: ae 05 e0 01 inc %l7
if (physical_disk->deleted) {
dev_t dev = physical_disk->dev;
unsigned deleted_count = 0;
for (major = 0; major < disktab_size; ++major) {
2002dbc: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
2002dc0: aa 05 60 01 inc %l5
2002dc4: 80 a5 40 01 cmp %l5, %g1
2002dc8: 2a bf ff d5 bcs,a 2002d1c <rtems_disk_delete+0x84>
2002dcc: e4 07 00 00 ld [ %i4 ], %l2
}
}
}
}
physical_disk->uses -= deleted_count;
2002dd0: c2 04 e0 14 ld [ %l3 + 0x14 ], %g1
2002dd4: ae 20 40 17 sub %g1, %l7, %l7
if (physical_disk->uses == 0) {
2002dd8: 80 a5 e0 00 cmp %l7, 0
2002ddc: 12 80 00 0c bne 2002e0c <rtems_disk_delete+0x174>
2002de0: ee 24 e0 14 st %l7, [ %l3 + 0x14 ]
rtems_filesystem_split_dev_t(physical_disk->dev, major, minor);
2002de4: c2 04 c0 00 ld [ %l3 ], %g1
disktab [major].minor [minor] = NULL;
2002de8: 05 00 80 8b sethi %hi(0x2022c00), %g2
2002dec: c4 00 a2 58 ld [ %g2 + 0x258 ], %g2 ! 2022e58 <disktab>
2002df0: 83 28 60 03 sll %g1, 3, %g1
2002df4: c4 00 80 01 ld [ %g2 + %g1 ], %g2
}
}
physical_disk->uses -= deleted_count;
if (physical_disk->uses == 0) {
rtems_filesystem_split_dev_t(physical_disk->dev, major, minor);
2002df8: c2 04 e0 04 ld [ %l3 + 4 ], %g1
disktab [major].minor [minor] = NULL;
free_disk_device(physical_disk);
2002dfc: 90 10 00 13 mov %l3, %o0
}
physical_disk->uses -= deleted_count;
if (physical_disk->uses == 0) {
rtems_filesystem_split_dev_t(physical_disk->dev, major, minor);
disktab [major].minor [minor] = NULL;
2002e00: 83 28 60 02 sll %g1, 2, %g1
free_disk_device(physical_disk);
2002e04: 7f ff fe cc call 2002934 <free_disk_device>
2002e08: c0 20 80 01 clr [ %g2 + %g1 ]
}
dd->deleted = true;
rtems_disk_cleanup(dd);
disk_unlock();
2002e0c: 7f ff ff 56 call 2002b64 <disk_unlock>
2002e10: b0 10 00 10 mov %l0, %i0
return RTEMS_SUCCESSFUL;
}
2002e14: 81 c7 e0 08 ret
2002e18: 81 e8 00 00 restore
rtems_filesystem_split_dev_t(physical_disk->dev, major, minor);
disktab [major].minor [minor] = NULL;
free_disk_device(physical_disk);
}
} else {
if (disk_to_remove->uses == 0) {
2002e1c: 80 a0 a0 00 cmp %g2, 0
2002e20: 12 bf ff fb bne 2002e0c <rtems_disk_delete+0x174> <== NEVER TAKEN
2002e24: 05 00 80 8b sethi %hi(0x2022c00), %g2
--physical_disk->uses;
rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
2002e28: c8 00 40 00 ld [ %g1 ], %g4
disktab [major].minor [minor] = NULL;
2002e2c: c6 00 a2 58 ld [ %g2 + 0x258 ], %g3
free_disk_device(physical_disk);
}
} else {
if (disk_to_remove->uses == 0) {
--physical_disk->uses;
rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
2002e30: c4 00 60 04 ld [ %g1 + 4 ], %g2
disktab [major].minor [minor] = NULL;
2002e34: 83 29 20 03 sll %g4, 3, %g1
2002e38: c6 00 c0 01 ld [ %g3 + %g1 ], %g3
disktab [major].minor [minor] = NULL;
free_disk_device(physical_disk);
}
} else {
if (disk_to_remove->uses == 0) {
--physical_disk->uses;
2002e3c: c2 04 e0 14 ld [ %l3 + 0x14 ], %g1
rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
disktab [major].minor [minor] = NULL;
2002e40: 85 28 a0 02 sll %g2, 2, %g2
disktab [major].minor [minor] = NULL;
free_disk_device(physical_disk);
}
} else {
if (disk_to_remove->uses == 0) {
--physical_disk->uses;
2002e44: 82 00 7f ff add %g1, -1, %g1
rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
disktab [major].minor [minor] = NULL;
2002e48: c0 20 c0 02 clr [ %g3 + %g2 ]
free_disk_device(disk_to_remove);
2002e4c: 7f ff fe ba call 2002934 <free_disk_device>
2002e50: c2 24 e0 14 st %g1, [ %l3 + 0x14 ]
}
dd->deleted = true;
rtems_disk_cleanup(dd);
disk_unlock();
2002e54: 7f ff ff 44 call 2002b64 <disk_unlock>
2002e58: b0 10 00 10 mov %l0, %i0
2002e5c: 30 bf ff ee b,a 2002e14 <rtems_disk_delete+0x17c>
return sc;
}
dd = get_disk_entry(dev, true);
if (dd == NULL) {
disk_unlock();
2002e60: 7f ff ff 41 call 2002b64 <disk_unlock> <== NOT EXECUTED
2002e64: a0 10 20 04 mov 4, %l0 <== NOT EXECUTED
return RTEMS_INVALID_ID;
2002e68: 30 bf ff 92 b,a 2002cb0 <rtems_disk_delete+0x18> <== NOT EXECUTED
0200298c <rtems_disk_io_done>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_disk_io_done(void)
{
200298c: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
2002990: 21 00 80 8b sethi %hi(0x2022c00), %l0
2002994: c2 04 22 5c ld [ %l0 + 0x25c ], %g1 ! 2022e5c <disktab_size>
2002998: 80 a0 60 00 cmp %g1, 0
200299c: 02 80 00 20 be 2002a1c <rtems_disk_io_done+0x90> <== NEVER TAKEN
20029a0: 23 00 80 8b sethi %hi(0x2022c00), %l1
20029a4: a8 10 20 00 clr %l4
20029a8: ac 14 62 58 or %l1, 0x258, %l6
20029ac: aa 14 22 5c or %l0, 0x25c, %l5
rtems_disk_device_table *dtab = disktab + major;
20029b0: c6 05 80 00 ld [ %l6 ], %g3
20029b4: 83 2d 20 03 sll %l4, 3, %g1
20029b8: a6 00 c0 01 add %g3, %g1, %l3
for (minor = 0; minor < dtab->size; ++minor) {
20029bc: c4 04 e0 04 ld [ %l3 + 4 ], %g2
20029c0: 80 a0 a0 00 cmp %g2, 0
20029c4: 02 80 00 21 be 2002a48 <rtems_disk_io_done+0xbc>
20029c8: a4 10 20 00 clr %l2
20029cc: c6 00 c0 01 ld [ %g3 + %g1 ], %g3
rtems_disk_device *dd = dtab->minor [minor];
20029d0: 83 2c a0 02 sll %l2, 2, %g1
20029d4: c2 00 c0 01 ld [ %g3 + %g1 ], %g1
if (dd != NULL) {
20029d8: 90 90 60 00 orcc %g1, 0, %o0
20029dc: 02 80 00 06 be 20029f4 <rtems_disk_io_done+0x68> <== ALWAYS TAKEN
20029e0: a4 04 a0 01 inc %l2
free_disk_device(dd);
20029e4: 7f ff ff d4 call 2002934 <free_disk_device> <== NOT EXECUTED
20029e8: 01 00 00 00 nop <== NOT EXECUTED
20029ec: c4 04 e0 04 ld [ %l3 + 4 ], %g2 <== NOT EXECUTED
20029f0: c6 04 c0 00 ld [ %l3 ], %g3 <== NOT EXECUTED
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
rtems_disk_device_table *dtab = disktab + major;
for (minor = 0; minor < dtab->size; ++minor) {
20029f4: 80 a0 80 12 cmp %g2, %l2
20029f8: 18 bf ff f7 bgu 20029d4 <rtems_disk_io_done+0x48>
20029fc: 83 2c a0 02 sll %l2, 2, %g1
if (dd != NULL) {
free_disk_device(dd);
}
}
free(dtab->minor);
2002a00: 40 00 04 e4 call 2003d90 <free>
2002a04: 90 10 00 03 mov %g3, %o0
rtems_disk_io_done(void)
{
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
2002a08: c2 05 40 00 ld [ %l5 ], %g1
2002a0c: a8 05 20 01 inc %l4
2002a10: 80 a0 40 14 cmp %g1, %l4
2002a14: 38 bf ff e8 bgu,a 20029b4 <rtems_disk_io_done+0x28> <== ALWAYS TAKEN
2002a18: c6 05 80 00 ld [ %l6 ], %g3
free_disk_device(dd);
}
}
free(dtab->minor);
}
free(disktab);
2002a1c: d0 04 62 58 ld [ %l1 + 0x258 ], %o0 <== NOT EXECUTED
2002a20: 40 00 04 dc call 2003d90 <free>
2002a24: 25 00 80 8b sethi %hi(0x2022c00), %l2
rtems_semaphore_delete(diskdevs_mutex);
2002a28: d0 04 a2 60 ld [ %l2 + 0x260 ], %o0 ! 2022e60 <diskdevs_mutex>
2002a2c: 40 00 14 7a call 2007c14 <rtems_semaphore_delete>
2002a30: b0 10 20 00 clr %i0
diskdevs_mutex = RTEMS_ID_NONE;
2002a34: c0 24 a2 60 clr [ %l2 + 0x260 ]
disktab = NULL;
2002a38: c0 24 62 58 clr [ %l1 + 0x258 ]
disktab_size = 0;
2002a3c: c0 24 22 5c clr [ %l0 + 0x25c ]
return RTEMS_SUCCESSFUL;
}
2002a40: 81 c7 e0 08 ret
2002a44: 81 e8 00 00 restore
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
rtems_disk_device_table *dtab = disktab + major;
for (minor = 0; minor < dtab->size; ++minor) {
2002a48: c6 00 c0 01 ld [ %g3 + %g1 ], %g3
rtems_disk_io_done(void)
{
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
2002a4c: a8 05 20 01 inc %l4
if (dd != NULL) {
free_disk_device(dd);
}
}
free(dtab->minor);
2002a50: 40 00 04 d0 call 2003d90 <free>
2002a54: 90 10 00 03 mov %g3, %o0
rtems_disk_io_done(void)
{
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
for (major = 0; major < disktab_size; ++major) {
2002a58: c2 05 40 00 ld [ %l5 ], %g1
2002a5c: 80 a0 40 14 cmp %g1, %l4
2002a60: 38 bf ff d5 bgu,a 20029b4 <rtems_disk_io_done+0x28>
2002a64: c6 05 80 00 ld [ %l6 ], %g3
free_disk_device(dd);
}
}
free(dtab->minor);
}
free(disktab);
2002a68: 10 bf ff ee b 2002a20 <rtems_disk_io_done+0x94>
2002a6c: d0 04 62 58 ld [ %l1 + 0x258 ], %o0
02002a70 <rtems_disk_io_initialize>:
}
}
rtems_status_code
rtems_disk_io_initialize(void)
{
2002a70: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_device_major_number size = DISKTAB_INITIAL_SIZE;
if (disktab_size > 0) {
2002a74: 21 00 80 8b sethi %hi(0x2022c00), %l0
2002a78: c2 04 22 5c ld [ %l0 + 0x25c ], %g1 ! 2022e5c <disktab_size>
2002a7c: 80 a0 60 00 cmp %g1, 0
2002a80: 12 80 00 19 bne 2002ae4 <rtems_disk_io_initialize+0x74> <== NEVER TAKEN
2002a84: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
disktab = calloc(size, sizeof(rtems_disk_device_table));
2002a88: 90 10 20 08 mov 8, %o0
2002a8c: 92 10 20 08 mov 8, %o1
2002a90: 40 00 04 1d call 2003b04 <calloc>
2002a94: 23 00 80 8b sethi %hi(0x2022c00), %l1
2002a98: d0 24 62 58 st %o0, [ %l1 + 0x258 ] ! 2022e58 <disktab>
if (disktab == NULL) {
2002a9c: 80 a2 20 00 cmp %o0, 0
2002aa0: 02 80 00 11 be 2002ae4 <rtems_disk_io_initialize+0x74> <== NEVER TAKEN
2002aa4: b0 10 20 1a mov 0x1a, %i0
return RTEMS_NO_MEMORY;
}
diskdevs_protected = false;
2002aa8: 03 00 80 8b sethi %hi(0x2022c00), %g1
sc = rtems_semaphore_create(
2002aac: 11 11 11 11 sethi %hi(0x44444400), %o0
disktab = calloc(size, sizeof(rtems_disk_device_table));
if (disktab == NULL) {
return RTEMS_NO_MEMORY;
}
diskdevs_protected = false;
2002ab0: c0 28 62 64 clrb [ %g1 + 0x264 ]
sc = rtems_semaphore_create(
2002ab4: 90 12 21 56 or %o0, 0x156, %o0
2002ab8: 92 10 20 01 mov 1, %o1
2002abc: 94 10 20 10 mov 0x10, %o2
2002ac0: 96 10 20 00 clr %o3
2002ac4: 25 00 80 8b sethi %hi(0x2022c00), %l2
2002ac8: 40 00 13 df call 2007a44 <rtems_semaphore_create>
2002acc: 98 14 a2 60 or %l2, 0x260, %o4 ! 2022e60 <diskdevs_mutex>
RTEMS_FIFO | RTEMS_BINARY_SEMAPHORE | RTEMS_NO_INHERIT_PRIORITY
| RTEMS_NO_PRIORITY_CEILING | RTEMS_LOCAL,
0,
&diskdevs_mutex
);
if (sc != RTEMS_SUCCESSFUL) {
2002ad0: 80 a2 20 00 cmp %o0, 0
2002ad4: 02 80 00 06 be 2002aec <rtems_disk_io_initialize+0x7c> <== ALWAYS TAKEN
2002ad8: 01 00 00 00 nop
free(disktab);
2002adc: 40 00 04 ad call 2003d90 <free> <== NOT EXECUTED
2002ae0: d0 04 62 58 ld [ %l1 + 0x258 ], %o0 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
2002ae4: 81 c7 e0 08 ret <== NOT EXECUTED
2002ae8: 81 e8 00 00 restore <== NOT EXECUTED
}
sc = rtems_bdbuf_init();
2002aec: 40 00 27 98 call 200c94c <rtems_bdbuf_init>
2002af0: 01 00 00 00 nop
if (sc != RTEMS_SUCCESSFUL) {
2002af4: 80 a2 20 00 cmp %o0, 0
2002af8: 12 80 00 05 bne 2002b0c <rtems_disk_io_initialize+0x9c> <== NEVER TAKEN
2002afc: 82 10 20 08 mov 8, %g1
free(disktab);
return RTEMS_UNSATISFIED;
}
disktab_size = size;
2002b00: c2 24 22 5c st %g1, [ %l0 + 0x25c ]
return RTEMS_SUCCESSFUL;
}
2002b04: 81 c7 e0 08 ret
2002b08: 91 e8 20 00 restore %g0, 0, %o0
return RTEMS_NO_MEMORY;
}
sc = rtems_bdbuf_init();
if (sc != RTEMS_SUCCESSFUL) {
rtems_semaphore_delete(diskdevs_mutex);
2002b0c: d0 04 a2 60 ld [ %l2 + 0x260 ], %o0 <== NOT EXECUTED
2002b10: 40 00 14 41 call 2007c14 <rtems_semaphore_delete> <== NOT EXECUTED
2002b14: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED
free(disktab);
2002b18: 40 00 04 9e call 2003d90 <free> <== NOT EXECUTED
2002b1c: d0 04 62 58 ld [ %l1 + 0x258 ], %o0 <== NOT EXECUTED
return RTEMS_UNSATISFIED;
2002b20: 81 c7 e0 08 ret <== NOT EXECUTED
2002b24: 81 e8 00 00 restore <== NOT EXECUTED
02002ba0 <rtems_disk_next>:
return RTEMS_SUCCESSFUL;
}
rtems_disk_device *
rtems_disk_next(dev_t dev)
{
2002ba0: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device_table *dtab = NULL;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
if (dev != (dev_t) -1) {
2002ba4: 80 a6 3f ff cmp %i0, -1
2002ba8: 02 80 00 38 be 2002c88 <rtems_disk_next+0xe8>
2002bac: 80 a6 7f ff cmp %i1, -1
rtems_filesystem_split_dev_t(dev, major, minor);
/* If minor wraps around */
if ((minor + 1) < minor) {
2002bb0: a0 06 60 01 add %i1, 1, %l0
2002bb4: 80 a4 00 19 cmp %l0, %i1
2002bb8: 0a 80 00 22 bcs 2002c40 <rtems_disk_next+0xa0> <== NEVER TAKEN
2002bbc: a2 10 00 18 mov %i0, %l1
} else {
++minor;
}
}
sc = disk_lock();
2002bc0: 7f ff ff da call 2002b28 <disk_lock>
2002bc4: 01 00 00 00 nop
if (sc != RTEMS_SUCCESSFUL) {
2002bc8: 80 a2 20 00 cmp %o0, 0
2002bcc: 12 80 00 21 bne 2002c50 <rtems_disk_next+0xb0> <== NEVER TAKEN
2002bd0: 03 00 80 8b sethi %hi(0x2022c00), %g1
return NULL;
}
if (major >= disktab_size) {
2002bd4: c8 00 62 5c ld [ %g1 + 0x25c ], %g4 ! 2022e5c <disktab_size>
2002bd8: 80 a4 40 04 cmp %l1, %g4
2002bdc: 1a 80 00 27 bcc 2002c78 <rtems_disk_next+0xd8> <== NEVER TAKEN
2002be0: 03 00 80 8b sethi %hi(0x2022c00), %g1
disk_unlock();
return NULL;
}
dtab = disktab + major;
2002be4: c6 00 62 58 ld [ %g1 + 0x258 ], %g3 ! 2022e58 <disktab>
2002be8: a5 2c 60 03 sll %l1, 3, %l2
2002bec: c2 00 c0 12 ld [ %g3 + %l2 ], %g1
2002bf0: a4 00 c0 12 add %g3, %l2, %l2
while (true) {
if (dtab->minor == NULL || minor >= dtab->size) {
2002bf4: 80 a0 60 00 cmp %g1, 0
2002bf8: 02 80 00 18 be 2002c58 <rtems_disk_next+0xb8>
2002bfc: a7 2c 20 02 sll %l0, 2, %l3
2002c00: c4 04 a0 04 ld [ %l2 + 4 ], %g2
2002c04: 80 a4 00 02 cmp %l0, %g2
2002c08: 3a 80 00 15 bcc,a 2002c5c <rtems_disk_next+0xbc>
2002c0c: a2 04 60 01 inc %l1
disk_unlock();
return NULL;
}
dtab = disktab + major;
} else if (dtab->minor [minor] == NULL) {
2002c10: c4 00 40 13 ld [ %g1 + %l3 ], %g2
2002c14: 80 a0 a0 00 cmp %g2, 0
2002c18: 02 bf ff f7 be 2002bf4 <rtems_disk_next+0x54>
2002c1c: a0 04 20 01 inc %l0
++minor;
} else {
++dtab->minor [minor]->uses;
2002c20: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1
2002c24: 82 00 60 01 inc %g1
disk_unlock();
2002c28: 7f ff ff cf call 2002b64 <disk_unlock>
2002c2c: c2 20 a0 14 st %g1, [ %g2 + 0x14 ]
return dtab->minor [minor];
2002c30: c2 04 80 00 ld [ %l2 ], %g1
2002c34: f0 00 40 13 ld [ %g1 + %l3 ], %i0
2002c38: 81 c7 e0 08 ret
2002c3c: 81 e8 00 00 restore
rtems_filesystem_split_dev_t(dev, major, minor);
/* If minor wraps around */
if ((minor + 1) < minor) {
/* If major wraps around */
if ((major + 1) < major) {
2002c40: a2 06 20 01 add %i0, 1, %l1 <== NOT EXECUTED
2002c44: 80 a4 40 18 cmp %l1, %i0 <== NOT EXECUTED
2002c48: 1a bf ff de bcc 2002bc0 <rtems_disk_next+0x20> <== NOT EXECUTED
2002c4c: a0 10 20 00 clr %l0 <== NOT EXECUTED
disk_unlock();
return dtab->minor [minor];
}
}
}
2002c50: 81 c7 e0 08 ret <== NOT EXECUTED
2002c54: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
dtab = disktab + major;
while (true) {
if (dtab->minor == NULL || minor >= dtab->size) {
minor = 0;
++major;
2002c58: a2 04 60 01 inc %l1
if (major >= disktab_size) {
2002c5c: 80 a1 00 11 cmp %g4, %l1
2002c60: 08 80 00 06 bleu 2002c78 <rtems_disk_next+0xd8>
2002c64: a5 2c 60 03 sll %l1, 3, %l2
disk_unlock();
return NULL;
}
dtab = disktab + major;
2002c68: a0 10 20 00 clr %l0
2002c6c: c2 00 c0 12 ld [ %g3 + %l2 ], %g1
return NULL;
}
dtab = disktab + major;
while (true) {
if (dtab->minor == NULL || minor >= dtab->size) {
2002c70: 10 bf ff e1 b 2002bf4 <rtems_disk_next+0x54>
2002c74: a4 00 c0 12 add %g3, %l2, %l2
minor = 0;
++major;
if (major >= disktab_size) {
disk_unlock();
2002c78: 7f ff ff bb call 2002b64 <disk_unlock>
2002c7c: b0 10 20 00 clr %i0
return NULL;
2002c80: 81 c7 e0 08 ret
2002c84: 81 e8 00 00 restore
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device_table *dtab = NULL;
rtems_device_major_number major = 0;
rtems_device_minor_number minor = 0;
if (dev != (dev_t) -1) {
2002c88: a0 10 20 00 clr %l0
2002c8c: 12 bf ff c9 bne 2002bb0 <rtems_disk_next+0x10> <== NEVER TAKEN
2002c90: a2 10 20 00 clr %l1
2002c94: 30 bf ff cb b,a 2002bc0 <rtems_disk_next+0x20>
02002ec0 <rtems_disk_obtain>:
return RTEMS_SUCCESSFUL;
}
rtems_disk_device *
rtems_disk_obtain(dev_t dev)
{
2002ec0: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_disk_device *dd = NULL;
rtems_interrupt_level level;
rtems_interrupt_disable(level);
2002ec4: 7f ff fe 00 call 20026c4 <sparc_disable_interrupts>
2002ec8: a4 10 00 18 mov %i0, %l2
2002ecc: a0 10 00 08 mov %o0, %l0
if (!diskdevs_protected) {
2002ed0: 03 00 80 8b sethi %hi(0x2022c00), %g1
2002ed4: c2 08 62 64 ldub [ %g1 + 0x264 ], %g1 ! 2022e64 <diskdevs_protected>
2002ed8: 80 a0 60 00 cmp %g1, 0
2002edc: 12 80 00 0a bne 2002f04 <rtems_disk_obtain+0x44> <== NEVER TAKEN
2002ee0: 92 10 00 19 mov %i1, %o1
/* Frequent and quickest case */
dd = get_disk_entry(dev, false);
2002ee4: 90 10 00 18 mov %i0, %o0
2002ee8: 7f ff fe 6e call 20028a0 <get_disk_entry>
2002eec: 94 10 20 00 clr %o2
2002ef0: b0 10 00 08 mov %o0, %i0
rtems_interrupt_enable(level);
2002ef4: 7f ff fd f8 call 20026d4 <sparc_enable_interrupts>
2002ef8: 90 10 00 10 mov %l0, %o0
2002efc: 81 c7 e0 08 ret
2002f00: 81 e8 00 00 restore
} else {
rtems_interrupt_enable(level);
2002f04: 7f ff fd f4 call 20026d4 <sparc_enable_interrupts> <== NOT EXECUTED
2002f08: b0 10 20 00 clr %i0 <== NOT EXECUTED
sc = disk_lock();
2002f0c: 7f ff ff 07 call 2002b28 <disk_lock> <== NOT EXECUTED
2002f10: 01 00 00 00 nop <== NOT EXECUTED
if (sc == RTEMS_SUCCESSFUL) {
2002f14: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2002f18: 12 bf ff f9 bne 2002efc <rtems_disk_obtain+0x3c> <== NOT EXECUTED
2002f1c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
dd = get_disk_entry(dev, false);
2002f20: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2002f24: 7f ff fe 5f call 20028a0 <get_disk_entry> <== NOT EXECUTED
2002f28: 94 10 20 00 clr %o2 <== NOT EXECUTED
disk_unlock();
2002f2c: 7f ff ff 0e call 2002b64 <disk_unlock> <== NOT EXECUTED
2002f30: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
}
}
return dd;
}
2002f34: 81 c7 e0 08 ret <== NOT EXECUTED
2002f38: 81 e8 00 00 restore <== NOT EXECUTED
02022f0c <rtems_dosfs_initialize>:
int rtems_dosfs_initialize(rtems_filesystem_mount_table_entry_t *mt_entry,
const void *data)
{
int rc;
rc = msdos_initialize_support(mt_entry,
2022f0c: 13 00 81 a6 sethi %hi(0x2069800), %o1 <== NOT EXECUTED
2022f10: 15 00 81 b8 sethi %hi(0x206e000), %o2 <== NOT EXECUTED
2022f14: 17 00 81 b8 sethi %hi(0x206e000), %o3 <== NOT EXECUTED
2022f18: 92 12 60 c0 or %o1, 0xc0, %o1 <== NOT EXECUTED
2022f1c: 94 12 a2 58 or %o2, 0x258, %o2 <== NOT EXECUTED
2022f20: 96 12 e2 20 or %o3, 0x220, %o3 <== NOT EXECUTED
2022f24: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2022f28: 40 00 00 03 call 2022f34 <msdos_initialize_support> <== NOT EXECUTED
2022f2c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02007ee8 <rtems_error>:
int rtems_error(
rtems_error_code_t error_flag,
const char *printf_format,
...
)
{
2007ee8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
va_list arglist;
int chars_written;
va_start(arglist, printf_format);
2007eec: 94 07 a0 4c add %fp, 0x4c, %o2 <== NOT EXECUTED
2007ef0: f4 27 a0 4c st %i2, [ %fp + 0x4c ] <== NOT EXECUTED
2007ef4: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
2007ef8: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
2007efc: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
chars_written = rtems_verror(error_flag, printf_format, arglist);
2007f00: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2007f04: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2007f08: 7f ff ff 7e call 2007d00 <rtems_verror> <== NOT EXECUTED
2007f0c: d4 27 bf fc st %o2, [ %fp + -4 ] <== NOT EXECUTED
va_end(arglist);
return chars_written;
}
2007f10: 81 c7 e0 08 ret <== NOT EXECUTED
2007f14: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02002b20 <rtems_filesystem_dirname>:
}
int rtems_filesystem_dirname(
const char *pathname
)
{
2002b20: 9d e3 bf a0 save %sp, -96, %sp
int len = strlen( pathname );
2002b24: 40 00 3f 83 call 2012930 <strlen>
2002b28: 90 10 00 18 mov %i0, %o0
while ( len ) {
2002b2c: a0 92 20 00 orcc %o0, 0, %l0
2002b30: 02 80 00 0d be 2002b64 <rtems_filesystem_dirname+0x44> <== NEVER TAKEN
2002b34: 01 00 00 00 nop
2002b38: 10 80 00 05 b 2002b4c <rtems_filesystem_dirname+0x2c>
2002b3c: b0 06 00 10 add %i0, %l0, %i0
2002b40: 80 a4 20 00 cmp %l0, 0
2002b44: 02 80 00 08 be 2002b64 <rtems_filesystem_dirname+0x44>
2002b48: 01 00 00 00 nop
len--;
if ( rtems_filesystem_is_separator( pathname[len] ) )
2002b4c: d0 4e 3f ff ldsb [ %i0 + -1 ], %o0
2002b50: 40 00 04 a9 call 2003df4 <rtems_filesystem_is_separator>
2002b54: a0 04 3f ff add %l0, -1, %l0
2002b58: 80 a2 20 00 cmp %o0, 0
2002b5c: 02 bf ff f9 be 2002b40 <rtems_filesystem_dirname+0x20>
2002b60: b0 06 3f ff add %i0, -1, %i0
break;
}
return len;
}
2002b64: 81 c7 e0 08 ret
2002b68: 91 e8 00 10 restore %g0, %l0, %o0
02002c70 <rtems_filesystem_evaluate_path>:
size_t pathnamelen,
int flags,
rtems_filesystem_location_info_t *pathloc,
int follow_link
)
{
2002c70: 9d e3 bf 98 save %sp, -104, %sp
/*
* Verify Input parameters.
*/
if ( !pathname )
2002c74: 80 a6 20 00 cmp %i0, 0
2002c78: 02 80 00 17 be 2002cd4 <rtems_filesystem_evaluate_path+0x64><== NEVER TAKEN
2002c7c: c0 27 bf fc clr [ %fp + -4 ]
rtems_set_errno_and_return_minus_one( EFAULT );
if ( !pathloc )
2002c80: 80 a6 e0 00 cmp %i3, 0
2002c84: 02 80 00 0e be 2002cbc <rtems_filesystem_evaluate_path+0x4c><== NEVER TAKEN
2002c88: 90 10 00 18 mov %i0, %o0
/*
* Evaluate the path using the optable evalpath.
*/
rtems_filesystem_get_start_loc( pathname, &i, pathloc );
2002c8c: 92 07 bf fc add %fp, -4, %o1
2002c90: 40 00 04 36 call 2003d68 <rtems_filesystem_get_start_loc>
2002c94: 94 10 00 1b mov %i3, %o2
/*
* We evaluation the path relative to the start location we get got.
*/
return rtems_filesystem_evaluate_relative_path( &pathname[i],
2002c98: d0 07 bf fc ld [ %fp + -4 ], %o0
2002c9c: 94 10 00 1a mov %i2, %o2
2002ca0: 92 26 40 08 sub %i1, %o0, %o1
2002ca4: 96 10 00 1b mov %i3, %o3
2002ca8: 90 06 00 08 add %i0, %o0, %o0
2002cac: 7f ff ff b0 call 2002b6c <rtems_filesystem_evaluate_relative_path>
2002cb0: 98 10 00 1c mov %i4, %o4
pathnamelen - i,
flags,
pathloc,
follow_link );
}
2002cb4: 81 c7 e0 08 ret
2002cb8: 91 e8 00 08 restore %g0, %o0, %o0
if ( !pathname )
rtems_set_errno_and_return_minus_one( EFAULT );
if ( !pathloc )
rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
2002cbc: 40 00 3b 50 call 20119fc <__errno> <== NOT EXECUTED
2002cc0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002cc4: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2002cc8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002ccc: 81 c7 e0 08 ret <== NOT EXECUTED
2002cd0: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Verify Input parameters.
*/
if ( !pathname )
rtems_set_errno_and_return_minus_one( EFAULT );
2002cd4: 40 00 3b 4a call 20119fc <__errno> <== NOT EXECUTED
2002cd8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002cdc: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
2002ce0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002ce4: 81 c7 e0 08 ret <== NOT EXECUTED
2002ce8: 81 e8 00 00 restore <== NOT EXECUTED
02002b6c <rtems_filesystem_evaluate_relative_path>:
size_t pathnamelen,
int flags,
rtems_filesystem_location_info_t *pathloc,
int follow_link
)
{
2002b6c: 9d e3 bf a0 save %sp, -96, %sp
/*
* Verify Input parameters.
*/
if ( !pathname )
2002b70: 80 a6 20 00 cmp %i0, 0
2002b74: 02 80 00 33 be 2002c40 <rtems_filesystem_evaluate_relative_path+0xd4><== NEVER TAKEN
2002b78: 80 a6 e0 00 cmp %i3, 0
rtems_set_errno_and_return_minus_one( EFAULT );
if ( !pathloc )
2002b7c: 02 80 00 37 be 2002c58 <rtems_filesystem_evaluate_relative_path+0xec><== NEVER TAKEN
2002b80: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
if ( !pathloc->ops->evalpath_h )
2002b84: c2 06 e0 0c ld [ %i3 + 0xc ], %g1
2002b88: c2 00 40 00 ld [ %g1 ], %g1
2002b8c: 80 a0 60 00 cmp %g1, 0
2002b90: 02 80 00 26 be 2002c28 <rtems_filesystem_evaluate_relative_path+0xbc><== NEVER TAKEN
2002b94: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
result = (*pathloc->ops->evalpath_h)( pathname, pathnamelen, flags, pathloc );
2002b98: 92 10 00 19 mov %i1, %o1
2002b9c: 94 10 00 1a mov %i2, %o2
2002ba0: 9f c0 40 00 call %g1
2002ba4: 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 ) {
2002ba8: b0 92 20 00 orcc %o0, 0, %i0
2002bac: 12 80 00 0f bne 2002be8 <rtems_filesystem_evaluate_relative_path+0x7c>
2002bb0: 80 a7 20 00 cmp %i4, 0
2002bb4: 02 80 00 2d be 2002c68 <rtems_filesystem_evaluate_relative_path+0xfc>
2002bb8: 01 00 00 00 nop
if ( !pathloc->ops->node_type_h ){
2002bbc: c4 06 e0 0c ld [ %i3 + 0xc ], %g2
2002bc0: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1
2002bc4: 80 a0 60 00 cmp %g1, 0
2002bc8: 22 80 00 13 be,a 2002c14 <rtems_filesystem_evaluate_relative_path+0xa8><== NEVER TAKEN
2002bcc: 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 );
2002bd0: 9f c0 40 00 call %g1
2002bd4: 90 10 00 1b mov %i3, %o0
if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) ||
2002bd8: 90 02 3f fd add %o0, -3, %o0
2002bdc: 80 a2 20 01 cmp %o0, 1
2002be0: 28 80 00 04 bleu,a 2002bf0 <rtems_filesystem_evaluate_relative_path+0x84>
2002be4: c4 06 e0 0c ld [ %i3 + 0xc ], %g2
result = (*pathloc->ops->eval_link_h)( pathloc, flags );
}
}
return result;
}
2002be8: 81 c7 e0 08 ret
2002bec: 81 e8 00 00 restore
type = (*pathloc->ops->node_type_h)( pathloc );
if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) ||
( type == RTEMS_FILESYSTEM_SYM_LINK ) ) {
if ( !pathloc->ops->eval_link_h ){
2002bf0: c2 00 a0 34 ld [ %g2 + 0x34 ], %g1
2002bf4: 80 a0 60 00 cmp %g1, 0
2002bf8: 02 80 00 06 be 2002c10 <rtems_filesystem_evaluate_relative_path+0xa4><== NEVER TAKEN
2002bfc: 90 10 00 1b mov %i3, %o0
* 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 );
2002c00: 9f c0 40 00 call %g1
2002c04: 92 10 00 1a mov %i2, %o1
}
}
return result;
}
2002c08: 81 c7 e0 08 ret
2002c0c: 91 e8 00 08 restore %g0, %o0, %o0
if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) ||
( type == RTEMS_FILESYSTEM_SYM_LINK ) ) {
if ( !pathloc->ops->eval_link_h ){
rtems_filesystem_freenode( pathloc );
2002c10: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
2002c14: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2002c18: 02 80 00 04 be 2002c28 <rtems_filesystem_evaluate_relative_path+0xbc><== NOT EXECUTED
2002c1c: 01 00 00 00 nop <== NOT EXECUTED
2002c20: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002c24: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2002c28: 40 00 3b 75 call 20119fc <__errno> <== NOT EXECUTED
2002c2c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002c30: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2002c34: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002c38: 81 c7 e0 08 ret <== NOT EXECUTED
2002c3c: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Verify Input parameters.
*/
if ( !pathname )
rtems_set_errno_and_return_minus_one( EFAULT );
2002c40: 40 00 3b 6f call 20119fc <__errno> <== NOT EXECUTED
2002c44: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002c48: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
2002c4c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002c50: 81 c7 e0 08 ret <== NOT EXECUTED
2002c54: 81 e8 00 00 restore <== NOT EXECUTED
if ( !pathloc )
rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
2002c58: 40 00 3b 69 call 20119fc <__errno> <== NOT EXECUTED
2002c5c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002c60: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2002c64: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002c68: 81 c7 e0 08 ret
2002c6c: 81 e8 00 00 restore
0200d010 <rtems_filesystem_get_mount_handler>:
rtems_filesystem_fsmount_me_t
rtems_filesystem_get_mount_handler(
const char *type
)
{
200d010: 9d e3 bf 98 save %sp, -104, %sp
find_arg fa = {
.type = type,
.mount_h = NULL
};
200d014: f0 27 bf f8 st %i0, [ %fp + -8 ]
200d018: c0 27 bf fc clr [ %fp + -4 ]
if ( type != NULL ) {
200d01c: 80 a6 20 00 cmp %i0, 0
200d020: 02 80 00 07 be 200d03c <rtems_filesystem_get_mount_handler+0x2c><== NEVER TAKEN
200d024: b0 10 20 00 clr %i0
rtems_filesystem_iterate( find_handler, &fa );
200d028: 11 00 80 33 sethi %hi(0x200cc00), %o0
200d02c: 92 07 bf f8 add %fp, -8, %o1
200d030: 7f ff ff c5 call 200cf44 <rtems_filesystem_iterate>
200d034: 90 12 22 4c or %o0, 0x24c, %o0
200d038: f0 07 bf fc ld [ %fp + -4 ], %i0
}
return fa.mount_h;
}
200d03c: 81 c7 e0 08 ret
200d040: 81 e8 00 00 restore
02002934 <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 )
{
2002934: 9d e3 bf 88 save %sp, -120, %sp
/*
* Set the default umask to "022".
*/
rtems_filesystem_umask = 022;
2002938: 21 00 80 7a sethi %hi(0x201e800), %l0
200293c: c2 04 21 80 ld [ %l0 + 0x180 ], %g1 ! 201e980 <rtems_current_user_env>
2002940: 84 10 20 12 mov 0x12, %g2
2002944: c4 20 60 2c st %g2, [ %g1 + 0x2c ]
/*
* mount the first filesystem.
*/
if ( rtems_filesystem_mount_table_size == 0 )
2002948: 03 00 80 74 sethi %hi(0x201d000), %g1
200294c: c2 00 60 68 ld [ %g1 + 0x68 ], %g1 ! 201d068 <rtems_filesystem_mount_table_size>
2002950: 80 a0 60 00 cmp %g1, 0
2002954: 02 80 00 3a be 2002a3c <rtems_filesystem_initialize+0x108><== NEVER TAKEN
2002958: 03 00 80 79 sethi %hi(0x201e400), %g1
rtems_fatal_error_occurred( 0xABCD0001 );
mt = &rtems_filesystem_mount_table[0];
200295c: c2 00 63 bc ld [ %g1 + 0x3bc ], %g1 ! 201e7bc <rtems_filesystem_mount_table>
status = mount( mt->device, mt->mount_point, mt->type, mt->fsoptions, NULL );
2002960: 98 10 20 00 clr %o4
2002964: d6 00 60 04 ld [ %g1 + 4 ], %o3
2002968: d0 00 60 08 ld [ %g1 + 8 ], %o0
200296c: d2 00 60 0c ld [ %g1 + 0xc ], %o1
2002970: 40 00 02 80 call 2003370 <mount>
2002974: d4 00 40 00 ld [ %g1 ], %o2
if ( status == -1 )
2002978: 80 a2 3f ff cmp %o0, -1
200297c: 02 80 00 35 be 2002a50 <rtems_filesystem_initialize+0x11c><== NEVER TAKEN
2002980: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
* gonna hit performance.
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
2002984: a4 07 bf ec add %fp, -20, %l2
status = mount( mt->device, mt->mount_point, mt->type, mt->fsoptions, NULL );
if ( status == -1 )
rtems_fatal_error_occurred( 0xABCD0002 );
rtems_filesystem_link_counts = 0;
2002988: c0 30 60 30 clrh [ %g1 + 0x30 ]
* gonna hit performance.
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
200298c: 23 00 80 75 sethi %hi(0x201d400), %l1
2002990: 92 10 20 01 mov 1, %o1
2002994: 94 10 20 00 clr %o2
2002998: 96 10 00 12 mov %l2, %o3
200299c: 98 10 20 00 clr %o4
20029a0: 40 00 00 b4 call 2002c70 <rtems_filesystem_evaluate_path>
20029a4: 90 14 61 18 or %l1, 0x118, %o0
rtems_filesystem_root = loc;
20029a8: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
20029ac: c4 07 bf ec ld [ %fp + -20 ], %g2
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20029b0: 96 10 00 12 mov %l2, %o3
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
20029b4: c4 20 60 18 st %g2, [ %g1 + 0x18 ]
20029b8: c4 07 bf f0 ld [ %fp + -16 ], %g2
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20029bc: 92 10 20 01 mov 1, %o1
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
20029c0: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
20029c4: c4 07 bf f4 ld [ %fp + -12 ], %g2
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20029c8: 94 10 20 00 clr %o2
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
20029cc: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
20029d0: c4 07 bf f8 ld [ %fp + -8 ], %g2
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20029d4: 98 10 20 00 clr %o4
*
* Till Straumann, 10/25/2002
*/
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
20029d8: c4 20 60 24 st %g2, [ %g1 + 0x24 ]
20029dc: c4 07 bf fc ld [ %fp + -4 ], %g2
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20029e0: 90 14 61 18 or %l1, 0x118, %o0
20029e4: 40 00 00 a3 call 2002c70 <rtems_filesystem_evaluate_path>
20029e8: c4 20 60 28 st %g2, [ %g1 + 0x28 ]
rtems_filesystem_current = loc;
20029ec: c4 07 bf ec ld [ %fp + -20 ], %g2
20029f0: c2 04 21 80 ld [ %l0 + 0x180 ], %g1
*
* 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);
20029f4: 11 00 80 75 sethi %hi(0x201d400), %o0
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_current = loc;
20029f8: c4 20 60 04 st %g2, [ %g1 + 4 ]
20029fc: c4 07 bf f0 ld [ %fp + -16 ], %g2
*
* 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);
2002a00: 90 12 21 20 or %o0, 0x120, %o0
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_current = loc;
2002a04: c4 20 60 08 st %g2, [ %g1 + 8 ]
2002a08: c4 07 bf f4 ld [ %fp + -12 ], %g2
*
* 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);
2002a0c: 92 10 21 ff mov 0x1ff, %o1
/* Clone the root pathloc */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
/* One more clone for the current node */
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_current = loc;
2002a10: c4 20 60 0c st %g2, [ %g1 + 0xc ]
2002a14: c4 07 bf f8 ld [ %fp + -8 ], %g2
2002a18: c4 20 60 10 st %g2, [ %g1 + 0x10 ]
2002a1c: c4 07 bf fc ld [ %fp + -4 ], %g2
*
* 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);
2002a20: 40 00 01 db call 200318c <mkdir>
2002a24: c4 20 60 14 st %g2, [ %g1 + 0x14 ]
if ( status != 0 )
2002a28: 80 a2 20 00 cmp %o0, 0
2002a2c: 12 80 00 07 bne 2002a48 <rtems_filesystem_initialize+0x114><== NEVER TAKEN
2002a30: 11 2a f3 40 sethi %hi(0xabcd0000), %o0
2002a34: 81 c7 e0 08 ret
2002a38: 81 e8 00 00 restore
/*
* mount the first filesystem.
*/
if ( rtems_filesystem_mount_table_size == 0 )
rtems_fatal_error_occurred( 0xABCD0001 );
2002a3c: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED
2002a40: 40 00 11 46 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2002a44: 90 12 20 01 or %o0, 1, %o0 ! abcd0001 <RAM_END+0xa98d0001><== NOT EXECUTED
* created that way by the IMFS.
*/
status = mkdir( "/dev", 0777);
if ( status != 0 )
rtems_fatal_error_occurred( 0xABCD0003 );
2002a48: 40 00 11 44 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2002a4c: 90 12 20 03 or %o0, 3, %o0 <== NOT EXECUTED
mt = &rtems_filesystem_mount_table[0];
status = mount( mt->device, mt->mount_point, mt->type, mt->fsoptions, NULL );
if ( status == -1 )
rtems_fatal_error_occurred( 0xABCD0002 );
2002a50: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED
2002a54: 40 00 11 41 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2002a58: 90 12 20 02 or %o0, 2, %o0 ! abcd0002 <RAM_END+0xa98d0002><== NOT EXECUTED
0200cf44 <rtems_filesystem_iterate>:
bool rtems_filesystem_iterate(
rtems_per_filesystem_routine routine,
void *routine_arg
)
{
200cf44: 9d e3 bf a0 save %sp, -96, %sp
const rtems_filesystem_table_t *table_entry = &rtems_filesystem_table [0];
rtems_chain_node *node = NULL;
bool stop = false;
while ( table_entry->type && !stop ) {
200cf48: 23 00 80 74 sethi %hi(0x201d000), %l1
200cf4c: c2 04 60 48 ld [ %l1 + 0x48 ], %g1 ! 201d048 <rtems_filesystem_table>
bool rtems_filesystem_iterate(
rtems_per_filesystem_routine routine,
void *routine_arg
)
{
200cf50: a0 10 00 18 mov %i0, %l0
const rtems_filesystem_table_t *table_entry = &rtems_filesystem_table [0];
rtems_chain_node *node = NULL;
bool stop = false;
while ( table_entry->type && !stop ) {
200cf54: 80 a0 60 00 cmp %g1, 0
200cf58: 12 80 00 07 bne 200cf74 <rtems_filesystem_iterate+0x30> <== ALWAYS TAKEN
200cf5c: a2 14 60 48 or %l1, 0x48, %l1
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 );
200cf60: 10 80 00 10 b 200cfa0 <rtems_filesystem_iterate+0x5c> <== NOT EXECUTED
200cf64: 23 00 80 7c sethi %hi(0x201f000), %l1 <== NOT EXECUTED
200cf68: 80 8a 20 ff btst 0xff, %o0
200cf6c: 12 80 00 27 bne 200d008 <rtems_filesystem_iterate+0xc4> <== ALWAYS TAKEN
200cf70: 01 00 00 00 nop
stop = (*routine)( table_entry, routine_arg );
200cf74: 90 10 00 11 mov %l1, %o0
200cf78: 9f c4 00 00 call %l0
200cf7c: 92 10 00 19 mov %i1, %o1
++table_entry;
200cf80: a2 04 60 08 add %l1, 8, %l1
{
const rtems_filesystem_table_t *table_entry = &rtems_filesystem_table [0];
rtems_chain_node *node = NULL;
bool stop = false;
while ( table_entry->type && !stop ) {
200cf84: c2 04 40 00 ld [ %l1 ], %g1
200cf88: 80 a0 60 00 cmp %g1, 0
200cf8c: 12 bf ff f7 bne 200cf68 <rtems_filesystem_iterate+0x24>
200cf90: b0 10 00 08 mov %o0, %i0
stop = (*routine)( table_entry, routine_arg );
++table_entry;
}
if ( !stop ) {
200cf94: 80 8a 20 ff btst 0xff, %o0
200cf98: 12 80 00 1a bne 200d000 <rtems_filesystem_iterate+0xbc>
200cf9c: 23 00 80 7c sethi %hi(0x201f000), %l1
200cfa0: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
200cfa4: 27 00 80 7a sethi %hi(0x201e800), %l3
200cfa8: 92 10 20 00 clr %o1
200cfac: 7f ff e6 4a call 20068d4 <rtems_semaphore_obtain>
200cfb0: 94 10 20 00 clr %o2
200cfb4: e4 04 e1 88 ld [ %l3 + 0x188 ], %l2
200cfb8: a6 14 e1 88 or %l3, 0x188, %l3
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200cfbc: a6 04 e0 04 add %l3, 4, %l3
rtems_libio_lock();
for (
200cfc0: 80 a4 80 13 cmp %l2, %l3
200cfc4: 12 80 00 06 bne 200cfdc <rtems_filesystem_iterate+0x98>
200cfc8: b0 10 20 00 clr %i0
200cfcc: 30 80 00 0b b,a 200cff8 <rtems_filesystem_iterate+0xb4>
200cfd0: 80 8a 20 ff btst 0xff, %o0
200cfd4: 12 80 00 09 bne 200cff8 <rtems_filesystem_iterate+0xb4>
200cfd8: 01 00 00 00 nop
!rtems_chain_is_tail( &filesystem_chain, node ) && !stop;
node = rtems_chain_next( node )
) {
const filesystem_node *fsn = (filesystem_node *) node;
stop = (*routine)( &fsn->entry, routine_arg );
200cfdc: 90 04 a0 08 add %l2, 8, %o0
200cfe0: 9f c4 00 00 call %l0
200cfe4: 92 10 00 19 mov %i1, %o1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
200cfe8: e4 04 80 00 ld [ %l2 ], %l2
++table_entry;
}
if ( !stop ) {
rtems_libio_lock();
for (
200cfec: 80 a4 80 13 cmp %l2, %l3
200cff0: 12 bf ff f8 bne 200cfd0 <rtems_filesystem_iterate+0x8c>
200cff4: b0 10 00 08 mov %o0, %i0
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200cff8: 7f ff e6 7e call 20069f0 <rtems_semaphore_release>
200cffc: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0
}
rtems_libio_unlock();
}
return stop;
}
200d000: 81 c7 e0 08 ret
200d004: 81 e8 00 00 restore
200d008: 81 c7 e0 08 ret
200d00c: 81 e8 00 00 restore
020032fc <rtems_filesystem_mount_iterate>:
bool rtems_filesystem_mount_iterate(
rtems_per_filesystem_mount_routine routine,
void *routine_arg
)
{
20032fc: 9d e3 bf a0 save %sp, -96, %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 );
2003300: 21 00 80 7c sethi %hi(0x201f000), %l0
2003304: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
2003308: 27 00 80 7a sethi %hi(0x201e800), %l3
200330c: 92 10 20 00 clr %o1
2003310: 40 00 0d 71 call 20068d4 <rtems_semaphore_obtain>
2003314: 94 10 20 00 clr %o2
2003318: e2 04 e1 60 ld [ %l3 + 0x160 ], %l1
200331c: a4 10 00 18 mov %i0, %l2
2003320: a6 14 e1 60 or %l3, 0x160, %l3
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2003324: a6 04 e0 04 add %l3, 4, %l3
rtems_chain_node *node = NULL;
bool stop = false;
rtems_libio_lock();
for (
2003328: 80 a4 40 13 cmp %l1, %l3
200332c: 12 80 00 06 bne 2003344 <rtems_filesystem_mount_iterate+0x48><== ALWAYS TAKEN
2003330: b0 10 20 00 clr %i0
2003334: 30 80 00 0b b,a 2003360 <rtems_filesystem_mount_iterate+0x64><== NOT EXECUTED
2003338: 80 8a 20 ff btst 0xff, %o0
200333c: 12 80 00 09 bne 2003360 <rtems_filesystem_mount_iterate+0x64><== NEVER TAKEN
2003340: 01 00 00 00 nop
node = rtems_chain_next( node )
) {
const rtems_filesystem_mount_table_entry_t *mt_entry =
(rtems_filesystem_mount_table_entry_t *) node;
stop = (*routine)( mt_entry, routine_arg );
2003344: 90 10 00 11 mov %l1, %o0
2003348: 9f c4 80 00 call %l2
200334c: 92 10 00 19 mov %i1, %o1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
2003350: e2 04 40 00 ld [ %l1 ], %l1
{
rtems_chain_node *node = NULL;
bool stop = false;
rtems_libio_lock();
for (
2003354: 80 a4 40 13 cmp %l1, %l3
2003358: 12 bf ff f8 bne 2003338 <rtems_filesystem_mount_iterate+0x3c>
200335c: b0 10 00 08 mov %o0, %i0
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
2003360: 40 00 0d a4 call 20069f0 <rtems_semaphore_release>
2003364: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
stop = (*routine)( mt_entry, routine_arg );
}
rtems_libio_unlock();
return stop;
}
2003368: 81 c7 e0 08 ret
200336c: 81 e8 00 00 restore
02002ab4 <rtems_filesystem_prefix_separators>:
int rtems_filesystem_prefix_separators(
const char *pathname,
int pathnamelen
)
{
2002ab4: 9d e3 bf a0 save %sp, -96, %sp
2002ab8: a0 10 00 18 mov %i0, %l0
/*
* Eat any separators at start of the path.
*/
int stripped = 0;
while ( *pathname && pathnamelen && rtems_filesystem_is_separator( *pathname ) )
2002abc: 80 a6 60 00 cmp %i1, 0
2002ac0: 02 80 00 15 be 2002b14 <rtems_filesystem_prefix_separators+0x60><== NEVER TAKEN
2002ac4: d0 0e 00 00 ldub [ %i0 ], %o0
2002ac8: 91 2a 20 18 sll %o0, 0x18, %o0
2002acc: 80 a2 20 00 cmp %o0, 0
2002ad0: 12 80 00 0a bne 2002af8 <rtems_filesystem_prefix_separators+0x44><== ALWAYS TAKEN
2002ad4: b0 10 20 00 clr %i0
2002ad8: 30 80 00 10 b,a 2002b18 <rtems_filesystem_prefix_separators+0x64><== NOT EXECUTED
2002adc: 80 a6 40 18 cmp %i1, %i0
2002ae0: 02 80 00 0b be 2002b0c <rtems_filesystem_prefix_separators+0x58><== NEVER TAKEN
2002ae4: d0 0c 00 18 ldub [ %l0 + %i0 ], %o0
2002ae8: 91 2a 20 18 sll %o0, 0x18, %o0
2002aec: 80 a2 20 00 cmp %o0, 0
2002af0: 02 80 00 0a be 2002b18 <rtems_filesystem_prefix_separators+0x64><== NEVER TAKEN
2002af4: 01 00 00 00 nop
2002af8: 40 00 04 bf call 2003df4 <rtems_filesystem_is_separator>
2002afc: 91 3a 20 18 sra %o0, 0x18, %o0
2002b00: 80 a2 20 00 cmp %o0, 0
2002b04: 32 bf ff f6 bne,a 2002adc <rtems_filesystem_prefix_separators+0x28>
2002b08: b0 06 20 01 inc %i0
pathname++;
pathnamelen--;
stripped++;
}
return stripped;
}
2002b0c: 81 c7 e0 08 ret
2002b10: 81 e8 00 00 restore
{
/*
* Eat any separators at start of the path.
*/
int stripped = 0;
while ( *pathname && pathnamelen && rtems_filesystem_is_separator( *pathname ) )
2002b14: b0 10 20 00 clr %i0 <== NOT EXECUTED
2002b18: 81 c7 e0 08 ret <== NOT EXECUTED
2002b1c: 81 e8 00 00 restore <== NOT EXECUTED
0200d044 <rtems_filesystem_register>:
int
rtems_filesystem_register(
const char *type,
rtems_filesystem_fsmount_me_t mount_h
)
{
200d044: 9d e3 bf a0 save %sp, -96, %sp
size_t fsn_size = sizeof( filesystem_node ) + strlen(type) + 1;
200d048: 40 00 16 3a call 2012930 <strlen>
200d04c: 90 10 00 18 mov %i0, %o0
filesystem_node *fsn = malloc( fsn_size );
200d050: 7f ff d8 0f call 200308c <malloc>
200d054: 90 02 20 11 add %o0, 0x11, %o0
char *type_storage = (char *) fsn + sizeof( filesystem_node );
if ( fsn == NULL )
200d058: a0 92 20 00 orcc %o0, 0, %l0
200d05c: 02 80 00 24 be 200d0ec <rtems_filesystem_register+0xa8> <== NEVER TAKEN
200d060: a4 04 20 10 add %l0, 0x10, %l2
rtems_set_errno_and_return_minus_one( ENOMEM );
strcpy(type_storage, type);
200d064: 92 10 00 18 mov %i0, %o1
200d068: 40 00 15 fa call 2012850 <strcpy>
200d06c: 90 10 00 12 mov %l2, %o0
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 );
200d070: 23 00 80 7c sethi %hi(0x201f000), %l1
200d074: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
200d078: 92 10 20 00 clr %o1
200d07c: 94 10 20 00 clr %o2
fsn->entry.type = type_storage;
200d080: e4 24 20 08 st %l2, [ %l0 + 8 ]
200d084: 7f ff e6 14 call 20068d4 <rtems_semaphore_obtain>
200d088: f2 24 20 0c st %i1, [ %l0 + 0xc ]
fsn->entry.mount_h = mount_h;
rtems_libio_lock();
if ( rtems_filesystem_get_mount_handler( type ) == NULL ) {
200d08c: 7f ff ff e1 call 200d010 <rtems_filesystem_get_mount_handler>
200d090: 90 10 00 18 mov %i0, %o0
200d094: 80 a2 20 00 cmp %o0, 0
200d098: 12 80 00 0a bne 200d0c0 <rtems_filesystem_register+0x7c> <== NEVER TAKEN
200d09c: 92 10 00 10 mov %l0, %o1
RTEMS_INLINE_ROUTINE void rtems_chain_append(
rtems_chain_control *the_chain,
rtems_chain_node *the_node
)
{
_Chain_Append( the_chain, the_node );
200d0a0: 11 00 80 7a sethi %hi(0x201e800), %o0
200d0a4: 7f ff e8 9c call 2007314 <_Chain_Append>
200d0a8: 90 12 21 88 or %o0, 0x188, %o0 ! 201e988 <filesystem_chain>
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200d0ac: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0
200d0b0: 7f ff e6 50 call 20069f0 <rtems_semaphore_release>
200d0b4: b0 10 20 00 clr %i0
rtems_set_errno_and_return_minus_one( EINVAL );
}
rtems_libio_unlock();
return 0;
200d0b8: 81 c7 e0 08 ret
200d0bc: 81 e8 00 00 restore
200d0c0: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0 <== NOT EXECUTED
200d0c4: 7f ff e6 4b call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200d0c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_libio_lock();
if ( rtems_filesystem_get_mount_handler( type ) == NULL ) {
rtems_chain_append( &filesystem_chain, &fsn->node );
} else {
rtems_libio_unlock();
free( fsn );
200d0cc: 7f ff d7 08 call 2002cec <free> <== NOT EXECUTED
200d0d0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
200d0d4: 40 00 12 4a call 20119fc <__errno> <== NOT EXECUTED
200d0d8: 01 00 00 00 nop <== NOT EXECUTED
200d0dc: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
200d0e0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
rtems_libio_unlock();
return 0;
}
200d0e4: 81 c7 e0 08 ret <== NOT EXECUTED
200d0e8: 81 e8 00 00 restore <== NOT EXECUTED
size_t fsn_size = sizeof( filesystem_node ) + strlen(type) + 1;
filesystem_node *fsn = malloc( fsn_size );
char *type_storage = (char *) fsn + sizeof( filesystem_node );
if ( fsn == NULL )
rtems_set_errno_and_return_minus_one( ENOMEM );
200d0ec: 40 00 12 44 call 20119fc <__errno> <== NOT EXECUTED
200d0f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200d0f4: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
200d0f8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200d0fc: 81 c7 e0 08 ret <== NOT EXECUTED
200d100: 81 e8 00 00 restore <== NOT EXECUTED
0200ce80 <rtems_filesystem_unregister>:
int
rtems_filesystem_unregister(
const char *type
)
{
200ce80: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_chain_node *node = NULL;
if ( type == NULL ) {
200ce84: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
200ce88: 02 80 00 29 be 200cf2c <rtems_filesystem_unregister+0xac> <== NOT EXECUTED
200ce8c: 21 00 80 7c sethi %hi(0x201f000), %l0 <== NOT EXECUTED
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 );
200ce90: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore><== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
200ce94: 25 00 80 7a sethi %hi(0x201e800), %l2 <== NOT EXECUTED
200ce98: 92 10 20 00 clr %o1 <== NOT EXECUTED
200ce9c: 7f ff e6 8e call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
200cea0: 94 10 20 00 clr %o2 <== NOT EXECUTED
200cea4: e2 04 a1 88 ld [ %l2 + 0x188 ], %l1 <== NOT EXECUTED
200cea8: a4 14 a1 88 or %l2, 0x188, %l2 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200ceac: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
}
rtems_libio_lock();
for (
200ceb0: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
200ceb4: 32 80 00 08 bne,a 200ced4 <rtems_filesystem_unregister+0x54><== NOT EXECUTED
200ceb8: d0 04 60 08 ld [ %l1 + 8 ], %o0 <== NOT EXECUTED
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200cebc: 10 80 00 14 b 200cf0c <rtems_filesystem_unregister+0x8c> <== NOT EXECUTED
200cec0: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 <== NOT EXECUTED
200cec4: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED
200cec8: 02 80 00 11 be 200cf0c <rtems_filesystem_unregister+0x8c> <== NOT EXECUTED
200cecc: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 <== NOT EXECUTED
!rtems_chain_is_tail( &filesystem_chain, node );
node = rtems_chain_next( node )
) {
filesystem_node *fsn = (filesystem_node *) node;
if ( strcmp( fsn->entry.type, type ) == 0 ) {
200ced0: d0 04 60 08 ld [ %l1 + 8 ], %o0 <== NOT EXECUTED
200ced4: 40 00 16 31 call 2012798 <strcmp> <== NOT EXECUTED
200ced8: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
200cedc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200cee0: 32 bf ff f9 bne,a 200cec4 <rtems_filesystem_unregister+0x44><== NOT EXECUTED
200cee4: e2 04 40 00 ld [ %l1 ], %l1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
200cee8: 7f ff e9 17 call 2007344 <_Chain_Extract> <== NOT EXECUTED
200ceec: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_chain_extract( node );
free( fsn );
200cef0: 7f ff d7 7f call 2002cec <free> <== NOT EXECUTED
200cef4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
200cef8: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 <== NOT EXECUTED
200cefc: 7f ff e6 bd call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200cf00: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_libio_unlock();
return 0;
200cf04: 81 c7 e0 08 ret <== NOT EXECUTED
200cf08: 81 e8 00 00 restore <== NOT EXECUTED
200cf0c: 7f ff e6 b9 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
200cf10: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
}
rtems_libio_unlock();
rtems_set_errno_and_return_minus_one( ENOENT );
200cf14: 40 00 12 ba call 20119fc <__errno> <== NOT EXECUTED
200cf18: 01 00 00 00 nop <== NOT EXECUTED
200cf1c: 82 10 20 02 mov 2, %g1 ! 2 <PROM_START+0x2> <== NOT EXECUTED
200cf20: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
200cf24: 81 c7 e0 08 ret <== NOT EXECUTED
200cf28: 81 e8 00 00 restore <== NOT EXECUTED
)
{
rtems_chain_node *node = NULL;
if ( type == NULL ) {
rtems_set_errno_and_return_minus_one( EINVAL );
200cf2c: 40 00 12 b4 call 20119fc <__errno> <== NOT EXECUTED
200cf30: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200cf34: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
200cf38: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200cf3c: 81 c7 e0 08 ret <== NOT EXECUTED
200cf40: 81 e8 00 00 restore <== NOT EXECUTED
0200786c <rtems_fsmount>:
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
200786c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
bool terminate = false;
/*
* scan through all fstab entries;
*/
while (!terminate &&
2007870: a2 10 20 00 clr %l1 <== NOT EXECUTED
)
/*-------------------------------------------------------------------------*\
| Return Value: |
| 0, if success, -1 and errno if failed |
\*=========================================================================*/
{
2007874: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
bool terminate = false;
/*
* scan through all fstab entries;
*/
while (!terminate &&
2007878: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
200787c: 02 80 00 18 be 20078dc <rtems_fsmount+0x70> <== NOT EXECUTED
2007880: b0 10 20 00 clr %i0 <== NOT EXECUTED
*/
if (tmp_rc == 0) {
tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);
if (tmp_rc != 0) {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNTPNT_CRTERR)) {
fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",
2007884: 25 00 81 c5 sethi %hi(0x2071400), %l2 <== NOT EXECUTED
2007888: 27 00 81 97 sethi %hi(0x2065c00), %l3 <== NOT EXECUTED
rc = tmp_rc;
}
}
else {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_OK)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
200788c: 2b 00 81 97 sethi %hi(0x2065c00), %l5 <== NOT EXECUTED
fstab_ptr->type,
fstab_ptr->options,
NULL);
if (tmp_rc != 0) {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_FAILED)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
2007890: 29 00 81 97 sethi %hi(0x2065c00), %l4 <== NOT EXECUTED
*/
if (tmp_rc == 0) {
tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);
if (tmp_rc != 0) {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNTPNT_CRTERR)) {
fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",
2007894: a4 14 a2 08 or %l2, 0x208, %l2 <== NOT EXECUTED
2007898: a6 14 e0 90 or %l3, 0x90, %l3 <== NOT EXECUTED
rc = tmp_rc;
}
}
else {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_OK)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
200789c: aa 15 60 f8 or %l5, 0xf8, %l5 <== NOT EXECUTED
fstab_ptr->type,
fstab_ptr->options,
NULL);
if (tmp_rc != 0) {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_FAILED)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
20078a0: a8 15 20 c8 or %l4, 0xc8, %l4 <== NOT EXECUTED
tmp_rc = 0;
/*
* create mount point
*/
if (tmp_rc == 0) {
tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);
20078a4: d0 04 20 04 ld [ %l0 + 4 ], %o0 <== NOT EXECUTED
20078a8: 40 00 0a 3e call 200a1a0 <rtems_mkdir> <== NOT EXECUTED
20078ac: 92 10 21 ff mov 0x1ff, %o1 <== NOT EXECUTED
if (tmp_rc != 0) {
20078b0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20078b4: 22 80 00 0f be,a 20078f0 <rtems_fsmount+0x84> <== NOT EXECUTED
20078b8: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNTPNT_CRTERR)) {
20078bc: c2 14 20 10 lduh [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
20078c0: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
20078c4: 32 80 00 20 bne,a 2007944 <rtems_fsmount+0xd8> <== NOT EXECUTED
20078c8: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",
fstab_ptr->target,
strerror(errno));
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNTPNT_CRTERR)) {
20078cc: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
20078d0: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
20078d4: 22 80 00 17 be,a 2007930 <rtems_fsmount+0xc4> <== NOT EXECUTED
20078d8: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (!terminate) {
fstab_ptr++;
fstab_idx++;
}
}
if (fail_idx != NULL) {
20078dc: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
20078e0: 32 80 00 02 bne,a 20078e8 <rtems_fsmount+0x7c> <== NOT EXECUTED
20078e4: e2 26 80 00 st %l1, [ %i2 ] <== NOT EXECUTED
*fail_idx = fstab_idx;
}
return rc;
}
20078e8: 81 c7 e0 08 ret <== NOT EXECUTED
20078ec: 81 e8 00 00 restore <== NOT EXECUTED
}
/*
* mount device to given mount point
*/
if (tmp_rc == 0) {
tmp_rc = mount(fstab_ptr->source,
20078f0: d2 04 20 04 ld [ %l0 + 4 ], %o1 <== NOT EXECUTED
20078f4: d4 04 20 08 ld [ %l0 + 8 ], %o2 <== NOT EXECUTED
20078f8: d6 04 20 0c ld [ %l0 + 0xc ], %o3 <== NOT EXECUTED
20078fc: 40 00 06 ca call 2009424 <mount> <== NOT EXECUTED
2007900: 98 10 20 00 clr %o4 <== NOT EXECUTED
fstab_ptr->target,
fstab_ptr->type,
fstab_ptr->options,
NULL);
if (tmp_rc != 0) {
2007904: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2007908: 02 80 00 1b be 2007974 <rtems_fsmount+0x108> <== NOT EXECUTED
200790c: c2 14 20 10 lduh [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_FAILED)) {
2007910: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
2007914: 32 80 00 21 bne,a 2007998 <rtems_fsmount+0x12c> <== NOT EXECUTED
2007918: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
" \"%s\" failed: %s\n",
fstab_ptr->source,
fstab_ptr->target,
strerror(errno));
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_FAILED)) {
200791c: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
2007920: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
2007924: 12 bf ff ef bne 20078e0 <rtems_fsmount+0x74> <== NOT EXECUTED
2007928: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
/*
* proceed to next entry
*/
if (!terminate) {
fstab_ptr++;
fstab_idx++;
200792c: a2 04 60 01 inc %l1 <== NOT EXECUTED
bool terminate = false;
/*
* scan through all fstab entries;
*/
while (!terminate &&
2007930: 80 a6 40 11 cmp %i1, %l1 <== NOT EXECUTED
2007934: 08 bf ff ea bleu 20078dc <rtems_fsmount+0x70> <== NOT EXECUTED
2007938: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
/*
* proceed to next entry
*/
if (!terminate) {
fstab_ptr++;
200793c: 10 bf ff da b 20078a4 <rtems_fsmount+0x38> <== NOT EXECUTED
2007940: a0 04 20 14 add %l0, 0x14, %l0 <== NOT EXECUTED
*/
if (tmp_rc == 0) {
tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);
if (tmp_rc != 0) {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNTPNT_CRTERR)) {
fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",
2007944: ec 04 20 04 ld [ %l0 + 4 ], %l6 <== NOT EXECUTED
2007948: 40 01 0a ce call 204a480 <__errno> <== NOT EXECUTED
200794c: ee 00 60 08 ld [ %g1 + 8 ], %l7 <== NOT EXECUTED
2007950: 40 01 25 7c call 2050f40 <strerror> <== NOT EXECUTED
2007954: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
2007958: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
200795c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2007960: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
2007964: 40 01 0d 77 call 204af40 <fprintf> <== NOT EXECUTED
2007968: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
fstab_ptr->target,
strerror(errno));
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNTPNT_CRTERR)) {
200796c: 10 bf ff d9 b 20078d0 <rtems_fsmount+0x64> <== NOT EXECUTED
2007970: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
terminate = true;
rc = tmp_rc;
}
}
else {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_OK)) {
2007974: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2007978: 32 80 00 16 bne,a 20079d0 <rtems_fsmount+0x164> <== NOT EXECUTED
200797c: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
fprintf(stdout,"fsmount: mounting of \"%s\" to"
" \"%s\" succeeded\n",
fstab_ptr->source,
fstab_ptr->target);
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_OK)) {
2007980: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
2007984: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2007988: 22 bf ff ea be,a 2007930 <rtems_fsmount+0xc4> <== NOT EXECUTED
200798c: a2 04 60 01 inc %l1 <== NOT EXECUTED
tmp_rc = mount(fstab_ptr->source,
fstab_ptr->target,
fstab_ptr->type,
fstab_ptr->options,
NULL);
if (tmp_rc != 0) {
2007990: 10 bf ff d3 b 20078dc <rtems_fsmount+0x70> <== NOT EXECUTED
2007994: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_FAILED)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
2007998: ee 04 00 00 ld [ %l0 ], %l7 <== NOT EXECUTED
200799c: fa 00 60 08 ld [ %g1 + 8 ], %i5 <== NOT EXECUTED
20079a0: 40 01 0a b8 call 204a480 <__errno> <== NOT EXECUTED
20079a4: ec 04 20 04 ld [ %l0 + 4 ], %l6 <== NOT EXECUTED
20079a8: 40 01 25 66 call 2050f40 <strerror> <== NOT EXECUTED
20079ac: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
20079b0: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20079b4: 98 10 00 08 mov %o0, %o4 <== NOT EXECUTED
20079b8: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
20079bc: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
20079c0: 40 01 0d 60 call 204af40 <fprintf> <== NOT EXECUTED
20079c4: 96 10 00 16 mov %l6, %o3 <== NOT EXECUTED
" \"%s\" failed: %s\n",
fstab_ptr->source,
fstab_ptr->target,
strerror(errno));
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_FAILED)) {
20079c8: 10 bf ff d6 b 2007920 <rtems_fsmount+0xb4> <== NOT EXECUTED
20079cc: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
rc = tmp_rc;
}
}
else {
if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_OK)) {
fprintf(stdout,"fsmount: mounting of \"%s\" to"
20079d0: d4 04 00 00 ld [ %l0 ], %o2 <== NOT EXECUTED
20079d4: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
20079d8: d6 04 20 04 ld [ %l0 + 4 ], %o3 <== NOT EXECUTED
20079dc: 40 01 0d 59 call 204af40 <fprintf> <== NOT EXECUTED
20079e0: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
" \"%s\" succeeded\n",
fstab_ptr->source,
fstab_ptr->target);
}
if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_OK)) {
20079e4: 10 bf ff e8 b 2007984 <rtems_fsmount+0x118> <== NOT EXECUTED
20079e8: c2 14 20 12 lduh [ %l0 + 0x12 ], %g1 <== NOT EXECUTED
020027ec <rtems_io_lookup_name>:
rtems_status_code rtems_io_lookup_name(
const char *name,
rtems_driver_name_t *device_info
)
{
20027ec: 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 );
20027f0: 40 00 40 50 call 2012930 <strlen> <== NOT EXECUTED
20027f4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20027f8: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED
20027fc: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2002800: 94 10 20 00 clr %o2 <== NOT EXECUTED
2002804: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2002808: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
200280c: 40 00 01 19 call 2002c70 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
2002810: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
the_jnode = loc.node_access;
if ( !loc.ops->node_type_h ) {
2002814: 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 );
2002818: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
the_jnode = loc.node_access;
if ( !loc.ops->node_type_h ) {
200281c: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 <== NOT EXECUTED
2002820: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2002824: 02 80 00 13 be 2002870 <rtems_io_lookup_name+0x84> <== NOT EXECUTED
2002828: e4 07 bf ec ld [ %fp + -20 ], %l2 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
node_type = (*loc.ops->node_type_h)( &loc );
200282c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002830: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) {
2002834: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
2002838: 02 80 00 1a be 20028a0 <rtems_io_lookup_name+0xb4> <== NOT EXECUTED
200283c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
2002840: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2002844: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2002848: 02 80 00 2b be 20028f4 <rtems_io_lookup_name+0x108> <== NOT EXECUTED
200284c: 01 00 00 00 nop <== NOT EXECUTED
2002850: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2002854: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2002858: 02 80 00 27 be 20028f4 <rtems_io_lookup_name+0x108> <== NOT EXECUTED
200285c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2002860: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002864: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED
2002868: 81 c7 e0 08 ret <== NOT EXECUTED
200286c: 81 e8 00 00 restore <== NOT EXECUTED
result = rtems_filesystem_evaluate_path( name, strlen( name ), 0x00, &loc, true );
the_jnode = loc.node_access;
if ( !loc.ops->node_type_h ) {
rtems_filesystem_freenode( &loc );
2002870: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
2002874: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2002878: 02 80 00 04 be 2002888 <rtems_io_lookup_name+0x9c> <== NOT EXECUTED
200287c: 01 00 00 00 nop <== NOT EXECUTED
2002880: 9f c0 40 00 call %g1 <== NOT EXECUTED
2002884: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2002888: 40 00 3c 5d call 20119fc <__errno> <== NOT EXECUTED
200288c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2002890: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2002894: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002898: 81 c7 e0 08 ret <== NOT EXECUTED
200289c: 81 e8 00 00 restore <== NOT EXECUTED
}
node_type = (*loc.ops->node_type_h)( &loc );
if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) {
20028a0: 12 bf ff e9 bne 2002844 <rtems_io_lookup_name+0x58> <== NOT EXECUTED
20028a4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
return RTEMS_UNSATISFIED;
}
device_info->device_name = (char *) name;
20028a8: f0 26 40 00 st %i0, [ %i1 ] <== NOT EXECUTED
device_info->device_name_length = strlen( name );
20028ac: 40 00 40 21 call 2012930 <strlen> <== NOT EXECUTED
20028b0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20028b4: d0 26 60 04 st %o0, [ %i1 + 4 ] <== NOT EXECUTED
device_info->major = the_jnode->info.device.major;
20028b8: c4 04 a0 50 ld [ %l2 + 0x50 ], %g2 <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor;
rtems_filesystem_freenode( &loc );
20028bc: 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;
20028c0: c4 26 60 08 st %g2, [ %i1 + 8 ] <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor;
20028c4: c4 04 a0 54 ld [ %l2 + 0x54 ], %g2 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
20028c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20028cc: 02 80 00 0c be 20028fc <rtems_io_lookup_name+0x110> <== NOT EXECUTED
20028d0: c4 26 60 0c st %g2, [ %i1 + 0xc ] <== NOT EXECUTED
20028d4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
20028d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20028dc: 02 80 00 08 be 20028fc <rtems_io_lookup_name+0x110> <== NOT EXECUTED
20028e0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20028e4: 9f c0 40 00 call %g1 <== NOT EXECUTED
20028e8: b0 10 20 00 clr %i0 <== NOT EXECUTED
20028ec: 81 c7 e0 08 ret <== NOT EXECUTED
20028f0: 81 e8 00 00 restore <== NOT EXECUTED
20028f4: 81 c7 e0 08 ret <== NOT EXECUTED
20028f8: 91 e8 20 0d restore %g0, 0xd, %o0 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
20028fc: 81 c7 e0 08 ret <== NOT EXECUTED
2002900: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02008424 <rtems_io_register_driver>:
rtems_status_code rtems_io_register_driver(
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
2008424: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
2008428: 03 00 80 8c sethi %hi(0x2023000), %g1
200842c: c2 00 63 ec ld [ %g1 + 0x3ec ], %g1 ! 20233ec <_ISR_Nest_level>
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
rtems_device_major_number major_limit = _IO_Number_of_drivers;
2008430: 09 00 80 8f sethi %hi(0x2023c00), %g4
if ( rtems_interrupt_is_in_progress() )
2008434: 80 a0 60 00 cmp %g1, 0
2008438: 84 10 20 12 mov 0x12, %g2
rtems_status_code rtems_io_register_driver(
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
200843c: 82 10 00 19 mov %i1, %g1
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
2008440: 12 80 00 49 bne 2008564 <rtems_io_register_driver+0x140>
2008444: c6 01 20 bc ld [ %g4 + 0xbc ], %g3
return RTEMS_CALLED_FROM_ISR;
if ( registered_major == NULL )
2008448: 80 a6 a0 00 cmp %i2, 0
200844c: 02 80 00 4b be 2008578 <rtems_io_register_driver+0x154>
2008450: 80 a6 60 00 cmp %i1, 0
return RTEMS_INVALID_ADDRESS;
/* Set it to an invalid value */
*registered_major = major_limit;
if ( driver_table == NULL )
2008454: 02 80 00 49 be 2008578 <rtems_io_register_driver+0x154>
2008458: c6 26 80 00 st %g3, [ %i2 ]
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
200845c: c4 06 40 00 ld [ %i1 ], %g2
2008460: 80 a0 a0 00 cmp %g2, 0
2008464: 22 80 00 42 be,a 200856c <rtems_io_register_driver+0x148>
2008468: c4 06 60 04 ld [ %i1 + 4 ], %g2
return RTEMS_INVALID_ADDRESS;
if ( rtems_io_is_empty_table( driver_table ) )
return RTEMS_INVALID_ADDRESS;
if ( major >= major_limit )
200846c: 80 a0 c0 18 cmp %g3, %i0
2008470: 08 80 00 3d bleu 2008564 <rtems_io_register_driver+0x140>
2008474: 84 10 20 0a mov 0xa, %g2
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2008478: 05 00 80 8c sethi %hi(0x2023000), %g2
200847c: c6 00 a3 50 ld [ %g2 + 0x350 ], %g3 ! 2023350 <_Thread_Dispatch_disable_level>
2008480: 86 00 e0 01 inc %g3
2008484: c6 20 a3 50 st %g3, [ %g2 + 0x350 ]
return RTEMS_INVALID_NUMBER;
_Thread_Disable_dispatch();
if ( major == 0 ) {
2008488: 80 a6 20 00 cmp %i0, 0
200848c: 12 80 00 2b bne 2008538 <rtems_io_register_driver+0x114>
2008490: 05 00 80 8f sethi %hi(0x2023c00), %g2
static rtems_status_code rtems_io_obtain_major_number(
rtems_device_major_number *major
)
{
rtems_device_major_number n = _IO_Number_of_drivers;
2008494: da 01 20 bc ld [ %g4 + 0xbc ], %o5
rtems_device_major_number m = 0;
/* major is error checked by caller */
for ( m = 0; m < n; ++m ) {
2008498: 80 a3 60 00 cmp %o5, 0
200849c: 02 80 00 3a be 2008584 <rtems_io_register_driver+0x160> <== NEVER TAKEN
20084a0: d8 00 a0 c0 ld [ %g2 + 0xc0 ], %o4
20084a4: 10 80 00 05 b 20084b8 <rtems_io_register_driver+0x94>
20084a8: 86 10 00 0c mov %o4, %g3
20084ac: 80 a3 40 18 cmp %o5, %i0
20084b0: 08 80 00 0b bleu 20084dc <rtems_io_register_driver+0xb8>
20084b4: 86 00 e0 18 add %g3, 0x18, %g3
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
20084b8: c8 00 c0 00 ld [ %g3 ], %g4
20084bc: 80 a1 20 00 cmp %g4, 0
20084c0: 32 bf ff fb bne,a 20084ac <rtems_io_register_driver+0x88>
20084c4: b0 06 20 01 inc %i0
20084c8: c8 00 e0 04 ld [ %g3 + 4 ], %g4
20084cc: 80 a1 20 00 cmp %g4, 0
20084d0: 32 bf ff f7 bne,a 20084ac <rtems_io_register_driver+0x88>
20084d4: b0 06 20 01 inc %i0
}
/* Assigns invalid value in case of failure */
*major = m;
if ( m != n )
20084d8: 80 a3 40 18 cmp %o5, %i0
20084dc: 02 80 00 2b be 2008588 <rtems_io_register_driver+0x164>
20084e0: f0 26 80 00 st %i0, [ %i2 ]
20084e4: 85 2e 20 03 sll %i0, 3, %g2
20084e8: 87 2e 20 05 sll %i0, 5, %g3
20084ec: 84 20 c0 02 sub %g3, %g2, %g2
20084f0: 84 03 00 02 add %o4, %g2, %g2
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
20084f4: c6 00 40 00 ld [ %g1 ], %g3
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
20084f8: b2 10 20 00 clr %i1
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
20084fc: c6 20 80 00 st %g3, [ %g2 ]
2008500: c6 00 60 04 ld [ %g1 + 4 ], %g3
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
2008504: b4 10 20 00 clr %i2
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
2008508: c6 20 a0 04 st %g3, [ %g2 + 4 ]
200850c: c6 00 60 08 ld [ %g1 + 8 ], %g3
2008510: c6 20 a0 08 st %g3, [ %g2 + 8 ]
2008514: c6 00 60 0c ld [ %g1 + 0xc ], %g3
2008518: c6 20 a0 0c st %g3, [ %g2 + 0xc ]
200851c: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
2008520: c6 20 a0 10 st %g3, [ %g2 + 0x10 ]
2008524: c2 00 60 14 ld [ %g1 + 0x14 ], %g1
_Thread_Enable_dispatch();
2008528: 40 00 07 53 call 200a274 <_Thread_Enable_dispatch>
200852c: c2 20 a0 14 st %g1, [ %g2 + 0x14 ]
return rtems_io_initialize( major, 0, NULL );
2008530: 40 00 27 fb call 201251c <rtems_io_initialize>
2008534: 81 e8 00 00 restore
_Thread_Enable_dispatch();
return sc;
}
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
2008538: c6 00 a0 c0 ld [ %g2 + 0xc0 ], %g3
200853c: 89 2e 20 05 sll %i0, 5, %g4
2008540: 85 2e 20 03 sll %i0, 3, %g2
2008544: 84 21 00 02 sub %g4, %g2, %g2
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008548: c8 00 c0 02 ld [ %g3 + %g2 ], %g4
200854c: 80 a1 20 00 cmp %g4, 0
2008550: 02 80 00 12 be 2008598 <rtems_io_register_driver+0x174>
2008554: 84 00 c0 02 add %g3, %g2, %g2
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
if ( !rtems_io_is_empty_table( table ) ) {
_Thread_Enable_dispatch();
2008558: 40 00 07 47 call 200a274 <_Thread_Enable_dispatch>
200855c: 01 00 00 00 nop
2008560: 84 10 20 0c mov 0xc, %g2 ! c <PROM_START+0xc>
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
}
2008564: 81 c7 e0 08 ret
2008568: 91 e8 00 02 restore %g0, %g2, %o0
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
200856c: 80 a0 a0 00 cmp %g2, 0
2008570: 12 bf ff c0 bne 2008470 <rtems_io_register_driver+0x4c>
2008574: 80 a0 c0 18 cmp %g3, %i0
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
2008578: 84 10 20 09 mov 9, %g2
}
200857c: 81 c7 e0 08 ret
2008580: 91 e8 00 02 restore %g0, %g2, %o0
if ( rtems_io_is_empty_table( table ) )
break;
}
/* Assigns invalid value in case of failure */
*major = m;
2008584: c0 26 80 00 clr [ %i2 ] <== NOT EXECUTED
if ( major == 0 ) {
rtems_status_code sc = rtems_io_obtain_major_number( registered_major );
if ( sc != RTEMS_SUCCESSFUL ) {
_Thread_Enable_dispatch();
2008588: 40 00 07 3b call 200a274 <_Thread_Enable_dispatch>
200858c: 01 00 00 00 nop
return sc;
2008590: 10 bf ff f5 b 2008564 <rtems_io_register_driver+0x140>
2008594: 84 10 20 05 mov 5, %g2 ! 5 <PROM_START+0x5>
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008598: c6 00 a0 04 ld [ %g2 + 4 ], %g3
200859c: 80 a0 e0 00 cmp %g3, 0
20085a0: 12 bf ff ee bne 2008558 <rtems_io_register_driver+0x134>
20085a4: 01 00 00 00 nop
if ( !rtems_io_is_empty_table( table ) ) {
_Thread_Enable_dispatch();
return RTEMS_RESOURCE_IN_USE;
}
*registered_major = major;
20085a8: 10 bf ff d3 b 20084f4 <rtems_io_register_driver+0xd0>
20085ac: f0 26 80 00 st %i0, [ %i2 ]
020099a0 <rtems_iterate_over_all_threads>:
#include <rtems/system.h>
#include <rtems/score/thread.h>
void rtems_iterate_over_all_threads(rtems_per_thread_routine routine)
{
20099a0: 9d e3 bf a0 save %sp, -96, %sp
uint32_t i;
uint32_t api_index;
Thread_Control *the_thread;
Objects_Information *information;
if ( !routine )
20099a4: 80 a6 20 00 cmp %i0, 0
20099a8: 02 80 00 23 be 2009a34 <rtems_iterate_over_all_threads+0x94><== NEVER TAKEN
20099ac: 25 00 80 97 sethi %hi(0x2025c00), %l2
20099b0: a4 14 a3 24 or %l2, 0x324, %l2 ! 2025f24 <_Objects_Information_table+0x4>
#endif
#include <rtems/system.h>
#include <rtems/score/thread.h>
void rtems_iterate_over_all_threads(rtems_per_thread_routine routine)
20099b4: a6 04 a0 10 add %l2, 0x10, %l3
if ( !routine )
return;
for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
if ( !_Objects_Information_table[ api_index ] )
20099b8: c2 04 80 00 ld [ %l2 ], %g1
20099bc: 80 a0 60 00 cmp %g1, 0
20099c0: 22 80 00 1a be,a 2009a28 <rtems_iterate_over_all_threads+0x88>
20099c4: a4 04 a0 04 add %l2, 4, %l2
continue;
information = _Objects_Information_table[ api_index ][ 1 ];
20099c8: e2 00 60 04 ld [ %g1 + 4 ], %l1
if ( !information )
20099cc: 80 a4 60 00 cmp %l1, 0
20099d0: 22 80 00 16 be,a 2009a28 <rtems_iterate_over_all_threads+0x88>
20099d4: a4 04 a0 04 add %l2, 4, %l2
continue;
for ( i=1 ; i <= information->maximum ; i++ ) {
20099d8: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1
20099dc: 84 90 60 00 orcc %g1, 0, %g2
20099e0: 22 80 00 12 be,a 2009a28 <rtems_iterate_over_all_threads+0x88>
20099e4: a4 04 a0 04 add %l2, 4, %l2
20099e8: a0 10 20 01 mov 1, %l0
the_thread = (Thread_Control *)information->local_table[ i ];
20099ec: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
20099f0: 83 2c 20 02 sll %l0, 2, %g1
20099f4: c2 00 c0 01 ld [ %g3 + %g1 ], %g1
if ( !the_thread )
20099f8: 90 90 60 00 orcc %g1, 0, %o0
20099fc: 02 80 00 05 be 2009a10 <rtems_iterate_over_all_threads+0x70><== NEVER TAKEN
2009a00: a0 04 20 01 inc %l0
continue;
(*routine)(the_thread);
2009a04: 9f c6 00 00 call %i0
2009a08: 01 00 00 00 nop
2009a0c: c4 14 60 10 lduh [ %l1 + 0x10 ], %g2
information = _Objects_Information_table[ api_index ][ 1 ];
if ( !information )
continue;
for ( i=1 ; i <= information->maximum ; i++ ) {
2009a10: 83 28 a0 10 sll %g2, 0x10, %g1
2009a14: 83 30 60 10 srl %g1, 0x10, %g1
2009a18: 80 a0 40 10 cmp %g1, %l0
2009a1c: 3a bf ff f5 bcc,a 20099f0 <rtems_iterate_over_all_threads+0x50>
2009a20: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
2009a24: a4 04 a0 04 add %l2, 4, %l2
Objects_Information *information;
if ( !routine )
return;
for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
2009a28: 80 a4 80 13 cmp %l2, %l3
2009a2c: 32 bf ff e4 bne,a 20099bc <rtems_iterate_over_all_threads+0x1c>
2009a30: c2 04 80 00 ld [ %l2 ], %g1
2009a34: 81 c7 e0 08 ret
2009a38: 81 e8 00 00 restore
0200cd14 <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 )
{
200cd14: 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 );
200cd18: 21 00 80 7c sethi %hi(0x201f000), %l0
200cd1c: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
200cd20: 92 10 20 00 clr %o1
200cd24: 7f ff e6 ec call 20068d4 <rtems_semaphore_obtain>
200cd28: 94 10 20 00 clr %o2
rtems_status_code rc;
rtems_id sema;
rtems_libio_lock();
if (rtems_libio_iop_freelist) {
200cd2c: 23 00 80 7c sethi %hi(0x201f000), %l1
200cd30: c2 04 61 c8 ld [ %l1 + 0x1c8 ], %g1 ! 201f1c8 <rtems_libio_iop_freelist>
200cd34: 80 a0 60 00 cmp %g1, 0
200cd38: 12 80 00 07 bne 200cd54 <rtems_libio_allocate+0x40>
200cd3c: 05 00 80 7c sethi %hi(0x201f000), %g2
next = iop->data1;
(void) memset( iop, 0, sizeof(rtems_libio_t) );
iop->flags = LIBIO_FLAGS_OPEN;
iop->sem = sema;
rtems_libio_iop_freelist = next;
goto done;
200cd40: b0 10 20 00 clr %i0
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200cd44: 7f ff e7 2b call 20069f0 <rtems_semaphore_release>
200cd48: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
iop = 0;
done:
rtems_libio_unlock();
return iop;
}
200cd4c: 81 c7 e0 08 ret
200cd50: 81 e8 00 00 restore
rtems_id sema;
rtems_libio_lock();
if (rtems_libio_iop_freelist) {
rc = rtems_semaphore_create(
200cd54: c4 00 a1 c4 ld [ %g2 + 0x1c4 ], %g2
200cd58: 92 10 20 01 mov 1, %o1
200cd5c: 82 20 40 02 sub %g1, %g2, %g1
200cd60: 83 38 60 03 sra %g1, 3, %g1
200cd64: 87 28 60 06 sll %g1, 6, %g3
200cd68: 85 28 60 03 sll %g1, 3, %g2
200cd6c: 84 20 c0 02 sub %g3, %g2, %g2
200cd70: 87 28 a0 06 sll %g2, 6, %g3
200cd74: 84 00 80 03 add %g2, %g3, %g2
200cd78: 84 00 80 01 add %g2, %g1, %g2
200cd7c: 87 28 a0 0f sll %g2, 0xf, %g3
200cd80: 84 20 c0 02 sub %g3, %g2, %g2
200cd84: 07 13 10 92 sethi %hi(0x4c424800), %g3
200cd88: 85 28 a0 03 sll %g2, 3, %g2
200cd8c: 86 10 e1 00 or %g3, 0x100, %g3
200cd90: 82 00 80 01 add %g2, %g1, %g1
200cd94: 94 10 20 54 mov 0x54, %o2
200cd98: 96 10 20 00 clr %o3
200cd9c: 90 10 40 03 or %g1, %g3, %o0
200cda0: 7f ff e6 2c call 2006650 <rtems_semaphore_create>
200cda4: 98 07 bf fc add %fp, -4, %o4
1,
RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY,
0,
&sema
);
if (rc != RTEMS_SUCCESSFUL)
200cda8: 80 a2 20 00 cmp %o0, 0
200cdac: 32 bf ff e6 bne,a 200cd44 <rtems_libio_allocate+0x30> <== NEVER TAKEN
200cdb0: b0 10 20 00 clr %i0 <== NOT EXECUTED
goto failed;
iop = rtems_libio_iop_freelist;
200cdb4: f0 04 61 c8 ld [ %l1 + 0x1c8 ], %i0
next = iop->data1;
200cdb8: c2 06 20 38 ld [ %i0 + 0x38 ], %g1
(void) memset( iop, 0, sizeof(rtems_libio_t) );
200cdbc: c0 26 20 30 clr [ %i0 + 0x30 ]
200cdc0: c0 26 20 1c clr [ %i0 + 0x1c ]
200cdc4: c0 26 20 34 clr [ %i0 + 0x34 ]
200cdc8: c0 26 00 00 clr [ %i0 ]
200cdcc: c0 26 20 04 clr [ %i0 + 4 ]
200cdd0: c0 26 20 08 clr [ %i0 + 8 ]
200cdd4: c0 26 20 0c clr [ %i0 + 0xc ]
200cdd8: c0 26 20 10 clr [ %i0 + 0x10 ]
200cddc: c0 26 20 14 clr [ %i0 + 0x14 ]
200cde0: c0 26 20 20 clr [ %i0 + 0x20 ]
200cde4: c0 26 20 24 clr [ %i0 + 0x24 ]
200cde8: c0 26 20 28 clr [ %i0 + 0x28 ]
200cdec: c0 26 20 2c clr [ %i0 + 0x2c ]
200cdf0: c0 26 20 40 clr [ %i0 + 0x40 ]
200cdf4: c0 26 20 44 clr [ %i0 + 0x44 ]
200cdf8: c0 26 20 38 clr [ %i0 + 0x38 ]
200cdfc: c0 26 20 3c clr [ %i0 + 0x3c ]
iop->flags = LIBIO_FLAGS_OPEN;
iop->sem = sema;
rtems_libio_iop_freelist = next;
200ce00: c2 24 61 c8 st %g1, [ %l1 + 0x1c8 ]
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;
200ce04: 82 10 21 00 mov 0x100, %g1
200ce08: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
iop->sem = sema;
200ce0c: c2 07 bf fc ld [ %fp + -4 ], %g1
rtems_libio_iop_freelist = next;
goto done;
200ce10: 10 bf ff cd b 200cd44 <rtems_libio_allocate+0x30>
200ce14: c2 26 20 30 st %g1, [ %i0 + 0x30 ]
0200ccb8 <rtems_libio_free>:
*/
void rtems_libio_free(
rtems_libio_t *iop
)
{
200ccb8: 9d e3 bf a0 save %sp, -96, %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 );
200ccbc: 23 00 80 7c sethi %hi(0x201f000), %l1
200ccc0: d0 04 61 cc ld [ %l1 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
200ccc4: 92 10 20 00 clr %o1
200ccc8: 7f ff e7 03 call 20068d4 <rtems_semaphore_obtain>
200cccc: 94 10 20 00 clr %o2
rtems_libio_lock();
if (iop->sem)
200ccd0: d0 06 20 30 ld [ %i0 + 0x30 ], %o0
200ccd4: 80 a2 20 00 cmp %o0, 0
200ccd8: 02 80 00 04 be 200cce8 <rtems_libio_free+0x30> <== NEVER TAKEN
200ccdc: a0 10 00 18 mov %i0, %l0
rtems_semaphore_delete(iop->sem);
200cce0: 7f ff e6 d0 call 2006820 <rtems_semaphore_delete>
200cce4: 01 00 00 00 nop
iop->flags &= ~LIBIO_FLAGS_OPEN;
200cce8: c4 04 20 18 ld [ %l0 + 0x18 ], %g2
iop->data1 = rtems_libio_iop_freelist;
200ccec: 03 00 80 7c sethi %hi(0x201f000), %g1
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200ccf0: f0 04 61 cc ld [ %l1 + 0x1cc ], %i0
200ccf4: c6 00 61 c8 ld [ %g1 + 0x1c8 ], %g3
rtems_libio_iop_freelist = iop;
200ccf8: e0 20 61 c8 st %l0, [ %g1 + 0x1c8 ]
rtems_libio_lock();
if (iop->sem)
rtems_semaphore_delete(iop->sem);
iop->flags &= ~LIBIO_FLAGS_OPEN;
200ccfc: 82 08 be ff and %g2, -257, %g1
iop->data1 = rtems_libio_iop_freelist;
200cd00: c6 24 20 38 st %g3, [ %l0 + 0x38 ]
rtems_libio_lock();
if (iop->sem)
rtems_semaphore_delete(iop->sem);
iop->flags &= ~LIBIO_FLAGS_OPEN;
200cd04: c2 24 20 18 st %g1, [ %l0 + 0x18 ]
200cd08: 7f ff e7 3a call 20069f0 <rtems_semaphore_release>
200cd0c: 81 e8 00 00 restore
02002e24 <rtems_libio_init>:
*
* Called by BSP startup code to initialize the libio subsystem.
*/
void rtems_libio_init( void )
{
2002e24: 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)
2002e28: 21 00 80 79 sethi %hi(0x201e400), %l0
2002e2c: d0 04 23 b4 ld [ %l0 + 0x3b4 ], %o0 ! 201e7b4 <rtems_libio_number_iops>
2002e30: 80 a2 20 00 cmp %o0, 0
2002e34: 22 80 00 1c be,a 2002ea4 <rtems_libio_init+0x80> <== NEVER TAKEN
2002e38: 11 13 10 92 sethi %hi(0x4c424800), %o0 <== NOT EXECUTED
{
rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops,
2002e3c: 7f ff ff 09 call 2002a60 <calloc>
2002e40: 92 10 20 48 mov 0x48, %o1
2002e44: 03 00 80 7c sethi %hi(0x201f000), %g1
2002e48: d0 20 61 c4 st %o0, [ %g1 + 0x1c4 ] ! 201f1c4 <rtems_libio_iops>
sizeof(rtems_libio_t));
if (rtems_libio_iops == NULL)
2002e4c: 80 a2 20 00 cmp %o0, 0
2002e50: 02 80 00 29 be 2002ef4 <rtems_libio_init+0xd0> <== NEVER TAKEN
2002e54: 82 10 00 08 mov %o0, %g1
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++)
2002e58: c6 04 23 b4 ld [ %l0 + 0x3b4 ], %g3
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;
2002e5c: 05 00 80 7c sethi %hi(0x201f000), %g2
for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)
2002e60: 80 a0 e0 01 cmp %g3, 1
2002e64: 08 80 00 0e bleu 2002e9c <rtems_libio_init+0x78> <== NEVER TAKEN
2002e68: d0 20 a1 c8 st %o0, [ %g2 + 0x1c8 ]
2002e6c: 82 02 20 48 add %o0, 0x48, %g1
2002e70: 84 10 20 01 mov 1, %g2
iop->data1 = iop + 1;
2002e74: c2 20 7f f0 st %g1, [ %g1 + -16 ]
2002e78: 84 00 a0 01 inc %g2
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++)
2002e7c: 80 a0 80 03 cmp %g2, %g3
2002e80: 12 bf ff fd bne 2002e74 <rtems_libio_init+0x50>
2002e84: 82 00 60 48 add %g1, 0x48, %g1
2002e88: 84 00 bf ff add %g2, -1, %g2
2002e8c: 83 28 a0 06 sll %g2, 6, %g1
2002e90: 85 28 a0 03 sll %g2, 3, %g2
2002e94: 82 00 80 01 add %g2, %g1, %g1
2002e98: 82 02 00 01 add %o0, %g1, %g1
iop->data1 = iop + 1;
iop->data1 = NULL;
2002e9c: c0 20 60 38 clr [ %g1 + 0x38 ]
/*
* Create the binary semaphore used to provide mutual exclusion
* on the IOP Table.
*/
rc = rtems_semaphore_create(
2002ea0: 11 13 10 92 sethi %hi(0x4c424800), %o0
2002ea4: 92 10 20 01 mov 1, %o1
2002ea8: 90 12 21 4f or %o0, 0x14f, %o0
2002eac: 94 10 20 54 mov 0x54, %o2
2002eb0: 96 10 20 00 clr %o3
2002eb4: 19 00 80 7c sethi %hi(0x201f000), %o4
2002eb8: 40 00 0d e6 call 2006650 <rtems_semaphore_create>
2002ebc: 98 13 21 cc or %o4, 0x1cc, %o4 ! 201f1cc <rtems_libio_semaphore>
1,
RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY,
RTEMS_NO_PRIORITY,
&rtems_libio_semaphore
);
if ( rc != RTEMS_SUCCESSFUL )
2002ec0: 80 a2 20 00 cmp %o0, 0
2002ec4: 12 80 00 0a bne 2002eec <rtems_libio_init+0xc8> <== NEVER TAKEN
2002ec8: 03 00 80 79 sethi %hi(0x201e400), %g1
/*
* Initialize the base file system infrastructure.
*/
if (rtems_fs_init_helper)
2002ecc: c2 00 63 b0 ld [ %g1 + 0x3b0 ], %g1 ! 201e7b0 <rtems_fs_init_helper>
2002ed0: 80 a0 60 00 cmp %g1, 0
2002ed4: 02 80 00 04 be 2002ee4 <rtems_libio_init+0xc0> <== NEVER TAKEN
2002ed8: 01 00 00 00 nop
(* rtems_fs_init_helper)();
2002edc: 9f c0 40 00 call %g1
2002ee0: 01 00 00 00 nop
2002ee4: 81 c7 e0 08 ret
2002ee8: 81 e8 00 00 restore
RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY,
RTEMS_NO_PRIORITY,
&rtems_libio_semaphore
);
if ( rc != RTEMS_SUCCESSFUL )
rtems_fatal_error_occurred( rc );
2002eec: 40 00 10 1b call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2002ef0: 01 00 00 00 nop <== NOT EXECUTED
if (rtems_libio_number_iops > 0)
{
rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops,
sizeof(rtems_libio_t));
if (rtems_libio_iops == NULL)
rtems_fatal_error_occurred(RTEMS_NO_MEMORY);
2002ef4: 40 00 10 19 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2002ef8: 90 10 20 1a mov 0x1a, %o0 ! 1a <PROM_START+0x1a> <== NOT EXECUTED
0200cbb0 <rtems_libio_is_file_open>:
*/
int rtems_libio_is_file_open(
void *node_access
)
{
200cbb0: 9d e3 bf a0 save %sp, -96, %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 );
200cbb4: 21 00 80 7c sethi %hi(0x201f000), %l0
200cbb8: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
200cbbc: 92 10 20 00 clr %o1
200cbc0: 7f ff e7 45 call 20068d4 <rtems_semaphore_obtain>
200cbc4: 94 10 20 00 clr %o2
/*
* Look for any active file descriptor entry.
*/
for (iop=rtems_libio_iops,i=0; i < rtems_libio_number_iops; iop++, i++){
200cbc8: 03 00 80 79 sethi %hi(0x201e400), %g1
200cbcc: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
200cbd0: 05 00 80 7c sethi %hi(0x201f000), %g2
200cbd4: 80 a0 60 00 cmp %g1, 0
200cbd8: 02 80 00 0e be 200cc10 <rtems_libio_is_file_open+0x60> <== NEVER TAKEN
200cbdc: c4 00 a1 c4 ld [ %g2 + 0x1c4 ], %g2
200cbe0: 86 10 20 00 clr %g3
if ((iop->flags & LIBIO_FLAGS_OPEN) != 0) {
200cbe4: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4
200cbe8: 80 89 21 00 btst 0x100, %g4
200cbec: 02 80 00 06 be 200cc04 <rtems_libio_is_file_open+0x54>
200cbf0: 86 00 e0 01 inc %g3
/*
* Check if this node is under the file system that we
* are trying to dismount.
*/
if ( iop->pathinfo.node_access == node_access ) {
200cbf4: c8 00 a0 1c ld [ %g2 + 0x1c ], %g4
200cbf8: 80 a1 00 18 cmp %g4, %i0
200cbfc: 02 80 00 0a be 200cc24 <rtems_libio_is_file_open+0x74>
200cc00: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
/*
* Look for any active file descriptor entry.
*/
for (iop=rtems_libio_iops,i=0; i < rtems_libio_number_iops; iop++, i++){
200cc04: 80 a0 c0 01 cmp %g3, %g1
200cc08: 0a bf ff f7 bcs 200cbe4 <rtems_libio_is_file_open+0x34>
200cc0c: 84 00 a0 48 add %g2, 0x48, %g2
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200cc10: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
200cc14: 7f ff e7 77 call 20069f0 <rtems_semaphore_release>
200cc18: b0 10 20 00 clr %i0
}
rtems_libio_unlock();
return result;
}
200cc1c: 81 c7 e0 08 ret
200cc20: 81 e8 00 00 restore
200cc24: 7f ff e7 73 call 20069f0 <rtems_semaphore_release>
200cc28: b0 10 20 01 mov 1, %i0
200cc2c: 81 c7 e0 08 ret
200cc30: 81 e8 00 00 restore
0200cc34 <rtems_libio_is_open_files_in_fs>:
*/
int rtems_libio_is_open_files_in_fs(
rtems_filesystem_mount_table_entry_t * fs_mt_entry
)
{
200cc34: 9d e3 bf a0 save %sp, -96, %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 );
200cc38: 21 00 80 7c sethi %hi(0x201f000), %l0
200cc3c: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0 ! 201f1cc <rtems_libio_semaphore>
200cc40: 92 10 20 00 clr %o1
200cc44: 7f ff e7 24 call 20068d4 <rtems_semaphore_obtain>
200cc48: 94 10 20 00 clr %o2
/*
* Look for any active file descriptor entry.
*/
for (iop=rtems_libio_iops,i=0; i < rtems_libio_number_iops; iop++, i++){
200cc4c: 03 00 80 79 sethi %hi(0x201e400), %g1
200cc50: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
200cc54: 05 00 80 7c sethi %hi(0x201f000), %g2
200cc58: 80 a0 60 00 cmp %g1, 0
200cc5c: 02 80 00 0e be 200cc94 <rtems_libio_is_open_files_in_fs+0x60><== NEVER TAKEN
200cc60: c4 00 a1 c4 ld [ %g2 + 0x1c4 ], %g2
200cc64: 86 10 20 00 clr %g3
if ((iop->flags & LIBIO_FLAGS_OPEN) != 0) {
200cc68: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4
200cc6c: 80 89 21 00 btst 0x100, %g4
200cc70: 02 80 00 06 be 200cc88 <rtems_libio_is_open_files_in_fs+0x54>
200cc74: 86 00 e0 01 inc %g3
/*
* Check if this node is under the file system that we
* are trying to dismount.
*/
if ( iop->pathinfo.mt_entry == fs_mt_entry ) {
200cc78: c8 00 a0 2c ld [ %g2 + 0x2c ], %g4
200cc7c: 80 a1 00 18 cmp %g4, %i0
200cc80: 02 80 00 0a be 200cca8 <rtems_libio_is_open_files_in_fs+0x74>
200cc84: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
/*
* Look for any active file descriptor entry.
*/
for (iop=rtems_libio_iops,i=0; i < rtems_libio_number_iops; iop++, i++){
200cc88: 80 a0 c0 01 cmp %g3, %g1
200cc8c: 0a bf ff f7 bcs 200cc68 <rtems_libio_is_open_files_in_fs+0x34>
200cc90: 84 00 a0 48 add %g2, 0x48, %g2
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
200cc94: d0 04 21 cc ld [ %l0 + 0x1cc ], %o0
200cc98: 7f ff e7 56 call 20069f0 <rtems_semaphore_release>
200cc9c: b0 10 20 00 clr %i0
}
rtems_libio_unlock();
return result;
}
200cca0: 81 c7 e0 08 ret
200cca4: 81 e8 00 00 restore
200cca8: 7f ff e7 52 call 20069f0 <rtems_semaphore_release>
200ccac: b0 10 20 01 mov 1, %i0
200ccb0: 81 c7 e0 08 ret
200ccb4: 81 e8 00 00 restore
0202e210 <rtems_libio_set_private_env>:
rtems_filesystem_freenode( &env->root_directory);
free(env);
}
}
rtems_status_code rtems_libio_set_private_env(void) {
202e210: 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);
202e214: 90 10 20 00 clr %o0
202e218: 92 10 20 00 clr %o1
202e21c: 40 00 07 74 call 202ffec <rtems_task_ident>
202e220: 94 07 bf fc add %fp, -4, %o2
if (sc != RTEMS_SUCCESSFUL) return sc;
202e224: b0 92 20 00 orcc %o0, 0, %i0
202e228: 12 80 00 45 bne 202e33c <rtems_libio_set_private_env+0x12c><== NEVER TAKEN
202e22c: 21 00 81 c3 sethi %hi(0x2070c00), %l0
/* Only for the first time a malloc is necesary */
if (rtems_current_user_env==&rtems_global_user_env) {
202e230: e4 04 22 24 ld [ %l0 + 0x224 ], %l2 ! 2070e24 <rtems_current_user_env>
202e234: 23 00 81 d3 sethi %hi(0x2074c00), %l1
202e238: a2 14 60 bc or %l1, 0xbc, %l1 ! 2074cbc <rtems_global_user_env>
202e23c: 80 a4 80 11 cmp %l2, %l1
202e240: 02 80 00 2e be 202e2f8 <rtems_libio_set_private_env+0xe8>
202e244: a6 14 22 24 or %l0, 0x224, %l3
return sc;
}
rtems_current_user_env = tmp;
};
*rtems_current_user_env = rtems_global_user_env; /* get the global values*/
202e248: 92 10 00 11 mov %l1, %o1
202e24c: 94 10 20 48 mov 0x48, %o2
202e250: 40 00 7d d8 call 204d9b0 <memcpy>
202e254: 90 10 00 12 mov %l2, %o0
rtems_current_user_env->task_id=task_id; /* mark the local values*/
202e258: c2 07 bf fc ld [ %fp + -4 ], %g1
* what we are trying to do here is forking off
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e25c: a2 07 bf e8 add %fp, -24, %l1
}
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*/
202e260: c2 24 80 00 st %g1, [ %l2 ]
* what we are trying to do here is forking off
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e264: 92 10 20 01 mov 1, %o1
202e268: 25 00 81 ab sethi %hi(0x206ac00), %l2
202e26c: 94 10 20 00 clr %o2
202e270: 96 10 00 11 mov %l1, %o3
202e274: 98 10 20 00 clr %o4
202e278: 7f ff 69 7a call 2008860 <rtems_filesystem_evaluate_path>
202e27c: 90 14 a3 90 or %l2, 0x390, %o0
rtems_filesystem_root = loc;
202e280: c2 04 22 24 ld [ %l0 + 0x224 ], %g1
202e284: c4 07 bf e8 ld [ %fp + -24 ], %g2
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e288: 90 14 a3 90 or %l2, 0x390, %o0
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
202e28c: c4 20 60 18 st %g2, [ %g1 + 0x18 ]
202e290: c4 07 bf ec ld [ %fp + -20 ], %g2
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e294: 96 10 00 11 mov %l1, %o3
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
202e298: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
202e29c: c4 07 bf f0 ld [ %fp + -16 ], %g2
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e2a0: 92 10 20 01 mov 1, %o1
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
202e2a4: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
202e2a8: c4 07 bf f4 ld [ %fp + -12 ], %g2
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e2ac: 94 10 20 00 clr %o2
* clones. The reason is a pathloc can be allocated by the
* file system and needs to be freed when deleting the environment.
*/
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
rtems_filesystem_root = loc;
202e2b0: c4 20 60 24 st %g2, [ %g1 + 0x24 ]
202e2b4: c4 07 bf f8 ld [ %fp + -8 ], %g2
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
202e2b8: 98 10 20 00 clr %o4
202e2bc: 7f ff 69 69 call 2008860 <rtems_filesystem_evaluate_path>
202e2c0: c4 20 60 28 st %g2, [ %g1 + 0x28 ]
rtems_filesystem_current = loc;
202e2c4: c4 07 bf e8 ld [ %fp + -24 ], %g2
202e2c8: c2 04 22 24 ld [ %l0 + 0x224 ], %g1
202e2cc: c4 20 60 04 st %g2, [ %g1 + 4 ]
202e2d0: c4 07 bf ec ld [ %fp + -20 ], %g2
202e2d4: c4 20 60 08 st %g2, [ %g1 + 8 ]
202e2d8: c4 07 bf f0 ld [ %fp + -16 ], %g2
202e2dc: c4 20 60 0c st %g2, [ %g1 + 0xc ]
202e2e0: c4 07 bf f4 ld [ %fp + -12 ], %g2
202e2e4: c4 20 60 10 st %g2, [ %g1 + 0x10 ]
202e2e8: c4 07 bf f8 ld [ %fp + -8 ], %g2
202e2ec: c4 20 60 14 st %g2, [ %g1 + 0x14 ]
return RTEMS_SUCCESSFUL;
}
202e2f0: 81 c7 e0 08 ret
202e2f4: 91 e8 20 00 restore %g0, 0, %o0
sc=rtems_task_ident(RTEMS_SELF,0,&task_id);
if (sc != RTEMS_SUCCESSFUL) return sc;
/* Only for the first time a malloc is necesary */
if (rtems_current_user_env==&rtems_global_user_env) {
rtems_user_env_t *tmp = malloc(sizeof(rtems_user_env_t));
202e2f8: 90 10 20 48 mov 0x48, %o0
202e2fc: 7f ff 6b 59 call 2009060 <malloc>
202e300: b0 10 20 1a mov 0x1a, %i0
if (!tmp)
202e304: a4 92 20 00 orcc %o0, 0, %l2
202e308: 02 80 00 0d be 202e33c <rtems_libio_set_private_env+0x12c><== NEVER TAKEN
202e30c: 92 10 00 13 mov %l3, %o1
#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);
202e310: 90 10 20 00 clr %o0
202e314: 15 00 80 b8 sethi %hi(0x202e000), %o2
202e318: 40 00 07 de call 2030290 <rtems_task_variable_add>
202e31c: 94 12 a0 dc or %o2, 0xdc, %o2 ! 202e0dc <free_user_env>
if (sc != RTEMS_SUCCESSFUL) {
202e320: b0 92 20 00 orcc %o0, 0, %i0
202e324: 12 80 00 04 bne 202e334 <rtems_libio_set_private_env+0x124><== NEVER TAKEN
202e328: 01 00 00 00 nop
* not initialized yet
*/
free(tmp);
return sc;
}
rtems_current_user_env = tmp;
202e32c: 10 bf ff c7 b 202e248 <rtems_libio_set_private_env+0x38>
202e330: e4 24 22 24 st %l2, [ %l0 + 0x224 ]
sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,(void(*)(void *))free_user_env);
if (sc != RTEMS_SUCCESSFUL) {
/* don't use free_user_env because the pathlocs are
* not initialized yet
*/
free(tmp);
202e334: 7f ff 69 6a call 20088dc <free> <== NOT EXECUTED
202e338: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
return sc;
202e33c: 81 c7 e0 08 ret <== NOT EXECUTED
202e340: 81 e8 00 00 restore <== NOT EXECUTED
0202e154 <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) {
202e154: 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);
202e158: 90 10 20 00 clr %o0 <== NOT EXECUTED
202e15c: 92 10 20 00 clr %o1 <== NOT EXECUTED
202e160: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
202e164: 40 00 07 a2 call 202ffec <rtems_task_ident> <== NOT EXECUTED
202e168: a4 10 00 18 mov %i0, %l2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
202e16c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202e170: 12 80 00 14 bne 202e1c0 <rtems_libio_share_private_env+0x6c><== NOT EXECUTED
202e174: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
if (rtems_current_user_env->task_id==current_task_id) {
202e178: 21 00 81 c3 sethi %hi(0x2070c00), %l0 <== NOT EXECUTED
202e17c: e6 04 22 24 ld [ %l0 + 0x224 ], %l3 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
202e180: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
202e184: c6 04 c0 00 ld [ %l3 ], %g3 <== NOT EXECUTED
202e188: 82 14 22 24 or %l0, 0x224, %g1 <== NOT EXECUTED
202e18c: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
202e190: 02 80 00 0e be 202e1c8 <rtems_libio_share_private_env+0x74><== NOT EXECUTED
202e194: a2 10 00 01 mov %g1, %l1 <== NOT EXECUTED
free_user_env(tmp);
};
/* AT THIS POINT, rtems_current_user_env is DANGLING */
sc = rtems_task_variable_get(task_id,(void*)&rtems_current_user_env,
202e198: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
202e19c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202e1a0: 40 00 08 9a call 2030408 <rtems_task_variable_get> <== NOT EXECUTED
202e1a4: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
(void*)&shared_user_env );
if (sc != RTEMS_SUCCESSFUL)
202e1a8: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
202e1ac: 02 80 00 10 be 202e1ec <rtems_libio_share_private_env+0x98><== NOT EXECUTED
202e1b0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
bailout:
/* fallback to the global env */
rtems_current_user_env = &rtems_global_user_env;
202e1b4: 05 00 81 d3 sethi %hi(0x2074c00), %g2 <== NOT EXECUTED
202e1b8: 84 10 a0 bc or %g2, 0xbc, %g2 ! 2074cbc <rtems_global_user_env><== NOT EXECUTED
202e1bc: c4 24 22 24 st %g2, [ %l0 + 0x224 ] <== NOT EXECUTED
return sc;
}
202e1c0: 81 c7 e0 08 ret <== NOT EXECUTED
202e1c4: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
if (rtems_current_user_env->task_id==current_task_id) {
/* 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);
202e1c8: 40 00 08 62 call 2030350 <rtems_task_variable_delete> <== NOT EXECUTED
202e1cc: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
202e1d0: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
202e1d4: 12 bf ff fb bne 202e1c0 <rtems_libio_share_private_env+0x6c><== NOT EXECUTED
202e1d8: 01 00 00 00 nop <== NOT EXECUTED
free_user_env(tmp);
202e1dc: 7f ff ff c0 call 202e0dc <free_user_env> <== NOT EXECUTED
202e1e0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
};
/* AT THIS POINT, rtems_current_user_env is DANGLING */
sc = rtems_task_variable_get(task_id,(void*)&rtems_current_user_env,
202e1e4: 10 bf ff ee b 202e19c <rtems_libio_share_private_env+0x48><== NOT EXECUTED
202e1e8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
(void*)&shared_user_env );
if (sc != RTEMS_SUCCESSFUL)
goto bailout;
sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,free_user_env);
202e1ec: 15 00 80 b8 sethi %hi(0x202e000), %o2 <== NOT EXECUTED
202e1f0: 40 00 08 28 call 2030290 <rtems_task_variable_add> <== NOT EXECUTED
202e1f4: 94 12 a0 dc or %o2, 0xdc, %o2 ! 202e0dc <free_user_env> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
202e1f8: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
202e1fc: 12 bf ff ef bne 202e1b8 <rtems_libio_share_private_env+0x64><== NOT EXECUTED
202e200: 05 00 81 d3 sethi %hi(0x2074c00), %g2 <== NOT EXECUTED
goto bailout;
/* the current_user_env is the same pointer that remote env */
rtems_current_user_env = shared_user_env;
202e204: 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;
202e208: 10 bf ff ee b 202e1c0 <rtems_libio_share_private_env+0x6c><== NOT EXECUTED
202e20c: c4 24 22 24 st %g2, [ %l0 + 0x224 ] <== NOT EXECUTED
0200cb58 <rtems_libio_to_fcntl_flags>:
*/
uint32_t rtems_libio_to_fcntl_flags(
uint32_t flags
)
{
200cb58: 82 10 00 08 mov %o0, %g1
uint32_t fcntl_flags = 0;
if ( (flags & LIBIO_FLAGS_READ_WRITE) == LIBIO_FLAGS_READ_WRITE ) {
200cb5c: 84 08 60 06 and %g1, 6, %g2
200cb60: 80 a0 a0 06 cmp %g2, 6
200cb64: 02 80 00 07 be 200cb80 <rtems_libio_to_fcntl_flags+0x28> <== NEVER TAKEN
200cb68: 90 10 20 02 mov 2, %o0
fcntl_flags |= O_RDWR;
} else if ( (flags & LIBIO_FLAGS_READ) == LIBIO_FLAGS_READ) {
200cb6c: 84 08 60 02 and %g1, 2, %g2
200cb70: 80 a0 00 02 cmp %g0, %g2
200cb74: 85 30 60 02 srl %g1, 2, %g2
200cb78: 90 60 3f ff subx %g0, -1, %o0
200cb7c: 90 0a 00 02 and %o0, %g2, %o0
fcntl_flags |= O_RDONLY;
} else if ( (flags & LIBIO_FLAGS_WRITE) == LIBIO_FLAGS_WRITE) {
fcntl_flags |= O_WRONLY;
}
if ( (flags & LIBIO_FLAGS_NO_DELAY) == LIBIO_FLAGS_NO_DELAY ) {
200cb80: 80 88 60 01 btst 1, %g1
200cb84: 02 80 00 04 be 200cb94 <rtems_libio_to_fcntl_flags+0x3c>
200cb88: 80 88 62 00 btst 0x200, %g1
fcntl_flags |= O_NONBLOCK;
200cb8c: 05 00 00 10 sethi %hi(0x4000), %g2
200cb90: 90 12 00 02 or %o0, %g2, %o0
}
if ( (flags & LIBIO_FLAGS_APPEND) == LIBIO_FLAGS_APPEND ) {
200cb94: 32 80 00 02 bne,a 200cb9c <rtems_libio_to_fcntl_flags+0x44>
200cb98: 90 12 20 08 or %o0, 8, %o0
fcntl_flags |= O_APPEND;
}
if ( (flags & LIBIO_FLAGS_CREATE) == LIBIO_FLAGS_CREATE ) {
200cb9c: 80 88 64 00 btst 0x400, %g1
200cba0: 32 80 00 02 bne,a 200cba8 <rtems_libio_to_fcntl_flags+0x50>
200cba4: 90 12 22 00 or %o0, 0x200, %o0
fcntl_flags |= O_CREAT;
}
return fcntl_flags;
}
200cba8: 81 c3 e0 08 retl
02009160 <rtems_malloc_statistics_at_free>:
* size and thus we skip updating the statistics.
*/
static void rtems_malloc_statistics_at_free(
void *pointer
)
{
2009160: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uintptr_t size;
if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) {
2009164: 03 00 81 c2 sethi %hi(0x2070800), %g1 <== NOT EXECUTED
2009168: d0 00 62 00 ld [ %g1 + 0x200 ], %o0 ! 2070a00 <RTEMS_Malloc_Heap><== NOT EXECUTED
200916c: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2009170: 40 00 19 c1 call 200f874 <_Protected_heap_Get_block_size> <== NOT EXECUTED
2009174: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
2009178: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
200917c: 02 80 00 08 be 200919c <rtems_malloc_statistics_at_free+0x3c><== NOT EXECUTED
2009180: 03 00 81 d3 sethi %hi(0x2074c00), %g1 <== NOT EXECUTED
MSBUMP(lifetime_freed, size);
2009184: c8 07 bf fc ld [ %fp + -4 ], %g4 <== NOT EXECUTED
2009188: 82 10 60 80 or %g1, 0x80, %g1 <== NOT EXECUTED
200918c: c4 18 60 28 ldd [ %g1 + 0x28 ], %g2 <== NOT EXECUTED
2009190: 86 80 c0 04 addcc %g3, %g4, %g3 <== NOT EXECUTED
2009194: 84 40 a0 00 addx %g2, 0, %g2 <== NOT EXECUTED
2009198: c4 38 60 28 std %g2, [ %g1 + 0x28 ] <== NOT EXECUTED
200919c: 81 c7 e0 08 ret <== NOT EXECUTED
20091a0: 81 e8 00 00 restore <== NOT EXECUTED
020091a4 <rtems_malloc_statistics_at_malloc>:
}
static void rtems_malloc_statistics_at_malloc(
void *pointer
)
{
20091a4: 9d e3 bf 98 save %sp, -104, %sp
uintptr_t actual_size = 0;
uint32_t current_depth;
rtems_malloc_statistics_t *s = &rtems_malloc_statistics;
if ( !pointer )
20091a8: 80 a6 20 00 cmp %i0, 0
20091ac: 02 80 00 14 be 20091fc <rtems_malloc_statistics_at_malloc+0x58><== NEVER TAKEN
20091b0: 03 00 81 c2 sethi %hi(0x2070800), %g1
return;
_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
20091b4: d0 00 62 00 ld [ %g1 + 0x200 ], %o0 ! 2070a00 <RTEMS_Malloc_Heap>
static void rtems_malloc_statistics_at_malloc(
void *pointer
)
{
uintptr_t actual_size = 0;
20091b8: c0 27 bf fc clr [ %fp + -4 ]
rtems_malloc_statistics_t *s = &rtems_malloc_statistics;
if ( !pointer )
return;
_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
20091bc: 92 10 00 18 mov %i0, %o1
20091c0: 40 00 19 ad call 200f874 <_Protected_heap_Get_block_size>
20091c4: 94 07 bf fc add %fp, -4, %o2
MSBUMP(lifetime_allocated, actual_size);
20091c8: 03 00 81 d3 sethi %hi(0x2074c00), %g1
20091cc: d8 07 bf fc ld [ %fp + -4 ], %o4
20091d0: 82 10 60 80 or %g1, 0x80, %g1
20091d4: c4 18 60 20 ldd [ %g1 + 0x20 ], %g2
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
20091d8: da 00 60 2c ld [ %g1 + 0x2c ], %o5
if (current_depth > s->max_depth)
20091dc: c8 00 60 18 ld [ %g1 + 0x18 ], %g4
if ( !pointer )
return;
_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
MSBUMP(lifetime_allocated, actual_size);
20091e0: 86 80 c0 0c addcc %g3, %o4, %g3
20091e4: 84 40 a0 00 addx %g2, 0, %g2
20091e8: c4 38 60 20 std %g2, [ %g1 + 0x20 ]
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
20091ec: 84 20 c0 0d sub %g3, %o5, %g2
if (current_depth > s->max_depth)
20091f0: 80 a0 80 04 cmp %g2, %g4
20091f4: 38 80 00 02 bgu,a 20091fc <rtems_malloc_statistics_at_malloc+0x58><== ALWAYS TAKEN
20091f8: c4 20 60 18 st %g2, [ %g1 + 0x18 ]
20091fc: 81 c7 e0 08 ret
2009200: 81 e8 00 00 restore
0201134c <rtems_memalign>:
int rtems_memalign(
void **pointer,
size_t alignment,
size_t size
)
{
201134c: 9d e3 bf a0 save %sp, -96, %sp
void *return_this;
/*
* Parameter error checks
*/
if ( !pointer )
2011350: a0 96 20 00 orcc %i0, 0, %l0
2011354: 02 80 00 20 be 20113d4 <rtems_memalign+0x88>
2011358: 03 00 80 8d sethi %hi(0x2023400), %g1
*pointer = NULL;
/*
* Do not attempt to allocate memory if not in correct system state.
*/
if ( _System_state_Is_up(_System_state_Get()) &&
201135c: c2 00 60 f0 ld [ %g1 + 0xf0 ], %g1 ! 20234f0 <_System_state_Current>
2011360: 80 a0 60 03 cmp %g1, 3
2011364: 02 80 00 17 be 20113c0 <rtems_memalign+0x74> <== ALWAYS TAKEN
2011368: c0 24 00 00 clr [ %l0 ]
/*
*
* If some free's have been deferred, then do them now.
*/
malloc_deferred_frees_process();
201136c: 7f ff cb 27 call 2004008 <malloc_deferred_frees_process>
2011370: b0 10 20 0c mov 0xc, %i0
uintptr_t size,
uintptr_t alignment
)
{
return
_Protected_heap_Allocate_aligned_with_boundary( heap, size, alignment, 0 );
2011374: 03 00 80 89 sethi %hi(0x2022400), %g1
2011378: d0 00 62 b0 ld [ %g1 + 0x2b0 ], %o0 ! 20226b0 <RTEMS_Malloc_Heap>
201137c: 94 10 00 19 mov %i1, %o2
2011380: 92 10 00 1a mov %i2, %o1
2011384: 7f ff e1 cd call 2009ab8 <_Protected_heap_Allocate_aligned_with_boundary>
2011388: 96 10 20 00 clr %o3
return_this = _Protected_heap_Allocate_aligned(
RTEMS_Malloc_Heap,
size,
alignment
);
if ( !return_this )
201138c: b2 92 20 00 orcc %o0, 0, %i1
2011390: 02 80 00 12 be 20113d8 <rtems_memalign+0x8c>
2011394: 03 00 80 8b sethi %hi(0x2022c00), %g1
return ENOMEM;
/*
* If configured, update the more involved statistics
*/
if ( rtems_malloc_statistics_helpers )
2011398: c2 00 62 08 ld [ %g1 + 0x208 ], %g1 ! 2022e08 <rtems_malloc_statistics_helpers>
201139c: 80 a0 60 00 cmp %g1, 0
20113a0: 22 80 00 06 be,a 20113b8 <rtems_memalign+0x6c> <== ALWAYS TAKEN
20113a4: f2 24 00 00 st %i1, [ %l0 ]
(*rtems_malloc_statistics_helpers->at_malloc)(pointer);
20113a8: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
20113ac: 9f c0 40 00 call %g1 <== NOT EXECUTED
20113b0: 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;
20113b4: f2 24 00 00 st %i1, [ %l0 ] <== NOT EXECUTED
return 0;
20113b8: 81 c7 e0 08 ret
20113bc: 91 e8 20 00 restore %g0, 0, %o0
*pointer = NULL;
/*
* Do not attempt to allocate memory if not in correct system state.
*/
if ( _System_state_Is_up(_System_state_Get()) &&
20113c0: 7f ff ca f9 call 2003fa4 <malloc_is_system_state_OK>
20113c4: 01 00 00 00 nop
20113c8: 80 8a 20 ff btst 0xff, %o0
20113cc: 12 bf ff e8 bne 201136c <rtems_memalign+0x20> <== ALWAYS TAKEN
20113d0: 01 00 00 00 nop
if (rtems_malloc_boundary_helpers)
(*rtems_malloc_boundary_helpers->at_malloc)(return_this, size);
#endif
*pointer = return_this;
return 0;
20113d4: b0 10 20 16 mov 0x16, %i0 ! 16 <PROM_START+0x16>
}
20113d8: 81 c7 e0 08 ret
20113dc: 81 e8 00 00 restore
0200a1a0 <rtems_mkdir>:
return (retval);
}
int
rtems_mkdir(const char *path, mode_t mode)
{
200a1a0: 9d e3 bf 58 save %sp, -168, %sp <== NOT EXECUTED
int success = 0;
char *dup_path = strdup(path);
200a1a4: 40 01 1a c3 call 2050cb0 <strdup> <== NOT EXECUTED
200a1a8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (dup_path != NULL) {
200a1ac: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
200a1b0: 02 80 00 76 be 200a388 <rtems_mkdir+0x1e8> <== NOT EXECUTED
200a1b4: 01 00 00 00 nop <== NOT EXECUTED
char *p;
p = path;
oumask = 0;
retval = 1;
if (p[0] == '/') /* Skip leading '/'. */
200a1b8: c2 0c 00 00 ldub [ %l0 ], %g1 <== NOT EXECUTED
200a1bc: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
200a1c0: 85 38 60 18 sra %g1, 0x18, %g2 <== NOT EXECUTED
200a1c4: 80 a0 a0 2f cmp %g2, 0x2f <== NOT EXECUTED
200a1c8: 02 80 00 5a be 200a330 <rtems_mkdir+0x190> <== NOT EXECUTED
200a1cc: a2 10 00 10 mov %l0, %l1 <== NOT EXECUTED
++p;
for (first = 1, last = 0; !last ; ++p) {
if (p[0] == '\0')
200a1d0: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED
p = path;
oumask = 0;
retval = 1;
if (p[0] == '/') /* Skip leading '/'. */
++p;
200a1d4: a6 10 20 00 clr %l3 <== NOT EXECUTED
200a1d8: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
retval = 0;
break;
}
}
if (!last)
*p = '/';
200a1dc: a8 10 20 2f mov 0x2f, %l4 <== NOT EXECUTED
}
if (last)
(void)umask(oumask);
if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
if (errno == EEXIST || errno == EISDIR) {
if (stat(path, &sb) < 0) {
200a1e0: aa 07 bf b8 add %fp, -72, %l5 <== NOT EXECUTED
retval = 0;
break;
} else if (!S_ISDIR(sb.st_mode)) {
200a1e4: 2f 00 00 3c sethi %hi(0xf000), %l7 <== NOT EXECUTED
oumask = 0;
retval = 1;
if (p[0] == '/') /* Skip leading '/'. */
++p;
for (first = 1, last = 0; !last ; ++p) {
if (p[0] == '\0')
200a1e8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200a1ec: 02 80 00 0c be 200a21c <rtems_mkdir+0x7c> <== NOT EXECUTED
200a1f0: 2d 00 00 10 sethi %hi(0x4000), %l6 <== NOT EXECUTED
last = 1;
else if (p[0] != '/')
200a1f4: 80 a0 60 2f cmp %g1, 0x2f <== NOT EXECUTED
200a1f8: 22 80 00 4a be,a 200a320 <rtems_mkdir+0x180> <== NOT EXECUTED
200a1fc: c2 4c 60 01 ldsb [ %l1 + 1 ], %g1 <== NOT EXECUTED
p = path;
oumask = 0;
retval = 1;
if (p[0] == '/') /* Skip leading '/'. */
++p;
for (first = 1, last = 0; !last ; ++p) {
200a200: a2 04 60 01 inc %l1 <== NOT EXECUTED
200a204: c2 0c 40 00 ldub [ %l1 ], %g1 <== NOT EXECUTED
200a208: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
if (p[0] == '\0')
200a20c: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED
200a210: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200a214: 12 bf ff f9 bne 200a1f8 <rtems_mkdir+0x58> <== NOT EXECUTED
200a218: 80 a0 60 2f cmp %g1, 0x2f <== NOT EXECUTED
last = 1;
else if (p[0] != '/')
continue;
*p = '\0';
200a21c: c0 2c 40 00 clrb [ %l1 ] <== NOT EXECUTED
200a220: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
if (!last && p[1] == '\0')
last = 1;
if (first) {
200a224: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200a228: 12 80 00 37 bne 200a304 <rtems_mkdir+0x164> <== NOT EXECUTED
200a22c: 01 00 00 00 nop <== NOT EXECUTED
oumask = umask(0);
numask = oumask & ~(S_IWUSR | S_IXUSR);
(void)umask(numask);
first = 0;
}
if (last)
200a230: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
200a234: 12 80 00 13 bne 200a280 <rtems_mkdir+0xe0> <== NOT EXECUTED
200a238: 92 10 21 ff mov 0x1ff, %o1 <== NOT EXECUTED
(void)umask(oumask);
if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
200a23c: 7f ff fc 01 call 2009240 <mkdir> <== NOT EXECUTED
200a240: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200a244: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200a248: 06 80 00 16 bl 200a2a0 <rtems_mkdir+0x100> <== NOT EXECUTED
200a24c: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
} else {
retval = 0;
break;
}
}
if (!last)
200a250: 22 80 00 0a be,a 200a278 <rtems_mkdir+0xd8> <== NOT EXECUTED
200a254: e8 2c 40 00 stb %l4, [ %l1 ] <== NOT EXECUTED
if (p[0] == '\0')
last = 1;
else if (p[0] != '/')
continue;
*p = '\0';
if (!last && p[1] == '\0')
200a258: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
int success = 0;
char *dup_path = strdup(path);
if (dup_path != NULL) {
success = build(dup_path, mode);
free(dup_path);
200a25c: 7f ff f9 a0 call 20088dc <free> <== NOT EXECUTED
200a260: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
return success != 0 ? 0 : -1;
200a264: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
200a268: 02 80 00 48 be 200a388 <rtems_mkdir+0x1e8> <== NOT EXECUTED
200a26c: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
200a270: 81 c7 e0 08 ret <== NOT EXECUTED
200a274: 81 e8 00 00 restore <== NOT EXECUTED
retval = 0;
break;
}
}
if (!last)
*p = '/';
200a278: 10 bf ff e2 b 200a200 <rtems_mkdir+0x60> <== NOT EXECUTED
200a27c: 84 10 20 00 clr %g2 <== NOT EXECUTED
numask = oumask & ~(S_IWUSR | S_IXUSR);
(void)umask(numask);
first = 0;
}
if (last)
(void)umask(oumask);
200a280: 40 00 08 9b call 200c4ec <umask> <== NOT EXECUTED
200a284: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
200a288: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
200a28c: 7f ff fb ed call 2009240 <mkdir> <== NOT EXECUTED
200a290: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200a294: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200a298: 16 bf ff ee bge 200a250 <rtems_mkdir+0xb0> <== NOT EXECUTED
200a29c: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
if (errno == EEXIST || errno == EISDIR) {
200a2a0: 40 01 00 78 call 204a480 <__errno> <== NOT EXECUTED
200a2a4: 01 00 00 00 nop <== NOT EXECUTED
200a2a8: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
200a2ac: 80 a0 60 11 cmp %g1, 0x11 <== NOT EXECUTED
200a2b0: 02 80 00 08 be 200a2d0 <rtems_mkdir+0x130> <== NOT EXECUTED
200a2b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200a2b8: 40 01 00 72 call 204a480 <__errno> <== NOT EXECUTED
200a2bc: 01 00 00 00 nop <== NOT EXECUTED
200a2c0: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
200a2c4: 80 a0 60 15 cmp %g1, 0x15 <== NOT EXECUTED
200a2c8: 12 80 00 32 bne 200a390 <rtems_mkdir+0x1f0> <== NOT EXECUTED
200a2cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (stat(path, &sb) < 0) {
200a2d0: 40 00 00 34 call 200a3a0 <stat> <== NOT EXECUTED
200a2d4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
200a2d8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200a2dc: 06 80 00 2d bl 200a390 <rtems_mkdir+0x1f0> <== NOT EXECUTED
200a2e0: c2 07 bf c4 ld [ %fp + -60 ], %g1 <== NOT EXECUTED
retval = 0;
break;
} else if (!S_ISDIR(sb.st_mode)) {
200a2e4: 82 08 40 17 and %g1, %l7, %g1 <== NOT EXECUTED
200a2e8: 80 a0 40 16 cmp %g1, %l6 <== NOT EXECUTED
200a2ec: 12 80 00 15 bne 200a340 <rtems_mkdir+0x1a0> <== NOT EXECUTED
200a2f0: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
else
errno = ENOTDIR;
retval = 0;
break;
}
if (last)
200a2f4: 22 bf ff e1 be,a 200a278 <rtems_mkdir+0xd8> <== NOT EXECUTED
200a2f8: e8 2c 40 00 stb %l4, [ %l1 ] <== NOT EXECUTED
200a2fc: 10 bf ff d8 b 200a25c <rtems_mkdir+0xbc> <== NOT EXECUTED
200a300: a2 10 20 02 mov 2, %l1 <== NOT EXECUTED
* mkdir [-m mode] dir
*
* We change the user's umask and then restore it,
* instead of doing chmod's.
*/
oumask = umask(0);
200a304: 40 00 08 7a call 200c4ec <umask> <== NOT EXECUTED
200a308: 90 10 20 00 clr %o0 <== NOT EXECUTED
200a30c: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
numask = oumask & ~(S_IWUSR | S_IXUSR);
(void)umask(numask);
200a310: 40 00 08 77 call 200c4ec <umask> <== NOT EXECUTED
200a314: 90 0a 3f 3f and %o0, -193, %o0 <== NOT EXECUTED
first = 0;
}
if (last)
200a318: 10 bf ff c7 b 200a234 <rtems_mkdir+0x94> <== NOT EXECUTED
200a31c: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
for (first = 1, last = 0; !last ; ++p) {
if (p[0] == '\0')
last = 1;
else if (p[0] != '/')
continue;
*p = '\0';
200a320: c0 2c 40 00 clrb [ %l1 ] <== NOT EXECUTED
if (!last && p[1] == '\0')
200a324: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
200a328: 10 bf ff bf b 200a224 <rtems_mkdir+0x84> <== NOT EXECUTED
200a32c: a4 60 3f ff subx %g0, -1, %l2 <== NOT EXECUTED
p = path;
oumask = 0;
retval = 1;
if (p[0] == '/') /* Skip leading '/'. */
++p;
200a330: c2 0c 20 01 ldub [ %l0 + 1 ], %g1 <== NOT EXECUTED
200a334: a2 04 20 01 add %l0, 1, %l1 <== NOT EXECUTED
200a338: 10 bf ff a6 b 200a1d0 <rtems_mkdir+0x30> <== NOT EXECUTED
200a33c: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
if (errno == EEXIST || errno == EISDIR) {
if (stat(path, &sb) < 0) {
retval = 0;
break;
} else if (!S_ISDIR(sb.st_mode)) {
if (last)
200a340: 02 80 00 0a be 200a368 <rtems_mkdir+0x1c8> <== NOT EXECUTED
200a344: 01 00 00 00 nop <== NOT EXECUTED
errno = EEXIST;
200a348: 40 01 00 4e call 204a480 <__errno> <== NOT EXECUTED
200a34c: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
200a350: 82 10 20 11 mov 0x11, %g1 <== NOT EXECUTED
200a354: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
int success = 0;
char *dup_path = strdup(path);
if (dup_path != NULL) {
success = build(dup_path, mode);
free(dup_path);
200a358: 7f ff f9 61 call 20088dc <free> <== NOT EXECUTED
200a35c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
200a360: 81 c7 e0 08 ret <== NOT EXECUTED
200a364: 81 e8 00 00 restore <== NOT EXECUTED
break;
} else if (!S_ISDIR(sb.st_mode)) {
if (last)
errno = EEXIST;
else
errno = ENOTDIR;
200a368: 40 01 00 46 call 204a480 <__errno> <== NOT EXECUTED
200a36c: 01 00 00 00 nop <== NOT EXECUTED
200a370: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> <== NOT EXECUTED
200a374: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
if (!last)
*p = '/';
}
if (!first && !last)
(void)umask(oumask);
200a378: 40 00 08 5d call 200c4ec <umask> <== NOT EXECUTED
200a37c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
int success = 0;
char *dup_path = strdup(path);
if (dup_path != NULL) {
success = build(dup_path, mode);
free(dup_path);
200a380: 7f ff f9 57 call 20088dc <free> <== NOT EXECUTED
200a384: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
return success != 0 ? 0 : -1;
}
200a388: 81 c7 e0 08 ret <== NOT EXECUTED
200a38c: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
}
}
if (!last)
*p = '/';
}
if (!first && !last)
200a390: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
200a394: 02 bf ff f9 be 200a378 <rtems_mkdir+0x1d8> <== NOT EXECUTED
200a398: 01 00 00 00 nop <== NOT EXECUTED
200a39c: 30 bf ff f9 b,a 200a380 <rtems_mkdir+0x1e0> <== NOT EXECUTED
02023a08 <rtems_nvdisk_crc16_gen_factors>:
* @relval RTEMS_SUCCESSFUL The table was generated.
* @retval RTEMS_NO_MEMORY The table could not be allocated from the heap.
*/
rtems_status_code
rtems_nvdisk_crc16_gen_factors (uint16_t pattern)
{
2023a08: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
uint32_t b;
rtems_nvdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);
2023a0c: 7f ff 95 95 call 2009060 <malloc> <== NOT EXECUTED
2023a10: 90 10 22 00 mov 0x200, %o0 <== NOT EXECUTED
2023a14: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
2023a18: d0 20 60 64 st %o0, [ %g1 + 0x64 ] ! 2074864 <rtems_nvdisk_crc16_factor><== NOT EXECUTED
* @relval RTEMS_SUCCESSFUL The table was generated.
* @retval RTEMS_NO_MEMORY The table could not be allocated from the heap.
*/
rtems_status_code
rtems_nvdisk_crc16_gen_factors (uint16_t pattern)
{
2023a1c: 9a 10 00 18 mov %i0, %o5 <== NOT EXECUTED
uint32_t b;
rtems_nvdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);
if (!rtems_nvdisk_crc16_factor)
2023a20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023a24: 88 10 20 00 clr %g4 <== NOT EXECUTED
2023a28: 02 80 00 14 be 2023a78 <rtems_nvdisk_crc16_gen_factors+0x70><== NOT EXECUTED
2023a2c: 82 10 20 1a mov 0x1a, %g1 <== NOT EXECUTED
2023a30: 82 10 00 04 mov %g4, %g1 <== NOT EXECUTED
2023a34: 84 10 20 07 mov 7, %g2 <== NOT EXECUTED
for (b = 0; b < 256; b++)
{
uint32_t i;
uint16_t v = b;
for (i = 8; i--;)
v = v & 1 ? (v >> 1) ^ pattern : v >> 1;
2023a38: 86 08 60 01 and %g1, 1, %g3 <== NOT EXECUTED
2023a3c: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
2023a40: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2023a44: 87 30 60 11 srl %g1, 0x11, %g3 <== NOT EXECUTED
2023a48: 02 80 00 03 be 2023a54 <rtems_nvdisk_crc16_gen_factors+0x4c><== NOT EXECUTED
2023a4c: 82 10 00 03 mov %g3, %g1 <== NOT EXECUTED
2023a50: 82 18 c0 0d xor %g3, %o5, %g1 <== NOT EXECUTED
for (b = 0; b < 256; b++)
{
uint32_t i;
uint16_t v = b;
for (i = 8; i--;)
2023a54: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2023a58: 12 bf ff f8 bne 2023a38 <rtems_nvdisk_crc16_gen_factors+0x30><== NOT EXECUTED
2023a5c: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
v = v & 1 ? (v >> 1) ^ pattern : v >> 1;
rtems_nvdisk_crc16_factor[b] = v & 0xffff;
2023a60: 85 29 20 01 sll %g4, 1, %g2 <== NOT EXECUTED
rtems_nvdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);
if (!rtems_nvdisk_crc16_factor)
return RTEMS_NO_MEMORY;
for (b = 0; b < 256; b++)
2023a64: 88 01 20 01 inc %g4 <== NOT EXECUTED
2023a68: 80 a1 21 00 cmp %g4, 0x100 <== NOT EXECUTED
2023a6c: 12 bf ff f1 bne 2023a30 <rtems_nvdisk_crc16_gen_factors+0x28><== NOT EXECUTED
2023a70: c2 32 00 02 sth %g1, [ %o0 + %g2 ] <== NOT EXECUTED
2023a74: 82 10 20 00 clr %g1 <== NOT EXECUTED
for (i = 8; i--;)
v = v & 1 ? (v >> 1) ^ pattern : v >> 1;
rtems_nvdisk_crc16_factor[b] = v & 0xffff;
}
return RTEMS_SUCCESSFUL;
}
2023a78: 81 c7 e0 08 ret <== NOT EXECUTED
2023a7c: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
02023298 <rtems_nvdisk_error>:
* @param ... The arguments for the format text.
* @return int The number of bytes written to the output.
*/
static int
rtems_nvdisk_error (const char *format, ...)
{
2023298: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int ret;
va_list args;
va_start (args, format);
fprintf (stderr, "nvdisk:error:");
202329c: 21 00 81 c5 sethi %hi(0x2071400), %l0 <== NOT EXECUTED
20232a0: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 ! 2071608 <_impure_ptr><== NOT EXECUTED
static int
rtems_nvdisk_error (const char *format, ...)
{
int ret;
va_list args;
va_start (args, format);
20232a4: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED
20232a8: f4 27 a0 4c st %i2, [ %fp + 0x4c ] <== NOT EXECUTED
20232ac: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
20232b0: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
20232b4: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
fprintf (stderr, "nvdisk:error:");
20232b8: d6 00 60 0c ld [ %g1 + 0xc ], %o3 <== NOT EXECUTED
static int
rtems_nvdisk_error (const char *format, ...)
{
int ret;
va_list args;
va_start (args, format);
20232bc: 82 07 a0 48 add %fp, 0x48, %g1 <== NOT EXECUTED
fprintf (stderr, "nvdisk:error:");
20232c0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
static int
rtems_nvdisk_error (const char *format, ...)
{
int ret;
va_list args;
va_start (args, format);
20232c4: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
fprintf (stderr, "nvdisk:error:");
20232c8: 94 10 20 0d mov 0xd, %o2 <== NOT EXECUTED
20232cc: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
20232d0: 40 00 a3 f4 call 204c2a0 <fwrite> <== NOT EXECUTED
20232d4: 90 12 21 08 or %o0, 0x108, %o0 ! 2069908 <msdos_ops+0x48> <== NOT EXECUTED
ret = vfprintf (stderr, format, args);
20232d8: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 <== NOT EXECUTED
20232dc: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
20232e0: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
20232e4: 40 00 d8 c8 call 2059604 <vfprintf> <== NOT EXECUTED
20232e8: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
fprintf (stderr, "\n");
20232ec: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 <== NOT EXECUTED
{
int ret;
va_list args;
va_start (args, format);
fprintf (stderr, "nvdisk:error:");
ret = vfprintf (stderr, format, args);
20232f0: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
fprintf (stderr, "\n");
20232f4: d2 00 60 0c ld [ %g1 + 0xc ], %o1 <== NOT EXECUTED
20232f8: 40 00 9f 2c call 204afa8 <fputc> <== NOT EXECUTED
20232fc: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED
fflush (stderr);
2023300: c2 04 22 08 ld [ %l0 + 0x208 ], %g1 <== NOT EXECUTED
2023304: 40 00 9d 69 call 204a8a8 <fflush> <== NOT EXECUTED
2023308: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
va_end (args);
return ret;
}
202330c: 81 c7 e0 08 ret <== NOT EXECUTED
2023310: 81 e8 00 00 restore <== NOT EXECUTED
02023314 <rtems_nvdisk_get_device>:
/**
* Map a block to a device.
*/
static rtems_nvdisk_device_ctl*
rtems_nvdisk_get_device (rtems_nvdisk* nvd, uint32_t block)
{
2023314: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
uint32_t device;
if (block >= nvd->block_count)
2023318: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
202331c: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
2023320: 08 80 00 1d bleu 2023394 <rtems_nvdisk_get_device+0x80> <== NOT EXECUTED
2023324: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
{
rtems_nvdisk_error ("read-block: bad block: %d", block);
return NULL;
}
for (device = 0; device < nvd->device_count; device++)
2023328: c8 06 20 18 ld [ %i0 + 0x18 ], %g4 <== NOT EXECUTED
202332c: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
2023330: 02 80 00 13 be 202337c <rtems_nvdisk_get_device+0x68> <== NOT EXECUTED
2023334: 84 10 20 00 clr %g2 <== NOT EXECUTED
uint32_t device;
if (block >= nvd->block_count)
{
rtems_nvdisk_error ("read-block: bad block: %d", block);
return NULL;
2023338: c2 06 20 14 ld [ %i0 + 0x14 ], %g1 <== NOT EXECUTED
}
for (device = 0; device < nvd->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
if ((block >= dc->block_base) &&
202333c: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
{
rtems_nvdisk_error ("read-block: bad block: %d", block);
return NULL;
}
for (device = 0; device < nvd->device_count; device++)
2023340: 84 00 a0 01 inc %g2 <== NOT EXECUTED
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
if ((block >= dc->block_base) &&
2023344: 80 a6 40 03 cmp %i1, %g3 <== NOT EXECUTED
2023348: 0a 80 00 09 bcs 202336c <rtems_nvdisk_get_device+0x58> <== NOT EXECUTED
202334c: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
2023350: d8 00 60 04 ld [ %g1 + 4 ], %o4 <== NOT EXECUTED
2023354: da 00 60 08 ld [ %g1 + 8 ], %o5 <== NOT EXECUTED
2023358: 86 00 c0 0c add %g3, %o4, %g3 <== NOT EXECUTED
202335c: 86 20 c0 0d sub %g3, %o5, %g3 <== NOT EXECUTED
2023360: 80 a6 40 03 cmp %i1, %g3 <== NOT EXECUTED
2023364: 0a 80 00 10 bcs 20233a4 <rtems_nvdisk_get_device+0x90> <== NOT EXECUTED
2023368: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_nvdisk_error ("read-block: bad block: %d", block);
return NULL;
}
for (device = 0; device < nvd->device_count; device++)
202336c: 80 a0 80 04 cmp %g2, %g4 <== NOT EXECUTED
2023370: 0a bf ff f3 bcs 202333c <rtems_nvdisk_get_device+0x28> <== NOT EXECUTED
2023374: 82 00 60 14 add %g1, 0x14, %g1 <== NOT EXECUTED
if ((block >= dc->block_base) &&
(block < (dc->block_base + dc->pages - dc->pages_desc)))
return dc;
}
rtems_nvdisk_error ("map-block:%d: no device/page map found", block);
2023378: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
202337c: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2023380: b0 10 20 00 clr %i0 <== NOT EXECUTED
2023384: 7f ff ff c5 call 2023298 <rtems_nvdisk_error> <== NOT EXECUTED
2023388: 90 12 21 38 or %o0, 0x138, %o0 <== NOT EXECUTED
return NULL;
}
202338c: 81 c7 e0 08 ret <== NOT EXECUTED
2023390: 81 e8 00 00 restore <== NOT EXECUTED
{
uint32_t device;
if (block >= nvd->block_count)
{
rtems_nvdisk_error ("read-block: bad block: %d", block);
2023394: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2023398: b0 10 20 00 clr %i0 <== NOT EXECUTED
202339c: 7f ff ff bf call 2023298 <rtems_nvdisk_error> <== NOT EXECUTED
20233a0: 90 12 21 18 or %o0, 0x118, %o0 <== NOT EXECUTED
return NULL;
20233a4: 81 c7 e0 08 ret <== NOT EXECUTED
20233a8: 81 e8 00 00 restore <== NOT EXECUTED
02023a80 <rtems_nvdisk_initialize>:
*/
rtems_device_driver
rtems_nvdisk_initialize (rtems_device_major_number major,
rtems_device_minor_number minor,
void* arg __attribute__((unused)))
{
2023a80: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
const rtems_nvdisk_config* c = rtems_nvdisk_configuration;
rtems_nvdisk* nvd;
rtems_status_code sc;
sc = rtems_disk_io_initialize ();
2023a84: 7f ff 8d 6f call 2007040 <rtems_disk_io_initialize> <== NOT EXECUTED
2023a88: a8 10 00 18 mov %i0, %l4 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2023a8c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023a90: 02 80 00 04 be 2023aa0 <rtems_nvdisk_initialize+0x20> <== NOT EXECUTED
2023a94: b6 10 00 08 mov %o0, %i3 <== NOT EXECUTED
}
rtems_nvdisk_count = rtems_nvdisk_configuration_size;
return RTEMS_SUCCESSFUL;
}
2023a98: 81 c7 e0 08 ret <== NOT EXECUTED
2023a9c: 91 e8 00 1b restore %g0, %i3, %o0 <== NOT EXECUTED
sc = rtems_disk_io_initialize ();
if (sc != RTEMS_SUCCESSFUL)
return sc;
sc = rtems_nvdisk_crc16_gen_factors (0x8408);
2023aa0: 11 00 00 21 sethi %hi(0x8400), %o0 <== NOT EXECUTED
2023aa4: 7f ff ff d9 call 2023a08 <rtems_nvdisk_crc16_gen_factors> <== NOT EXECUTED
2023aa8: 90 12 20 08 or %o0, 8, %o0 ! 8408 <PROM_START+0x8408> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2023aac: b6 92 20 00 orcc %o0, 0, %i3 <== NOT EXECUTED
2023ab0: 12 bf ff fa bne 2023a98 <rtems_nvdisk_initialize+0x18> <== NOT EXECUTED
2023ab4: 39 00 81 c2 sethi %hi(0x2070800), %i4 <== NOT EXECUTED
return sc;
rtems_nvdisks = calloc (rtems_nvdisk_configuration_size,
2023ab8: d0 07 23 4c ld [ %i4 + 0x34c ], %o0 ! 2070b4c <rtems_nvdisk_configuration_size><== NOT EXECUTED
2023abc: 7f ff 91 e6 call 2008254 <calloc> <== NOT EXECUTED
2023ac0: 92 10 20 28 mov 0x28, %o1 <== NOT EXECUTED
2023ac4: 05 00 81 d2 sethi %hi(0x2074800), %g2 <== NOT EXECUTED
sizeof (rtems_nvdisk));
if (!rtems_nvdisks)
2023ac8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023acc: 02 80 00 76 be 2023ca4 <rtems_nvdisk_initialize+0x224> <== NOT EXECUTED
2023ad0: d0 20 a0 5c st %o0, [ %g2 + 0x5c ] <== NOT EXECUTED
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
2023ad4: c2 07 23 4c ld [ %i4 + 0x34c ], %g1 <== NOT EXECUTED
2023ad8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023adc: 02 80 00 74 be 2023cac <rtems_nvdisk_initialize+0x22c> <== NOT EXECUTED
2023ae0: 23 00 81 95 sethi %hi(0x2065400), %l1 <== NOT EXECUTED
{
char name[] = RTEMS_NVDISK_DEVICE_BASE_NAME "a";
2023ae4: 2b 00 00 18 sethi %hi(0x6000), %l5 <== NOT EXECUTED
}
nvd->block_count = blocks;
nvd->device_count = c->device_count;
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
2023ae8: 2f 00 80 8c sethi %hi(0x2023000), %l7 <== NOT EXECUTED
{
rtems_nvdisk_error ("disk create phy failed");
return sc;
}
sc = rtems_semaphore_create (rtems_build_name ('N', 'V', 'D', 'K'), 1,
2023aec: 3b 13 95 91 sethi %hi(0x4e564400), %i5 <== NOT EXECUTED
sizeof (rtems_nvdisk));
if (!rtems_nvdisks)
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
2023af0: b8 17 23 4c or %i4, 0x34c, %i4 <== NOT EXECUTED
2023af4: a2 14 62 84 or %l1, 0x284, %l1 <== NOT EXECUTED
{
char name[] = RTEMS_NVDISK_DEVICE_BASE_NAME "a";
2023af8: aa 15 61 00 or %l5, 0x100, %l5 <== NOT EXECUTED
}
nvd->block_count = blocks;
nvd->device_count = c->device_count;
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
2023afc: ae 15 e3 ac or %l7, 0x3ac, %l7 <== NOT EXECUTED
{
rtems_nvdisk_error ("disk create phy failed");
return sc;
}
sc = rtems_semaphore_create (rtems_build_name ('N', 'V', 'D', 'K'), 1,
2023b00: ba 17 60 4b or %i5, 0x4b, %i5 <== NOT EXECUTED
sizeof (rtems_nvdisk));
if (!rtems_nvdisks)
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
2023b04: a6 10 20 00 clr %l3 <== NOT EXECUTED
2023b08: a4 10 20 00 clr %l2 <== NOT EXECUTED
}
nvd->block_count = blocks;
nvd->device_count = c->device_count;
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
2023b0c: ac 07 bf e8 add %fp, -24, %l6 <== NOT EXECUTED
if (!rtems_nvdisks)
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
{
char name[] = RTEMS_NVDISK_DEVICE_BASE_NAME "a";
2023b10: ea 37 bf f0 sth %l5, [ %fp + -16 ] <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
2023b14: e8 27 bf f8 st %l4, [ %fp + -8 ] <== NOT EXECUTED
temp.__overlay.minor = _minor;
2023b18: e4 27 bf fc st %l2, [ %fp + -4 ] <== NOT EXECUTED
uint32_t device;
uint32_t blocks = 0;
nvd = &rtems_nvdisks[minor];
name [sizeof(RTEMS_NVDISK_DEVICE_BASE_NAME)] += minor;
2023b1c: e4 2f bf f1 stb %l2, [ %fp + -15 ] <== NOT EXECUTED
if (!rtems_nvdisks)
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
{
char name[] = RTEMS_NVDISK_DEVICE_BASE_NAME "a";
2023b20: 05 0b d9 19 sethi %hi(0x2f646400), %g2 <== NOT EXECUTED
2023b24: 07 0b db 9d sethi %hi(0x2f6e7400), %g3 <== NOT EXECUTED
2023b28: 84 10 a1 76 or %g2, 0x176, %g2 <== NOT EXECUTED
2023b2c: 86 10 e2 64 or %g3, 0x264, %g3 <== NOT EXECUTED
2023b30: c4 3f bf e8 std %g2, [ %fp + -24 ] <== NOT EXECUTED
dev_t dev = rtems_filesystem_make_dev_t (major, minor);
uint32_t device;
uint32_t blocks = 0;
nvd = &rtems_nvdisks[minor];
2023b34: a0 02 00 13 add %o0, %l3, %l0 <== NOT EXECUTED
return temp.device;
2023b38: c4 1f bf f8 ldd [ %fp + -8 ], %g2 <== NOT EXECUTED
name [sizeof(RTEMS_NVDISK_DEVICE_BASE_NAME)] += minor;
nvd->major = major;
2023b3c: e8 22 00 13 st %l4, [ %o0 + %l3 ] <== NOT EXECUTED
nvd->minor = minor;
2023b40: e4 24 20 04 st %l2, [ %l0 + 4 ] <== NOT EXECUTED
nvd->flags = c->flags;
2023b44: c2 04 60 0c ld [ %l1 + 0xc ], %g1 <== NOT EXECUTED
2023b48: c4 3f bf e0 std %g2, [ %fp + -32 ] <== NOT EXECUTED
2023b4c: c2 24 20 08 st %g1, [ %l0 + 8 ] <== NOT EXECUTED
nvd->block_size = c->block_size;
2023b50: c2 04 40 00 ld [ %l1 ], %g1 <== NOT EXECUTED
nvd->info_level = c->info_level;
nvd->devices = calloc (c->device_count, sizeof (rtems_nvdisk_device_ctl));
2023b54: 92 10 20 14 mov 0x14, %o1 <== NOT EXECUTED
name [sizeof(RTEMS_NVDISK_DEVICE_BASE_NAME)] += minor;
nvd->major = major;
nvd->minor = minor;
nvd->flags = c->flags;
nvd->block_size = c->block_size;
2023b58: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
nvd->info_level = c->info_level;
2023b5c: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED
2023b60: c2 24 20 24 st %g1, [ %l0 + 0x24 ] <== NOT EXECUTED
nvd->devices = calloc (c->device_count, sizeof (rtems_nvdisk_device_ctl));
2023b64: 7f ff 91 bc call 2008254 <calloc> <== NOT EXECUTED
2023b68: d0 04 60 04 ld [ %l1 + 4 ], %o0 <== NOT EXECUTED
2023b6c: d0 24 20 14 st %o0, [ %l0 + 0x14 ] <== NOT EXECUTED
if (!nvd->devices)
2023b70: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023b74: 02 80 00 4c be 2023ca4 <rtems_nvdisk_initialize+0x224> <== NOT EXECUTED
2023b78: b2 10 00 08 mov %o0, %i1 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
for (device = 0; device < c->device_count; device++)
2023b7c: c2 04 60 04 ld [ %l1 + 4 ], %g1 <== NOT EXECUTED
2023b80: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2023b84: 02 80 00 2a be 2023c2c <rtems_nvdisk_initialize+0x1ac> <== NOT EXECUTED
2023b88: b6 10 20 00 clr %i3 <== NOT EXECUTED
2023b8c: b0 10 20 00 clr %i0 <== NOT EXECUTED
2023b90: 10 80 00 03 b 2023b9c <rtems_nvdisk_initialize+0x11c> <== NOT EXECUTED
2023b94: b4 10 20 00 clr %i2 <== NOT EXECUTED
2023b98: f2 04 20 14 ld [ %l0 + 0x14 ], %i1 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_pages_in_device (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
return dd->size / nvd->block_size;
2023b9c: c4 04 60 08 ld [ %l1 + 8 ], %g2 <== NOT EXECUTED
for (device = 0; device < c->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
dc->device = device;
2023ba0: f4 26 40 18 st %i2, [ %i1 + %i0 ] <== NOT EXECUTED
2023ba4: 83 2e a0 04 sll %i2, 4, %g1 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_pages_in_device (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
return dd->size / nvd->block_size;
2023ba8: d2 04 20 0c ld [ %l0 + 0xc ], %o1 <== NOT EXECUTED
2023bac: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2023bb0: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
2023bb4: 40 00 fb 74 call 2062984 <.udiv> <== NOT EXECUTED
2023bb8: c2 27 bf d4 st %g1, [ %fp + -44 ] <== NOT EXECUTED
rtems_nvdisk_page_desc_pages (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
uint32_t pages = rtems_nvdisk_pages_in_device (nvd, dd);
uint32_t bytes = pages * sizeof (uint16_t);
return ((bytes - 1) / nvd->block_size) + 1;
2023bbc: c2 07 bf d4 ld [ %fp + -44 ], %g1 <== NOT EXECUTED
if (!nvd->devices)
return RTEMS_NO_MEMORY;
for (device = 0; device < c->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
2023bc0: b2 06 40 18 add %i1, %i0, %i1 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_pages_in_device (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
return dd->size / nvd->block_size;
2023bc4: 84 10 00 08 mov %o0, %g2 <== NOT EXECUTED
for (device = 0; device < c->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
2023bc8: d0 26 60 04 st %o0, [ %i1 + 4 ] <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_pages_in_device (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
return dd->size / nvd->block_size;
2023bcc: c6 04 20 0c ld [ %l0 + 0xc ], %g3 <== NOT EXECUTED
rtems_nvdisk_page_desc_pages (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
uint32_t pages = rtems_nvdisk_pages_in_device (nvd, dd);
uint32_t bytes = pages * sizeof (uint16_t);
return ((bytes - 1) / nvd->block_size) + 1;
2023bd0: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
2023bd4: 92 10 00 03 mov %g3, %o1 <== NOT EXECUTED
2023bd8: c4 27 bf d8 st %g2, [ %fp + -40 ] <== NOT EXECUTED
2023bdc: 40 00 fb 6a call 2062984 <.udiv> <== NOT EXECUTED
2023be0: c6 27 bf dc st %g3, [ %fp + -36 ] <== NOT EXECUTED
2023be4: c6 07 bf dc ld [ %fp + -36 ], %g3 <== NOT EXECUTED
2023be8: 91 2a 20 01 sll %o0, 1, %o0 <== NOT EXECUTED
2023bec: 92 10 00 03 mov %g3, %o1 <== NOT EXECUTED
2023bf0: 40 00 fb 65 call 2062984 <.udiv> <== NOT EXECUTED
2023bf4: 90 02 3f ff add %o0, -1, %o0 <== NOT EXECUTED
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
blocks += dc->pages - dc->pages_desc;
dc->descriptor = &c->devices[device];
2023bf8: c2 07 bf d4 ld [ %fp + -44 ], %g1 <== NOT EXECUTED
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
2023bfc: f6 26 60 0c st %i3, [ %i1 + 0xc ] <== NOT EXECUTED
rtems_nvdisk_page_desc_pages (const rtems_nvdisk* nvd,
const rtems_nvdisk_device_desc* dd)
{
uint32_t pages = rtems_nvdisk_pages_in_device (nvd, dd);
uint32_t bytes = pages * sizeof (uint16_t);
return ((bytes - 1) / nvd->block_size) + 1;
2023c00: 90 02 20 01 inc %o0 <== NOT EXECUTED
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
blocks += dc->pages - dc->pages_desc;
2023c04: c4 07 bf d8 ld [ %fp + -40 ], %g2 <== NOT EXECUTED
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
2023c08: d0 26 60 08 st %o0, [ %i1 + 8 ] <== NOT EXECUTED
nvd->devices = calloc (c->device_count, sizeof (rtems_nvdisk_device_ctl));
if (!nvd->devices)
return RTEMS_NO_MEMORY;
for (device = 0; device < c->device_count; device++)
2023c0c: c6 04 60 04 ld [ %l1 + 4 ], %g3 <== NOT EXECUTED
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
blocks += dc->pages - dc->pages_desc;
dc->descriptor = &c->devices[device];
2023c10: c2 26 60 10 st %g1, [ %i1 + 0x10 ] <== NOT EXECUTED
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
blocks += dc->pages - dc->pages_desc;
2023c14: 84 20 80 08 sub %g2, %o0, %g2 <== NOT EXECUTED
nvd->devices = calloc (c->device_count, sizeof (rtems_nvdisk_device_ctl));
if (!nvd->devices)
return RTEMS_NO_MEMORY;
for (device = 0; device < c->device_count; device++)
2023c18: b4 06 a0 01 inc %i2 <== NOT EXECUTED
dc->device = device;
dc->pages = rtems_nvdisk_pages_in_device (nvd, &c->devices[device]);
dc->pages_desc = rtems_nvdisk_page_desc_pages (nvd, &c->devices[device]);
dc->block_base = blocks;
blocks += dc->pages - dc->pages_desc;
2023c1c: b6 06 c0 02 add %i3, %g2, %i3 <== NOT EXECUTED
nvd->devices = calloc (c->device_count, sizeof (rtems_nvdisk_device_ctl));
if (!nvd->devices)
return RTEMS_NO_MEMORY;
for (device = 0; device < c->device_count; device++)
2023c20: 80 a0 c0 1a cmp %g3, %i2 <== NOT EXECUTED
2023c24: 18 bf ff dd bgu 2023b98 <rtems_nvdisk_initialize+0x118> <== NOT EXECUTED
2023c28: b0 06 20 14 add %i0, 0x14, %i0 <== NOT EXECUTED
blocks += dc->pages - dc->pages_desc;
dc->descriptor = &c->devices[device];
}
nvd->block_count = blocks;
2023c2c: f6 24 20 10 st %i3, [ %l0 + 0x10 ] <== NOT EXECUTED
nvd->device_count = c->device_count;
2023c30: c2 04 60 04 ld [ %l1 + 4 ], %g1 <== NOT EXECUTED
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
2023c34: d0 1f bf e0 ldd [ %fp + -32 ], %o0 <== NOT EXECUTED
dc->descriptor = &c->devices[device];
}
nvd->block_count = blocks;
nvd->device_count = c->device_count;
2023c38: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
2023c3c: d4 04 40 00 ld [ %l1 ], %o2 <== NOT EXECUTED
2023c40: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2023c44: ec 23 a0 5c st %l6, [ %sp + 0x5c ] <== NOT EXECUTED
2023c48: 98 10 00 17 mov %l7, %o4 <== NOT EXECUTED
2023c4c: 7f ff 8e da call 20077b4 <rtems_disk_create_phys> <== NOT EXECUTED
2023c50: 9a 10 20 00 clr %o5 <== NOT EXECUTED
rtems_nvdisk_ioctl, NULL, name);
if (sc != RTEMS_SUCCESSFUL)
2023c54: b6 92 20 00 orcc %o0, 0, %i3 <== NOT EXECUTED
2023c58: 12 80 00 1d bne 2023ccc <rtems_nvdisk_initialize+0x24c> <== NOT EXECUTED
2023c5c: 98 04 20 20 add %l0, 0x20, %o4 <== NOT EXECUTED
{
rtems_nvdisk_error ("disk create phy failed");
return sc;
}
sc = rtems_semaphore_create (rtems_build_name ('N', 'V', 'D', 'K'), 1,
2023c60: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
2023c64: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2023c68: 94 10 20 54 mov 0x54, %o2 <== NOT EXECUTED
2023c6c: 7f ff a5 b9 call 200d350 <rtems_semaphore_create> <== NOT EXECUTED
2023c70: 96 10 20 00 clr %o3 <== NOT EXECUTED
RTEMS_PRIORITY | RTEMS_BINARY_SEMAPHORE |
RTEMS_INHERIT_PRIORITY, 0, &nvd->lock);
if (sc != RTEMS_SUCCESSFUL)
2023c74: b6 92 20 00 orcc %o0, 0, %i3 <== NOT EXECUTED
2023c78: 12 80 00 11 bne 2023cbc <rtems_nvdisk_initialize+0x23c> <== NOT EXECUTED
2023c7c: a4 04 a0 01 inc %l2 <== NOT EXECUTED
sizeof (rtems_nvdisk));
if (!rtems_nvdisks)
return RTEMS_NO_MEMORY;
for (minor = 0; minor < rtems_nvdisk_configuration_size; minor++, c++)
2023c80: c2 07 00 00 ld [ %i4 ], %g1 <== NOT EXECUTED
2023c84: 80 a0 40 12 cmp %g1, %l2 <== NOT EXECUTED
2023c88: 08 80 00 09 bleu 2023cac <rtems_nvdisk_initialize+0x22c> <== NOT EXECUTED
2023c8c: a6 04 e0 28 add %l3, 0x28, %l3 <== NOT EXECUTED
2023c90: 07 00 81 d2 sethi %hi(0x2074800), %g3 <== NOT EXECUTED
2023c94: a2 04 60 14 add %l1, 0x14, %l1 <== NOT EXECUTED
2023c98: 86 10 e0 5c or %g3, 0x5c, %g3 <== NOT EXECUTED
2023c9c: 10 bf ff 9d b 2023b10 <rtems_nvdisk_initialize+0x90> <== NOT EXECUTED
2023ca0: d0 00 c0 00 ld [ %g3 ], %o0 <== NOT EXECUTED
}
}
rtems_nvdisk_count = rtems_nvdisk_configuration_size;
return RTEMS_SUCCESSFUL;
2023ca4: 10 bf ff 7d b 2023a98 <rtems_nvdisk_initialize+0x18> <== NOT EXECUTED
2023ca8: b6 10 20 1a mov 0x1a, %i3 <== NOT EXECUTED
rtems_nvdisk_error ("disk lock create failed");
return sc;
}
}
rtems_nvdisk_count = rtems_nvdisk_configuration_size;
2023cac: 05 00 81 d2 sethi %hi(0x2074800), %g2 <== NOT EXECUTED
2023cb0: b6 10 20 00 clr %i3 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
2023cb4: 10 bf ff 79 b 2023a98 <rtems_nvdisk_initialize+0x18> <== NOT EXECUTED
2023cb8: c2 20 a0 60 st %g1, [ %g2 + 0x60 ] <== NOT EXECUTED
sc = rtems_semaphore_create (rtems_build_name ('N', 'V', 'D', 'K'), 1,
RTEMS_PRIORITY | RTEMS_BINARY_SEMAPHORE |
RTEMS_INHERIT_PRIORITY, 0, &nvd->lock);
if (sc != RTEMS_SUCCESSFUL)
{
rtems_nvdisk_error ("disk lock create failed");
2023cbc: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2023cc0: 7f ff fd 76 call 2023298 <rtems_nvdisk_error> <== NOT EXECUTED
2023cc4: 90 12 21 b0 or %o0, 0x1b0, %o0 ! 20699b0 <msdos_ops+0xf0> <== NOT EXECUTED
return sc;
2023cc8: 30 bf ff 74 b,a 2023a98 <rtems_nvdisk_initialize+0x18> <== NOT EXECUTED
sc = rtems_disk_create_phys(dev, c->block_size, blocks,
rtems_nvdisk_ioctl, NULL, name);
if (sc != RTEMS_SUCCESSFUL)
{
rtems_nvdisk_error ("disk create phy failed");
2023ccc: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2023cd0: 7f ff fd 72 call 2023298 <rtems_nvdisk_error> <== NOT EXECUTED
2023cd4: 90 12 21 98 or %o0, 0x198, %o0 ! 2069998 <msdos_ops+0xd8> <== NOT EXECUTED
return sc;
2023cd8: 30 bf ff 70 b,a 2023a98 <rtems_nvdisk_initialize+0x18> <== NOT EXECUTED
020233ac <rtems_nvdisk_ioctl>:
* @param argp IOCTL argument.
* @retval The IOCTL return value
*/
static int
rtems_nvdisk_ioctl (rtems_disk_device *dd, uint32_t req, void* argp)
{
20233ac: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
dev_t dev = rtems_disk_get_device_identifier (dd);
rtems_device_minor_number minor = rtems_filesystem_dev_minor_t (dev);
rtems_blkdev_request* r = argp;
rtems_status_code sc;
if (minor >= rtems_nvdisk_count)
20233b0: 03 00 81 d2 sethi %hi(0x2074800), %g1 <== NOT EXECUTED
20233b4: c4 00 60 60 ld [ %g1 + 0x60 ], %g2 ! 2074860 <rtems_nvdisk_count><== NOT EXECUTED
dev_t device
)
{
union __rtems_dev_t temp;
temp.device = device;
20233b8: c2 06 20 04 ld [ %i0 + 4 ], %g1 <== NOT EXECUTED
20233bc: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
20233c0: 08 80 01 0b bleu 20237ec <rtems_nvdisk_ioctl+0x440> <== NOT EXECUTED
20233c4: 39 00 81 d2 sethi %hi(0x2074800), %i4 <== NOT EXECUTED
{
errno = ENODEV;
return -1;
}
if (rtems_nvdisks[minor].device_count == 0)
20233c8: c4 07 20 5c ld [ %i4 + 0x5c ], %g2 ! 207485c <rtems_nvdisks><== NOT EXECUTED
20233cc: 87 28 60 05 sll %g1, 5, %g3 <== NOT EXECUTED
20233d0: 83 28 60 03 sll %g1, 3, %g1 <== NOT EXECUTED
20233d4: b6 00 40 03 add %g1, %g3, %i3 <== NOT EXECUTED
20233d8: 82 00 80 1b add %g2, %i3, %g1 <== NOT EXECUTED
20233dc: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED
20233e0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20233e4: 02 80 01 02 be 20237ec <rtems_nvdisk_ioctl+0x440> <== NOT EXECUTED
20233e8: 01 00 00 00 nop <== NOT EXECUTED
{
errno = ENODEV;
return -1;
}
errno = 0;
20233ec: 40 00 9c 25 call 204a480 <__errno> <== NOT EXECUTED
20233f0: 01 00 00 00 nop <== NOT EXECUTED
sc = rtems_semaphore_obtain (rtems_nvdisks[minor].lock, RTEMS_WAIT, 0);
20233f4: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
{
errno = ENODEV;
return -1;
}
errno = 0;
20233f8: c0 22 00 00 clr [ %o0 ] <== NOT EXECUTED
sc = rtems_semaphore_obtain (rtems_nvdisks[minor].lock, RTEMS_WAIT, 0);
20233fc: 82 00 40 1b add %g1, %i3, %g1 <== NOT EXECUTED
2023400: d0 00 60 20 ld [ %g1 + 0x20 ], %o0 <== NOT EXECUTED
2023404: 92 10 20 00 clr %o1 <== NOT EXECUTED
2023408: 7f ff a8 8c call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
202340c: 94 10 20 00 clr %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2023410: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023414: 12 80 00 1b bne 2023480 <rtems_nvdisk_ioctl+0xd4> <== NOT EXECUTED
2023418: 01 00 00 00 nop <== NOT EXECUTED
errno = EIO;
else
{
errno = 0;
202341c: 40 00 9c 19 call 204a480 <__errno> <== NOT EXECUTED
2023420: 01 00 00 00 nop <== NOT EXECUTED
switch (req)
2023424: 03 08 00 10 sethi %hi(0x20004000), %g1 <== NOT EXECUTED
2023428: 84 10 62 82 or %g1, 0x282, %g2 ! 20004282 <RAM_END+0x1dc04282><== NOT EXECUTED
202342c: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
2023430: 02 80 00 51 be 2023574 <rtems_nvdisk_ioctl+0x1c8> <== NOT EXECUTED
2023434: c0 22 00 00 clr [ %o0 ] <== NOT EXECUTED
2023438: 05 30 06 10 sethi %hi(0xc0184000), %g2 <== NOT EXECUTED
202343c: 84 10 a2 01 or %g2, 0x201, %g2 ! c0184201 <RAM_END+0xbdd84201><== NOT EXECUTED
2023440: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
2023444: 02 80 00 50 be 2023584 <rtems_nvdisk_ioctl+0x1d8> <== NOT EXECUTED
2023448: 82 10 62 80 or %g1, 0x280, %g1 <== NOT EXECUTED
202344c: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2023450: 02 80 00 17 be 20234ac <rtems_nvdisk_ioctl+0x100> <== NOT EXECUTED
2023454: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
case RTEMS_NVDISK_IOCTL_INFO_LEVEL:
rtems_nvdisks[minor].info_level = (uintptr_t) argp;
break;
default:
rtems_blkdev_ioctl (dd, req, argp);
2023458: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
202345c: 7f ff 8c 3f call 2006558 <rtems_blkdev_ioctl> <== NOT EXECUTED
2023460: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2023464: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
2023468: b6 00 40 1b add %g1, %i3, %i3 <== NOT EXECUTED
break;
}
sc = rtems_semaphore_release (rtems_nvdisks[minor].lock);
202346c: 7f ff a8 ba call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2023470: d0 06 e0 20 ld [ %i3 + 0x20 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2023474: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023478: 02 80 00 06 be 2023490 <rtems_nvdisk_ioctl+0xe4> <== NOT EXECUTED
202347c: 01 00 00 00 nop <== NOT EXECUTED
errno = EIO;
2023480: 40 00 9c 00 call 204a480 <__errno> <== NOT EXECUTED
2023484: 01 00 00 00 nop <== NOT EXECUTED
2023488: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
202348c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
}
return errno == 0 ? 0 : -1;
2023490: 40 00 9b fc call 204a480 <__errno> <== NOT EXECUTED
2023494: 01 00 00 00 nop <== NOT EXECUTED
2023498: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
202349c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
20234a0: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
}
20234a4: 81 c7 e0 08 ret <== NOT EXECUTED
20234a8: 81 e8 00 00 restore <== NOT EXECUTED
break;
}
break;
case RTEMS_NVDISK_IOCTL_ERASE_DISK:
errno = rtems_nvdisk_erase_disk (&rtems_nvdisks[minor]);
20234ac: 40 00 9b f5 call 204a480 <__errno> <== NOT EXECUTED
20234b0: 01 00 00 00 nop <== NOT EXECUTED
20234b4: e4 07 20 5c ld [ %i4 + 0x5c ], %l2 <== NOT EXECUTED
20234b8: a4 04 80 1b add %l2, %i3, %l2 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "erase-disk");
#endif
for (device = 0; device < nvd->device_count; device++)
20234bc: c8 04 a0 18 ld [ %l2 + 0x18 ], %g4 <== NOT EXECUTED
20234c0: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
20234c4: 02 80 00 bf be 20237c0 <rtems_nvdisk_ioctl+0x414> <== NOT EXECUTED
20234c8: ae 10 00 08 mov %o0, %l7 <== NOT EXECUTED
20234cc: aa 10 20 00 clr %l5 <== NOT EXECUTED
20234d0: ac 10 20 00 clr %l6 <== NOT EXECUTED
20234d4: a8 07 bf fe add %fp, -2, %l4 <== NOT EXECUTED
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
uint32_t page;
for (page = 0; page < (dc->pages - dc->pages_desc); page++)
{
int ret = rtems_nvdisk_write_checksum (nvd, dc->device, page, 0xffff);
20234d8: a6 10 3f ff mov -1, %l3 <== NOT EXECUTED
rtems_nvdisk_info (nvd, "erase-disk");
#endif
for (device = 0; device < nvd->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
20234dc: c2 04 a0 14 ld [ %l2 + 0x14 ], %g1 <== NOT EXECUTED
20234e0: a2 00 40 15 add %g1, %l5, %l1 <== NOT EXECUTED
uint32_t page;
for (page = 0; page < (dc->pages - dc->pages_desc); page++)
20234e4: c6 04 60 04 ld [ %l1 + 4 ], %g3 <== NOT EXECUTED
20234e8: c4 04 60 08 ld [ %l1 + 8 ], %g2 <== NOT EXECUTED
20234ec: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
20234f0: 02 80 00 b0 be 20237b0 <rtems_nvdisk_ioctl+0x404> <== NOT EXECUTED
20234f4: a0 10 20 00 clr %l0 <== NOT EXECUTED
{
int ret = rtems_nvdisk_write_checksum (nvd, dc->device, page, 0xffff);
20234f8: 10 80 00 0a b 2023520 <rtems_nvdisk_ioctl+0x174> <== NOT EXECUTED
20234fc: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
for (device = 0; device < nvd->device_count; device++)
{
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
uint32_t page;
for (page = 0; page < (dc->pages - dc->pages_desc); page++)
2023500: c2 04 60 08 ld [ %l1 + 8 ], %g1 <== NOT EXECUTED
2023504: a0 04 20 01 inc %l0 <== NOT EXECUTED
2023508: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
202350c: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
2023510: 3a 80 00 a8 bcc,a 20237b0 <rtems_nvdisk_ioctl+0x404> <== NOT EXECUTED
2023514: c8 04 a0 18 ld [ %l2 + 0x18 ], %g4 <== NOT EXECUTED
2023518: c2 04 a0 14 ld [ %l2 + 0x14 ], %g1 <== NOT EXECUTED
{
int ret = rtems_nvdisk_write_checksum (nvd, dc->device, page, 0xffff);
202351c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2023520: e6 37 bf fe sth %l3, [ %fp + -2 ] <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
2023524: 87 2a 20 02 sll %o0, 2, %g3 <== NOT EXECUTED
2023528: 85 2a 20 04 sll %o0, 4, %g2 <== NOT EXECUTED
202352c: 84 00 c0 02 add %g3, %g2, %g2 <== NOT EXECUTED
2023530: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2023534: c4 00 60 10 ld [ %g1 + 0x10 ], %g2 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-write: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->write (device, dd->flags, dd->base, offset, buffer, size);
2023538: 97 2c 20 01 sll %l0, 1, %o3 <== NOT EXECUTED
202353c: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 <== NOT EXECUTED
2023540: d4 00 a0 04 ld [ %g2 + 4 ], %o2 <== NOT EXECUTED
2023544: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
2023548: d2 00 80 00 ld [ %g2 ], %o1 <== NOT EXECUTED
202354c: 98 10 00 14 mov %l4, %o4 <== NOT EXECUTED
2023550: 9f c0 40 00 call %g1 <== NOT EXECUTED
2023554: 9a 10 20 02 mov 2, %o5 <== NOT EXECUTED
rtems_nvdisk_device_ctl* dc = &nvd->devices[device];
uint32_t page;
for (page = 0; page < (dc->pages - dc->pages_desc); page++)
{
int ret = rtems_nvdisk_write_checksum (nvd, dc->device, page, 0xffff);
if (ret)
2023558: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202355c: 22 bf ff e9 be,a 2023500 <rtems_nvdisk_ioctl+0x154> <== NOT EXECUTED
2023560: c4 04 60 04 ld [ %l1 + 4 ], %g2 <== NOT EXECUTED
break;
}
break;
case RTEMS_NVDISK_IOCTL_ERASE_DISK:
errno = rtems_nvdisk_erase_disk (&rtems_nvdisks[minor]);
2023564: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
2023568: d0 25 c0 00 st %o0, [ %l7 ] <== NOT EXECUTED
break;
202356c: 10 bf ff c0 b 202346c <rtems_nvdisk_ioctl+0xc0> <== NOT EXECUTED
2023570: b6 00 40 1b add %g1, %i3, %i3 <== NOT EXECUTED
case RTEMS_NVDISK_IOCTL_INFO_LEVEL:
rtems_nvdisks[minor].info_level = (uintptr_t) argp;
2023574: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
2023578: b6 00 40 1b add %g1, %i3, %i3 <== NOT EXECUTED
break;
202357c: 10 bf ff bc b 202346c <rtems_nvdisk_ioctl+0xc0> <== NOT EXECUTED
2023580: f4 26 e0 24 st %i2, [ %i3 + 0x24 ] <== NOT EXECUTED
{
errno = 0;
switch (req)
{
case RTEMS_BLKIO_REQUEST:
switch (r->req)
2023584: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
2023588: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202358c: 12 80 00 8f bne 20237c8 <rtems_nvdisk_ioctl+0x41c> <== NOT EXECUTED
2023590: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
{
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
2023594: 40 00 9b bb call 204a480 <__errno> <== NOT EXECUTED
2023598: 3b 00 00 3f sethi %hi(0xfc00), %i5 <== NOT EXECUTED
202359c: e4 07 20 5c ld [ %i4 + 0x5c ], %l2 <== NOT EXECUTED
20235a0: e0 06 a0 10 ld [ %i2 + 0x10 ], %l0 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20235a4: 31 00 81 d2 sethi %hi(0x2074800), %i0 <== NOT EXECUTED
{
case RTEMS_BLKIO_REQUEST:
switch (r->req)
{
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
20235a8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20235ac: d0 27 bf f0 st %o0, [ %fp + -16 ] <== NOT EXECUTED
20235b0: a4 04 80 1b add %l2, %i3, %l2 <== NOT EXECUTED
ret = rtems_nvdisk_read_checksum (nvd, dc->device, page, &crc);
if (ret)
return ret;
if (crc == 0xffff)
20235b4: ba 17 63 ff or %i5, 0x3ff, %i5 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20235b8: b0 16 20 64 or %i0, 0x64, %i0 <== NOT EXECUTED
{
case RTEMS_BLKIO_REQUEST:
switch (r->req)
{
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
20235bc: ac 06 a0 28 add %i2, 0x28, %l6 <== NOT EXECUTED
20235c0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-read: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->read (device, dd->flags, dd->base, offset, buffer, size);
20235c4: ae 07 bf fe add %fp, -2, %l7 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "read: blocks=%d", req->bufnum);
#endif
for (bufs = 0; (ret == 0) && (bufs < req->bufnum); bufs++, sg++)
20235c8: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
20235cc: 82 00 bf ff add %g2, -1, %g1 <== NOT EXECUTED
20235d0: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
20235d4: 1a 80 01 0b bcc 2023a00 <rtems_nvdisk_ioctl+0x654> <== NOT EXECUTED
20235d8: 82 10 20 00 clr %g1 <== NOT EXECUTED
{
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
20235dc: d0 05 bf f4 ld [ %l6 + -12 ], %o0 <== NOT EXECUTED
20235e0: 40 00 fc e9 call 2062984 <.udiv> <== NOT EXECUTED
20235e4: d2 04 a0 0c ld [ %l2 + 0xc ], %o1 <== NOT EXECUTED
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
20235e8: b2 92 20 00 orcc %o0, 0, %i1 <== NOT EXECUTED
20235ec: 02 80 00 87 be 2023808 <rtems_nvdisk_ioctl+0x45c> <== NOT EXECUTED
20235f0: e2 05 bf f8 ld [ %l6 + -8 ], %l1 <== NOT EXECUTED
{
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
20235f4: aa 10 20 00 clr %l5 <== NOT EXECUTED
for (b = 0; b < nvb; b++, data += nvd->block_size)
{
ret = rtems_nvdisk_read_block (nvd, sg->block + b, data);
20235f8: e6 05 bf f0 ld [ %l6 + -16 ], %l3 <== NOT EXECUTED
uint32_t page;
uint16_t crc;
uint16_t cs;
int ret;
dc = rtems_nvdisk_get_device (nvd, block);
20235fc: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
{
ret = rtems_nvdisk_read_block (nvd, sg->block + b, data);
2023600: a6 05 40 13 add %l5, %l3, %l3 <== NOT EXECUTED
uint32_t page;
uint16_t crc;
uint16_t cs;
int ret;
dc = rtems_nvdisk_get_device (nvd, block);
2023604: 7f ff ff 44 call 2023314 <rtems_nvdisk_get_device> <== NOT EXECUTED
2023608: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
if (!dc)
202360c: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2023610: 02 80 00 51 be 2023754 <rtems_nvdisk_ioctl+0x3a8> <== NOT EXECUTED
2023614: 98 10 00 17 mov %l7, %o4 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, " read-block:%d=>%02d-%03d, cs:%04x",
block, dc->device, page, crc);
#endif
ret = rtems_nvdisk_read_checksum (nvd, dc->device, page, &crc);
2023618: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
202361c: c4 04 a0 14 ld [ %l2 + 0x14 ], %g2 <== NOT EXECUTED
2023620: 87 2a 20 02 sll %o0, 2, %g3 <== NOT EXECUTED
2023624: 83 2a 20 04 sll %o0, 4, %g1 <== NOT EXECUTED
2023628: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
202362c: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2023630: c4 00 60 10 ld [ %g1 + 0x10 ], %g2 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_get_page (rtems_nvdisk_device_ctl* dc,
uint32_t block)
{
return block - dc->block_base;
2023634: e8 04 20 0c ld [ %l0 + 0xc ], %l4 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-read: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->read (device, dd->flags, dd->base, offset, buffer, size);
2023638: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 <== NOT EXECUTED
202363c: d4 00 a0 04 ld [ %g2 + 4 ], %o2 <== NOT EXECUTED
2023640: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
2023644: d2 00 80 00 ld [ %g2 ], %o1 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_get_page (rtems_nvdisk_device_ctl* dc,
uint32_t block)
{
return block - dc->block_base;
2023648: a8 24 c0 14 sub %l3, %l4, %l4 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-read: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->read (device, dd->flags, dd->base, offset, buffer, size);
202364c: 97 2d 20 01 sll %l4, 1, %o3 <== NOT EXECUTED
2023650: 9f c0 40 00 call %g1 <== NOT EXECUTED
2023654: 9a 10 20 02 mov 2, %o5 <== NOT EXECUTED
block, dc->device, page, crc);
#endif
ret = rtems_nvdisk_read_checksum (nvd, dc->device, page, &crc);
if (ret)
2023658: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
202365c: 12 80 00 40 bne 202375c <rtems_nvdisk_ioctl+0x3b0> <== NOT EXECUTED
2023660: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
return ret;
if (crc == 0xffff)
2023664: c2 17 bf fe lduh [ %fp + -2 ], %g1 <== NOT EXECUTED
2023668: 80 a0 40 1d cmp %g1, %i5 <== NOT EXECUTED
202366c: 22 80 00 47 be,a 2023788 <rtems_nvdisk_ioctl+0x3dc> <== NOT EXECUTED
2023670: d4 04 a0 0c ld [ %l2 + 0xc ], %o2 <== NOT EXECUTED
#endif
memset (buffer, 0, nvd->block_size);
return 0;
}
ret = rtems_nvdisk_read_page (nvd, dc->device, page + dc->pages_desc, buffer);
2023674: c4 04 00 00 ld [ %l0 ], %g2 <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
2023678: c6 04 a0 14 ld [ %l2 + 0x14 ], %g3 <== NOT EXECUTED
202367c: 89 28 a0 02 sll %g2, 2, %g4 <== NOT EXECUTED
2023680: 83 28 a0 04 sll %g2, 4, %g1 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-read: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->read (device, dd->flags, dd->base, offset, buffer, size);
2023684: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
2023688: 82 01 00 01 add %g4, %g1, %g1 <== NOT EXECUTED
202368c: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
2023690: c6 00 60 10 ld [ %g1 + 0x10 ], %g3 <== NOT EXECUTED
rtems_nvdisk_read_page (const rtems_nvdisk* nvd,
uint32_t device,
uint32_t page,
void* buffer)
{
return rtems_nvdisk_device_read (nvd, device,
2023694: e0 04 a0 0c ld [ %l2 + 0xc ], %l0 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-read: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->read (device, dd->flags, dd->base, offset, buffer, size);
2023698: c2 00 e0 0c ld [ %g3 + 0xc ], %g1 <== NOT EXECUTED
202369c: 90 05 00 08 add %l4, %o0, %o0 <== NOT EXECUTED
20236a0: e8 00 e0 04 ld [ %g3 + 4 ], %l4 <== NOT EXECUTED
20236a4: c6 00 c0 00 ld [ %g3 ], %g3 <== NOT EXECUTED
20236a8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20236ac: c2 27 bf e0 st %g1, [ %fp + -32 ] <== NOT EXECUTED
20236b0: c4 27 bf e8 st %g2, [ %fp + -24 ] <== NOT EXECUTED
20236b4: 7f ff 7d 36 call 2002b8c <.umul> <== NOT EXECUTED
20236b8: c6 27 bf e4 st %g3, [ %fp + -28 ] <== NOT EXECUTED
20236bc: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20236c0: c4 07 bf e8 ld [ %fp + -24 ], %g2 <== NOT EXECUTED
20236c4: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
20236c8: c6 07 bf e4 ld [ %fp + -28 ], %g3 <== NOT EXECUTED
20236cc: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20236d0: 92 10 00 03 mov %g3, %o1 <== NOT EXECUTED
20236d4: 90 10 00 02 mov %g2, %o0 <== NOT EXECUTED
20236d8: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
20236dc: 9a 10 00 10 mov %l0, %o5 <== NOT EXECUTED
20236e0: 9f c0 40 00 call %g1 <== NOT EXECUTED
20236e4: 98 10 00 11 mov %l1, %o4 <== NOT EXECUTED
return 0;
}
ret = rtems_nvdisk_read_page (nvd, dc->device, page + dc->pages_desc, buffer);
if (ret)
20236e8: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED
20236ec: 12 80 00 1c bne 202375c <rtems_nvdisk_ioctl+0x3b0> <== NOT EXECUTED
20236f0: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
return ret;
cs = rtems_nvdisk_page_checksum (buffer, nvd->block_size);
20236f4: c8 04 a0 0c ld [ %l2 + 0xc ], %g4 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20236f8: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
20236fc: 02 80 00 0d be 2023730 <rtems_nvdisk_ioctl+0x384> <== NOT EXECUTED
2023700: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED
2023704: da 06 00 00 ld [ %i0 ], %o5 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
2023708: c6 0c 40 01 ldub [ %l1 + %g1 ], %g3 <== NOT EXECUTED
202370c: 85 2a a0 10 sll %o2, 0x10, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
2023710: 82 00 60 01 inc %g1 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
2023714: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
2023718: 80 a1 00 01 cmp %g4, %g1 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
202371c: 84 18 80 03 xor %g2, %g3, %g2 <== NOT EXECUTED
2023720: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
2023724: 85 28 a0 01 sll %g2, 1, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
2023728: 18 bf ff f8 bgu 2023708 <rtems_nvdisk_ioctl+0x35c> <== NOT EXECUTED
202372c: d4 13 40 02 lduh [ %o5 + %g2 ], %o2 <== NOT EXECUTED
if (ret)
return ret;
cs = rtems_nvdisk_page_checksum (buffer, nvd->block_size);
if (cs != crc)
2023730: d6 17 bf fe lduh [ %fp + -2 ], %o3 <== NOT EXECUTED
2023734: 95 2a a0 10 sll %o2, 0x10, %o2 <== NOT EXECUTED
2023738: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
202373c: 80 a2 80 0b cmp %o2, %o3 <== NOT EXECUTED
2023740: 02 80 00 16 be 2023798 <rtems_nvdisk_ioctl+0x3ec> <== NOT EXECUTED
2023744: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
{
rtems_nvdisk_error ("read-block: crc failure: %d: buffer:%04x page:%04x",
2023748: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
202374c: 7f ff fe d3 call 2023298 <rtems_nvdisk_error> <== NOT EXECUTED
2023750: 90 12 21 60 or %o0, 0x160, %o0 <== NOT EXECUTED
2023754: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2023758: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
break;
}
}
req->status = ret ? RTEMS_IO_ERROR : RTEMS_SUCCESSFUL;
req->req_done (req->done_arg, req->status);
202375c: c4 06 a0 04 ld [ %i2 + 4 ], %g2 <== NOT EXECUTED
2023760: d0 06 a0 08 ld [ %i2 + 8 ], %o0 <== NOT EXECUTED
2023764: c2 27 bf e0 st %g1, [ %fp + -32 ] <== NOT EXECUTED
2023768: 9f c0 80 00 call %g2 <== NOT EXECUTED
202376c: d2 26 a0 0c st %o1, [ %i2 + 0xc ] <== NOT EXECUTED
{
case RTEMS_BLKIO_REQUEST:
switch (r->req)
{
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
2023770: c4 07 20 5c ld [ %i4 + 0x5c ], %g2 <== NOT EXECUTED
2023774: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
2023778: c6 07 bf f0 ld [ %fp + -16 ], %g3 <== NOT EXECUTED
202377c: b6 00 80 1b add %g2, %i3, %i3 <== NOT EXECUTED
break;
2023780: 10 bf ff 3b b 202346c <rtems_nvdisk_ioctl+0xc0> <== NOT EXECUTED
2023784: c2 20 c0 00 st %g1, [ %g3 ] <== NOT EXECUTED
if (crc == 0xffff)
{
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_warning (nvd, "read-block: crc not set: %d", block);
#endif
memset (buffer, 0, nvd->block_size);
2023788: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202378c: 40 00 a9 1c call 204dbfc <memset> <== NOT EXECUTED
2023790: 92 10 20 00 clr %o1 <== NOT EXECUTED
2023794: c8 04 a0 0c ld [ %l2 + 0xc ], %g4 <== NOT EXECUTED
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
2023798: aa 05 60 01 inc %l5 <== NOT EXECUTED
202379c: 80 a6 40 15 cmp %i1, %l5 <== NOT EXECUTED
20237a0: 08 80 00 19 bleu 2023804 <rtems_nvdisk_ioctl+0x458> <== NOT EXECUTED
20237a4: a2 04 40 04 add %l1, %g4, %l1 <== NOT EXECUTED
{
ret = rtems_nvdisk_read_block (nvd, sg->block + b, data);
20237a8: 10 bf ff 95 b 20235fc <rtems_nvdisk_ioctl+0x250> <== NOT EXECUTED
20237ac: e6 05 bf f0 ld [ %l6 + -16 ], %l3 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "erase-disk");
#endif
for (device = 0; device < nvd->device_count; device++)
20237b0: ac 05 a0 01 inc %l6 <== NOT EXECUTED
20237b4: 80 a5 80 04 cmp %l6, %g4 <== NOT EXECUTED
20237b8: 0a bf ff 49 bcs 20234dc <rtems_nvdisk_ioctl+0x130> <== NOT EXECUTED
20237bc: aa 05 60 14 add %l5, 0x14, %l5 <== NOT EXECUTED
20237c0: 10 bf ff 69 b 2023564 <rtems_nvdisk_ioctl+0x1b8> <== NOT EXECUTED
20237c4: 90 10 20 00 clr %o0 <== NOT EXECUTED
{
errno = 0;
switch (req)
{
case RTEMS_BLKIO_REQUEST:
switch (r->req)
20237c8: 02 80 00 15 be 202381c <rtems_nvdisk_ioctl+0x470> <== NOT EXECUTED
20237cc: 01 00 00 00 nop <== NOT EXECUTED
case RTEMS_BLKDEV_REQ_WRITE:
errno = rtems_nvdisk_write (&rtems_nvdisks[minor], r);
break;
default:
errno = EINVAL;
20237d0: 40 00 9b 2c call 204a480 <__errno> <== NOT EXECUTED
20237d4: 01 00 00 00 nop <== NOT EXECUTED
20237d8: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
20237dc: 84 10 20 16 mov 0x16, %g2 <== NOT EXECUTED
20237e0: b6 00 40 1b add %g1, %i3, %i3 <== NOT EXECUTED
20237e4: 10 bf ff 22 b 202346c <rtems_nvdisk_ioctl+0xc0> <== NOT EXECUTED
20237e8: c4 22 00 00 st %g2, [ %o0 ] <== NOT EXECUTED
return -1;
}
if (rtems_nvdisks[minor].device_count == 0)
{
errno = ENODEV;
20237ec: 40 00 9b 25 call 204a480 <__errno> <== NOT EXECUTED
20237f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20237f4: 82 10 20 13 mov 0x13, %g1 <== NOT EXECUTED
20237f8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
20237fc: 81 c7 e0 08 ret <== NOT EXECUTED
2023800: 81 e8 00 00 restore <== NOT EXECUTED
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
2023804: e0 06 a0 10 ld [ %i2 + 0x10 ], %l0 <== NOT EXECUTED
2023808: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
202380c: ac 05 a0 10 add %l6, 0x10, %l6 <== NOT EXECUTED
2023810: 82 00 60 01 inc %g1 <== NOT EXECUTED
2023814: 10 bf ff 6d b 20235c8 <rtems_nvdisk_ioctl+0x21c> <== NOT EXECUTED
2023818: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
break;
case RTEMS_BLKDEV_REQ_WRITE:
errno = rtems_nvdisk_write (&rtems_nvdisks[minor], r);
202381c: 40 00 9b 19 call 204a480 <__errno> <== NOT EXECUTED
2023820: 3b 00 81 d2 sethi %hi(0x2074800), %i5 <== NOT EXECUTED
2023824: e6 07 20 5c ld [ %i4 + 0x5c ], %l3 <== NOT EXECUTED
2023828: e0 06 a0 10 ld [ %i2 + 0x10 ], %l0 <== NOT EXECUTED
202382c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2023830: d0 27 bf f0 st %o0, [ %fp + -16 ] <== NOT EXECUTED
2023834: a6 04 c0 1b add %l3, %i3, %l3 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
2023838: ba 17 60 64 or %i5, 0x64, %i5 <== NOT EXECUTED
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
break;
case RTEMS_BLKDEV_REQ_WRITE:
errno = rtems_nvdisk_write (&rtems_nvdisks[minor], r);
202383c: ac 06 a0 28 add %i2, 0x28, %l6 <== NOT EXECUTED
2023840: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-write: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->write (device, dd->flags, dd->base, offset, buffer, size);
2023844: b2 07 bf fe add %fp, -2, %i1 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "write: blocks=%d", req->bufnum);
#endif
for (bufs = 0; (ret == 0) && (bufs < req->bufnum); bufs++, sg++)
2023848: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
202384c: 82 00 bf ff add %g2, -1, %g1 <== NOT EXECUTED
2023850: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
2023854: 08 80 00 44 bleu 2023964 <rtems_nvdisk_ioctl+0x5b8> <== NOT EXECUTED
2023858: 92 10 20 00 clr %o1 <== NOT EXECUTED
{
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
202385c: d0 05 bf f4 ld [ %l6 + -12 ], %o0 <== NOT EXECUTED
2023860: 40 00 fc 49 call 2062984 <.udiv> <== NOT EXECUTED
2023864: d2 04 e0 0c ld [ %l3 + 0xc ], %o1 <== NOT EXECUTED
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
2023868: ae 92 20 00 orcc %o0, 0, %l7 <== NOT EXECUTED
202386c: 02 80 00 60 be 20239ec <rtems_nvdisk_ioctl+0x640> <== NOT EXECUTED
2023870: e2 05 bf f8 ld [ %l6 + -8 ], %l1 <== NOT EXECUTED
{
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
2023874: a8 10 20 00 clr %l4 <== NOT EXECUTED
for (b = 0; b < nvb; b++, data += nvd->block_size)
{
ret = rtems_nvdisk_write_block (nvd, sg->block + b, data);
2023878: ea 05 bf f0 ld [ %l6 + -16 ], %l5 <== NOT EXECUTED
rtems_nvdisk_device_ctl* dc;
uint32_t page;
uint16_t cs;
int ret;
dc = rtems_nvdisk_get_device (nvd, block);
202387c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
{
ret = rtems_nvdisk_write_block (nvd, sg->block + b, data);
2023880: aa 05 00 15 add %l4, %l5, %l5 <== NOT EXECUTED
rtems_nvdisk_device_ctl* dc;
uint32_t page;
uint16_t cs;
int ret;
dc = rtems_nvdisk_get_device (nvd, block);
2023884: 7f ff fe a4 call 2023314 <rtems_nvdisk_get_device> <== NOT EXECUTED
2023888: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
if (!dc)
202388c: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2023890: 22 80 00 35 be,a 2023964 <rtems_nvdisk_ioctl+0x5b8> <== NOT EXECUTED
2023894: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_get_page (rtems_nvdisk_device_ctl* dc,
uint32_t block)
{
return block - dc->block_base;
2023898: c2 04 a0 0c ld [ %l2 + 0xc ], %g1 <== NOT EXECUTED
if (!dc)
return EIO;
page = rtems_nvdisk_get_page (dc, block);
cs = rtems_nvdisk_page_checksum (buffer, nvd->block_size);
202389c: f0 04 e0 0c ld [ %l3 + 0xc ], %i0 <== NOT EXECUTED
*/
static uint32_t
rtems_nvdisk_get_page (rtems_nvdisk_device_ctl* dc,
uint32_t block)
{
return block - dc->block_base;
20238a0: aa 25 40 01 sub %l5, %g1, %l5 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20238a4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
20238a8: 02 80 00 0e be 20238e0 <rtems_nvdisk_ioctl+0x534> <== NOT EXECUTED
20238ac: a0 10 3f ff mov -1, %l0 <== NOT EXECUTED
20238b0: c8 07 40 00 ld [ %i5 ], %g4 <== NOT EXECUTED
20238b4: 82 10 20 00 clr %g1 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
20238b8: c6 0c 40 01 ldub [ %l1 + %g1 ], %g3 <== NOT EXECUTED
20238bc: 85 2c 20 10 sll %l0, 0x10, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20238c0: 82 00 60 01 inc %g1 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
20238c4: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20238c8: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED
cs = rtems_nvdisk_calc_crc16 (cs, *buffer);
20238cc: 84 18 80 03 xor %g2, %g3, %g2 <== NOT EXECUTED
20238d0: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
20238d4: 85 28 a0 01 sll %g2, 1, %g2 <== NOT EXECUTED
rtems_nvdisk_page_checksum (const uint8_t* buffer, uint32_t page_size)
{
uint16_t cs = 0xffff;
uint32_t i;
for (i = 0; i < page_size; i++, buffer++)
20238d8: 18 bf ff f8 bgu 20238b8 <rtems_nvdisk_ioctl+0x50c> <== NOT EXECUTED
20238dc: e0 11 00 02 lduh [ %g4 + %g2 ], %l0 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, " write-block:%d=>%02d-%03d", block, dc->device, page);
#endif
ret = rtems_nvdisk_write_page (nvd, dc->device, page + dc->pages_desc, buffer);
20238e0: c4 04 80 00 ld [ %l2 ], %g2 <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
20238e4: c6 04 e0 14 ld [ %l3 + 0x14 ], %g3 <== NOT EXECUTED
20238e8: 89 28 a0 02 sll %g2, 2, %g4 <== NOT EXECUTED
20238ec: 83 28 a0 04 sll %g2, 4, %g1 <== NOT EXECUTED
20238f0: 82 01 00 01 add %g4, %g1, %g1 <== NOT EXECUTED
20238f4: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
20238f8: c6 00 60 10 ld [ %g1 + 0x10 ], %g3 <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-write: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->write (device, dd->flags, dd->base, offset, buffer, size);
20238fc: d0 04 a0 08 ld [ %l2 + 8 ], %o0 <== NOT EXECUTED
2023900: c2 00 e0 0c ld [ %g3 + 0xc ], %g1 <== NOT EXECUTED
2023904: d4 00 e0 04 ld [ %g3 + 4 ], %o2 <== NOT EXECUTED
2023908: c6 00 c0 00 ld [ %g3 ], %g3 <== NOT EXECUTED
202390c: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2023910: c2 27 bf e0 st %g1, [ %fp + -32 ] <== NOT EXECUTED
2023914: c4 27 bf e8 st %g2, [ %fp + -24 ] <== NOT EXECUTED
2023918: c6 27 bf e4 st %g3, [ %fp + -28 ] <== NOT EXECUTED
202391c: d4 27 bf ec st %o2, [ %fp + -20 ] <== NOT EXECUTED
2023920: 7f ff 7c 9b call 2002b8c <.umul> <== NOT EXECUTED
2023924: 90 05 40 08 add %l5, %o0, %o0 <== NOT EXECUTED
2023928: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
202392c: c4 07 bf e8 ld [ %fp + -24 ], %g2 <== NOT EXECUTED
2023930: c6 07 bf e4 ld [ %fp + -28 ], %g3 <== NOT EXECUTED
2023934: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
2023938: d4 07 bf ec ld [ %fp + -20 ], %o2 <== NOT EXECUTED
202393c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2023940: 92 10 00 03 mov %g3, %o1 <== NOT EXECUTED
2023944: 90 10 00 02 mov %g2, %o0 <== NOT EXECUTED
2023948: 9a 10 00 18 mov %i0, %o5 <== NOT EXECUTED
202394c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2023950: 98 10 00 11 mov %l1, %o4 <== NOT EXECUTED
rtems_nvdisk_info (nvd, " write-block:%d=>%02d-%03d", block, dc->device, page);
#endif
ret = rtems_nvdisk_write_page (nvd, dc->device, page + dc->pages_desc, buffer);
if (ret)
2023954: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2023958: 22 80 00 0c be,a 2023988 <rtems_nvdisk_ioctl+0x5dc> <== NOT EXECUTED
202395c: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "write: blocks=%d", req->bufnum);
#endif
for (bufs = 0; (ret == 0) && (bufs < req->bufnum); bufs++, sg++)
2023960: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
break;
}
}
req->status = ret ? RTEMS_IO_ERROR : RTEMS_SUCCESSFUL;
req->req_done (req->done_arg, req->status);
2023964: c2 06 a0 04 ld [ %i2 + 4 ], %g1 <== NOT EXECUTED
2023968: d0 06 a0 08 ld [ %i2 + 8 ], %o0 <== NOT EXECUTED
202396c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2023970: d2 26 a0 0c st %o1, [ %i2 + 0xc ] <== NOT EXECUTED
case RTEMS_BLKDEV_REQ_READ:
errno = rtems_nvdisk_read (&rtems_nvdisks[minor], r);
break;
case RTEMS_BLKDEV_REQ_WRITE:
errno = rtems_nvdisk_write (&rtems_nvdisks[minor], r);
2023974: c2 07 20 5c ld [ %i4 + 0x5c ], %g1 <== NOT EXECUTED
2023978: c6 07 bf f0 ld [ %fp + -16 ], %g3 <== NOT EXECUTED
202397c: b6 00 40 1b add %g1, %i3, %i3 <== NOT EXECUTED
break;
2023980: 10 bf fe bb b 202346c <rtems_nvdisk_ioctl+0xc0> <== NOT EXECUTED
2023984: c0 20 c0 00 clr [ %g3 ] <== NOT EXECUTED
* Get the descriptor for a device.
*/
static const rtems_nvdisk_device_desc*
rtems_nvdisk_device_descriptor (const rtems_nvdisk* nvd, uint32_t device)
{
return nvd->devices[device].descriptor;
2023988: c4 04 e0 14 ld [ %l3 + 0x14 ], %g2 <== NOT EXECUTED
202398c: 87 2a 20 02 sll %o0, 2, %g3 <== NOT EXECUTED
2023990: 83 2a 20 04 sll %o0, 4, %g1 <== NOT EXECUTED
2023994: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED
2023998: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
202399c: c4 00 60 10 ld [ %g1 + 0x10 ], %g2 <== NOT EXECUTED
ret = rtems_nvdisk_write_page (nvd, dc->device, page + dc->pages_desc, buffer);
if (ret)
return ret;
return rtems_nvdisk_write_checksum (nvd, dc->device, page, cs);
20239a0: e0 37 bf fe sth %l0, [ %fp + -2 ] <== NOT EXECUTED
ops = nvd->devices[device].descriptor->nv_ops;
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_printf (nvd, " dev-write: %02d-%08x: s=%d",
device, offset, size);
#endif
return ops->write (device, dd->flags, dd->base, offset, buffer, size);
20239a4: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 <== NOT EXECUTED
20239a8: d4 00 a0 04 ld [ %g2 + 4 ], %o2 <== NOT EXECUTED
20239ac: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
20239b0: d2 00 80 00 ld [ %g2 ], %o1 <== NOT EXECUTED
20239b4: 97 2d 60 01 sll %l5, 1, %o3 <== NOT EXECUTED
20239b8: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
20239bc: 9f c0 40 00 call %g1 <== NOT EXECUTED
20239c0: 9a 10 20 02 mov 2, %o5 <== NOT EXECUTED
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
{
ret = rtems_nvdisk_write_block (nvd, sg->block + b, data);
if (ret)
20239c4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20239c8: 12 bf ff e7 bne 2023964 <rtems_nvdisk_ioctl+0x5b8> <== NOT EXECUTED
20239cc: 92 10 20 1b mov 0x1b, %o1 <== NOT EXECUTED
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
20239d0: a8 05 20 01 inc %l4 <== NOT EXECUTED
20239d4: 80 a5 c0 14 cmp %l7, %l4 <== NOT EXECUTED
20239d8: 08 80 00 04 bleu 20239e8 <rtems_nvdisk_ioctl+0x63c> <== NOT EXECUTED
20239dc: c2 04 e0 0c ld [ %l3 + 0xc ], %g1 <== NOT EXECUTED
20239e0: 10 bf ff a6 b 2023878 <rtems_nvdisk_ioctl+0x4cc> <== NOT EXECUTED
20239e4: a2 04 40 01 add %l1, %g1, %l1 <== NOT EXECUTED
20239e8: e0 06 a0 10 ld [ %i2 + 0x10 ], %l0 <== NOT EXECUTED
uint8_t* data;
uint32_t nvb;
uint32_t b;
nvb = sg->length / nvd->block_size;
data = sg->buffer;
for (b = 0; b < nvb; b++, data += nvd->block_size)
20239ec: c4 07 bf f4 ld [ %fp + -12 ], %g2 <== NOT EXECUTED
20239f0: ac 05 a0 10 add %l6, 0x10, %l6 <== NOT EXECUTED
20239f4: 84 00 a0 01 inc %g2 <== NOT EXECUTED
20239f8: 10 bf ff 94 b 2023848 <rtems_nvdisk_ioctl+0x49c> <== NOT EXECUTED
20239fc: c4 27 bf f4 st %g2, [ %fp + -12 ] <== NOT EXECUTED
#if RTEMS_NVDISK_TRACE
rtems_nvdisk_info (nvd, "read: blocks=%d", req->bufnum);
#endif
for (bufs = 0; (ret == 0) && (bufs < req->bufnum); bufs++, sg++)
2023a00: 10 bf ff 57 b 202375c <rtems_nvdisk_ioctl+0x3b0> <== NOT EXECUTED
2023a04: 92 10 20 00 clr %o1 <== NOT EXECUTED
02023d24 <rtems_nvdisk_sram_read>:
uint32_t flags __attribute__((unused)),
void* base,
uint32_t offset,
void* buffer,
size_t size)
{
2023d24: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
memcpy (buffer, (base + offset), size);
return 0;
}
2023d28: b0 10 20 00 clr %i0 <== NOT EXECUTED
void* base,
uint32_t offset,
void* buffer,
size_t size)
{
memcpy (buffer, (base + offset), size);
2023d2c: 92 06 80 1b add %i2, %i3, %o1 <== NOT EXECUTED
2023d30: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
2023d34: 40 00 a7 1f call 204d9b0 <memcpy> <== NOT EXECUTED
2023d38: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
return 0;
}
2023d3c: 81 c7 e0 08 ret <== NOT EXECUTED
2023d40: 81 e8 00 00 restore <== NOT EXECUTED
02023cdc <rtems_nvdisk_sram_verify>:
uint32_t flags __attribute__((unused)),
void* base,
uint32_t offset,
const void* buffer,
size_t size)
{
2023cdc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
return memcmp ((base + offset), buffer, size) == 0 ? 0 : EIO;
2023ce0: 90 06 80 1b add %i2, %i3, %o0 <== NOT EXECUTED
2023ce4: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
2023ce8: 40 00 a7 01 call 204d8ec <memcmp> <== NOT EXECUTED
2023cec: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
2023cf0: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2023cf4: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
2023cf8: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
}
2023cfc: 81 c7 e0 08 ret <== NOT EXECUTED
2023d00: 91 ee 20 05 restore %i0, 5, %o0 <== NOT EXECUTED
02023d04 <rtems_nvdisk_sram_write>:
uint32_t flags __attribute__((unused)),
void* base,
uint32_t offset,
const void* buffer,
size_t size)
{
2023d04: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
memcpy ((base + offset), buffer, size);
return 0;
}
2023d08: b0 10 20 00 clr %i0 <== NOT EXECUTED
void* base,
uint32_t offset,
const void* buffer,
size_t size)
{
memcpy ((base + offset), buffer, size);
2023d0c: 90 06 80 1b add %i2, %i3, %o0 <== NOT EXECUTED
2023d10: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
2023d14: 40 00 a7 27 call 204d9b0 <memcpy> <== NOT EXECUTED
2023d18: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
return 0;
}
2023d1c: 81 c7 e0 08 ret <== NOT EXECUTED
2023d20: 81 e8 00 00 restore <== NOT EXECUTED
02008508 <rtems_object_get_class_information>:
rtems_status_code rtems_object_get_class_information(
int the_api,
int the_class,
rtems_object_api_class_information *info
)
{
2008508: 9d e3 bf a0 save %sp, -96, %sp
200850c: 90 10 00 18 mov %i0, %o0
int i;
/*
* Validate parameters and look up information structure.
*/
if ( !info )
2008510: 80 a6 a0 00 cmp %i2, 0
2008514: 02 80 00 20 be 2008594 <rtems_object_get_class_information+0x8c>
2008518: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
obj_info = _Objects_Get_information( the_api, the_class );
200851c: 92 10 00 19 mov %i1, %o1
2008520: 40 00 07 72 call 200a2e8 <_Objects_Get_information>
2008524: b0 10 20 0a mov 0xa, %i0
if ( !obj_info )
2008528: 80 a2 20 00 cmp %o0, 0
200852c: 02 80 00 1a be 2008594 <rtems_object_get_class_information+0x8c>
2008530: 01 00 00 00 nop
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
2008534: c2 02 20 08 ld [ %o0 + 8 ], %g1
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
2008538: c8 12 20 10 lduh [ %o0 + 0x10 ], %g4
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
200853c: c4 0a 20 12 ldub [ %o0 + 0x12 ], %g2
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
2008540: c2 26 80 00 st %g1, [ %i2 ]
info->maximum_id = obj_info->maximum_id;
2008544: c2 02 20 0c ld [ %o0 + 0xc ], %g1
info->auto_extend = obj_info->auto_extend;
2008548: c4 2e a0 0c stb %g2, [ %i2 + 0xc ]
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
200854c: c2 26 a0 04 st %g1, [ %i2 + 4 ]
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
2008550: c8 26 a0 08 st %g4, [ %i2 + 8 ]
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008554: 80 a1 20 00 cmp %g4, 0
2008558: 02 80 00 0d be 200858c <rtems_object_get_class_information+0x84><== NEVER TAKEN
200855c: 84 10 20 00 clr %g2
2008560: da 02 20 1c ld [ %o0 + 0x1c ], %o5
2008564: 86 10 20 01 mov 1, %g3
2008568: 82 10 20 01 mov 1, %g1
if ( !obj_info->local_table[i] )
200856c: 87 28 e0 02 sll %g3, 2, %g3
2008570: c6 03 40 03 ld [ %o5 + %g3 ], %g3
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008574: 82 00 60 01 inc %g1
if ( !obj_info->local_table[i] )
unallocated++;
2008578: 80 a0 00 03 cmp %g0, %g3
200857c: 84 60 bf ff subx %g2, -1, %g2
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008580: 80 a1 00 01 cmp %g4, %g1
2008584: 1a bf ff fa bcc 200856c <rtems_object_get_class_information+0x64>
2008588: 86 10 00 01 mov %g1, %g3
if ( !obj_info->local_table[i] )
unallocated++;
info->unallocated = unallocated;
200858c: c4 26 a0 10 st %g2, [ %i2 + 0x10 ]
2008590: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
2008594: 81 c7 e0 08 ret
2008598: 81 e8 00 00 restore
02007eb4 <rtems_panic>:
void rtems_panic(
const char *printf_format,
...
)
{
2007eb4: 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);
2007eb8: 11 08 00 00 sethi %hi(0x20000000), %o0 <== NOT EXECUTED
...
)
{
va_list arglist;
va_start(arglist, printf_format);
2007ebc: 94 07 a0 48 add %fp, 0x48, %o2 <== NOT EXECUTED
2007ec0: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED
2007ec4: f4 27 a0 4c st %i2, [ %fp + 0x4c ] <== NOT EXECUTED
2007ec8: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED
2007ecc: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED
2007ed0: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
(void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist);
2007ed4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2007ed8: 7f ff ff 8a call 2007d00 <rtems_verror> <== NOT EXECUTED
2007edc: d4 27 bf fc st %o2, [ %fp + -4 ] <== NOT EXECUTED
va_end(arglist);
}
2007ee0: 81 c7 e0 08 ret <== NOT EXECUTED
2007ee4: 81 e8 00 00 restore <== NOT EXECUTED
02014734 <rtems_partition_create>:
uint32_t length,
uint32_t buffer_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
2014734: 9d e3 bf a0 save %sp, -96, %sp
register Partition_Control *the_partition;
if ( !rtems_is_name_valid( name ) )
2014738: a0 96 20 00 orcc %i0, 0, %l0
201473c: 02 80 00 31 be 2014800 <rtems_partition_create+0xcc>
2014740: b0 10 20 03 mov 3, %i0
return RTEMS_INVALID_NAME;
if ( !starting_address )
2014744: 80 a6 60 00 cmp %i1, 0
2014748: 02 80 00 32 be 2014810 <rtems_partition_create+0xdc>
201474c: 80 a7 60 00 cmp %i5, 0
return RTEMS_INVALID_ADDRESS;
if ( !id )
2014750: 02 80 00 30 be 2014810 <rtems_partition_create+0xdc> <== NEVER TAKEN
2014754: 80 a6 e0 00 cmp %i3, 0
return RTEMS_INVALID_ADDRESS;
if ( length == 0 || buffer_size == 0 || length < buffer_size ||
2014758: 02 80 00 2c be 2014808 <rtems_partition_create+0xd4>
201475c: 80 a6 a0 00 cmp %i2, 0
2014760: 02 80 00 2a be 2014808 <rtems_partition_create+0xd4>
2014764: 80 a6 80 1b cmp %i2, %i3
2014768: 0a 80 00 28 bcs 2014808 <rtems_partition_create+0xd4>
201476c: 80 8e e0 07 btst 7, %i3
2014770: 12 80 00 26 bne 2014808 <rtems_partition_create+0xd4>
2014774: 80 8e 60 07 btst 7, %i1
!_Partition_Is_buffer_size_aligned( buffer_size ) )
return RTEMS_INVALID_SIZE;
if ( !_Addresses_Is_aligned( starting_address ) )
2014778: 12 80 00 26 bne 2014810 <rtems_partition_create+0xdc>
201477c: 03 00 81 03 sethi %hi(0x2040c00), %g1
2014780: c4 00 60 e0 ld [ %g1 + 0xe0 ], %g2 ! 2040ce0 <_Thread_Dispatch_disable_level>
2014784: 84 00 a0 01 inc %g2
2014788: c4 20 60 e0 st %g2, [ %g1 + 0xe0 ]
* This function allocates a partition control block from
* the inactive chain of free partition control blocks.
*/
RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Allocate ( void )
{
return (Partition_Control *) _Objects_Allocate( &_Partition_Information );
201478c: 25 00 81 02 sethi %hi(0x2040800), %l2
2014790: 40 00 12 8d call 20191c4 <_Objects_Allocate>
2014794: 90 14 a2 e4 or %l2, 0x2e4, %o0 ! 2040ae4 <_Partition_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_partition = _Partition_Allocate();
if ( !the_partition ) {
2014798: a2 92 20 00 orcc %o0, 0, %l1
201479c: 02 80 00 1f be 2014818 <rtems_partition_create+0xe4>
20147a0: 92 10 00 1b mov %i3, %o1
#endif
the_partition->starting_address = starting_address;
the_partition->length = length;
the_partition->buffer_size = buffer_size;
the_partition->attribute_set = attribute_set;
20147a4: f8 24 60 1c st %i4, [ %l1 + 0x1c ]
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
#endif
the_partition->starting_address = starting_address;
20147a8: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
the_partition->length = length;
20147ac: f4 24 60 14 st %i2, [ %l1 + 0x14 ]
the_partition->buffer_size = buffer_size;
20147b0: f6 24 60 18 st %i3, [ %l1 + 0x18 ]
the_partition->attribute_set = attribute_set;
the_partition->number_of_used_blocks = 0;
20147b4: c0 24 60 20 clr [ %l1 + 0x20 ]
_Chain_Initialize( &the_partition->Memory, starting_address,
20147b8: 40 00 6c c1 call 202fabc <.udiv>
20147bc: 90 10 00 1a mov %i2, %o0
20147c0: 92 10 00 19 mov %i1, %o1
20147c4: 94 10 00 08 mov %o0, %o2
20147c8: 96 10 00 1b mov %i3, %o3
20147cc: b8 04 60 24 add %l1, 0x24, %i4
20147d0: 40 00 0c d7 call 2017b2c <_Chain_Initialize>
20147d4: 90 10 00 1c mov %i4, %o0
20147d8: c2 14 60 0a lduh [ %l1 + 0xa ], %g1
20147dc: c6 04 60 08 ld [ %l1 + 8 ], %g3
20147e0: a4 14 a2 e4 or %l2, 0x2e4, %l2
20147e4: c4 04 a0 1c ld [ %l2 + 0x1c ], %g2
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
20147e8: e0 24 60 0c st %l0, [ %l1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
20147ec: 83 28 60 02 sll %g1, 2, %g1
&_Partition_Information,
&the_partition->Object,
(Objects_Name) name
);
*id = the_partition->Object.id;
20147f0: c6 27 40 00 st %g3, [ %i5 ]
20147f4: e2 20 80 01 st %l1, [ %g2 + %g1 ]
name,
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
20147f8: 40 00 16 af call 201a2b4 <_Thread_Enable_dispatch>
20147fc: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
2014800: 81 c7 e0 08 ret
2014804: 81 e8 00 00 restore
}
2014808: 81 c7 e0 08 ret
201480c: 91 e8 20 08 restore %g0, 8, %o0
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
2014810: 81 c7 e0 08 ret
2014814: 91 e8 20 09 restore %g0, 9, %o0
_Thread_Disable_dispatch(); /* prevents deletion */
the_partition = _Partition_Allocate();
if ( !the_partition ) {
_Thread_Enable_dispatch();
2014818: 40 00 16 a7 call 201a2b4 <_Thread_Enable_dispatch>
201481c: b0 10 20 05 mov 5, %i0
return RTEMS_TOO_MANY;
2014820: 81 c7 e0 08 ret
2014824: 81 e8 00 00 restore
0200ab00 <rtems_pipe_initialize>:
/*
* Initialization of FIFO/pipe module.
*/
void rtems_pipe_initialize (void)
{
200ab00: 9d e3 bf a0 save %sp, -96, %sp
if (!rtems_pipe_configured)
200ab04: 03 00 80 7b sethi %hi(0x201ec00), %g1
200ab08: c2 08 62 e4 ldub [ %g1 + 0x2e4 ], %g1 ! 201eee4 <rtems_pipe_configured>
200ab0c: 80 a0 60 00 cmp %g1, 0
200ab10: 02 80 00 13 be 200ab5c <rtems_pipe_initialize+0x5c> <== ALWAYS TAKEN
200ab14: 19 00 80 7c sethi %hi(0x201f000), %o4
return;
if (rtems_pipe_semaphore)
200ab18: c2 03 20 48 ld [ %o4 + 0x48 ], %g1 ! 201f048 <rtems_pipe_semaphore><== NOT EXECUTED
200ab1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200ab20: 12 80 00 0f bne 200ab5c <rtems_pipe_initialize+0x5c> <== NOT EXECUTED
200ab24: 98 13 20 48 or %o4, 0x48, %o4 <== NOT EXECUTED
return;
rtems_status_code sc;
sc = rtems_semaphore_create(
200ab28: 11 14 12 54 sethi %hi(0x50495000), %o0 <== NOT EXECUTED
200ab2c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
200ab30: 90 12 20 45 or %o0, 0x45, %o0 <== NOT EXECUTED
200ab34: 94 10 20 54 mov 0x54, %o2 <== NOT EXECUTED
200ab38: 7f ff ee c6 call 2006650 <rtems_semaphore_create> <== NOT EXECUTED
200ab3c: 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)
200ab40: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200ab44: 12 80 00 08 bne 200ab64 <rtems_pipe_initialize+0x64> <== NOT EXECUTED
200ab48: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
rtems_interval now;
now = rtems_clock_get_ticks_since_boot();
200ab4c: 7f ff ed a1 call 20061d0 <rtems_clock_get_ticks_since_boot><== NOT EXECUTED
200ab50: 01 00 00 00 nop <== NOT EXECUTED
rtems_pipe_no = now;
200ab54: 03 00 80 7c sethi %hi(0x201f000), %g1 <== NOT EXECUTED
200ab58: d0 30 60 50 sth %o0, [ %g1 + 0x50 ] ! 201f050 <rtems_pipe_no><== NOT EXECUTED
200ab5c: 81 c7 e0 08 ret
200ab60: 81 e8 00 00 restore
sc = rtems_semaphore_create(
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)
rtems_fatal_error_occurred (sc);
200ab64: 7f ff f0 fd call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
02046ea8 <rtems_rate_monotonic_period>:
rtems_status_code rtems_rate_monotonic_period(
rtems_id id,
rtems_interval length
)
{
2046ea8: 9d e3 bf 98 save %sp, -104, %sp
2046eac: 11 00 81 d6 sethi %hi(0x2075800), %o0
2046eb0: 92 10 00 18 mov %i0, %o1
2046eb4: 90 12 21 68 or %o0, 0x168, %o0
2046eb8: 7f ff 21 a7 call 200f554 <_Objects_Get>
2046ebc: 94 07 bf fc add %fp, -4, %o2
rtems_rate_monotonic_period_states local_state;
ISR_Level level;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
2046ec0: c2 07 bf fc ld [ %fp + -4 ], %g1
2046ec4: 80 a0 60 00 cmp %g1, 0
2046ec8: 02 80 00 04 be 2046ed8 <rtems_rate_monotonic_period+0x30>
2046ecc: a0 10 00 08 mov %o0, %l0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2046ed0: 81 c7 e0 08 ret
2046ed4: 91 e8 20 04 restore %g0, 4, %o0
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( !_Thread_Is_executing( the_period->owner ) ) {
2046ed8: 23 00 81 d3 sethi %hi(0x2074c00), %l1
2046edc: c4 02 20 40 ld [ %o0 + 0x40 ], %g2
2046ee0: c2 04 63 00 ld [ %l1 + 0x300 ], %g1
2046ee4: 80 a0 80 01 cmp %g2, %g1
2046ee8: 02 80 00 06 be 2046f00 <rtems_rate_monotonic_period+0x58>
2046eec: 80 a6 60 00 cmp %i1, 0
_Thread_Enable_dispatch();
2046ef0: 7f ff 24 42 call 200fff8 <_Thread_Enable_dispatch>
2046ef4: b0 10 20 17 mov 0x17, %i0
return RTEMS_NOT_OWNER_OF_RESOURCE;
2046ef8: 81 c7 e0 08 ret
2046efc: 81 e8 00 00 restore
}
if ( length == RTEMS_PERIOD_STATUS ) {
2046f00: 12 80 00 0e bne 2046f38 <rtems_rate_monotonic_period+0x90>
2046f04: 01 00 00 00 nop
switch ( the_period->state ) {
2046f08: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
2046f0c: 80 a0 60 04 cmp %g1, 4
2046f10: 18 80 00 06 bgu 2046f28 <rtems_rate_monotonic_period+0x80><== NEVER TAKEN
2046f14: b0 10 20 00 clr %i0
2046f18: 83 28 60 02 sll %g1, 2, %g1
2046f1c: 05 00 81 bb sethi %hi(0x206ec00), %g2
2046f20: 84 10 a3 50 or %g2, 0x350, %g2 ! 206ef50 <CSWTCH.48>
2046f24: f0 00 80 01 ld [ %g2 + %g1 ], %i0
);
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
2046f28: 7f ff 24 34 call 200fff8 <_Thread_Enable_dispatch>
2046f2c: 01 00 00 00 nop
return RTEMS_SUCCESSFUL;
2046f30: 81 c7 e0 08 ret
2046f34: 81 e8 00 00 restore
}
_Thread_Enable_dispatch();
return( return_value );
}
_ISR_Disable( level );
2046f38: 7f fe f2 ba call 2003a20 <sparc_disable_interrupts>
2046f3c: 01 00 00 00 nop
2046f40: a6 10 00 08 mov %o0, %l3
switch ( the_period->state ) {
2046f44: e4 04 20 38 ld [ %l0 + 0x38 ], %l2
2046f48: 80 a4 a0 02 cmp %l2, 2
2046f4c: 02 80 00 1a be 2046fb4 <rtems_rate_monotonic_period+0x10c>
2046f50: 80 a4 a0 04 cmp %l2, 4
2046f54: 02 80 00 32 be 204701c <rtems_rate_monotonic_period+0x174>
2046f58: 80 a4 a0 00 cmp %l2, 0
2046f5c: 12 bf ff dd bne 2046ed0 <rtems_rate_monotonic_period+0x28><== NEVER TAKEN
2046f60: 01 00 00 00 nop
case RATE_MONOTONIC_INACTIVE: {
_ISR_Enable( level );
2046f64: 7f fe f2 b3 call 2003a30 <sparc_enable_interrupts>
2046f68: 01 00 00 00 nop
/*
* Baseline statistics information for the beginning of a period.
*/
_Rate_monotonic_Initiate_statistics( the_period );
2046f6c: 7f ff ff 48 call 2046c8c <_Rate_monotonic_Initiate_statistics>
2046f70: 90 10 00 10 mov %l0, %o0
the_period->state = RATE_MONOTONIC_ACTIVE;
2046f74: 82 10 20 02 mov 2, %g1
2046f78: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2046f7c: 03 00 81 1c sethi %hi(0x2047000), %g1
2046f80: 82 10 60 6c or %g1, 0x6c, %g1 ! 204706c <_Rate_monotonic_Timeout>
the_watchdog->id = id;
2046f84: f0 24 20 30 st %i0, [ %l0 + 0x30 ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2046f88: 92 04 20 10 add %l0, 0x10, %o1
2046f8c: 11 00 81 d3 sethi %hi(0x2074c00), %o0
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2046f90: f2 24 20 1c st %i1, [ %l0 + 0x1c ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2046f94: 90 12 23 20 or %o0, 0x320, %o0
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2046f98: c0 24 20 18 clr [ %l0 + 0x18 ]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
2046f9c: c0 24 20 34 clr [ %l0 + 0x34 ]
_Rate_monotonic_Timeout,
id,
NULL
);
the_period->next_length = length;
2046fa0: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2046fa4: c2 24 20 2c st %g1, [ %l0 + 0x2c ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2046fa8: 7f ff 28 d8 call 2011308 <_Watchdog_Insert>
2046fac: b0 10 20 00 clr %i0
2046fb0: 30 bf ff de b,a 2046f28 <rtems_rate_monotonic_period+0x80>
case RATE_MONOTONIC_ACTIVE:
/*
* Update statistics from the concluding period.
*/
_Rate_monotonic_Update_statistics( the_period );
2046fb4: 7f ff ff 7d call 2046da8 <_Rate_monotonic_Update_statistics>
2046fb8: 90 10 00 10 mov %l0, %o0
/*
* This tells the _Rate_monotonic_Timeout that this task is
* in the process of blocking on the period and that we
* may be changing the length of the next period.
*/
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
2046fbc: 82 10 20 01 mov 1, %g1
the_period->next_length = length;
2046fc0: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
/*
* This tells the _Rate_monotonic_Timeout that this task is
* in the process of blocking on the period and that we
* may be changing the length of the next period.
*/
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
2046fc4: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
the_period->next_length = length;
_ISR_Enable( level );
2046fc8: 7f fe f2 9a call 2003a30 <sparc_enable_interrupts>
2046fcc: 90 10 00 13 mov %l3, %o0
_Thread_Executing->Wait.id = the_period->Object.id;
2046fd0: c2 04 63 00 ld [ %l1 + 0x300 ], %g1
2046fd4: c4 04 20 08 ld [ %l0 + 8 ], %g2
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
2046fd8: 90 10 00 01 mov %g1, %o0
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
the_period->next_length = length;
_ISR_Enable( level );
_Thread_Executing->Wait.id = the_period->Object.id;
2046fdc: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
2046fe0: 7f ff 26 ae call 2010a98 <_Thread_Set_state>
2046fe4: 13 00 00 10 sethi %hi(0x4000), %o1
/*
* Did the watchdog timer expire while we were actually blocking
* on it?
*/
_ISR_Disable( level );
2046fe8: 7f fe f2 8e call 2003a20 <sparc_disable_interrupts>
2046fec: 01 00 00 00 nop
local_state = the_period->state;
2046ff0: e6 04 20 38 ld [ %l0 + 0x38 ], %l3
the_period->state = RATE_MONOTONIC_ACTIVE;
2046ff4: e4 24 20 38 st %l2, [ %l0 + 0x38 ]
_ISR_Enable( level );
2046ff8: 7f fe f2 8e call 2003a30 <sparc_enable_interrupts>
2046ffc: 01 00 00 00 nop
/*
* If it did, then we want to unblock ourself and continue as
* if nothing happen. The period was reset in the timeout routine.
*/
if ( local_state == RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING )
2047000: 80 a4 e0 03 cmp %l3, 3
2047004: 02 80 00 17 be 2047060 <rtems_rate_monotonic_period+0x1b8>
2047008: d0 04 63 00 ld [ %l1 + 0x300 ], %o0
_Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
_Thread_Enable_dispatch();
204700c: 7f ff 23 fb call 200fff8 <_Thread_Enable_dispatch>
2047010: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
2047014: 81 c7 e0 08 ret
2047018: 81 e8 00 00 restore
case RATE_MONOTONIC_EXPIRED:
/*
* Update statistics from the concluding period
*/
_Rate_monotonic_Update_statistics( the_period );
204701c: 7f ff ff 63 call 2046da8 <_Rate_monotonic_Update_statistics>
2047020: 90 10 00 10 mov %l0, %o0
_ISR_Enable( level );
2047024: 7f fe f2 83 call 2003a30 <sparc_enable_interrupts>
2047028: 90 10 00 13 mov %l3, %o0
the_period->state = RATE_MONOTONIC_ACTIVE;
204702c: 82 10 20 02 mov 2, %g1
2047030: 92 04 20 10 add %l0, 0x10, %o1
2047034: 11 00 81 d3 sethi %hi(0x2074c00), %o0
2047038: 90 12 23 20 or %o0, 0x320, %o0 ! 2074f20 <_Watchdog_Ticks_chain>
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
204703c: f2 24 20 1c st %i1, [ %l0 + 0x1c ]
the_period->next_length = length;
2047040: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
*/
_Rate_monotonic_Update_statistics( the_period );
_ISR_Enable( level );
the_period->state = RATE_MONOTONIC_ACTIVE;
2047044: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2047048: 7f ff 28 b0 call 2011308 <_Watchdog_Insert>
204704c: b0 10 20 06 mov 6, %i0
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
2047050: 7f ff 23 ea call 200fff8 <_Thread_Enable_dispatch>
2047054: 01 00 00 00 nop
return RTEMS_TIMEOUT;
2047058: 81 c7 e0 08 ret
204705c: 81 e8 00 00 restore
/*
* If it did, then we want to unblock ourself and continue as
* if nothing happen. The period was reset in the timeout routine.
*/
if ( local_state == RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING )
_Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
2047060: 7f ff 22 cc call 200fb90 <_Thread_Clear_state>
2047064: 13 00 00 10 sethi %hi(0x4000), %o1
2047068: 30 bf ff e9 b,a 204700c <rtems_rate_monotonic_period+0x164>
0202fcb0 <rtems_rate_monotonic_report_statistics_with_plugin>:
*/
void rtems_rate_monotonic_report_statistics_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
202fcb0: 9d e3 bf 30 save %sp, -208, %sp
rtems_id id;
rtems_rate_monotonic_period_statistics the_stats;
rtems_rate_monotonic_period_status the_status;
char name[5];
if ( !print )
202fcb4: 80 a6 60 00 cmp %i1, 0
202fcb8: 02 80 00 4d be 202fdec <rtems_rate_monotonic_report_statistics_with_plugin+0x13c><== NEVER TAKEN
202fcbc: 90 10 00 18 mov %i0, %o0
return;
(*print)( context, "Period information by period\n" );
202fcc0: 13 00 81 ac sethi %hi(0x206b000), %o1
202fcc4: 9f c6 40 00 call %i1
202fcc8: 92 12 61 f8 or %o1, 0x1f8, %o1 ! 206b1f8 <_TOD_Days_per_month+0x68>
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
(*print)( context, "--- CPU times are in seconds ---\n" );
202fccc: 90 10 00 18 mov %i0, %o0
202fcd0: 13 00 81 ac sethi %hi(0x206b000), %o1
202fcd4: 9f c6 40 00 call %i1
202fcd8: 92 12 62 18 or %o1, 0x218, %o1 ! 206b218 <_TOD_Days_per_month+0x88>
(*print)( context, "--- Wall times are in seconds ---\n" );
202fcdc: 90 10 00 18 mov %i0, %o0
202fce0: 13 00 81 ac sethi %hi(0x206b000), %o1
202fce4: 9f c6 40 00 call %i1
202fce8: 92 12 62 40 or %o1, 0x240, %o1 ! 206b240 <_TOD_Days_per_month+0xb0>
Be sure to test the various cases.
(*print)( context,"\
1234567890123456789012345678901234567890123456789012345678901234567890123456789\
\n");
*/
(*print)( context, " ID OWNER COUNT MISSED "
202fcec: 90 10 00 18 mov %i0, %o0
202fcf0: 13 00 81 ac sethi %hi(0x206b000), %o1
202fcf4: 9f c6 40 00 call %i1
202fcf8: 92 12 62 68 or %o1, 0x268, %o1 ! 206b268 <_TOD_Days_per_month+0xd8>
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
" "
#endif
" WALL TIME\n"
);
(*print)( context, " "
202fcfc: 90 10 00 18 mov %i0, %o0
202fd00: 13 00 81 ac sethi %hi(0x206b000), %o1
202fd04: 9f c6 40 00 call %i1
202fd08: 92 12 62 b8 or %o1, 0x2b8, %o1 ! 206b2b8 <_TOD_Days_per_month+0x128>
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202fd0c: 23 00 81 d6 sethi %hi(0x2075800), %l1
202fd10: a2 14 61 68 or %l1, 0x168, %l1 ! 2075968 <_Rate_monotonic_Information>
202fd14: e0 04 60 08 ld [ %l1 + 8 ], %l0
202fd18: c2 04 60 0c ld [ %l1 + 0xc ], %g1
202fd1c: 80 a4 00 01 cmp %l0, %g1
202fd20: 18 80 00 33 bgu 202fdec <rtems_rate_monotonic_report_statistics_with_plugin+0x13c><== NEVER TAKEN
202fd24: 3b 00 81 ac sethi %hi(0x206b000), %i5
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
(*print)( context,
202fd28: 39 00 81 ac sethi %hi(0x206b000), %i4
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
(*print)( context,
202fd2c: 35 00 81 ac sethi %hi(0x206b000), %i2
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
(*print)( context, "\n" );
202fd30: 2f 00 81 ac sethi %hi(0x206b000), %l7
rtems_object_get_name( the_status.owner, sizeof(name), name );
/*
* Print part of report line that is not dependent on granularity
*/
(*print)( context,
202fd34: ba 17 63 08 or %i5, 0x308, %i5
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
(*print)( context,
202fd38: b8 17 23 28 or %i4, 0x328, %i4
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
(*print)( context,
202fd3c: b4 16 a3 48 or %i2, 0x348, %i2
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
(*print)( context, "\n" );
202fd40: ae 15 e3 20 or %l7, 0x320, %l7
202fd44: a4 07 bf a0 add %fp, -96, %l2
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
if ( status != RTEMS_SUCCESSFUL )
continue;
/* If the above passed, so should this but check it anyway */
status = rtems_rate_monotonic_get_status( id, &the_status );
202fd48: ac 07 bf d8 add %fp, -40, %l6
#if defined(RTEMS_DEBUG)
if ( status != RTEMS_SUCCESSFUL )
continue;
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
202fd4c: a6 07 bf f8 add %fp, -8, %l3
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202fd50: aa 07 bf b8 add %fp, -72, %l5
202fd54: 10 80 00 06 b 202fd6c <rtems_rate_monotonic_report_statistics_with_plugin+0xbc>
202fd58: a8 07 bf f0 add %fp, -16, %l4
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202fd5c: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202fd60: 80 a0 40 10 cmp %g1, %l0
202fd64: 0a 80 00 22 bcs 202fdec <rtems_rate_monotonic_report_statistics_with_plugin+0x13c>
202fd68: 01 00 00 00 nop
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
202fd6c: 90 10 00 10 mov %l0, %o0
202fd70: 40 00 5b 67 call 2046b0c <rtems_rate_monotonic_get_statistics>
202fd74: 92 10 00 12 mov %l2, %o1
if ( status != RTEMS_SUCCESSFUL )
202fd78: 80 a2 20 00 cmp %o0, 0
202fd7c: 32 bf ff f8 bne,a 202fd5c <rtems_rate_monotonic_report_statistics_with_plugin+0xac>
202fd80: c2 04 60 0c ld [ %l1 + 0xc ], %g1
continue;
/* If the above passed, so should this but check it anyway */
status = rtems_rate_monotonic_get_status( id, &the_status );
202fd84: 92 10 00 16 mov %l6, %o1
202fd88: 40 00 5b 90 call 2046bc8 <rtems_rate_monotonic_get_status>
202fd8c: 90 10 00 10 mov %l0, %o0
#if defined(RTEMS_DEBUG)
if ( status != RTEMS_SUCCESSFUL )
continue;
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
202fd90: d0 07 bf d8 ld [ %fp + -40 ], %o0
202fd94: 94 10 00 13 mov %l3, %o2
202fd98: 7f ff 75 6a call 200d340 <rtems_object_get_name>
202fd9c: 92 10 20 05 mov 5, %o1
/*
* Print part of report line that is not dependent on granularity
*/
(*print)( context,
202fda0: d8 1f bf a0 ldd [ %fp + -96 ], %o4
202fda4: 92 10 00 1d mov %i5, %o1
202fda8: 94 10 00 10 mov %l0, %o2
202fdac: 90 10 00 18 mov %i0, %o0
202fdb0: 9f c6 40 00 call %i1
202fdb4: 96 10 00 13 mov %l3, %o3
);
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
202fdb8: c2 07 bf a0 ld [ %fp + -96 ], %g1
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202fdbc: 94 10 00 14 mov %l4, %o2
202fdc0: 90 10 00 15 mov %l5, %o0
);
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
202fdc4: 80 a0 60 00 cmp %g1, 0
202fdc8: 12 80 00 0b bne 202fdf4 <rtems_rate_monotonic_report_statistics_with_plugin+0x144>
202fdcc: 92 10 00 17 mov %l7, %o1
(*print)( context, "\n" );
202fdd0: 9f c6 40 00 call %i1
202fdd4: 90 10 00 18 mov %i0, %o0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202fdd8: c2 04 60 0c ld [ %l1 + 0xc ], %g1
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202fddc: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202fde0: 80 a0 40 10 cmp %g1, %l0
202fde4: 1a bf ff e3 bcc 202fd70 <rtems_rate_monotonic_report_statistics_with_plugin+0xc0><== ALWAYS TAKEN
202fde8: 90 10 00 10 mov %l0, %o0
202fdec: 81 c7 e0 08 ret
202fdf0: 81 e8 00 00 restore
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202fdf4: 40 00 05 b6 call 20314cc <_Timespec_Divide_by_integer>
202fdf8: 92 10 00 01 mov %g1, %o1
(*print)( context,
202fdfc: d0 07 bf ac ld [ %fp + -84 ], %o0
202fe00: 40 00 ca e3 call 206298c <.div>
202fe04: 92 10 23 e8 mov 0x3e8, %o1
202fe08: 96 10 00 08 mov %o0, %o3
202fe0c: d0 07 bf b4 ld [ %fp + -76 ], %o0
202fe10: d6 27 bf 9c st %o3, [ %fp + -100 ]
202fe14: 40 00 ca de call 206298c <.div>
202fe18: 92 10 23 e8 mov 0x3e8, %o1
202fe1c: c2 07 bf f0 ld [ %fp + -16 ], %g1
202fe20: b6 10 00 08 mov %o0, %i3
202fe24: d0 07 bf f4 ld [ %fp + -12 ], %o0
202fe28: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
202fe2c: 40 00 ca d8 call 206298c <.div>
202fe30: 92 10 23 e8 mov 0x3e8, %o1
202fe34: d8 07 bf b0 ld [ %fp + -80 ], %o4
202fe38: d6 07 bf 9c ld [ %fp + -100 ], %o3
202fe3c: d4 07 bf a8 ld [ %fp + -88 ], %o2
202fe40: 9a 10 00 1b mov %i3, %o5
202fe44: d0 23 a0 60 st %o0, [ %sp + 0x60 ]
202fe48: 92 10 00 1c mov %i4, %o1
202fe4c: 9f c6 40 00 call %i1
202fe50: 90 10 00 18 mov %i0, %o0
struct timespec wall_average;
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
202fe54: d2 07 bf a0 ld [ %fp + -96 ], %o1
202fe58: 94 10 00 14 mov %l4, %o2
202fe5c: 40 00 05 9c call 20314cc <_Timespec_Divide_by_integer>
202fe60: 90 07 bf d0 add %fp, -48, %o0
(*print)( context,
202fe64: d0 07 bf c4 ld [ %fp + -60 ], %o0
202fe68: 40 00 ca c9 call 206298c <.div>
202fe6c: 92 10 23 e8 mov 0x3e8, %o1
202fe70: 96 10 00 08 mov %o0, %o3
202fe74: d0 07 bf cc ld [ %fp + -52 ], %o0
202fe78: d6 27 bf 9c st %o3, [ %fp + -100 ]
202fe7c: 40 00 ca c4 call 206298c <.div>
202fe80: 92 10 23 e8 mov 0x3e8, %o1
202fe84: c2 07 bf f0 ld [ %fp + -16 ], %g1
202fe88: b6 10 00 08 mov %o0, %i3
202fe8c: d0 07 bf f4 ld [ %fp + -12 ], %o0
202fe90: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
202fe94: 40 00 ca be call 206298c <.div>
202fe98: 92 10 23 e8 mov 0x3e8, %o1
202fe9c: d4 07 bf c0 ld [ %fp + -64 ], %o2
202fea0: d6 07 bf 9c ld [ %fp + -100 ], %o3
202fea4: d8 07 bf c8 ld [ %fp + -56 ], %o4
202fea8: d0 23 a0 60 st %o0, [ %sp + 0x60 ]
202feac: 9a 10 00 1b mov %i3, %o5
202feb0: 90 10 00 18 mov %i0, %o0
202feb4: 9f c6 40 00 call %i1
202feb8: 92 10 00 1a mov %i2, %o1
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202febc: 10 bf ff a8 b 202fd5c <rtems_rate_monotonic_report_statistics_with_plugin+0xac>
202fec0: c2 04 60 0c ld [ %l1 + 0xc ], %g1
0202fee0 <rtems_rate_monotonic_reset_all_statistics>:
/*
* rtems_rate_monotonic_reset_all_statistics
*/
void rtems_rate_monotonic_reset_all_statistics( void )
{
202fee0: 9d e3 bf a0 save %sp, -96, %sp
202fee4: 03 00 81 d3 sethi %hi(0x2074c00), %g1
202fee8: c4 00 62 40 ld [ %g1 + 0x240 ], %g2 ! 2074e40 <_Thread_Dispatch_disable_level>
202feec: 84 00 a0 01 inc %g2
202fef0: c4 20 62 40 st %g2, [ %g1 + 0x240 ]
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202fef4: 23 00 81 d6 sethi %hi(0x2075800), %l1
202fef8: a2 14 61 68 or %l1, 0x168, %l1 ! 2075968 <_Rate_monotonic_Information>
202fefc: e0 04 60 08 ld [ %l1 + 8 ], %l0
202ff00: c2 04 60 0c ld [ %l1 + 0xc ], %g1
202ff04: 80 a4 00 01 cmp %l0, %g1
202ff08: 18 80 00 09 bgu 202ff2c <rtems_rate_monotonic_reset_all_statistics+0x4c><== NEVER TAKEN
202ff0c: 01 00 00 00 nop
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_reset_statistics( id );
202ff10: 40 00 00 0a call 202ff38 <rtems_rate_monotonic_reset_statistics>
202ff14: 90 10 00 10 mov %l0, %o0
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202ff18: c2 04 60 0c ld [ %l1 + 0xc ], %g1
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202ff1c: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202ff20: 80 a0 40 10 cmp %g1, %l0
202ff24: 1a bf ff fb bcc 202ff10 <rtems_rate_monotonic_reset_all_statistics+0x30>
202ff28: 01 00 00 00 nop
}
/*
* Done so exit thread dispatching disabled critical section.
*/
_Thread_Enable_dispatch();
202ff2c: 7f ff 80 33 call 200fff8 <_Thread_Enable_dispatch>
202ff30: 81 e8 00 00 restore
02015618 <rtems_region_get_segment_size>:
rtems_status_code rtems_region_get_segment_size(
rtems_id id,
void *segment,
uintptr_t *size
)
{
2015618: 9d e3 bf 98 save %sp, -104, %sp
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
register Region_Control *the_region;
if ( !segment )
201561c: 80 a6 60 00 cmp %i1, 0
2015620: 02 80 00 22 be 20156a8 <rtems_region_get_segment_size+0x90>
2015624: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
if ( !size )
2015628: 02 80 00 20 be 20156a8 <rtems_region_get_segment_size+0x90>
201562c: 21 00 81 03 sethi %hi(0x2040c00), %l0
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
2015630: 40 00 08 f4 call 2017a00 <_API_Mutex_Lock>
2015634: d0 04 21 98 ld [ %l0 + 0x198 ], %o0 ! 2040d98 <_RTEMS_Allocator_Mutex>
2015638: 92 10 00 18 mov %i0, %o1
201563c: 11 00 81 02 sethi %hi(0x2040800), %o0
2015640: 94 07 bf fc add %fp, -4, %o2
2015644: 40 00 10 34 call 2019714 <_Objects_Get_no_protection>
2015648: 90 12 23 64 or %o0, 0x364, %o0
the_region = _Region_Get( id, &location );
switch ( location ) {
201564c: c2 07 bf fc ld [ %fp + -4 ], %g1
2015650: 80 a0 60 00 cmp %g1, 0
2015654: 12 80 00 0f bne 2015690 <rtems_region_get_segment_size+0x78>
2015658: 80 a0 60 01 cmp %g1, 1
case OBJECTS_LOCAL:
if ( !_Heap_Size_of_alloc_area( &the_region->Memory, segment, size ) )
201565c: 90 02 20 68 add %o0, 0x68, %o0
2015660: 92 10 00 19 mov %i1, %o1
2015664: 94 10 00 1a mov %i2, %o2
2015668: 40 00 0e 88 call 2019088 <_Heap_Size_of_alloc_area>
201566c: b0 10 20 09 mov 9, %i0
2015670: 80 8a 20 ff btst 0xff, %o0
2015674: 02 80 00 03 be 2015680 <rtems_region_get_segment_size+0x68><== NEVER TAKEN
2015678: 01 00 00 00 nop
201567c: b0 10 20 00 clr %i0 ! 0 <PROM_START>
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
2015680: 40 00 08 f6 call 2017a58 <_API_Mutex_Unlock>
2015684: d0 04 21 98 ld [ %l0 + 0x198 ], %o0
return return_status;
2015688: 81 c7 e0 08 ret
201568c: 81 e8 00 00 restore
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
the_region = _Region_Get( id, &location );
switch ( location ) {
2015690: 12 bf ff fb bne 201567c <rtems_region_get_segment_size+0x64><== NEVER TAKEN
2015694: b0 10 20 04 mov 4, %i0
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
2015698: 40 00 08 f0 call 2017a58 <_API_Mutex_Unlock>
201569c: d0 04 21 98 ld [ %l0 + 0x198 ], %o0
return return_status;
20156a0: 81 c7 e0 08 ret
20156a4: 81 e8 00 00 restore
}
20156a8: 81 c7 e0 08 ret
20156ac: 91 e8 20 09 restore %g0, 9, %o0
020493c0 <rtems_rfs_bitmap_close>:
return rtems_rfs_bitmap_create_search (control);
}
int
rtems_rfs_bitmap_close (rtems_rfs_bitmap_control* control)
{
20493c0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
free (control->search_bits);
20493c4: d0 06 20 14 ld [ %i0 + 0x14 ], %o0 <== NOT EXECUTED
20493c8: 7f fe fd 45 call 20088dc <free> <== NOT EXECUTED
20493cc: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
20493d0: 81 c7 e0 08 ret <== NOT EXECUTED
20493d4: 81 e8 00 00 restore <== NOT EXECUTED
02049428 <rtems_rfs_bitmap_create_search>:
return 0;
}
int
rtems_rfs_bitmap_create_search (rtems_rfs_bitmap_control* control)
{
2049428: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_map map;
size_t size;
rtems_rfs_bitmap_bit bit;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
204942c: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
2049430: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2049434: 7f ff ff e9 call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
2049438: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rc > 0)
204943c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049440: 24 80 00 04 ble,a 2049450 <rtems_rfs_bitmap_create_search+0x28><== NOT EXECUTED
2049444: d0 06 20 14 ld [ %i0 + 0x14 ], %o0 <== NOT EXECUTED
bit++;
map++;
}
return 0;
}
2049448: 81 c7 e0 08 ret <== NOT EXECUTED
204944c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
if (rc > 0)
return rc;
control->free = 0;
search_map = control->search_bits;
size = control->size;
2049450: da 06 20 0c ld [ %i0 + 0xc ], %o5 <== NOT EXECUTED
bit = 0;
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
2049454: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
control->free = 0;
2049458: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
search_map = control->search_bits;
size = control->size;
bit = 0;
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
while (size)
204945c: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
2049460: 02 80 00 25 be 20494f4 <rtems_rfs_bitmap_create_search+0xcc><== NOT EXECUTED
2049464: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2049468: d6 07 bf fc ld [ %fp + -4 ], %o3 <== NOT EXECUTED
204946c: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_bitmap_mask_section (0, size));
available = size;
}
else
{
bits = *map;
2049470: a2 10 20 20 mov 0x20, %l1 <== NOT EXECUTED
{
/*
* Use the normal bit operators because we do not change the bits just merge
* the 2 separate parts.
*/
bits1 &= mask;
2049474: 9e 10 3f ff mov -1, %o7 <== NOT EXECUTED
rtems_rfs_bitmap_set (*search_map, bit);
else
{
int b;
for (b = 0; b < available; b++)
if (!rtems_rfs_bitmap_test (bits, b))
2049478: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
while (size)
{
rtems_rfs_bitmap_element bits;
int available;
if (size < rtems_rfs_bitmap_element_bits ())
204947c: 80 a3 60 1f cmp %o5, 0x1f <== NOT EXECUTED
2049480: 38 80 00 20 bgu,a 2049500 <rtems_rfs_bitmap_create_search+0xd8><== NOT EXECUTED
2049484: c6 02 c0 00 ld [ %o3 ], %g3 <== NOT EXECUTED
{
/*
* Use the normal bit operators because we do not change the bits just merge
* the 2 separate parts.
*/
bits1 &= mask;
2049488: c2 02 c0 00 ld [ %o3 ], %g1 <== NOT EXECUTED
204948c: 86 24 40 0d sub %l1, %o5, %g3 <== NOT EXECUTED
if (size < rtems_rfs_bitmap_element_bits ())
{
bits = rtems_rfs_bitmap_merge (*map,
RTEMS_RFS_BITMAP_ELEMENT_SET,
rtems_rfs_bitmap_mask_section (0, size));
available = size;
2049490: 88 10 00 0d mov %o5, %g4 <== NOT EXECUTED
{
/*
* Use the normal bit operators because we do not change the bits just merge
* the 2 separate parts.
*/
bits1 &= mask;
2049494: 87 33 c0 03 srl %o7, %g3, %g3 <== NOT EXECUTED
if (size < rtems_rfs_bitmap_element_bits ())
{
bits = rtems_rfs_bitmap_merge (*map,
RTEMS_RFS_BITMAP_ELEMENT_SET,
rtems_rfs_bitmap_mask_section (0, size));
available = size;
2049498: 92 10 00 0d mov %o5, %o1 <== NOT EXECUTED
{
/*
* Use the normal bit operators because we do not change the bits just merge
* the 2 separate parts.
*/
bits1 &= mask;
204949c: 86 08 c0 01 and %g3, %g1, %g3 <== NOT EXECUTED
{
bits = *map;
available = rtems_rfs_bitmap_element_bits ();
}
if (rtems_rfs_bitmap_match (bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
20494a0: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20494a4: 02 80 00 0e be 20494dc <rtems_rfs_bitmap_create_search+0xb4><== NOT EXECUTED
20494a8: 80 a2 a0 20 cmp %o2, 0x20 <== NOT EXECUTED
20494ac: 82 10 20 00 clr %g1 <== NOT EXECUTED
rtems_rfs_bitmap_set (*search_map, bit);
else
{
int b;
for (b = 0; b < available; b++)
if (!rtems_rfs_bitmap_test (bits, b))
20494b0: 85 2b 00 01 sll %o4, %g1, %g2 <== NOT EXECUTED
20494b4: 80 88 80 03 btst %g2, %g3 <== NOT EXECUTED
20494b8: 02 80 00 05 be 20494cc <rtems_rfs_bitmap_create_search+0xa4><== NOT EXECUTED
20494bc: 82 00 60 01 inc %g1 <== NOT EXECUTED
control->free++;
20494c0: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
20494c4: 84 00 a0 01 inc %g2 <== NOT EXECUTED
20494c8: c4 24 20 10 st %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
if (rtems_rfs_bitmap_match (bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
rtems_rfs_bitmap_set (*search_map, bit);
else
{
int b;
for (b = 0; b < available; b++)
20494cc: 80 a1 00 01 cmp %g4, %g1 <== NOT EXECUTED
20494d0: 14 bf ff f9 bg 20494b4 <rtems_rfs_bitmap_create_search+0x8c><== NOT EXECUTED
20494d4: 85 2b 00 01 sll %o4, %g1, %g2 <== NOT EXECUTED
control->free++;
}
size -= available;
if (bit == rtems_rfs_bitmap_element_bits ())
20494d8: 80 a2 a0 20 cmp %o2, 0x20 <== NOT EXECUTED
20494dc: 02 80 00 0c be 204950c <rtems_rfs_bitmap_create_search+0xe4><== NOT EXECUTED
20494e0: 9a 23 40 09 sub %o5, %o1, %o5 <== NOT EXECUTED
bit = 0;
search_map++;
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
}
else
bit++;
20494e4: 94 02 a0 01 inc %o2 <== NOT EXECUTED
search_map = control->search_bits;
size = control->size;
bit = 0;
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
while (size)
20494e8: 80 a3 60 00 cmp %o5, 0 <== NOT EXECUTED
20494ec: 12 bf ff e4 bne 204947c <rtems_rfs_bitmap_create_search+0x54><== NOT EXECUTED
20494f0: 96 02 e0 04 add %o3, 4, %o3 <== NOT EXECUTED
20494f4: 90 10 20 00 clr %o0 <== NOT EXECUTED
bit++;
map++;
}
return 0;
}
20494f8: 81 c7 e0 08 ret <== NOT EXECUTED
20494fc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_mask_section (0, size));
available = size;
}
else
{
bits = *map;
2049500: 92 10 20 20 mov 0x20, %o1 <== NOT EXECUTED
2049504: 10 bf ff e7 b 20494a0 <rtems_rfs_bitmap_create_search+0x78><== NOT EXECUTED
2049508: 88 10 20 20 mov 0x20, %g4 <== NOT EXECUTED
size -= available;
if (bit == rtems_rfs_bitmap_element_bits ())
{
bit = 0;
search_map++;
204950c: 90 02 20 04 add %o0, 4, %o0 <== NOT EXECUTED
*search_map = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
2049510: 94 10 20 00 clr %o2 <== NOT EXECUTED
2049514: 10 bf ff f5 b 20494e8 <rtems_rfs_bitmap_create_search+0xc0><== NOT EXECUTED
2049518: de 22 00 00 st %o7, [ %o0 ] <== NOT EXECUTED
020493d8 <rtems_rfs_bitmap_load_map>:
* @return int The error number (errno). No error if 0.
*/
static int
rtems_rfs_bitmap_load_map (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_map* map)
{
20493d8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
if (!control->buffer)
20493dc: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
* @return int The error number (errno). No error if 0.
*/
static int
rtems_rfs_bitmap_load_map (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_map* map)
{
20493e0: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc;
if (!control->buffer)
20493e4: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
20493e8: 02 80 00 0e be 2049420 <rtems_rfs_bitmap_load_map+0x48> <== NOT EXECUTED
20493ec: b0 10 20 06 mov 6, %i0 <== NOT EXECUTED
return ENXIO;
*map = NULL;
rc = rtems_rfs_buffer_handle_request (control->fs,
20493f0: d0 04 20 04 ld [ %l0 + 4 ], %o0 <== NOT EXECUTED
20493f4: d4 04 20 08 ld [ %l0 + 8 ], %o2 <== NOT EXECUTED
int rc;
if (!control->buffer)
return ENXIO;
*map = NULL;
20493f8: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (control->fs,
20493fc: 7f ff d9 48 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2049400: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
control->buffer,
control->block,
true);
if (rc)
2049404: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2049408: 12 80 00 06 bne 2049420 <rtems_rfs_bitmap_load_map+0x48> <== NOT EXECUTED
204940c: 01 00 00 00 nop <== NOT EXECUTED
return rc;
*map = rtems_rfs_buffer_data (control->buffer);
2049410: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
2049414: c2 00 60 08 ld [ %g1 + 8 ], %g1 <== NOT EXECUTED
2049418: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
204941c: c2 26 40 00 st %g1, [ %i1 ] <== NOT EXECUTED
return 0;
}
2049420: 81 c7 e0 08 ret <== NOT EXECUTED
2049424: 81 e8 00 00 restore <== NOT EXECUTED
02049b0c <rtems_rfs_bitmap_map_alloc>:
int
rtems_rfs_bitmap_map_alloc (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_bit seed,
bool* allocated,
rtems_rfs_bitmap_bit* bit)
{
2049b0c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = 0;
/*
* By default we assume the allocation failed.
*/
*allocated = false;
2049b10: c0 2e 80 00 clrb [ %i2 ] <== NOT EXECUTED
2049b14: a0 10 00 19 mov %i1, %l0 <== NOT EXECUTED
* we have searched all of the map. The seed may not be aligned to a window
* boundary so we may need to search a partial window and this may also not
* be balanced for the upper or lower seeds. We move to the limits, search
* then return false if no clear bits are found.
*/
while (((upper_seed >= 0) && (upper_seed < control->size))
2049b18: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
2049b1c: 06 80 00 1f bl 2049b98 <rtems_rfs_bitmap_map_alloc+0x8c> <== NOT EXECUTED
2049b20: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2049b24: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2049b28: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
2049b2c: 1a 80 00 1b bcc 2049b98 <rtems_rfs_bitmap_map_alloc+0x8c> <== NOT EXECUTED
2049b30: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
/*
* Search up first so bits allocated in succession are grouped together.
*/
if (upper_seed < control->size)
{
*bit = upper_seed;
2049b34: e0 26 c0 00 st %l0, [ %i3 ] <== NOT EXECUTED
rc = rtems_rfs_search_map_for_clear_bit (control, bit, allocated,
2049b38: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2049b3c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2049b40: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2049b44: 7f ff ff 44 call 2049854 <T.54> <== NOT EXECUTED
2049b48: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
window, 1);
if ((rc > 0) || *allocated)
2049b4c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049b50: 14 80 00 27 bg 2049bec <rtems_rfs_bitmap_map_alloc+0xe0> <== NOT EXECUTED
2049b54: 01 00 00 00 nop <== NOT EXECUTED
2049b58: c2 0e 80 00 ldub [ %i2 ], %g1 <== NOT EXECUTED
2049b5c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2049b60: 12 80 00 23 bne 2049bec <rtems_rfs_bitmap_map_alloc+0xe0> <== NOT EXECUTED
2049b64: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
break;
}
if (lower_seed >= 0)
2049b68: 36 80 00 15 bge,a 2049bbc <rtems_rfs_bitmap_map_alloc+0xb0><== NOT EXECUTED
2049b6c: f2 26 c0 00 st %i1, [ %i3 ] <== NOT EXECUTED
/*
* Do not bound the limits at the edges of the map. Do not update if an
* edge has been passed.
*/
if (upper_seed < control->size)
2049b70: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2049b74: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2049b78: 38 80 00 02 bgu,a 2049b80 <rtems_rfs_bitmap_map_alloc+0x74><== NOT EXECUTED
2049b7c: a0 04 28 00 add %l0, 0x800, %l0 <== NOT EXECUTED
upper_seed += window;
if (lower_seed >= 0)
2049b80: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2049b84: 06 bf ff e5 bl 2049b18 <rtems_rfs_bitmap_map_alloc+0xc> <== NOT EXECUTED
2049b88: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
* we have searched all of the map. The seed may not be aligned to a window
* boundary so we may need to search a partial window and this may also not
* be balanced for the upper or lower seeds. We move to the limits, search
* then return false if no clear bits are found.
*/
while (((upper_seed >= 0) && (upper_seed < control->size))
2049b8c: 16 bf ff e6 bge 2049b24 <rtems_rfs_bitmap_map_alloc+0x18> <== NOT EXECUTED
2049b90: b2 06 78 00 add %i1, -2048, %i1 <== NOT EXECUTED
2049b94: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2049b98: 06 80 00 15 bl 2049bec <rtems_rfs_bitmap_map_alloc+0xe0> <== NOT EXECUTED
2049b9c: 01 00 00 00 nop <== NOT EXECUTED
|| ((lower_seed >= 0) && (lower_seed < control->size)))
2049ba0: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
* we have searched all of the map. The seed may not be aligned to a window
* boundary so we may need to search a partial window and this may also not
* be balanced for the upper or lower seeds. We move to the limits, search
* then return false if no clear bits are found.
*/
while (((upper_seed >= 0) && (upper_seed < control->size))
2049ba4: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2049ba8: 1a 80 00 11 bcc 2049bec <rtems_rfs_bitmap_map_alloc+0xe0> <== NOT EXECUTED
2049bac: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
|| ((lower_seed >= 0) && (lower_seed < control->size)))
{
/*
* Search up first so bits allocated in succession are grouped together.
*/
if (upper_seed < control->size)
2049bb0: 2a bf ff e2 bcs,a 2049b38 <rtems_rfs_bitmap_map_alloc+0x2c><== NOT EXECUTED
2049bb4: e0 26 c0 00 st %l0, [ %i3 ] <== NOT EXECUTED
break;
}
if (lower_seed >= 0)
{
*bit = lower_seed;
2049bb8: f2 26 c0 00 st %i1, [ %i3 ] <== NOT EXECUTED
rc = rtems_rfs_search_map_for_clear_bit (control, bit, allocated,
2049bbc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2049bc0: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2049bc4: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2049bc8: 7f ff ff 23 call 2049854 <T.54> <== NOT EXECUTED
2049bcc: 96 10 3f ff mov -1, %o3 <== NOT EXECUTED
window, -1);
if ((rc > 0) || *allocated)
2049bd0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049bd4: 14 80 00 06 bg 2049bec <rtems_rfs_bitmap_map_alloc+0xe0> <== NOT EXECUTED
2049bd8: 01 00 00 00 nop <== NOT EXECUTED
2049bdc: c2 0e 80 00 ldub [ %i2 ], %g1 <== NOT EXECUTED
2049be0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2049be4: 22 bf ff e4 be,a 2049b74 <rtems_rfs_bitmap_map_alloc+0x68><== NOT EXECUTED
2049be8: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
if (lower_seed >= 0)
lower_seed -= window;
}
return 0;
}
2049bec: 81 c7 e0 08 ret <== NOT EXECUTED
2049bf0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02049734 <rtems_rfs_bitmap_map_clear>:
}
int
rtems_rfs_bitmap_map_clear (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_bit bit)
{
2049734: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_map map;
rtems_rfs_bitmap_map search_map;
int index;
int offset;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
2049738: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
204973c: 7f ff ff 27 call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
2049740: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
2049744: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049748: 24 80 00 04 ble,a 2049758 <rtems_rfs_bitmap_map_clear+0x24><== NOT EXECUTED
204974c: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
rtems_rfs_buffer_mark_dirty (control->buffer);
control->free++;
return 0;
}
2049750: 81 c7 e0 08 ret <== NOT EXECUTED
2049754: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
int offset;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
if (bit >= control->size)
2049758: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
204975c: 1a bf ff fd bcc 2049750 <rtems_rfs_bitmap_map_clear+0x1c> <== NOT EXECUTED
2049760: 90 10 20 16 mov 0x16, %o0 <== NOT EXECUTED
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
2049764: d8 07 bf fc ld [ %fp + -4 ], %o4 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
if (bit >= control->size)
return EINVAL;
search_map = control->search_bits;
2049768: c6 06 20 14 ld [ %i0 + 0x14 ], %g3 <== NOT EXECUTED
index = rtems_rfs_bitmap_map_index (bit);
204976c: 89 3e 60 05 sra %i1, 5, %g4 <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
2049770: 9b 29 20 02 sll %g4, 2, %o5 <== NOT EXECUTED
2049774: d4 03 00 0d ld [ %o4 + %o5 ], %o2 <== NOT EXECUTED
2049778: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
204977c: 85 3e 60 0a sra %i1, 0xa, %g2 <== NOT EXECUTED
if (bit >= control->size)
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
2049780: b3 28 40 19 sll %g1, %i1, %i1 <== NOT EXECUTED
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
2049784: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
if (bit >= control->size)
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
2049788: b2 12 80 19 or %o2, %i1, %i1 <== NOT EXECUTED
204978c: f2 23 00 0d st %i1, [ %o4 + %o5 ] <== NOT EXECUTED
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
rtems_rfs_buffer_mark_dirty (control->buffer);
2049790: d8 06 00 00 ld [ %i0 ], %o4 <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
2049794: da 00 c0 02 ld [ %g3 + %g2 ], %o5 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
control->free++;
2049798: d6 06 20 10 ld [ %i0 + 0x10 ], %o3 <== NOT EXECUTED
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
rtems_rfs_buffer_mark_dirty (control->buffer);
204979c: c2 2b 00 00 stb %g1, [ %o4 ] <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
20497a0: 83 28 40 04 sll %g1, %g4, %g1 <== NOT EXECUTED
20497a4: 82 13 40 01 or %o5, %g1, %g1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
control->free++;
20497a8: 90 10 20 00 clr %o0 <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_clear (map[index], 1 << offset);
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset(bit);
search_map[index] = rtems_rfs_bitmap_clear (search_map[index], 1 << offset);
20497ac: c2 20 c0 02 st %g1, [ %g3 + %g2 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
control->free++;
20497b0: 82 02 e0 01 add %o3, 1, %g1 <== NOT EXECUTED
20497b4: c2 26 20 10 st %g1, [ %i0 + 0x10 ] <== NOT EXECUTED
return 0;
}
20497b8: 81 c7 e0 08 ret <== NOT EXECUTED
20497bc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02049560 <rtems_rfs_bitmap_map_clear_all>:
return 0;
}
int
rtems_rfs_bitmap_map_clear_all (rtems_rfs_bitmap_control* control)
{
2049560: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_bit last_search_bit;
size_t elements;
int e;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
2049564: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
2049568: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
204956c: 7f ff ff 9b call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
2049570: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rc > 0)
2049574: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049578: 24 80 00 04 ble,a 2049588 <rtems_rfs_bitmap_map_clear_all+0x28><== NOT EXECUTED
204957c: d8 06 20 0c ld [ %i0 + 0xc ], %o4 <== NOT EXECUTED
rtems_rfs_bitmap_mask (last_search_bit));
rtems_rfs_buffer_mark_dirty (control->buffer);
return 0;
}
2049580: 81 c7 e0 08 ret <== NOT EXECUTED
2049584: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
control->free = elements;
2049588: da 07 bf fc ld [ %fp + -4 ], %o5 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
204958c: 98 03 3f ff add %o4, -1, %o4 <== NOT EXECUTED
control->free = elements;
2049590: 84 10 20 00 clr %g2 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
2049594: 99 33 20 05 srl %o4, 5, %o4 <== NOT EXECUTED
control->free = elements;
2049598: 82 10 20 00 clr %g1 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
204959c: 86 03 20 01 add %o4, 1, %g3 <== NOT EXECUTED
control->free = elements;
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
20495a0: 88 10 3f ff mov -1, %g4 <== NOT EXECUTED
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
control->free = elements;
20495a4: c6 26 20 10 st %g3, [ %i0 + 0x10 ] <== NOT EXECUTED
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
20495a8: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
20495ac: c8 23 40 02 st %g4, [ %o5 + %g2 ] <== NOT EXECUTED
elements = rtems_rfs_bitmap_elements (control->size);
control->free = elements;
for (e = 0; e < elements; e++)
20495b0: 82 00 60 01 inc %g1 <== NOT EXECUTED
20495b4: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED
20495b8: 18 bf ff fc bgu 20495a8 <rtems_rfs_bitmap_map_clear_all+0x48><== NOT EXECUTED
20495bc: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
* Set the un-mapped bits in the last search element so the available logic
* works.
*/
last_search_bit = rtems_rfs_bitmap_map_offset (elements);
if (last_search_bit == 0)
20495c0: 86 88 e0 1f andcc %g3, 0x1f, %g3 <== NOT EXECUTED
20495c4: 02 80 00 04 be 20495d4 <rtems_rfs_bitmap_map_clear_all+0x74><== NOT EXECUTED
20495c8: 96 10 3f ff mov -1, %o3 <== NOT EXECUTED
20495cc: 86 20 00 03 neg %g3 <== NOT EXECUTED
20495d0: 97 31 00 03 srl %g4, %g3, %o3 <== NOT EXECUTED
last_search_bit = rtems_rfs_bitmap_element_bits ();
elements = rtems_rfs_bitmap_elements (elements);
20495d4: 87 33 20 05 srl %o4, 5, %g3 <== NOT EXECUTED
for (e = 0; e < (elements - 1); e++)
20495d8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20495dc: 02 80 00 13 be 2049628 <rtems_rfs_bitmap_map_clear_all+0xc8><== NOT EXECUTED
20495e0: 84 10 20 00 clr %g2 <== NOT EXECUTED
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
20495e4: c8 04 20 14 ld [ %l0 + 0x14 ], %g4 <== NOT EXECUTED
return 0;
}
int
rtems_rfs_bitmap_map_clear_all (rtems_rfs_bitmap_control* control)
20495e8: 82 10 20 00 clr %g1 <== NOT EXECUTED
last_search_bit = rtems_rfs_bitmap_element_bits ();
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < (elements - 1); e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
20495ec: 9a 10 3f ff mov -1, %o5 <== NOT EXECUTED
20495f0: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
20495f4: da 21 00 02 st %o5, [ %g4 + %g2 ] <== NOT EXECUTED
if (last_search_bit == 0)
last_search_bit = rtems_rfs_bitmap_element_bits ();
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < (elements - 1); e++)
20495f8: 82 00 60 01 inc %g1 <== NOT EXECUTED
20495fc: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
2049600: 12 bf ff fc bne 20495f0 <rtems_rfs_bitmap_map_clear_all+0x90><== NOT EXECUTED
2049604: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
control->search_bits[elements - 1] =
rtems_rfs_bitmap_merge (RTEMS_RFS_BITMAP_ELEMENT_CLEAR,
RTEMS_RFS_BITMAP_ELEMENT_SET,
rtems_rfs_bitmap_mask (last_search_bit));
rtems_rfs_buffer_mark_dirty (control->buffer);
2049608: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < (elements - 1); e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
control->search_bits[elements - 1] =
204960c: 87 28 e0 02 sll %g3, 2, %g3 <== NOT EXECUTED
rtems_rfs_bitmap_merge (RTEMS_RFS_BITMAP_ELEMENT_CLEAR,
RTEMS_RFS_BITMAP_ELEMENT_SET,
rtems_rfs_bitmap_mask (last_search_bit));
rtems_rfs_buffer_mark_dirty (control->buffer);
2049610: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2049614: 90 10 20 00 clr %o0 <== NOT EXECUTED
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < (elements - 1); e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_CLEAR;
control->search_bits[elements - 1] =
2049618: d6 21 00 03 st %o3, [ %g4 + %g3 ] <== NOT EXECUTED
rtems_rfs_bitmap_merge (RTEMS_RFS_BITMAP_ELEMENT_CLEAR,
RTEMS_RFS_BITMAP_ELEMENT_SET,
rtems_rfs_bitmap_mask (last_search_bit));
rtems_rfs_buffer_mark_dirty (control->buffer);
204961c: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
return 0;
}
2049620: 81 c7 e0 08 ret <== NOT EXECUTED
2049624: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
2049628: 10 bf ff f8 b 2049608 <rtems_rfs_bitmap_map_clear_all+0xa8><== NOT EXECUTED
204962c: c8 04 20 14 ld [ %l0 + 0x14 ], %g4 <== NOT EXECUTED
020497c0 <rtems_rfs_bitmap_map_set>:
}
int
rtems_rfs_bitmap_map_set (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_bit bit)
{
20497c0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_map map;
rtems_rfs_bitmap_map search_map;
int index;
int offset;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
20497c4: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
20497c8: 7f ff ff 04 call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
20497cc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
20497d0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20497d4: 24 80 00 04 ble,a 20497e4 <rtems_rfs_bitmap_map_set+0x24><== NOT EXECUTED
20497d8: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
search_map[index] = rtems_rfs_bitmap_set (search_map[index], 1 << offset);
control->free--;
rtems_rfs_buffer_mark_dirty (control->buffer);
}
return 0;
}
20497dc: 81 c7 e0 08 ret <== NOT EXECUTED
20497e0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
int offset;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
if (bit >= control->size)
20497e4: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
20497e8: 1a bf ff fd bcc 20497dc <rtems_rfs_bitmap_map_set+0x1c> <== NOT EXECUTED
20497ec: 90 10 20 16 mov 0x16, %o0 <== NOT EXECUTED
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_set (map[index], 1 << offset);
20497f0: c8 07 bf fc ld [ %fp + -4 ], %g4 <== NOT EXECUTED
if (rc > 0)
return rc;
if (bit >= control->size)
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
20497f4: 9b 3e 60 05 sra %i1, 5, %o5 <== NOT EXECUTED
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_set (map[index], 1 << offset);
20497f8: 87 2b 60 02 sll %o5, 2, %g3 <== NOT EXECUTED
*/
static rtems_rfs_bitmap_element
rtems_rfs_bitmap_set (rtems_rfs_bitmap_element target,
rtems_rfs_bitmap_element bits)
{
return RTEMS_RFS_BITMAP_SET_BITS (target, bits);
20497fc: c4 01 00 03 ld [ %g4 + %g3 ], %g2 <== NOT EXECUTED
2049800: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2049804: 99 28 40 19 sll %g1, %i1, %o4 <== NOT EXECUTED
2049808: 84 28 80 0c andn %g2, %o4, %g2 <== NOT EXECUTED
if (bit >= control->size)
return EINVAL;
search_map = control->search_bits;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
map[index] = rtems_rfs_bitmap_set (map[index], 1 << offset);
204980c: c4 21 00 03 st %g2, [ %g4 + %g3 ] <== NOT EXECUTED
if (rtems_rfs_bitmap_match(map[index], RTEMS_RFS_BITMAP_ELEMENT_SET))
2049810: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2049814: 90 10 20 00 clr %o0 <== NOT EXECUTED
2049818: 12 bf ff f1 bne 20497dc <rtems_rfs_bitmap_map_set+0x1c> <== NOT EXECUTED
204981c: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
search_map[index] = rtems_rfs_bitmap_set (search_map[index], 1 << offset);
control->free--;
rtems_rfs_buffer_mark_dirty (control->buffer);
2049820: d8 06 00 00 ld [ %i0 ], %o4 <== NOT EXECUTED
if (rtems_rfs_bitmap_match(map[index], RTEMS_RFS_BITMAP_ELEMENT_SET))
{
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
search_map[index] = rtems_rfs_bitmap_set (search_map[index], 1 << offset);
2049824: b3 3e 60 0a sra %i1, 0xa, %i1 <== NOT EXECUTED
2049828: b3 2e 60 02 sll %i1, 2, %i1 <== NOT EXECUTED
204982c: c8 00 80 19 ld [ %g2 + %i1 ], %g4 <== NOT EXECUTED
control->free--;
2049830: c6 06 20 10 ld [ %i0 + 0x10 ], %g3 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
2049834: c2 2b 00 00 stb %g1, [ %o4 ] <== NOT EXECUTED
if (rtems_rfs_bitmap_match(map[index], RTEMS_RFS_BITMAP_ELEMENT_SET))
{
bit = index;
index = rtems_rfs_bitmap_map_index (bit);
offset = rtems_rfs_bitmap_map_offset (bit);
search_map[index] = rtems_rfs_bitmap_set (search_map[index], 1 << offset);
2049838: 83 28 40 0d sll %g1, %o5, %g1 <== NOT EXECUTED
204983c: 82 29 00 01 andn %g4, %g1, %g1 <== NOT EXECUTED
2049840: c2 20 80 19 st %g1, [ %g2 + %i1 ] <== NOT EXECUTED
control->free--;
2049844: 82 00 ff ff add %g3, -1, %g1 <== NOT EXECUTED
2049848: c2 26 20 10 st %g1, [ %i0 + 0x10 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (control->buffer);
}
return 0;
}
204984c: 81 c7 e0 08 ret <== NOT EXECUTED
2049850: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02049630 <rtems_rfs_bitmap_map_set_all>:
return 0;
}
int
rtems_rfs_bitmap_map_set_all (rtems_rfs_bitmap_control* control)
{
2049630: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_map map;
size_t elements;
int e;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
2049634: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
2049638: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
204963c: 7f ff ff 67 call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
2049640: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rc > 0)
2049644: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049648: 24 80 00 04 ble,a 2049658 <rtems_rfs_bitmap_map_set_all+0x28><== NOT EXECUTED
204964c: da 06 20 0c ld [ %i0 + 0xc ], %o5 <== NOT EXECUTED
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
rtems_rfs_buffer_mark_dirty (control->buffer);
return 0;
}
2049650: 81 c7 e0 08 ret <== NOT EXECUTED
2049654: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
control->free = 0;
2049658: c8 07 bf fc ld [ %fp + -4 ], %g4 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
204965c: 9a 03 7f ff add %o5, -1, %o5 <== NOT EXECUTED
control->free = 0;
2049660: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
2049664: 9b 33 60 05 srl %o5, 5, %o5 <== NOT EXECUTED
control->free = 0;
2049668: 84 10 20 00 clr %g2 <== NOT EXECUTED
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
elements = rtems_rfs_bitmap_elements (control->size);
204966c: 86 03 60 01 add %o5, 1, %g3 <== NOT EXECUTED
control->free = 0;
2049670: 82 10 20 00 clr %g1 <== NOT EXECUTED
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
2049674: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
2049678: c0 21 00 02 clr [ %g4 + %g2 ] <== NOT EXECUTED
elements = rtems_rfs_bitmap_elements (control->size);
control->free = 0;
for (e = 0; e < elements; e++)
204967c: 82 00 60 01 inc %g1 <== NOT EXECUTED
2049680: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED
2049684: 18 bf ff fc bgu 2049674 <rtems_rfs_bitmap_map_set_all+0x44><== NOT EXECUTED
2049688: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
map[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < elements; e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
204968c: c8 04 20 14 ld [ %l0 + 0x14 ], %g4 <== NOT EXECUTED
control->free = 0;
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
elements = rtems_rfs_bitmap_elements (elements);
2049690: 87 33 60 05 srl %o5, 5, %g3 <== NOT EXECUTED
for (e = 0; e < elements; e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
2049694: 84 10 20 00 clr %g2 <== NOT EXECUTED
control->free = 0;
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
elements = rtems_rfs_bitmap_elements (elements);
2049698: 86 00 e0 01 inc %g3 <== NOT EXECUTED
for (e = 0; e < elements; e++)
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
204969c: 82 10 20 00 clr %g1 <== NOT EXECUTED
20496a0: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
20496a4: c0 21 00 02 clr [ %g4 + %g2 ] <== NOT EXECUTED
for (e = 0; e < elements; e++)
map[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
elements = rtems_rfs_bitmap_elements (elements);
for (e = 0; e < elements; e++)
20496a8: 82 00 60 01 inc %g1 <== NOT EXECUTED
20496ac: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
20496b0: 0a bf ff fc bcs 20496a0 <rtems_rfs_bitmap_map_set_all+0x70><== NOT EXECUTED
20496b4: 84 10 00 01 mov %g1, %g2 <== NOT EXECUTED
control->search_bits[e] = RTEMS_RFS_BITMAP_ELEMENT_SET;
rtems_rfs_buffer_mark_dirty (control->buffer);
20496b8: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
20496bc: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
20496c0: 90 10 20 00 clr %o0 <== NOT EXECUTED
20496c4: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
return 0;
}
20496c8: 81 c7 e0 08 ret <== NOT EXECUTED
20496cc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020496d0 <rtems_rfs_bitmap_map_test>:
int
rtems_rfs_bitmap_map_test (rtems_rfs_bitmap_control* control,
rtems_rfs_bitmap_bit bit,
bool* state)
{
20496d0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_map map;
int index;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
20496d4: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
20496d8: 7f ff ff 40 call 20493d8 <rtems_rfs_bitmap_load_map> <== NOT EXECUTED
20496dc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
20496e0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20496e4: 24 80 00 04 ble,a 20496f4 <rtems_rfs_bitmap_map_test+0x24><== NOT EXECUTED
20496e8: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
if (bit >= control->size)
return EINVAL;
index = rtems_rfs_bitmap_map_index (bit);
*state = rtems_rfs_bitmap_test (map[index], bit);
return 0;
}
20496ec: 81 c7 e0 08 ret <== NOT EXECUTED
20496f0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
int index;
int rc;
rc = rtems_rfs_bitmap_load_map (control, &map);
if (rc > 0)
return rc;
if (bit >= control->size)
20496f4: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
20496f8: 1a bf ff fd bcc 20496ec <rtems_rfs_bitmap_map_test+0x1c> <== NOT EXECUTED
20496fc: 90 10 20 16 mov 0x16, %o0 <== NOT EXECUTED
return EINVAL;
index = rtems_rfs_bitmap_map_index (bit);
*state = rtems_rfs_bitmap_test (map[index], bit);
2049700: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
2049704: 83 3e 60 05 sra %i1, 5, %g1 <== NOT EXECUTED
2049708: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
204970c: c2 00 80 01 ld [ %g2 + %g1 ], %g1 <== NOT EXECUTED
2049710: 90 10 20 00 clr %o0 <== NOT EXECUTED
2049714: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2049718: b3 28 80 19 sll %g2, %i1, %i1 <== NOT EXECUTED
204971c: b2 0e 40 01 and %i1, %g1, %i1 <== NOT EXECUTED
2049720: 80 a0 00 19 cmp %g0, %i1 <== NOT EXECUTED
2049724: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
2049728: c2 2e 80 00 stb %g1, [ %i2 ] <== NOT EXECUTED
return 0;
}
204972c: 81 c7 e0 08 ret <== NOT EXECUTED
2049730: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02049388 <rtems_rfs_bitmap_mask>:
return 0;
}
rtems_rfs_bitmap_element
rtems_rfs_bitmap_mask (unsigned int size)
{
2049388: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED
204938c: 90 20 00 08 neg %o0 <== NOT EXECUTED
rtems_rfs_bitmap_element mask = RTEMS_RFS_BITMAP_ELEMENT_FULL_MASK;
mask >>= (rtems_rfs_bitmap_element_bits () - size);
return mask;
}
2049390: 81 c3 e0 08 retl <== NOT EXECUTED
2049394: 91 30 40 08 srl %g1, %o0, %o0 <== NOT EXECUTED
02049398 <rtems_rfs_bitmap_mask_section>:
rtems_rfs_bitmap_element
rtems_rfs_bitmap_mask_section (unsigned int start, unsigned int end)
{
2049398: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
rtems_rfs_bitmap_element mask = 0;
if (end > start)
204939c: 80 a2 40 08 cmp %o1, %o0 <== NOT EXECUTED
20493a0: 08 80 00 06 bleu 20493b8 <rtems_rfs_bitmap_mask_section+0x20><== NOT EXECUTED
20493a4: 90 10 20 00 clr %o0 <== NOT EXECUTED
mask = rtems_rfs_bitmap_mask (end - start) << start;
20493a8: 92 20 40 09 sub %g1, %o1, %o1 <== NOT EXECUTED
20493ac: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
20493b0: 91 32 00 09 srl %o0, %o1, %o0 <== NOT EXECUTED
20493b4: 91 2a 00 01 sll %o0, %g1, %o0 <== NOT EXECUTED
return mask;
}
20493b8: 81 c3 e0 08 retl <== NOT EXECUTED
0204951c <rtems_rfs_bitmap_open>:
rtems_rfs_bitmap_open (rtems_rfs_bitmap_control* control,
rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* buffer,
size_t size,
rtems_rfs_buffer_block block)
{
204951c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
control->fs = fs;
control->block = block;
control->size = size;
elements = rtems_rfs_bitmap_elements (elements);
control->search_bits = malloc (elements * sizeof (rtems_rfs_bitmap_element));
2049520: 90 06 ff ff add %i3, -1, %o0 <== NOT EXECUTED
size_t size,
rtems_rfs_buffer_block block)
{
size_t elements = rtems_rfs_bitmap_elements (size);
control->buffer = buffer;
2049524: f4 26 00 00 st %i2, [ %i0 ] <== NOT EXECUTED
control->fs = fs;
control->block = block;
control->size = size;
elements = rtems_rfs_bitmap_elements (elements);
control->search_bits = malloc (elements * sizeof (rtems_rfs_bitmap_element));
2049528: 91 32 20 0a srl %o0, 0xa, %o0 <== NOT EXECUTED
rtems_rfs_buffer_block block)
{
size_t elements = rtems_rfs_bitmap_elements (size);
control->buffer = buffer;
control->fs = fs;
204952c: f2 26 20 04 st %i1, [ %i0 + 4 ] <== NOT EXECUTED
control->block = block;
control->size = size;
elements = rtems_rfs_bitmap_elements (elements);
control->search_bits = malloc (elements * sizeof (rtems_rfs_bitmap_element));
2049530: 90 02 20 01 inc %o0 <== NOT EXECUTED
{
size_t elements = rtems_rfs_bitmap_elements (size);
control->buffer = buffer;
control->fs = fs;
control->block = block;
2049534: f8 26 20 08 st %i4, [ %i0 + 8 ] <== NOT EXECUTED
control->size = size;
elements = rtems_rfs_bitmap_elements (elements);
control->search_bits = malloc (elements * sizeof (rtems_rfs_bitmap_element));
2049538: 91 2a 20 02 sll %o0, 2, %o0 <== NOT EXECUTED
204953c: 7f fe fe c9 call 2009060 <malloc> <== NOT EXECUTED
2049540: f6 26 20 0c st %i3, [ %i0 + 0xc ] <== NOT EXECUTED
if (!control->search_bits)
2049544: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2049548: 02 80 00 04 be 2049558 <rtems_rfs_bitmap_open+0x3c> <== NOT EXECUTED
204954c: d0 26 20 14 st %o0, [ %i0 + 0x14 ] <== NOT EXECUTED
return ENOMEM;
return rtems_rfs_bitmap_create_search (control);
2049550: 7f ff ff b6 call 2049428 <rtems_rfs_bitmap_create_search> <== NOT EXECUTED
2049554: 81 e8 00 00 restore <== NOT EXECUTED
}
2049558: 81 c7 e0 08 ret <== NOT EXECUTED
204955c: 91 e8 20 0c restore %g0, 0xc, %o0 <== NOT EXECUTED
0203e760 <rtems_rfs_block_find_indirect>:
rtems_rfs_block_find_indirect (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* buffer,
rtems_rfs_block_no block,
int offset,
rtems_rfs_block_no* result)
{
203e760: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* If the handle has a buffer and this request is a different block the current
* buffer is released.
*/
rc = rtems_rfs_buffer_handle_request (fs, buffer, block, true);
203e764: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203e768: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
203e76c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203e770: 40 00 04 6b call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203e774: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (rc > 0)
203e778: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203e77c: 24 80 00 04 ble,a 203e78c <rtems_rfs_block_find_indirect+0x2c><== NOT EXECUTED
203e780: c4 06 60 08 ld [ %i1 + 8 ], %g2 <== NOT EXECUTED
*result = 0;
rc = EIO;
}
return 0;
}
203e784: 81 c7 e0 08 ret <== NOT EXECUTED
203e788: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
*/
rc = rtems_rfs_buffer_handle_request (fs, buffer, block, true);
if (rc > 0)
return rc;
*result = rtems_rfs_block_get_number (buffer, offset);
203e78c: 83 2e e0 02 sll %i3, 2, %g1 <== NOT EXECUTED
203e790: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203e794: 82 00 60 02 add %g1, 2, %g1 <== NOT EXECUTED
203e798: c6 08 80 01 ldub [ %g2 + %g1 ], %g3 <== NOT EXECUTED
203e79c: b7 2e e0 02 sll %i3, 2, %i3 <== NOT EXECUTED
203e7a0: c2 08 80 1b ldub [ %g2 + %i3 ], %g1 <== NOT EXECUTED
203e7a4: 84 00 80 1b add %g2, %i3, %g2 <== NOT EXECUTED
203e7a8: c8 08 a0 01 ldub [ %g2 + 1 ], %g4 <== NOT EXECUTED
203e7ac: da 08 a0 03 ldub [ %g2 + 3 ], %o5 <== NOT EXECUTED
203e7b0: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
if ((*result + 1) == 0)
*result = 0;
if (*result >= rtems_rfs_fs_blocks (fs))
203e7b4: c4 06 20 04 ld [ %i0 + 4 ], %g2 <== NOT EXECUTED
*/
rc = rtems_rfs_buffer_handle_request (fs, buffer, block, true);
if (rc > 0)
return rc;
*result = rtems_rfs_block_get_number (buffer, offset);
203e7b8: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
203e7bc: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203e7c0: 82 13 40 01 or %o5, %g1, %g1 <== NOT EXECUTED
203e7c4: 82 10 40 04 or %g1, %g4, %g1 <== NOT EXECUTED
203e7c8: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
if ((*result + 1) == 0)
203e7cc: 86 38 00 01 xnor %g0, %g1, %g3 <== NOT EXECUTED
203e7d0: 80 a0 00 03 cmp %g0, %g3 <== NOT EXECUTED
203e7d4: 86 60 20 00 subx %g0, 0, %g3 <== NOT EXECUTED
203e7d8: 82 08 40 03 and %g1, %g3, %g1 <== NOT EXECUTED
203e7dc: c2 27 00 00 st %g1, [ %i4 ] <== NOT EXECUTED
*result = 0;
if (*result >= rtems_rfs_fs_blocks (fs))
203e7e0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
203e7e4: 0a bf ff e8 bcs 203e784 <rtems_rfs_block_find_indirect+0x24><== NOT EXECUTED
203e7e8: 90 10 20 00 clr %o0 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_FIND))
printf ("rtems-rfs: block-find: invalid block in table:"
" block=%" PRId32 ", indirect=%" PRId32 "/%d\n", *result, block, offset);
*result = 0;
203e7ec: c0 27 00 00 clr [ %i4 ] <== NOT EXECUTED
rc = EIO;
}
return 0;
}
203e7f0: 81 c7 e0 08 ret <== NOT EXECUTED
203e7f4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0203e6ac <rtems_rfs_block_get_block_size>:
void
rtems_rfs_block_get_block_size (rtems_rfs_file_system* fs,
rtems_rfs_pos pos,
rtems_rfs_block_size* size)
{
203e6ac: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (pos == 0)
203e6b0: 80 96 40 1a orcc %i1, %i2, %g0 <== NOT EXECUTED
203e6b4: 02 80 00 11 be 203e6f8 <rtems_rfs_block_get_block_size+0x4c><== NOT EXECUTED
203e6b8: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_block_set_size_zero (size);
else
{
size->count = pos / rtems_rfs_fs_block_size (fs) + 1;
203e6bc: e0 06 20 08 ld [ %i0 + 8 ], %l0 <== NOT EXECUTED
203e6c0: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
203e6c4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
203e6c8: 40 00 94 4c call 20637f8 <__udivdi3> <== NOT EXECUTED
203e6cc: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203e6d0: 92 02 60 01 inc %o1 <== NOT EXECUTED
size->offset = pos % rtems_rfs_fs_block_size (fs);
203e6d4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
{
if (pos == 0)
rtems_rfs_block_set_size_zero (size);
else
{
size->count = pos / rtems_rfs_fs_block_size (fs) + 1;
203e6d8: d2 26 c0 00 st %o1, [ %i3 ] <== NOT EXECUTED
size->offset = pos % rtems_rfs_fs_block_size (fs);
203e6dc: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
203e6e0: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203e6e4: 40 00 95 16 call 2063b3c <__umoddi3> <== NOT EXECUTED
203e6e8: 94 10 20 00 clr %o2 <== NOT EXECUTED
203e6ec: d2 26 e0 04 st %o1, [ %i3 + 4 ] <== NOT EXECUTED
203e6f0: 81 c7 e0 08 ret <== NOT EXECUTED
203e6f4: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_set_size_zero (rtems_rfs_block_size* size)
{
size->count = 0;
size->offset = 0;
203e6f8: c0 26 e0 04 clr [ %i3 + 4 ] <== NOT EXECUTED
* @param size A pointer to the block size.
*/
static inline void
rtems_rfs_block_set_size_zero (rtems_rfs_block_size* size)
{
size->count = 0;
203e6fc: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
203e700: 81 c7 e0 08 ret <== NOT EXECUTED
203e704: 81 e8 00 00 restore <== NOT EXECUTED
0203e64c <rtems_rfs_block_get_bpos>:
void
rtems_rfs_block_get_bpos (rtems_rfs_file_system* fs,
rtems_rfs_pos pos,
rtems_rfs_block_pos* bpos)
{
203e64c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
bpos->bno = pos / rtems_rfs_fs_block_size (fs);
203e650: e0 06 20 08 ld [ %i0 + 8 ], %l0 <== NOT EXECUTED
203e654: 94 10 20 00 clr %o2 <== NOT EXECUTED
203e658: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
203e65c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
203e660: 40 00 94 66 call 20637f8 <__udivdi3> <== NOT EXECUTED
203e664: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
bpos->boff = pos % rtems_rfs_fs_block_size (fs);
203e668: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
void
rtems_rfs_block_get_bpos (rtems_rfs_file_system* fs,
rtems_rfs_pos pos,
rtems_rfs_block_pos* bpos)
{
bpos->bno = pos / rtems_rfs_fs_block_size (fs);
203e66c: d2 26 c0 00 st %o1, [ %i3 ] <== NOT EXECUTED
bpos->boff = pos % rtems_rfs_fs_block_size (fs);
203e670: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
203e674: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203e678: 40 00 95 31 call 2063b3c <__umoddi3> <== NOT EXECUTED
203e67c: 94 10 20 00 clr %o2 <== NOT EXECUTED
203e680: d2 26 e0 04 st %o1, [ %i3 + 4 ] <== NOT EXECUTED
}
203e684: 81 c7 e0 08 ret <== NOT EXECUTED
203e688: 81 e8 00 00 restore <== NOT EXECUTED
0203e68c <rtems_rfs_block_get_pos>:
rtems_rfs_pos
rtems_rfs_block_get_pos (rtems_rfs_file_system* fs,
rtems_rfs_block_pos* bpos)
{
203e68c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
203e690: d0 06 20 08 ld [ %i0 + 8 ], %o0 <== NOT EXECUTED
203e694: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
203e698: 7f ff 11 3d call 2002b8c <.umul> <== NOT EXECUTED
203e69c: b0 10 20 00 clr %i0 <== NOT EXECUTED
203e6a0: f2 06 60 04 ld [ %i1 + 4 ], %i1 <== NOT EXECUTED
return (bpos->bno * rtems_rfs_fs_block_size (fs)) + bpos->boff;
}
203e6a4: 81 c7 e0 08 ret <== NOT EXECUTED
203e6a8: 93 ea 00 19 restore %o0, %i1, %o1 <== NOT EXECUTED
0203e708 <rtems_rfs_block_get_size>:
}
rtems_rfs_pos
rtems_rfs_block_get_size (rtems_rfs_file_system* fs,
rtems_rfs_block_size* size)
{
203e708: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
uint32_t offset;
uint64_t block_size;
if (size->count == 0)
203e70c: d6 06 40 00 ld [ %i1 ], %o3 <== NOT EXECUTED
203e710: a0 10 20 00 clr %l0 <== NOT EXECUTED
203e714: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
203e718: 02 80 00 0d be 203e74c <rtems_rfs_block_get_size+0x44> <== NOT EXECUTED
203e71c: a2 10 20 00 clr %l1 <== NOT EXECUTED
return 0;
if (size->offset == 0)
203e720: e0 06 60 04 ld [ %i1 + 4 ], %l0 <== NOT EXECUTED
203e724: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
203e728: 22 80 00 0c be,a 203e758 <rtems_rfs_block_get_size+0x50> <== NOT EXECUTED
203e72c: e0 06 20 08 ld [ %i0 + 8 ], %l0 <== NOT EXECUTED
203e730: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED
offset = rtems_rfs_fs_block_size (fs);
else
offset = size->offset;
block_size = rtems_rfs_fs_block_size (fs);
return (((uint64_t) (size->count - 1)) * block_size) + offset;
203e734: 96 02 ff ff add %o3, -1, %o3 <== NOT EXECUTED
203e738: 90 10 20 00 clr %o0 <== NOT EXECUTED
203e73c: 40 00 91 ea call 2062ee4 <__muldi3> <== NOT EXECUTED
203e740: 94 10 20 00 clr %o2 <== NOT EXECUTED
203e744: a2 82 40 10 addcc %o1, %l0, %l1 <== NOT EXECUTED
203e748: a0 42 20 00 addx %o0, 0, %l0 <== NOT EXECUTED
}
203e74c: b2 10 00 11 mov %l1, %i1 <== NOT EXECUTED
203e750: 81 c7 e0 08 ret <== NOT EXECUTED
203e754: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
uint32_t offset;
uint64_t block_size;
if (size->count == 0)
return 0;
if (size->offset == 0)
offset = rtems_rfs_fs_block_size (fs);
203e758: 10 bf ff f7 b 203e734 <rtems_rfs_block_get_size+0x2c> <== NOT EXECUTED
203e75c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
0203f2e0 <rtems_rfs_block_map_close>:
}
int
rtems_rfs_block_map_close (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map)
{
203f2e0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = 0;
int brc;
if (map->dirty && map->inode)
203f2e4: c2 0e 40 00 ldub [ %i1 ], %g1 <== NOT EXECUTED
203f2e8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203f2ec: 02 80 00 1a be 203f354 <rtems_rfs_block_map_close+0x74> <== NOT EXECUTED
203f2f0: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
203f2f4: d2 06 60 04 ld [ %i1 + 4 ], %o1 <== NOT EXECUTED
203f2f8: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
203f2fc: 22 80 00 07 be,a 203f318 <rtems_rfs_block_map_close+0x38><== NOT EXECUTED
203f300: b0 10 20 00 clr %i0 <== NOT EXECUTED
{
brc = rtems_rfs_inode_load (fs, map->inode);
203f304: 40 00 10 51 call 2043448 <rtems_rfs_inode_load> <== NOT EXECUTED
203f308: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (brc > 0)
203f30c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f310: 04 80 00 13 ble 203f35c <rtems_rfs_block_map_close+0x7c> <== NOT EXECUTED
203f314: 84 10 20 00 clr %g2 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
203f318: 92 06 60 38 add %i1, 0x38, %o1 <== NOT EXECUTED
map->dirty = false;
}
}
map->inode = NULL;
203f31c: c0 26 60 04 clr [ %i1 + 4 ] <== NOT EXECUTED
203f320: 40 00 01 36 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203f324: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f328: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
203f32c: c0 2e 60 38 clrb [ %i1 + 0x38 ] <== NOT EXECUTED
handle->bnum = 0;
203f330: c0 26 60 3c clr [ %i1 + 0x3c ] <== NOT EXECUTED
handle->buffer = NULL;
203f334: c0 26 60 40 clr [ %i1 + 0x40 ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
203f338: 40 00 01 30 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203f33c: 92 06 60 44 add %i1, 0x44, %o1 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
203f340: c0 26 60 4c clr [ %i1 + 0x4c ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
203f344: c0 2e 60 44 clrb [ %i1 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
203f348: c0 26 60 48 clr [ %i1 + 0x48 ] <== NOT EXECUTED
rc = brc;
brc = rtems_rfs_buffer_handle_close (fs, &map->doubly_buffer);
if ((brc > 0) && (rc == 0))
rc = brc;
return rc;
}
203f34c: 81 c7 e0 08 ret <== NOT EXECUTED
203f350: 81 e8 00 00 restore <== NOT EXECUTED
brc = rtems_rfs_inode_unload (fs, map->inode, true);
if (brc > 0)
rc = brc;
map->dirty = false;
203f354: 10 bf ff f1 b 203f318 <rtems_rfs_block_map_close+0x38> <== NOT EXECUTED
203f358: b0 10 20 00 clr %i0 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block (rtems_rfs_inode_handle* handle, int block, uint32_t bno)
{
rtems_rfs_write_u32 (&handle->node->data.blocks[block], bno);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
203f35c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
if (rc == 0)
{
int b;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_inode_set_block (map->inode, b, map->blocks[b]);
203f360: c6 06 60 04 ld [ %i1 + 4 ], %g3 <== NOT EXECUTED
203f364: 88 06 40 02 add %i1, %g2, %g4 <== NOT EXECUTED
* @param bno The block number.
*/
static inline void
rtems_rfs_inode_set_block (rtems_rfs_inode_handle* handle, int block, uint32_t bno)
{
rtems_rfs_write_u32 (&handle->node->data.blocks[block], bno);
203f368: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
203f36c: c8 01 20 24 ld [ %g4 + 0x24 ], %g4 <== NOT EXECUTED
203f370: 9a 03 40 02 add %o5, %g2, %o5 <== NOT EXECUTED
203f374: 99 31 20 18 srl %g4, 0x18, %o4 <== NOT EXECUTED
203f378: d8 2b 60 1c stb %o4, [ %o5 + 0x1c ] <== NOT EXECUTED
203f37c: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
203f380: 99 31 20 10 srl %g4, 0x10, %o4 <== NOT EXECUTED
203f384: 9a 03 40 02 add %o5, %g2, %o5 <== NOT EXECUTED
203f388: d8 2b 60 1d stb %o4, [ %o5 + 0x1d ] <== NOT EXECUTED
203f38c: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
203f390: 99 31 20 08 srl %g4, 8, %o4 <== NOT EXECUTED
203f394: 9a 03 40 02 add %o5, %g2, %o5 <== NOT EXECUTED
203f398: d8 2b 60 1e stb %o4, [ %o5 + 0x1e ] <== NOT EXECUTED
203f39c: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
203f3a0: 9a 03 40 02 add %o5, %g2, %o5 <== NOT EXECUTED
203f3a4: c8 2b 60 1f stb %g4, [ %o5 + 0x1f ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
203f3a8: 84 00 a0 04 add %g2, 4, %g2 <== NOT EXECUTED
if (rc == 0)
{
int b;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
203f3ac: 80 a0 a0 14 cmp %g2, 0x14 <== NOT EXECUTED
203f3b0: 12 bf ff ec bne 203f360 <rtems_rfs_block_map_close+0x80> <== NOT EXECUTED
203f3b4: c2 28 e0 10 stb %g1, [ %g3 + 0x10 ] <== NOT EXECUTED
rtems_rfs_inode_set_block (map->inode, b, map->blocks[b]);
rtems_rfs_inode_set_block_count (map->inode, map->size.count);
203f3b8: c6 06 60 04 ld [ %i1 + 4 ], %g3 <== NOT EXECUTED
203f3bc: c4 06 60 08 ld [ %i1 + 8 ], %g2 <== NOT EXECUTED
* @param block_count The block count.
*/
static inline void
rtems_rfs_inode_set_block_count (rtems_rfs_inode_handle* handle, uint32_t block_count)
{
rtems_rfs_write_u32 (&handle->node->block_count, block_count);
203f3c0: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f3c4: 9b 30 a0 18 srl %g2, 0x18, %o5 <== NOT EXECUTED
203f3c8: da 29 20 0c stb %o5, [ %g4 + 0xc ] <== NOT EXECUTED
203f3cc: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f3d0: 9b 30 a0 10 srl %g2, 0x10, %o5 <== NOT EXECUTED
203f3d4: da 29 20 0d stb %o5, [ %g4 + 0xd ] <== NOT EXECUTED
203f3d8: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f3dc: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
203f3e0: da 29 20 0e stb %o5, [ %g4 + 0xe ] <== NOT EXECUTED
203f3e4: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
rtems_rfs_inode_set_block_offset (map->inode, map->size.offset);
rtems_rfs_inode_set_last_map_block (map->inode, map->last_map_block);
rtems_rfs_inode_set_last_data_block (map->inode, map->last_data_block);
brc = rtems_rfs_inode_unload (fs, map->inode, true);
203f3e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f3ec: c4 29 20 0f stb %g2, [ %g4 + 0xf ] <== NOT EXECUTED
int b;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_inode_set_block (map->inode, b, map->blocks[b]);
rtems_rfs_inode_set_block_count (map->inode, map->size.count);
rtems_rfs_inode_set_block_offset (map->inode, map->size.offset);
203f3f0: c8 06 60 04 ld [ %i1 + 4 ], %g4 <== NOT EXECUTED
203f3f4: c4 06 60 0c ld [ %i1 + 0xc ], %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
203f3f8: da 01 20 0c ld [ %g4 + 0xc ], %o5 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_count (rtems_rfs_inode_handle* handle, uint32_t block_count)
{
rtems_rfs_write_u32 (&handle->node->block_count, block_count);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
203f3fc: c2 28 e0 10 stb %g1, [ %g3 + 0x10 ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
203f400: 87 30 a0 08 srl %g2, 8, %g3 <== NOT EXECUTED
203f404: c6 2b 60 0a stb %g3, [ %o5 + 0xa ] <== NOT EXECUTED
203f408: c6 01 20 0c ld [ %g4 + 0xc ], %g3 <== NOT EXECUTED
rtems_rfs_inode_set_last_map_block (map->inode, map->last_map_block);
rtems_rfs_inode_set_last_data_block (map->inode, map->last_data_block);
brc = rtems_rfs_inode_unload (fs, map->inode, true);
203f40c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203f410: c4 28 e0 0b stb %g2, [ %g3 + 0xb ] <== NOT EXECUTED
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_inode_set_block (map->inode, b, map->blocks[b]);
rtems_rfs_inode_set_block_count (map->inode, map->size.count);
rtems_rfs_inode_set_block_offset (map->inode, map->size.offset);
rtems_rfs_inode_set_last_map_block (map->inode, map->last_map_block);
203f414: c6 06 60 04 ld [ %i1 + 4 ], %g3 <== NOT EXECUTED
203f418: c4 06 60 1c ld [ %i1 + 0x1c ], %g2 <== NOT EXECUTED
* @param block_count The last map block number.
*/
static inline void
rtems_rfs_inode_set_last_map_block (rtems_rfs_inode_handle* handle, uint32_t last_map_block)
{
rtems_rfs_write_u32 (&handle->node->last_map_block, last_map_block);
203f41c: da 00 e0 0c ld [ %g3 + 0xc ], %o5 <== NOT EXECUTED
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
203f420: c2 29 20 10 stb %g1, [ %g4 + 0x10 ] <== NOT EXECUTED
* @param block_count The last map block number.
*/
static inline void
rtems_rfs_inode_set_last_map_block (rtems_rfs_inode_handle* handle, uint32_t last_map_block)
{
rtems_rfs_write_u32 (&handle->node->last_map_block, last_map_block);
203f424: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
203f428: c8 2b 60 30 stb %g4, [ %o5 + 0x30 ] <== NOT EXECUTED
203f42c: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f430: 9b 30 a0 10 srl %g2, 0x10, %o5 <== NOT EXECUTED
203f434: da 29 20 31 stb %o5, [ %g4 + 0x31 ] <== NOT EXECUTED
203f438: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f43c: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
203f440: da 29 20 32 stb %o5, [ %g4 + 0x32 ] <== NOT EXECUTED
203f444: c8 00 e0 0c ld [ %g3 + 0xc ], %g4 <== NOT EXECUTED
203f448: c4 29 20 33 stb %g2, [ %g4 + 0x33 ] <== NOT EXECUTED
rtems_rfs_inode_set_last_data_block (map->inode, map->last_data_block);
203f44c: c4 06 60 04 ld [ %i1 + 4 ], %g2 <== NOT EXECUTED
203f450: c8 06 60 20 ld [ %i1 + 0x20 ], %g4 <== NOT EXECUTED
* @param block_count The last data block number.
*/
static inline void
rtems_rfs_inode_set_last_data_block (rtems_rfs_inode_handle* handle, uint32_t last_data_block)
{
rtems_rfs_write_u32 (&handle->node->last_data_block, last_data_block);
203f454: da 00 a0 0c ld [ %g2 + 0xc ], %o5 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_last_map_block (rtems_rfs_inode_handle* handle, uint32_t last_map_block)
{
rtems_rfs_write_u32 (&handle->node->last_map_block, last_map_block);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
203f458: c2 28 e0 10 stb %g1, [ %g3 + 0x10 ] <== NOT EXECUTED
* @param block_count The last data block number.
*/
static inline void
rtems_rfs_inode_set_last_data_block (rtems_rfs_inode_handle* handle, uint32_t last_data_block)
{
rtems_rfs_write_u32 (&handle->node->last_data_block, last_data_block);
203f45c: 87 31 20 18 srl %g4, 0x18, %g3 <== NOT EXECUTED
203f460: c6 2b 60 34 stb %g3, [ %o5 + 0x34 ] <== NOT EXECUTED
203f464: c6 00 a0 0c ld [ %g2 + 0xc ], %g3 <== NOT EXECUTED
203f468: 9b 31 20 10 srl %g4, 0x10, %o5 <== NOT EXECUTED
203f46c: da 28 e0 35 stb %o5, [ %g3 + 0x35 ] <== NOT EXECUTED
203f470: c6 00 a0 0c ld [ %g2 + 0xc ], %g3 <== NOT EXECUTED
203f474: 9b 31 20 08 srl %g4, 8, %o5 <== NOT EXECUTED
203f478: da 28 e0 36 stb %o5, [ %g3 + 0x36 ] <== NOT EXECUTED
203f47c: c6 00 a0 0c ld [ %g2 + 0xc ], %g3 <== NOT EXECUTED
203f480: c8 28 e0 37 stb %g4, [ %g3 + 0x37 ] <== NOT EXECUTED
brc = rtems_rfs_inode_unload (fs, map->inode, true);
203f484: d2 06 60 04 ld [ %i1 + 4 ], %o1 <== NOT EXECUTED
203f488: 40 00 0f b4 call 2043358 <rtems_rfs_inode_unload> <== NOT EXECUTED
203f48c: c2 28 a0 10 stb %g1, [ %g2 + 0x10 ] <== NOT EXECUTED
if (brc > 0)
rc = brc;
map->dirty = false;
203f490: c0 2e 40 00 clrb [ %i1 ] <== NOT EXECUTED
rtems_rfs_inode_set_block_count (map->inode, map->size.count);
rtems_rfs_inode_set_block_offset (map->inode, map->size.offset);
rtems_rfs_inode_set_last_map_block (map->inode, map->last_map_block);
rtems_rfs_inode_set_last_data_block (map->inode, map->last_data_block);
brc = rtems_rfs_inode_unload (fs, map->inode, true);
203f494: 82 38 00 08 xnor %g0, %o0, %g1 <== NOT EXECUTED
203f498: 83 38 60 1f sra %g1, 0x1f, %g1 <== NOT EXECUTED
203f49c: 10 bf ff 9f b 203f318 <rtems_rfs_block_map_close+0x38> <== NOT EXECUTED
203f4a0: b0 0a 00 01 and %o0, %g1, %i0 <== NOT EXECUTED
0203e7f8 <rtems_rfs_block_map_find>:
int
rtems_rfs_block_map_find (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_block_pos* bpos,
rtems_rfs_block_no* block)
{
203e7f8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc = 0;
*block = 0;
203e7fc: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
/*
* Range checking here makes the remaining logic simpler.
*/
if (rtems_rfs_block_pos_block_past_end (bpos, &map->size))
203e800: e4 06 80 00 ld [ %i2 ], %l2 <== NOT EXECUTED
203e804: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203e808: 12 80 00 1c bne 203e878 <rtems_rfs_block_map_find+0x80> <== NOT EXECUTED
203e80c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
203e810: e6 06 60 08 ld [ %i1 + 8 ], %l3 <== NOT EXECUTED
203e814: 80 a4 80 13 cmp %l2, %l3 <== NOT EXECUTED
203e818: 3a 80 00 54 bcc,a 203e968 <rtems_rfs_block_map_find+0x170><== NOT EXECUTED
203e81c: b0 10 20 06 mov 6, %i0 <== NOT EXECUTED
return ENXIO;
/*
* If the block position is the same and we have found the block just return it.
*/
if ((bpos->bno == map->bpos.bno) && (map->bpos.block != 0))
203e820: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
203e824: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED
203e828: 22 80 00 3f be,a 203e924 <rtems_rfs_block_map_find+0x12c><== NOT EXECUTED
203e82c: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
/*
* Determine the type of access we need to perform. If the number of blocks
* is less than or equal to the number of slots in the inode the blocks are
* directly accessed.
*/
if (map->size.count <= RTEMS_RFS_INODE_BLOCKS)
203e830: 80 a4 e0 05 cmp %l3, 5 <== NOT EXECUTED
203e834: 38 80 00 17 bgu,a 203e890 <rtems_rfs_block_map_find+0x98><== NOT EXECUTED
203e838: e8 04 20 30 ld [ %l0 + 0x30 ], %l4 <== NOT EXECUTED
{
*block = map->blocks[bpos->bno];
203e83c: a4 04 a0 08 add %l2, 8, %l2 <== NOT EXECUTED
203e840: a5 2c a0 02 sll %l2, 2, %l2 <== NOT EXECUTED
203e844: a4 06 40 12 add %i1, %l2, %l2 <== NOT EXECUTED
203e848: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
203e84c: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
}
}
if (rc == 0)
{
rtems_rfs_block_copy_bpos (&map->bpos, bpos);
203e850: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
203e854: c2 06 a0 04 ld [ %i2 + 4 ], %g1 <== NOT EXECUTED
203e858: c4 06 80 00 ld [ %i2 ], %g2 <== NOT EXECUTED
203e85c: c6 26 60 18 st %g3, [ %i1 + 0x18 ] <== NOT EXECUTED
203e860: c4 26 60 10 st %g2, [ %i1 + 0x10 ] <== NOT EXECUTED
203e864: c2 26 60 14 st %g1, [ %i1 + 0x14 ] <== NOT EXECUTED
map->bpos.block = *block;
203e868: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
203e86c: c2 26 60 18 st %g1, [ %i1 + 0x18 ] <== NOT EXECUTED
203e870: 81 c7 e0 08 ret <== NOT EXECUTED
203e874: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
*block = 0;
/*
* Range checking here makes the remaining logic simpler.
*/
if (rtems_rfs_block_pos_block_past_end (bpos, &map->size))
203e878: e6 06 60 08 ld [ %i1 + 8 ], %l3 <== NOT EXECUTED
203e87c: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
203e880: 12 bf ff e6 bne 203e818 <rtems_rfs_block_map_find+0x20> <== NOT EXECUTED
203e884: 80 a4 80 13 cmp %l2, %l3 <== NOT EXECUTED
rtems_rfs_block_copy_bpos (&map->bpos, bpos);
map->bpos.block = *block;
}
return rc;
}
203e888: 81 c7 e0 08 ret <== NOT EXECUTED
203e88c: 91 e8 20 06 restore %g0, 6, %o0 <== NOT EXECUTED
* The map is either singly or doubly indirect.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = bpos->bno % fs->blocks_per_block;
203e890: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
203e894: 40 00 90 e8 call 2062c34 <.urem> <== NOT EXECUTED
203e898: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
singly = bpos->bno / fs->blocks_per_block;
203e89c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
* The map is either singly or doubly indirect.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = bpos->bno % fs->blocks_per_block;
203e8a0: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
singly = bpos->bno / fs->blocks_per_block;
203e8a4: 40 00 90 38 call 2062984 <.udiv> <== NOT EXECUTED
203e8a8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (map->size.count <= fs->block_map_singly_blocks)
203e8ac: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = bpos->bno % fs->blocks_per_block;
singly = bpos->bno / fs->blocks_per_block;
203e8b0: d0 27 bf fc st %o0, [ %fp + -4 ] <== NOT EXECUTED
if (map->size.count <= fs->block_map_singly_blocks)
203e8b4: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
203e8b8: 08 80 00 20 bleu 203e938 <rtems_rfs_block_map_find+0x140> <== NOT EXECUTED
203e8bc: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
rtems_rfs_block_no doubly;
doubly = singly / fs->blocks_per_block;
singly %= fs->blocks_per_block;
if (map->size.count < fs->block_map_doubly_blocks)
203e8c0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1 <== NOT EXECUTED
203e8c4: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
203e8c8: 1a 80 00 28 bcc 203e968 <rtems_rfs_block_map_find+0x170> <== NOT EXECUTED
203e8cc: b0 10 20 06 mov 6, %i0 <== NOT EXECUTED
* The map is doubly indirect.
*/
rtems_rfs_block_no doubly;
doubly = singly / fs->blocks_per_block;
singly %= fs->blocks_per_block;
203e8d0: 40 00 90 d9 call 2062c34 <.urem> <== NOT EXECUTED
203e8d4: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
if (map->size.count < fs->block_map_doubly_blocks)
{
rc = rtems_rfs_block_find_indirect (fs,
203e8d8: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
* The map is doubly indirect.
*/
rtems_rfs_block_no doubly;
doubly = singly / fs->blocks_per_block;
singly %= fs->blocks_per_block;
203e8dc: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
if (map->size.count < fs->block_map_doubly_blocks)
{
rc = rtems_rfs_block_find_indirect (fs,
203e8e0: 40 00 90 29 call 2062984 <.udiv> <== NOT EXECUTED
203e8e4: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
203e8e8: 82 02 20 08 add %o0, 8, %g1 <== NOT EXECUTED
203e8ec: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203e8f0: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203e8f4: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
203e8f8: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
* The map is doubly indirect.
*/
rtems_rfs_block_no doubly;
doubly = singly / fs->blocks_per_block;
singly %= fs->blocks_per_block;
203e8fc: e4 27 bf fc st %l2, [ %fp + -4 ] <== NOT EXECUTED
if (map->size.count < fs->block_map_doubly_blocks)
{
rc = rtems_rfs_block_find_indirect (fs,
203e900: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203e904: 92 06 60 44 add %i1, 0x44, %o1 <== NOT EXECUTED
203e908: 7f ff ff 96 call 203e760 <rtems_rfs_block_find_indirect> <== NOT EXECUTED
203e90c: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
&map->doubly_buffer,
map->blocks[doubly],
singly, &singly);
if (rc == 0)
203e910: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e914: 12 80 00 15 bne 203e968 <rtems_rfs_block_map_find+0x170> <== NOT EXECUTED
203e918: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
{
rc = rtems_rfs_block_find_indirect (fs,
203e91c: 10 80 00 0c b 203e94c <rtems_rfs_block_map_find+0x154> <== NOT EXECUTED
203e920: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return ENXIO;
/*
* If the block position is the same and we have found the block just return it.
*/
if ((bpos->bno == map->bpos.bno) && (map->bpos.block != 0))
203e924: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203e928: 02 bf ff c3 be 203e834 <rtems_rfs_block_map_find+0x3c> <== NOT EXECUTED
203e92c: 80 a4 e0 05 cmp %l3, 5 <== NOT EXECUTED
* is less than or equal to the number of slots in the inode the blocks are
* directly accessed.
*/
if (map->size.count <= RTEMS_RFS_INODE_BLOCKS)
{
*block = map->blocks[bpos->bno];
203e930: 10 bf ff c8 b 203e850 <rtems_rfs_block_map_find+0x58> <== NOT EXECUTED
203e934: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
{
/*
* This is a single indirect table of blocks anchored off a slot in the
* inode.
*/
rc = rtems_rfs_block_find_indirect (fs,
203e938: 82 02 20 08 add %o0, 8, %g1 <== NOT EXECUTED
203e93c: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203e940: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203e944: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
&map->doubly_buffer,
map->blocks[doubly],
singly, &singly);
if (rc == 0)
{
rc = rtems_rfs_block_find_indirect (fs,
203e948: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203e94c: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
203e950: 92 06 60 38 add %i1, 0x38, %o1 <== NOT EXECUTED
203e954: 7f ff ff 83 call 203e760 <rtems_rfs_block_find_indirect> <== NOT EXECUTED
203e958: 98 10 00 1b mov %i3, %o4 <== NOT EXECUTED
}
}
}
}
if (rc == 0)
203e95c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203e960: 22 bf ff bd be,a 203e854 <rtems_rfs_block_map_find+0x5c> <== NOT EXECUTED
203e964: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
rtems_rfs_block_copy_bpos (&map->bpos, bpos);
map->bpos.block = *block;
}
return rc;
}
203e968: 81 c7 e0 08 ret <== NOT EXECUTED
203e96c: 81 e8 00 00 restore <== NOT EXECUTED
0203edf8 <rtems_rfs_block_map_free_all>:
int
rtems_rfs_block_map_free_all (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map)
{
return rtems_rfs_block_map_shrink (fs, map, map->size.count);
203edf8: d4 02 60 08 ld [ %o1 + 8 ], %o2 <== NOT EXECUTED
203edfc: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
203ee00: 7f ff ff 30 call 203eac0 <rtems_rfs_block_map_shrink> <== NOT EXECUTED
203ee04: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0203ef28 <rtems_rfs_block_map_grow>:
int
rtems_rfs_block_map_grow (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
size_t blocks,
rtems_rfs_block_no* new_block)
{
203ef28: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))
printf ("rtems-rfs: block-map-grow: entry: blocks=%zd count=%" PRIu32 "\n",
blocks, map->size.count);
if ((map->size.count + blocks) >= rtems_rfs_fs_max_block_map_blocks (fs))
203ef2c: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 <== NOT EXECUTED
203ef30: c4 06 60 08 ld [ %i1 + 8 ], %g2 <== NOT EXECUTED
int
rtems_rfs_block_map_grow (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
size_t blocks,
rtems_rfs_block_no* new_block)
{
203ef34: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))
printf ("rtems-rfs: block-map-grow: entry: blocks=%zd count=%" PRIu32 "\n",
blocks, map->size.count);
if ((map->size.count + blocks) >= rtems_rfs_fs_max_block_map_blocks (fs))
203ef38: 84 06 80 02 add %i2, %g2, %g2 <== NOT EXECUTED
203ef3c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
203ef40: 1a 80 00 e0 bcc 203f2c0 <rtems_rfs_block_map_grow+0x398> <== NOT EXECUTED
203ef44: b0 10 20 1b mov 0x1b, %i0 <== NOT EXECUTED
/*
* Allocate a block at a time. The buffer handles hold the blocks so adding
* this way does not thrash the cache with lots of requests.
*/
for (b = 0; b < blocks; b++)
203ef48: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
203ef4c: 02 80 00 c3 be 203f258 <rtems_rfs_block_map_grow+0x330> <== NOT EXECUTED
203ef50: ae 06 60 38 add %i1, 0x38, %l7 <== NOT EXECUTED
203ef54: d2 06 60 20 ld [ %i1 + 0x20 ], %o1 <== NOT EXECUTED
return rc;
}
}
else
{
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
203ef58: ba 06 60 44 add %i1, 0x44, %i5 <== NOT EXECUTED
203ef5c: a2 10 20 00 clr %l1 <== NOT EXECUTED
203ef60: a8 07 bf fc add %fp, -4, %l4 <== NOT EXECUTED
return rc;
}
}
}
rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
203ef64: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
* doubly indirect block as well. Both always occur when direct is 0
* and the doubly indirect block when singly is 0.
*/
if (direct == 0)
{
rc = rtems_rfs_block_map_indirect_alloc (fs, map,
203ef68: 10 80 00 13 b 203efb4 <rtems_rfs_block_map_grow+0x8c> <== NOT EXECUTED
203ef6c: b8 07 bf f8 add %fp, -8, %i4 <== NOT EXECUTED
false, &block);
if (rc > 0)
return rc;
if (map->size.count < RTEMS_RFS_INODE_BLOCKS)
map->blocks[map->size.count] = block;
203ef70: 82 05 60 08 add %l5, 8, %g1 <== NOT EXECUTED
203ef74: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203ef78: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203ef7c: d2 20 60 04 st %o1, [ %g1 + 4 ] <== NOT EXECUTED
203ef80: 82 10 00 09 mov %o1, %g1 <== NOT EXECUTED
}
rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
}
map->size.count++;
203ef84: aa 05 60 01 inc %l5 <== NOT EXECUTED
map->size.offset = 0;
203ef88: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
if (b == 0)
203ef8c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203ef90: 12 80 00 04 bne 203efa0 <rtems_rfs_block_map_grow+0x78> <== NOT EXECUTED
203ef94: ea 26 60 08 st %l5, [ %i1 + 8 ] <== NOT EXECUTED
*new_block = block;
203ef98: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
203ef9c: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
map->last_data_block = block;
203efa0: c2 26 60 20 st %g1, [ %i1 + 0x20 ] <== NOT EXECUTED
/*
* Allocate a block at a time. The buffer handles hold the blocks so adding
* this way does not thrash the cache with lots of requests.
*/
for (b = 0; b < blocks; b++)
203efa4: a2 04 60 01 inc %l1 <== NOT EXECUTED
203efa8: 80 a6 80 11 cmp %i2, %l1 <== NOT EXECUTED
203efac: 08 80 00 ab bleu 203f258 <rtems_rfs_block_map_grow+0x330> <== NOT EXECUTED
203efb0: e6 2e 40 00 stb %l3, [ %i1 ] <== NOT EXECUTED
/*
* Allocate the block. If an indirect block is needed and cannot be
* allocated free this block.
*/
rc = rtems_rfs_group_bitmap_alloc (fs, map->last_data_block,
203efb4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203efb8: 94 10 20 00 clr %o2 <== NOT EXECUTED
203efbc: 40 00 0f 70 call 2042d7c <rtems_rfs_group_bitmap_alloc> <== NOT EXECUTED
203efc0: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
false, &block);
if (rc > 0)
203efc4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203efc8: 14 80 00 c4 bg 203f2d8 <rtems_rfs_block_map_grow+0x3b0> <== NOT EXECUTED
203efcc: 01 00 00 00 nop <== NOT EXECUTED
return rc;
if (map->size.count < RTEMS_RFS_INODE_BLOCKS)
203efd0: ea 06 60 08 ld [ %i1 + 8 ], %l5 <== NOT EXECUTED
203efd4: 80 a5 60 04 cmp %l5, 4 <== NOT EXECUTED
203efd8: 08 bf ff e6 bleu 203ef70 <rtems_rfs_block_map_grow+0x48> <== NOT EXECUTED
203efdc: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
* Single indirect access is occuring. It could still be doubly indirect.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = map->size.count % fs->blocks_per_block;
203efe0: f0 04 20 30 ld [ %l0 + 0x30 ], %i0 <== NOT EXECUTED
203efe4: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
203efe8: 40 00 8f 13 call 2062c34 <.urem> <== NOT EXECUTED
203efec: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
singly = map->size.count / fs->blocks_per_block;
203eff0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
* Single indirect access is occuring. It could still be doubly indirect.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = map->size.count % fs->blocks_per_block;
203eff4: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
singly = map->size.count / fs->blocks_per_block;
203eff8: 40 00 8e 63 call 2062984 <.udiv> <== NOT EXECUTED
203effc: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
if (map->size.count < fs->block_map_singly_blocks)
203f000: c4 04 20 34 ld [ %l0 + 0x34 ], %g2 <== NOT EXECUTED
203f004: 80 a5 40 02 cmp %l5, %g2 <== NOT EXECUTED
203f008: 1a 80 00 32 bcc 203f0d0 <rtems_rfs_block_map_grow+0x1a8> <== NOT EXECUTED
203f00c: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
* Singly indirect tables are being used. Allocate a new block for a
* mapping table if direct is 0 or we are moving up (upping). If upping
* move the direct blocks into the table and if not this is the first
* entry of a new block.
*/
if ((direct == 0) ||
203f010: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203f014: 02 80 00 06 be 203f02c <rtems_rfs_block_map_grow+0x104> <== NOT EXECUTED
203f018: 80 a4 a0 05 cmp %l2, 5 <== NOT EXECUTED
203f01c: 12 80 00 91 bne 203f260 <rtems_rfs_block_map_grow+0x338> <== NOT EXECUTED
203f020: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f024: 32 80 00 90 bne,a 203f264 <rtems_rfs_block_map_grow+0x33c><== NOT EXECUTED
203f028: 82 00 60 08 add %g1, 8, %g1 <== NOT EXECUTED
/*
* Upping is when we move from direct to singly indirect.
*/
bool upping;
upping = map->size.count == RTEMS_RFS_INODE_BLOCKS;
rc = rtems_rfs_block_map_indirect_alloc (fs, map,
203f02c: aa 1d 60 05 xor %l5, 5, %l5 <== NOT EXECUTED
203f030: 80 a0 00 15 cmp %g0, %l5 <== NOT EXECUTED
203f034: 96 00 60 08 add %g1, 8, %o3 <== NOT EXECUTED
203f038: 98 60 3f ff subx %g0, -1, %o4 <== NOT EXECUTED
203f03c: 97 2a e0 02 sll %o3, 2, %o3 <== NOT EXECUTED
203f040: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f044: 96 06 40 0b add %i1, %o3, %o3 <== NOT EXECUTED
203f048: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203f04c: 96 02 e0 04 add %o3, 4, %o3 <== NOT EXECUTED
203f050: 7f ff ff 6f call 203ee0c <rtems_rfs_block_map_indirect_alloc><== NOT EXECUTED
203f054: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
203f058: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
singly);
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
singly_block, true);
if (rc > 0)
203f05c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203f060: 34 80 00 9b bg,a 203f2cc <rtems_rfs_block_map_grow+0x3a4><== NOT EXECUTED
203f064: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
return rc;
}
}
}
rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
203f068: c2 06 60 40 ld [ %i1 + 0x40 ], %g1 <== NOT EXECUTED
203f06c: c6 0f bf fc ldub [ %fp + -4 ], %g3 <== NOT EXECUTED
203f070: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
203f074: 83 2c a0 02 sll %l2, 2, %g1 <== NOT EXECUTED
203f078: c6 28 80 01 stb %g3, [ %g2 + %g1 ] <== NOT EXECUTED
203f07c: c4 06 60 40 ld [ %i1 + 0x40 ], %g2 <== NOT EXECUTED
203f080: c6 17 bf fc lduh [ %fp + -4 ], %g3 <== NOT EXECUTED
203f084: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f088: a4 00 60 02 add %g1, 2, %l2 <== NOT EXECUTED
203f08c: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED
203f090: c6 28 a0 01 stb %g3, [ %g2 + 1 ] <== NOT EXECUTED
203f094: c4 06 60 40 ld [ %i1 + 0x40 ], %g2 <== NOT EXECUTED
203f098: c6 07 bf fc ld [ %fp + -4 ], %g3 <== NOT EXECUTED
203f09c: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f0a0: 87 30 e0 08 srl %g3, 8, %g3 <== NOT EXECUTED
203f0a4: c6 28 80 12 stb %g3, [ %g2 + %l2 ] <== NOT EXECUTED
203f0a8: c4 06 60 40 ld [ %i1 + 0x40 ], %g2 <== NOT EXECUTED
203f0ac: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f0b0: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
203f0b4: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
203f0b8: c4 28 60 03 stb %g2, [ %g1 + 3 ] <== NOT EXECUTED
203f0bc: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
203f0c0: ea 06 60 08 ld [ %i1 + 8 ], %l5 <== NOT EXECUTED
203f0c4: e6 2e 60 38 stb %l3, [ %i1 + 0x38 ] <== NOT EXECUTED
203f0c8: 10 bf ff af b 203ef84 <rtems_rfs_block_map_grow+0x5c> <== NOT EXECUTED
203f0cc: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
* Doubly indirect tables are being used.
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no singly_block;
doubly = singly / fs->blocks_per_block;
203f0d0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203f0d4: 40 00 8e 2c call 2062984 <.udiv> <== NOT EXECUTED
203f0d8: d0 27 bf f4 st %o0, [ %fp + -12 ] <== NOT EXECUTED
singly %= fs->blocks_per_block;
203f0dc: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
* Doubly indirect tables are being used.
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no singly_block;
doubly = singly / fs->blocks_per_block;
203f0e0: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
singly %= fs->blocks_per_block;
203f0e4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
203f0e8: 40 00 8e d3 call 2062c34 <.urem> <== NOT EXECUTED
203f0ec: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
* Allocate a new block for a singly indirect table if direct is 0 as
* it is the first entry of a new block. We may also need to allocate a
* doubly indirect block as well. Both always occur when direct is 0
* and the doubly indirect block when singly is 0.
*/
if (direct == 0)
203f0f0: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
203f0f4: 12 80 00 38 bne 203f1d4 <rtems_rfs_block_map_grow+0x2ac> <== NOT EXECUTED
203f0f8: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
{
rc = rtems_rfs_block_map_indirect_alloc (fs, map,
203f0fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f100: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203f104: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
203f108: 96 10 00 1c mov %i4, %o3 <== NOT EXECUTED
203f10c: 7f ff ff 40 call 203ee0c <rtems_rfs_block_map_indirect_alloc><== NOT EXECUTED
203f110: 98 10 20 00 clr %o4 <== NOT EXECUTED
&map->singly_buffer,
&singly_block,
false);
if (rc > 0)
203f114: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f118: 14 80 00 6c bg 203f2c8 <rtems_rfs_block_map_grow+0x3a0> <== NOT EXECUTED
203f11c: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
/*
* Allocate a new block for a doubly indirect table if singly is 0 as
* it is the first entry of a new singly indirect block.
*/
if ((singly == 0) ||
203f120: 02 80 00 06 be 203f138 <rtems_rfs_block_map_grow+0x210> <== NOT EXECUTED
203f124: 80 a5 60 05 cmp %l5, 5 <== NOT EXECUTED
203f128: 12 80 00 53 bne 203f274 <rtems_rfs_block_map_grow+0x34c> <== NOT EXECUTED
203f12c: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED
203f130: 12 80 00 52 bne 203f278 <rtems_rfs_block_map_grow+0x350> <== NOT EXECUTED
203f134: 82 05 a0 08 add %l6, 8, %g1 <== NOT EXECUTED
((doubly == 0) && (singly == RTEMS_RFS_INODE_BLOCKS)))
{
bool upping;
upping = map->size.count == fs->block_map_singly_blocks;
rc = rtems_rfs_block_map_indirect_alloc (fs, map,
203f138: c4 06 60 08 ld [ %i1 + 8 ], %g2 <== NOT EXECUTED
203f13c: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
203f140: 96 05 a0 08 add %l6, 8, %o3 <== NOT EXECUTED
203f144: 82 18 80 01 xor %g2, %g1, %g1 <== NOT EXECUTED
203f148: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
203f14c: 97 2a e0 02 sll %o3, 2, %o3 <== NOT EXECUTED
203f150: 98 60 3f ff subx %g0, -1, %o4 <== NOT EXECUTED
203f154: 96 06 40 0b add %i1, %o3, %o3 <== NOT EXECUTED
203f158: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f15c: 96 02 e0 04 add %o3, 4, %o3 <== NOT EXECUTED
203f160: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203f164: 7f ff ff 2a call 203ee0c <rtems_rfs_block_map_indirect_alloc><== NOT EXECUTED
203f168: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
&map->doubly_buffer,
&map->blocks[doubly],
upping);
if (rc > 0)
203f16c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f170: 34 80 00 4d bg,a 203f2a4 <rtems_rfs_block_map_grow+0x37c><== NOT EXECUTED
203f174: d4 07 bf f8 ld [ %fp + -8 ], %o2 <== NOT EXECUTED
rtems_rfs_group_bitmap_free (fs, false, block);
return rc;
}
}
rtems_rfs_block_set_number (&map->doubly_buffer,
203f178: c2 06 60 4c ld [ %i1 + 0x4c ], %g1 <== NOT EXECUTED
203f17c: c6 0f bf f8 ldub [ %fp + -8 ], %g3 <== NOT EXECUTED
203f180: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
203f184: 83 2d 60 02 sll %l5, 2, %g1 <== NOT EXECUTED
203f188: c6 28 80 01 stb %g3, [ %g2 + %g1 ] <== NOT EXECUTED
203f18c: c4 06 60 4c ld [ %i1 + 0x4c ], %g2 <== NOT EXECUTED
203f190: c6 17 bf f8 lduh [ %fp + -8 ], %g3 <== NOT EXECUTED
203f194: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f198: aa 00 60 02 add %g1, 2, %l5 <== NOT EXECUTED
203f19c: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED
203f1a0: c6 28 a0 01 stb %g3, [ %g2 + 1 ] <== NOT EXECUTED
203f1a4: c4 06 60 4c ld [ %i1 + 0x4c ], %g2 <== NOT EXECUTED
203f1a8: c6 07 bf f8 ld [ %fp + -8 ], %g3 <== NOT EXECUTED
203f1ac: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f1b0: 87 30 e0 08 srl %g3, 8, %g3 <== NOT EXECUTED
203f1b4: c6 28 80 15 stb %g3, [ %g2 + %l5 ] <== NOT EXECUTED
203f1b8: c4 06 60 4c ld [ %i1 + 0x4c ], %g2 <== NOT EXECUTED
203f1bc: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
203f1c0: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
203f1c4: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
203f1c8: c4 28 60 03 stb %g2, [ %g1 + 3 ] <== NOT EXECUTED
203f1cc: 10 bf ff a7 b 203f068 <rtems_rfs_block_map_grow+0x140> <== NOT EXECUTED
203f1d0: e6 2e 60 44 stb %l3, [ %i1 + 0x44 ] <== NOT EXECUTED
singly,
singly_block);
}
else
{
rc = rtems_rfs_buffer_handle_request (fs,
203f1d4: ac 05 a0 08 add %l6, 8, %l6 <== NOT EXECUTED
203f1d8: ad 2d a0 02 sll %l6, 2, %l6 <== NOT EXECUTED
203f1dc: ac 06 40 16 add %i1, %l6, %l6 <== NOT EXECUTED
203f1e0: d4 05 a0 04 ld [ %l6 + 4 ], %o2 <== NOT EXECUTED
203f1e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f1e8: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
203f1ec: 40 00 01 cc call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203f1f0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
&map->doubly_buffer,
map->blocks[doubly],
true);
if (rc > 0)
203f1f4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f1f8: 14 80 00 34 bg 203f2c8 <rtems_rfs_block_map_grow+0x3a0> <== NOT EXECUTED
203f1fc: 85 2d 60 02 sll %l5, 2, %g2 <== NOT EXECUTED
{
rtems_rfs_group_bitmap_free (fs, false, block);
return rc;
}
singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
203f200: c2 06 60 4c ld [ %i1 + 0x4c ], %g1 <== NOT EXECUTED
203f204: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
203f208: ab 2d 60 02 sll %l5, 2, %l5 <== NOT EXECUTED
203f20c: 84 00 a0 02 add %g2, 2, %g2 <== NOT EXECUTED
203f210: d4 08 40 15 ldub [ %g1 + %l5 ], %o2 <== NOT EXECUTED
203f214: c4 08 40 02 ldub [ %g1 + %g2 ], %g2 <== NOT EXECUTED
203f218: 82 00 40 15 add %g1, %l5, %g1 <== NOT EXECUTED
203f21c: c6 08 60 01 ldub [ %g1 + 1 ], %g3 <== NOT EXECUTED
203f220: c2 08 60 03 ldub [ %g1 + 3 ], %g1 <== NOT EXECUTED
203f224: 95 2a a0 18 sll %o2, 0x18, %o2 <== NOT EXECUTED
203f228: 94 10 40 0a or %g1, %o2, %o2 <== NOT EXECUTED
203f22c: 83 28 e0 10 sll %g3, 0x10, %g1 <== NOT EXECUTED
203f230: 94 12 80 01 or %o2, %g1, %o2 <== NOT EXECUTED
203f234: 83 28 a0 08 sll %g2, 8, %g1 <== NOT EXECUTED
203f238: 94 12 80 01 or %o2, %g1, %o2 <== NOT EXECUTED
203f23c: d4 27 bf f8 st %o2, [ %fp + -8 ] <== NOT EXECUTED
singly);
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
203f240: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f244: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
203f248: 40 00 01 b5 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203f24c: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203f250: 10 bf ff 83 b 203f05c <rtems_rfs_block_map_grow+0x134> <== NOT EXECUTED
203f254: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
map->last_data_block = block;
map->dirty = true;
}
return 0;
}
203f258: 81 c7 e0 08 ret <== NOT EXECUTED
203f25c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
&map->blocks[singly],
upping);
}
else
{
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
203f260: 82 00 60 08 add %g1, 8, %g1 <== NOT EXECUTED
203f264: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203f268: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203f26c: 10 bf ff f5 b 203f240 <rtems_rfs_block_map_grow+0x318> <== NOT EXECUTED
203f270: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
return rc;
}
}
else
{
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
203f274: 82 05 a0 08 add %l6, 8, %g1 <== NOT EXECUTED
203f278: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203f27c: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203f280: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
203f284: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f288: 92 10 00 1d mov %i5, %o1 <== NOT EXECUTED
203f28c: 40 00 01 a4 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203f290: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
map->blocks[doubly], true);
if (rc > 0)
203f294: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f298: 24 bf ff b9 ble,a 203f17c <rtems_rfs_block_map_grow+0x254><== NOT EXECUTED
203f29c: c2 06 60 4c ld [ %i1 + 0x4c ], %g1 <== NOT EXECUTED
{
rtems_rfs_group_bitmap_free (fs, false, singly_block);
203f2a0: d4 07 bf f8 ld [ %fp + -8 ], %o2 <== NOT EXECUTED
203f2a4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f2a8: 40 00 0e 81 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203f2ac: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_rfs_group_bitmap_free (fs, false, block);
203f2b0: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
203f2b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f2b8: 40 00 0e 7d call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203f2bc: 92 10 20 00 clr %o1 <== NOT EXECUTED
return rc;
203f2c0: 81 c7 e0 08 ret <== NOT EXECUTED
203f2c4: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
singly_block, true);
if (rc > 0)
{
rtems_rfs_group_bitmap_free (fs, false, block);
203f2c8: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
203f2cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f2d0: 40 00 0e 77 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203f2d4: 92 10 20 00 clr %o1 <== NOT EXECUTED
return rc;
203f2d8: 81 c7 e0 08 ret <== NOT EXECUTED
203f2dc: 81 e8 00 00 restore <== NOT EXECUTED
0203ee0c <rtems_rfs_block_map_indirect_alloc>:
rtems_rfs_block_map_indirect_alloc (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_buffer_handle* buffer,
rtems_rfs_block_no* block,
bool upping)
{
203ee0c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc;
/*
* Save the new block locally because upping can have *block pointing to the
* slots which are cleared when upping.
*/
rc = rtems_rfs_group_bitmap_alloc (fs, map->last_map_block, false, &new_block);
203ee10: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
203ee14: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_indirect_alloc (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_buffer_handle* buffer,
rtems_rfs_block_no* block,
bool upping)
{
203ee18: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc;
/*
* Save the new block locally because upping can have *block pointing to the
* slots which are cleared when upping.
*/
rc = rtems_rfs_group_bitmap_alloc (fs, map->last_map_block, false, &new_block);
203ee1c: 94 10 20 00 clr %o2 <== NOT EXECUTED
203ee20: 40 00 0f d7 call 2042d7c <rtems_rfs_group_bitmap_alloc> <== NOT EXECUTED
203ee24: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if (rc > 0)
203ee28: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203ee2c: 14 80 00 0c bg 203ee5c <rtems_rfs_block_map_indirect_alloc+0x50><== NOT EXECUTED
203ee30: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
return rc;
rc = rtems_rfs_buffer_handle_request (fs, buffer, new_block, false);
203ee34: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ee38: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203ee3c: 40 00 02 b8 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203ee40: 96 10 20 00 clr %o3 <== NOT EXECUTED
if (rc > 0)
203ee44: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203ee48: 04 80 00 07 ble 203ee64 <rtems_rfs_block_map_indirect_alloc+0x58><== NOT EXECUTED
203ee4c: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
{
rtems_rfs_group_bitmap_free (fs, false, new_block);
203ee50: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ee54: 40 00 0f 96 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203ee58: 92 10 20 00 clr %o1 <== NOT EXECUTED
return rc;
203ee5c: 81 c7 e0 08 ret <== NOT EXECUTED
203ee60: 81 e8 00 00 restore <== NOT EXECUTED
}
memset (rtems_rfs_buffer_data (buffer), 0xff, rtems_rfs_fs_block_size (fs));
203ee64: c2 06 a0 08 ld [ %i2 + 8 ], %g1 <== NOT EXECUTED
203ee68: d4 04 20 08 ld [ %l0 + 8 ], %o2 <== NOT EXECUTED
203ee6c: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
203ee70: 40 00 3b 63 call 204dbfc <memset> <== NOT EXECUTED
203ee74: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
if (upping)
203ee78: 80 8f 20 ff btst 0xff, %i4 <== NOT EXECUTED
203ee7c: 02 80 00 25 be 203ef10 <rtems_rfs_block_map_indirect_alloc+0x104><== NOT EXECUTED
203ee80: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
203ee84: 84 10 00 19 mov %i1, %g2 <== NOT EXECUTED
203ee88: 82 10 20 00 clr %g1 <== NOT EXECUTED
int b;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))
printf ("rtems-rfs: block-map-grow: upping: block-count=%" PRId32 "\n",
map->size.count);
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_block_set_number (buffer, b, map->blocks[b]);
203ee8c: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
203ee90: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
203ee94: c8 08 a0 24 ldub [ %g2 + 0x24 ], %g4 <== NOT EXECUTED
203ee98: c6 00 e0 24 ld [ %g3 + 0x24 ], %g3 <== NOT EXECUTED
203ee9c: c8 28 c0 01 stb %g4, [ %g3 + %g1 ] <== NOT EXECUTED
203eea0: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
203eea4: c8 10 a0 24 lduh [ %g2 + 0x24 ], %g4 <== NOT EXECUTED
203eea8: c6 00 e0 24 ld [ %g3 + 0x24 ], %g3 <== NOT EXECUTED
203eeac: 86 00 c0 01 add %g3, %g1, %g3 <== NOT EXECUTED
203eeb0: c8 28 e0 01 stb %g4, [ %g3 + 1 ] <== NOT EXECUTED
203eeb4: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
203eeb8: c8 00 a0 24 ld [ %g2 + 0x24 ], %g4 <== NOT EXECUTED
203eebc: c6 00 e0 24 ld [ %g3 + 0x24 ], %g3 <== NOT EXECUTED
203eec0: 89 31 20 08 srl %g4, 8, %g4 <== NOT EXECUTED
203eec4: 86 00 c0 01 add %g3, %g1, %g3 <== NOT EXECUTED
203eec8: c8 28 e0 02 stb %g4, [ %g3 + 2 ] <== NOT EXECUTED
203eecc: c6 06 a0 08 ld [ %i2 + 8 ], %g3 <== NOT EXECUTED
203eed0: c8 00 a0 24 ld [ %g2 + 0x24 ], %g4 <== NOT EXECUTED
203eed4: c6 00 e0 24 ld [ %g3 + 0x24 ], %g3 <== NOT EXECUTED
203eed8: 84 00 a0 04 add %g2, 4, %g2 <== NOT EXECUTED
203eedc: 86 00 c0 01 add %g3, %g1, %g3 <== NOT EXECUTED
203eee0: c8 28 e0 03 stb %g4, [ %g3 + 3 ] <== NOT EXECUTED
203eee4: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
{
int b;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))
printf ("rtems-rfs: block-map-grow: upping: block-count=%" PRId32 "\n",
map->size.count);
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
203eee8: 80 a0 60 14 cmp %g1, 0x14 <== NOT EXECUTED
203eeec: 12 bf ff e9 bne 203ee90 <rtems_rfs_block_map_indirect_alloc+0x84><== NOT EXECUTED
203eef0: da 2e 80 00 stb %o5, [ %i2 ] <== NOT EXECUTED
rtems_rfs_block_set_number (buffer, b, map->blocks[b]);
memset (map->blocks, 0, sizeof (map->blocks));
203eef4: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
203eef8: 82 06 60 24 add %i1, 0x24, %g1 <== NOT EXECUTED
203eefc: c0 20 60 10 clr [ %g1 + 0x10 ] <== NOT EXECUTED
203ef00: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
203ef04: c0 20 60 08 clr [ %g1 + 8 ] <== NOT EXECUTED
203ef08: c0 20 60 0c clr [ %g1 + 0xc ] <== NOT EXECUTED
}
rtems_rfs_buffer_mark_dirty (buffer);
*block = new_block;
203ef0c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
map->size.count);
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_block_set_number (buffer, b, map->blocks[b]);
memset (map->blocks, 0, sizeof (map->blocks));
}
rtems_rfs_buffer_mark_dirty (buffer);
203ef10: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
*block = new_block;
203ef14: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
map->size.count);
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
rtems_rfs_block_set_number (buffer, b, map->blocks[b]);
memset (map->blocks, 0, sizeof (map->blocks));
}
rtems_rfs_buffer_mark_dirty (buffer);
203ef18: c4 2e 80 00 stb %g2, [ %i2 ] <== NOT EXECUTED
*block = new_block;
map->last_map_block = new_block;
203ef1c: c2 26 60 1c st %g1, [ %i1 + 0x1c ] <== NOT EXECUTED
return 0;
}
203ef20: 81 c7 e0 08 ret <== NOT EXECUTED
203ef24: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0203ea0c <rtems_rfs_block_map_indirect_shrink>:
rtems_rfs_block_map_indirect_shrink (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_buffer_handle* buffer,
rtems_rfs_block_no indirect,
rtems_rfs_block_no index)
{
203ea0c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
* block to be freed and the indirect block is now also free, or we have only
* one indirect table and we can fit the remaining blocks into the inode,
* then either move to the next indirect block or move the remaining blocks
* into the inode and free the indirect table's block.
*/
if ((index == 0) ||
203ea10: 80 a7 20 00 cmp %i4, 0 <== NOT EXECUTED
203ea14: 22 80 00 07 be,a 203ea30 <rtems_rfs_block_map_indirect_shrink+0x24><== NOT EXECUTED
203ea18: b6 06 e0 08 add %i3, 8, %i3 <== NOT EXECUTED
203ea1c: 80 a7 20 05 cmp %i4, 5 <== NOT EXECUTED
203ea20: 02 80 00 11 be 203ea64 <rtems_rfs_block_map_indirect_shrink+0x58><== NOT EXECUTED
203ea24: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
203ea28: 81 c7 e0 08 ret <== NOT EXECUTED
203ea2c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
((indirect == 0) && (index == RTEMS_RFS_INODE_BLOCKS)))
{
rtems_rfs_block_no block_to_free = map->blocks[indirect];
203ea30: b7 2e e0 02 sll %i3, 2, %i3 <== NOT EXECUTED
203ea34: b6 06 40 1b add %i1, %i3, %i3 <== NOT EXECUTED
203ea38: f8 06 e0 04 ld [ %i3 + 4 ], %i4 <== NOT EXECUTED
else
{
/*
* One less singly indirect block in the inode.
*/
map->blocks[indirect] = 0;
203ea3c: c0 26 e0 04 clr [ %i3 + 4 ] <== NOT EXECUTED
}
rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);
203ea40: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203ea44: 92 10 20 00 clr %o1 <== NOT EXECUTED
203ea48: 40 00 10 99 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203ea4c: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
if (rc > 0)
203ea50: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203ea54: 24 80 00 02 ble,a 203ea5c <rtems_rfs_block_map_indirect_shrink+0x50><== NOT EXECUTED
203ea58: f8 26 60 1c st %i4, [ %i1 + 0x1c ] <== NOT EXECUTED
map->last_map_block = block_to_free;
}
return rc;
}
203ea5c: 81 c7 e0 08 ret <== NOT EXECUTED
203ea60: 81 e8 00 00 restore <== NOT EXECUTED
* block to be freed and the indirect block is now also free, or we have only
* one indirect table and we can fit the remaining blocks into the inode,
* then either move to the next indirect block or move the remaining blocks
* into the inode and free the indirect table's block.
*/
if ((index == 0) ||
203ea64: 12 bf ff f1 bne 203ea28 <rtems_rfs_block_map_indirect_shrink+0x1c><== NOT EXECUTED
203ea68: 84 10 20 00 clr %g2 <== NOT EXECUTED
((indirect == 0) && (index == RTEMS_RFS_INODE_BLOCKS)))
{
rtems_rfs_block_no block_to_free = map->blocks[indirect];
203ea6c: c2 06 a0 08 ld [ %i2 + 8 ], %g1 <== NOT EXECUTED
203ea70: f8 06 60 24 ld [ %i1 + 0x24 ], %i4 <== NOT EXECUTED
203ea74: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
/*
* Move to direct inode access.
*/
int b;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
map->blocks[b] = rtems_rfs_block_get_number (buffer, b);
203ea78: c6 08 60 02 ldub [ %g1 + 2 ], %g3 <== NOT EXECUTED
203ea7c: d8 08 40 00 ldub [ %g1 ], %o4 <== NOT EXECUTED
203ea80: c8 08 60 01 ldub [ %g1 + 1 ], %g4 <== NOT EXECUTED
203ea84: da 08 60 03 ldub [ %g1 + 3 ], %o5 <== NOT EXECUTED
203ea88: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
203ea8c: 99 2b 20 18 sll %o4, 0x18, %o4 <== NOT EXECUTED
203ea90: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203ea94: 88 13 00 04 or %o4, %g4, %g4 <== NOT EXECUTED
203ea98: 88 11 00 0d or %g4, %o5, %g4 <== NOT EXECUTED
203ea9c: 88 11 00 03 or %g4, %g3, %g4 <== NOT EXECUTED
203eaa0: 86 06 40 02 add %i1, %g2, %g3 <== NOT EXECUTED
203eaa4: c8 20 e0 24 st %g4, [ %g3 + 0x24 ] <== NOT EXECUTED
203eaa8: 84 00 a0 04 add %g2, 4, %g2 <== NOT EXECUTED
{
/*
* Move to direct inode access.
*/
int b;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
203eaac: 80 a0 a0 14 cmp %g2, 0x14 <== NOT EXECUTED
203eab0: 12 bf ff f2 bne 203ea78 <rtems_rfs_block_map_indirect_shrink+0x6c><== NOT EXECUTED
203eab4: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
* One less singly indirect block in the inode.
*/
map->blocks[indirect] = 0;
}
rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);
203eab8: 10 bf ff e3 b 203ea44 <rtems_rfs_block_map_indirect_shrink+0x38><== NOT EXECUTED
203eabc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
0203e970 <rtems_rfs_block_map_next_block>:
int
rtems_rfs_block_map_next_block (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_block_no* block)
{
203e970: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_rfs_block_pos bpos;
bpos.bno = map->bpos.bno + 1;
203e974: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
int
rtems_rfs_block_map_next_block (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_block_no* block)
{
203e978: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
rtems_rfs_block_pos bpos;
bpos.bno = map->bpos.bno + 1;
203e97c: 82 00 60 01 inc %g1 <== NOT EXECUTED
bpos.boff = 0;
203e980: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
rtems_rfs_block_map_next_block (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_block_no* block)
{
rtems_rfs_block_pos bpos;
bpos.bno = map->bpos.bno + 1;
203e984: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
bpos.boff = 0;
bpos.block = 0;
203e988: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
return rtems_rfs_block_map_find (fs, map, &bpos, block);
203e98c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203e990: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
203e994: 7f ff ff 99 call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
203e998: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED
}
203e99c: 81 c7 e0 08 ret <== NOT EXECUTED
203e9a0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0203f4a4 <rtems_rfs_block_map_open>:
int
rtems_rfs_block_map_open (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* inode,
rtems_rfs_block_map* map)
{
203f4a4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
* Set the count to 0 so at least find fails, then open the handle and make
* sure the inode has been loaded into memory. If we did not load the inode
* do not unload it. The caller may assume it is still loaded when we return.
*/
map->dirty = false;
203f4a8: c0 2e 80 00 clrb [ %i2 ] <== NOT EXECUTED
map->inode = NULL;
203f4ac: c0 26 a0 04 clr [ %i2 + 4 ] <== NOT EXECUTED
* @param size A pointer to the block size.
*/
static inline void
rtems_rfs_block_set_size_zero (rtems_rfs_block_size* size)
{
size->count = 0;
203f4b0: c0 26 a0 08 clr [ %i2 + 8 ] <== NOT EXECUTED
size->offset = 0;
203f4b4: c0 26 a0 0c clr [ %i2 + 0xc ] <== NOT EXECUTED
* @param bpos A pointer to the block position.
*/
static inline void
rtems_rfs_block_set_bpos_zero (rtems_rfs_block_pos* bpos)
{
bpos->bno = 0;
203f4b8: c0 26 a0 10 clr [ %i2 + 0x10 ] <== NOT EXECUTED
bpos->boff = 0;
203f4bc: c0 26 a0 14 clr [ %i2 + 0x14 ] <== NOT EXECUTED
bpos->block = 0;
203f4c0: c0 26 a0 18 clr [ %i2 + 0x18 ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
203f4c4: c0 2e a0 38 clrb [ %i2 + 0x38 ] <== NOT EXECUTED
handle->bnum = 0;
203f4c8: c0 26 a0 3c clr [ %i2 + 0x3c ] <== NOT EXECUTED
handle->buffer = NULL;
203f4cc: c0 26 a0 40 clr [ %i2 + 0x40 ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
203f4d0: c0 2e a0 44 clrb [ %i2 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
203f4d4: c0 26 a0 48 clr [ %i2 + 0x48 ] <== NOT EXECUTED
handle->buffer = NULL;
203f4d8: c0 26 a0 4c clr [ %i2 + 0x4c ] <== NOT EXECUTED
return rc;
rc = rtems_rfs_buffer_handle_open (fs, &map->doubly_buffer);
if (rc > 0)
return rc;
rc = rtems_rfs_inode_load (fs, inode);
203f4dc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203f4e0: 40 00 0f da call 2043448 <rtems_rfs_inode_load> <== NOT EXECUTED
203f4e4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (rc > 0)
203f4e8: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
203f4ec: 14 80 00 40 bg 203f5ec <rtems_rfs_block_map_open+0x148> <== NOT EXECUTED
203f4f0: 84 10 00 1a mov %i2, %g2 <== NOT EXECUTED
/*
* Extract the block and block count data from the inode into the targets
* byte order.
*/
map->inode = inode;
203f4f4: c6 06 60 0c ld [ %i1 + 0xc ], %g3 <== NOT EXECUTED
203f4f8: f2 26 a0 04 st %i1, [ %i2 + 4 ] <== NOT EXECUTED
203f4fc: 82 00 e0 1c add %g3, 0x1c, %g1 <== NOT EXECUTED
block_size = rtems_rfs_fs_block_size (fs);
return (((uint64_t) (size->count - 1)) * block_size) + offset;
}
int
rtems_rfs_block_map_open (rtems_rfs_file_system* fs,
203f500: 94 00 e0 30 add %g3, 0x30, %o2 <== NOT EXECUTED
* Extract the block and block count data from the inode into the targets
* byte order.
*/
map->inode = inode;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
map->blocks[b] = rtems_rfs_inode_get_block (inode, b);
203f504: d6 08 40 00 ldub [ %g1 ], %o3 <== NOT EXECUTED
203f508: c8 08 60 01 ldub [ %g1 + 1 ], %g4 <== NOT EXECUTED
203f50c: d8 08 60 03 ldub [ %g1 + 3 ], %o4 <== NOT EXECUTED
203f510: da 08 60 02 ldub [ %g1 + 2 ], %o5 <== NOT EXECUTED
203f514: 97 2a e0 18 sll %o3, 0x18, %o3 <== NOT EXECUTED
203f518: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203f51c: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
203f520: 88 12 c0 04 or %o3, %g4, %g4 <== NOT EXECUTED
203f524: 88 11 00 0c or %g4, %o4, %g4 <== NOT EXECUTED
203f528: 88 11 00 0d or %g4, %o5, %g4 <== NOT EXECUTED
203f52c: c8 20 a0 24 st %g4, [ %g2 + 0x24 ] <== NOT EXECUTED
203f530: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED
/*
* Extract the block and block count data from the inode into the targets
* byte order.
*/
map->inode = inode;
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
203f534: 80 a0 40 0a cmp %g1, %o2 <== NOT EXECUTED
203f538: 12 bf ff f3 bne 203f504 <rtems_rfs_block_map_open+0x60> <== NOT EXECUTED
203f53c: 84 00 a0 04 add %g2, 4, %g2 <== NOT EXECUTED
map->blocks[b] = rtems_rfs_inode_get_block (inode, b);
map->size.count = rtems_rfs_inode_get_block_count (inode);
203f540: d8 08 e0 0c ldub [ %g3 + 0xc ], %o4 <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
203f544: 82 00 e0 0c add %g3, 0xc, %g1 <== NOT EXECUTED
203f548: da 08 60 03 ldub [ %g1 + 3 ], %o5 <== NOT EXECUTED
203f54c: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
203f550: c8 08 60 01 ldub [ %g1 + 1 ], %g4 <== NOT EXECUTED
203f554: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
203f558: 83 2b 20 18 sll %o4, 0x18, %g1 <== NOT EXECUTED
203f55c: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203f560: 82 13 40 01 or %o5, %g1, %g1 <== NOT EXECUTED
203f564: 82 10 40 04 or %g1, %g4, %g1 <== NOT EXECUTED
203f568: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
203f56c: c2 26 a0 08 st %g1, [ %i2 + 8 ] <== NOT EXECUTED
map->size.offset = rtems_rfs_inode_get_block_offset (inode);
203f570: c4 08 e0 0b ldub [ %g3 + 0xb ], %g2 <== NOT EXECUTED
203f574: c2 08 e0 0a ldub [ %g3 + 0xa ], %g1 <== NOT EXECUTED
203f578: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
203f57c: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
203f580: c2 26 a0 0c st %g1, [ %i2 + 0xc ] <== NOT EXECUTED
* @return uint32_t The last map block number.
*/
static inline uint32_t
rtems_rfs_inode_get_last_map_block (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->last_map_block);
203f584: 82 00 e0 30 add %g3, 0x30, %g1 <== NOT EXECUTED
map->last_map_block = rtems_rfs_inode_get_last_map_block (inode);
203f588: d8 08 e0 30 ldub [ %g3 + 0x30 ], %o4 <== NOT EXECUTED
203f58c: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
203f590: da 08 60 03 ldub [ %g1 + 3 ], %o5 <== NOT EXECUTED
203f594: c8 08 60 01 ldub [ %g1 + 1 ], %g4 <== NOT EXECUTED
203f598: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
203f59c: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203f5a0: 83 2b 20 18 sll %o4, 0x18, %g1 <== NOT EXECUTED
203f5a4: 82 13 40 01 or %o5, %g1, %g1 <== NOT EXECUTED
203f5a8: 82 10 40 04 or %g1, %g4, %g1 <== NOT EXECUTED
203f5ac: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
203f5b0: c2 26 a0 1c st %g1, [ %i2 + 0x1c ] <== NOT EXECUTED
map->last_data_block = rtems_rfs_inode_get_last_data_block (inode);
203f5b4: c2 08 e0 34 ldub [ %g3 + 0x34 ], %g1 <== NOT EXECUTED
* @return uint32_t The last data block number.
*/
static inline uint32_t
rtems_rfs_inode_get_last_data_block (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->last_data_block);
203f5b8: 86 00 e0 34 add %g3, 0x34, %g3 <== NOT EXECUTED
203f5bc: c4 08 e0 02 ldub [ %g3 + 2 ], %g2 <== NOT EXECUTED
203f5c0: c8 08 e0 03 ldub [ %g3 + 3 ], %g4 <== NOT EXECUTED
203f5c4: c6 08 e0 01 ldub [ %g3 + 1 ], %g3 <== NOT EXECUTED
203f5c8: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
203f5cc: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203f5d0: 82 11 00 01 or %g4, %g1, %g1 <== NOT EXECUTED
203f5d4: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
203f5d8: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
203f5dc: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
203f5e0: c2 26 a0 20 st %g1, [ %i2 + 0x20 ] <== NOT EXECUTED
rc = rtems_rfs_inode_unload (fs, inode, false);
203f5e4: 40 00 0f 5d call 2043358 <rtems_rfs_inode_unload> <== NOT EXECUTED
203f5e8: 95 e8 20 00 restore %g0, 0, %o2 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
203f5ec: 92 06 a0 38 add %i2, 0x38, %o1 <== NOT EXECUTED
203f5f0: 40 00 00 82 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203f5f4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203f5f8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
handle->dirty = false;
203f5fc: c0 2e a0 38 clrb [ %i2 + 0x38 ] <== NOT EXECUTED
handle->bnum = 0;
203f600: c0 26 a0 3c clr [ %i2 + 0x3c ] <== NOT EXECUTED
handle->buffer = NULL;
203f604: c0 26 a0 40 clr [ %i2 + 0x40 ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
203f608: 92 06 a0 44 add %i2, 0x44, %o1 <== NOT EXECUTED
203f60c: 40 00 00 7b call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203f610: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
203f614: c0 26 a0 4c clr [ %i2 + 0x4c ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
203f618: c0 2e a0 44 clrb [ %i2 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
203f61c: c0 26 a0 48 clr [ %i2 + 0x48 ] <== NOT EXECUTED
return rc;
}
203f620: 81 c7 e0 08 ret <== NOT EXECUTED
203f624: 81 e8 00 00 restore <== NOT EXECUTED
0203e9a4 <rtems_rfs_block_map_seek>:
int
rtems_rfs_block_map_seek (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_pos_rel offset,
rtems_rfs_block_no* block)
{
203e9a4: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_rfs_block_pos bpos;
rtems_rfs_block_copy_bpos (&bpos, &map->bpos);
203e9a8: e0 06 60 14 ld [ %i1 + 0x14 ], %l0 <== NOT EXECUTED
203e9ac: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED
static inline void
rtems_rfs_block_add_pos (rtems_rfs_file_system* fs,
rtems_rfs_pos_rel offset,
rtems_rfs_block_pos* bpos)
{
rtems_rfs_block_get_bpos (fs,
203e9b0: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED
203e9b4: d0 06 60 10 ld [ %i1 + 0x10 ], %o0 <== NOT EXECUTED
203e9b8: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
203e9bc: e0 27 bf f8 st %l0, [ %fp + -8 ] <== NOT EXECUTED
203e9c0: 7f ff 10 73 call 2002b8c <.umul> <== NOT EXECUTED
203e9c4: d0 27 bf f4 st %o0, [ %fp + -12 ] <== NOT EXECUTED
203e9c8: 82 02 00 10 add %o0, %l0, %g1 <== NOT EXECUTED
203e9cc: b6 86 c0 01 addcc %i3, %g1, %i3 <== NOT EXECUTED
203e9d0: a0 07 bf f4 add %fp, -12, %l0 <== NOT EXECUTED
203e9d4: b4 46 a0 00 addx %i2, 0, %i2 <== NOT EXECUTED
203e9d8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203e9dc: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
203e9e0: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203e9e4: 7f ff ff 1a call 203e64c <rtems_rfs_block_get_bpos> <== NOT EXECUTED
203e9e8: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
int
rtems_rfs_block_map_seek (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
rtems_rfs_pos_rel offset,
rtems_rfs_block_no* block)
{
203e9ec: 96 10 00 1c mov %i4, %o3 <== NOT EXECUTED
rtems_rfs_block_get_pos (fs, bpos) + offset,
bpos);
bpos->block = 0;
203e9f0: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_rfs_block_pos bpos;
rtems_rfs_block_copy_bpos (&bpos, &map->bpos);
rtems_rfs_block_add_pos (fs, offset, &bpos);
return rtems_rfs_block_map_find (fs, map, &bpos, block);
203e9f4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203e9f8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203e9fc: 7f ff ff 7f call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
203ea00: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
}
203ea04: 81 c7 e0 08 ret <== NOT EXECUTED
203ea08: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0203eac0 <rtems_rfs_block_map_shrink>:
int
rtems_rfs_block_map_shrink (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
size_t blocks)
{
203eac0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_SHRINK))
printf ("rtems-rfs: block-map-shrink: entry: blocks=%zd count=%" PRIu32 "\n",
blocks, map->size.count);
if (map->size.count == 0)
203eac4: ec 06 60 08 ld [ %i1 + 8 ], %l6 <== NOT EXECUTED
int
rtems_rfs_block_map_shrink (rtems_rfs_file_system* fs,
rtems_rfs_block_map* map,
size_t blocks)
{
203eac8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_SHRINK))
printf ("rtems-rfs: block-map-shrink: entry: blocks=%zd count=%" PRIu32 "\n",
blocks, map->size.count);
if (map->size.count == 0)
203eacc: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED
203ead0: 02 80 00 8e be 203ed08 <rtems_rfs_block_map_shrink+0x248> <== NOT EXECUTED
203ead4: ba 10 00 16 mov %l6, %i5 <== NOT EXECUTED
return 0;
if (blocks > map->size.count)
203ead8: 80 a5 80 1a cmp %l6, %i2 <== NOT EXECUTED
203eadc: 2a 80 00 05 bcs,a 203eaf0 <rtems_rfs_block_map_shrink+0x30><== NOT EXECUTED
203eae0: b4 10 00 16 mov %l6, %i2 <== NOT EXECUTED
blocks = map->size.count;
while (blocks)
203eae4: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
203eae8: 22 80 00 7e be,a 203ece0 <rtems_rfs_block_map_shrink+0x220><== NOT EXECUTED
203eaec: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
{
/*
* Request the indirect block and then obtain the block number from the
* indirect block.
*/
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
203eaf0: a8 06 60 38 add %i1, 0x38, %l4 <== NOT EXECUTED
rtems_rfs_block_no doubly_singly;
doubly = singly / fs->blocks_per_block;
doubly_singly = singly % fs->blocks_per_block;
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
203eaf4: aa 06 60 44 add %i1, 0x44, %l5 <== NOT EXECUTED
if (rc > 0)
return rc;
map->size.count--;
map->size.offset = 0;
map->last_data_block = block_to_free;
map->dirty = true;
203eaf8: 10 80 00 15 b 203eb4c <rtems_rfs_block_map_shrink+0x8c> <== NOT EXECUTED
203eafc: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
{
/*
* We have less than RTEMS_RFS_INODE_BLOCKS so they are held in the
* inode.
*/
block_to_free = map->blocks[block];
203eb00: bb 2f 60 02 sll %i5, 2, %i5 <== NOT EXECUTED
203eb04: ba 06 40 1d add %i1, %i5, %i5 <== NOT EXECUTED
203eb08: e2 07 60 04 ld [ %i5 + 4 ], %l1 <== NOT EXECUTED
map->blocks[block] = 0;
203eb0c: c0 27 60 04 clr [ %i5 + 4 ] <== NOT EXECUTED
{
rc = EIO;
break;
}
}
rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);
203eb10: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203eb14: 92 10 20 00 clr %o1 <== NOT EXECUTED
203eb18: 40 00 10 65 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203eb1c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
203eb20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203eb24: 14 80 00 7a bg 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203eb28: b4 86 bf ff addcc %i2, -1, %i2 <== NOT EXECUTED
return rc;
map->size.count--;
203eb2c: ec 06 60 08 ld [ %i1 + 8 ], %l6 <== NOT EXECUTED
map->size.offset = 0;
map->last_data_block = block_to_free;
203eb30: e2 26 60 20 st %l1, [ %i1 + 0x20 ] <== NOT EXECUTED
}
}
rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);
if (rc > 0)
return rc;
map->size.count--;
203eb34: ba 05 bf ff add %l6, -1, %i5 <== NOT EXECUTED
map->size.offset = 0;
203eb38: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
}
}
rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);
if (rc > 0)
return rc;
map->size.count--;
203eb3c: fa 26 60 08 st %i5, [ %i1 + 8 ] <== NOT EXECUTED
map->size.offset = 0;
map->last_data_block = block_to_free;
map->dirty = true;
203eb40: e6 2e 40 00 stb %l3, [ %i1 ] <== NOT EXECUTED
return 0;
if (blocks > map->size.count)
blocks = map->size.count;
while (blocks)
203eb44: 02 80 00 60 be 203ecc4 <rtems_rfs_block_map_shrink+0x204> <== NOT EXECUTED
203eb48: ac 10 00 1d mov %i5, %l6 <== NOT EXECUTED
{
rtems_rfs_block_no block;
rtems_rfs_block_no block_to_free;
int rc;
block = map->size.count - 1;
203eb4c: b8 07 7f ff add %i5, -1, %i4 <== NOT EXECUTED
if (block < RTEMS_RFS_INODE_BLOCKS)
203eb50: 80 a7 20 04 cmp %i4, 4 <== NOT EXECUTED
203eb54: 28 bf ff eb bleu,a 203eb00 <rtems_rfs_block_map_shrink+0x40><== NOT EXECUTED
203eb58: ba 07 60 07 add %i5, 7, %i5 <== NOT EXECUTED
* table of block numbers.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = block % fs->blocks_per_block;
203eb5c: e2 04 20 30 ld [ %l0 + 0x30 ], %l1 <== NOT EXECUTED
203eb60: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
203eb64: 40 00 90 34 call 2062c34 <.urem> <== NOT EXECUTED
203eb68: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
singly = block / fs->blocks_per_block;
203eb6c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
* table of block numbers.
*/
rtems_rfs_block_no direct;
rtems_rfs_block_no singly;
direct = block % fs->blocks_per_block;
203eb70: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
singly = block / fs->blocks_per_block;
203eb74: 40 00 8f 84 call 2062984 <.udiv> <== NOT EXECUTED
203eb78: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
if (block < fs->block_map_singly_blocks)
203eb7c: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
203eb80: 80 a7 00 01 cmp %i4, %g1 <== NOT EXECUTED
203eb84: 0a 80 00 64 bcs 203ed14 <rtems_rfs_block_map_shrink+0x254><== NOT EXECUTED
203eb88: ae 10 00 08 mov %o0, %l7 <== NOT EXECUTED
rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
singly, direct);
if (rc)
return rc;
}
else if (block < fs->block_map_doubly_blocks)
203eb8c: c2 04 20 38 ld [ %l0 + 0x38 ], %g1 <== NOT EXECUTED
203eb90: 80 a7 00 01 cmp %i4, %g1 <== NOT EXECUTED
203eb94: 1a 80 00 4d bcc 203ecc8 <rtems_rfs_block_map_shrink+0x208><== NOT EXECUTED
203eb98: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
* value is still valid for doubly indirect tables.
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no doubly_singly;
doubly = singly / fs->blocks_per_block;
203eb9c: 40 00 8f 7a call 2062984 <.udiv> <== NOT EXECUTED
203eba0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
doubly_singly = singly % fs->blocks_per_block;
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
203eba4: 82 02 20 08 add %o0, 8, %g1 <== NOT EXECUTED
203eba8: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203ebac: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203ebb0: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
* value is still valid for doubly indirect tables.
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no doubly_singly;
doubly = singly / fs->blocks_per_block;
203ebb4: ba 10 00 08 mov %o0, %i5 <== NOT EXECUTED
doubly_singly = singly % fs->blocks_per_block;
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
203ebb8: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
203ebbc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ebc0: 40 00 03 57 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203ebc4: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
map->blocks[doubly], true);
if (rc > 0)
203ebc8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ebcc: 14 80 00 50 bg 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203ebd0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no doubly_singly;
doubly = singly / fs->blocks_per_block;
doubly_singly = singly % fs->blocks_per_block;
203ebd4: 40 00 90 18 call 2062c34 <.urem> <== NOT EXECUTED
203ebd8: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
map->blocks[doubly], true);
if (rc > 0)
return rc;
singly = rtems_rfs_block_get_number (&map->doubly_buffer,
203ebdc: c2 06 60 4c ld [ %i1 + 0x4c ], %g1 <== NOT EXECUTED
203ebe0: 85 2a 20 02 sll %o0, 2, %g2 <== NOT EXECUTED
203ebe4: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
203ebe8: 86 00 a0 02 add %g2, 2, %g3 <== NOT EXECUTED
203ebec: ee 08 40 02 ldub [ %g1 + %g2 ], %l7 <== NOT EXECUTED
203ebf0: c6 08 40 03 ldub [ %g1 + %g3 ], %g3 <== NOT EXECUTED
203ebf4: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
203ebf8: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
203ebfc: c2 08 60 03 ldub [ %g1 + 3 ], %g1 <== NOT EXECUTED
203ec00: af 2d e0 18 sll %l7, 0x18, %l7 <== NOT EXECUTED
203ec04: ae 10 40 17 or %g1, %l7, %l7 <== NOT EXECUTED
203ec08: 83 28 a0 10 sll %g2, 0x10, %g1 <== NOT EXECUTED
203ec0c: ae 15 c0 01 or %l7, %g1, %l7 <== NOT EXECUTED
203ec10: 83 28 e0 08 sll %g3, 8, %g1 <== NOT EXECUTED
*/
rtems_rfs_block_no doubly;
rtems_rfs_block_no doubly_singly;
doubly = singly / fs->blocks_per_block;
doubly_singly = singly % fs->blocks_per_block;
203ec14: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
map->blocks[doubly], true);
if (rc > 0)
return rc;
singly = rtems_rfs_block_get_number (&map->doubly_buffer,
203ec18: ae 15 c0 01 or %l7, %g1, %l7 <== NOT EXECUTED
doubly_singly);
/*
* Read the singly indirect table and get the block number.
*/
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
203ec1c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ec20: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
203ec24: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
203ec28: 40 00 03 3d call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203ec2c: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
singly, true);
if (rc > 0)
203ec30: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ec34: 14 80 00 36 bg 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203ec38: 85 2c a0 02 sll %l2, 2, %g2 <== NOT EXECUTED
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ec3c: c2 06 60 40 ld [ %i1 + 0x40 ], %g1 <== NOT EXECUTED
203ec40: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
203ec44: 86 00 a0 02 add %g2, 2, %g3 <== NOT EXECUTED
203ec48: e2 08 40 02 ldub [ %g1 + %g2 ], %l1 <== NOT EXECUTED
203ec4c: c6 08 40 03 ldub [ %g1 + %g3 ], %g3 <== NOT EXECUTED
203ec50: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
203ec54: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
203ec58: c2 08 60 03 ldub [ %g1 + 3 ], %g1 <== NOT EXECUTED
203ec5c: a3 2c 60 18 sll %l1, 0x18, %l1 <== NOT EXECUTED
203ec60: a2 10 40 11 or %g1, %l1, %l1 <== NOT EXECUTED
203ec64: 83 28 a0 10 sll %g2, 0x10, %g1 <== NOT EXECUTED
direct);
if (direct == 0)
203ec68: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
singly, true);
if (rc > 0)
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ec6c: a2 14 40 01 or %l1, %g1, %l1 <== NOT EXECUTED
203ec70: 83 28 e0 08 sll %g3, 8, %g1 <== NOT EXECUTED
direct);
if (direct == 0)
203ec74: 12 bf ff a7 bne 203eb10 <rtems_rfs_block_map_shrink+0x50> <== NOT EXECUTED
203ec78: a2 14 40 01 or %l1, %g1, %l1 <== NOT EXECUTED
{
rc = rtems_rfs_group_bitmap_free (fs, false, singly);
203ec7c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ec80: 92 10 20 00 clr %o1 <== NOT EXECUTED
203ec84: 40 00 10 0a call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
203ec88: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
if (rc > 0)
203ec8c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ec90: 14 80 00 1f bg 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203ec94: 96 10 00 1d mov %i5, %o3 <== NOT EXECUTED
return rc;
map->last_map_block = singly;
203ec98: ee 26 60 1c st %l7, [ %i1 + 0x1c ] <== NOT EXECUTED
rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->doubly_buffer,
203ec9c: 98 10 00 16 mov %l6, %o4 <== NOT EXECUTED
203eca0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203eca4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203eca8: 7f ff ff 59 call 203ea0c <rtems_rfs_block_map_indirect_shrink><== NOT EXECUTED
203ecac: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
doubly, doubly_singly);
if (rc)
203ecb0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ecb4: 22 bf ff 98 be,a 203eb14 <rtems_rfs_block_map_shrink+0x54><== NOT EXECUTED
203ecb8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
if (rtems_rfs_block_pos_past_end (&map->bpos, &map->size))
rtems_rfs_block_size_get_bpos (&map->size, &map->bpos);
return 0;
}
203ecbc: 81 c7 e0 08 ret <== NOT EXECUTED
203ecc0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
map->last_data_block = block_to_free;
map->dirty = true;
blocks--;
}
if (map->size.count == 0)
203ecc4: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
203ecc8: 32 80 00 06 bne,a 203ece0 <rtems_rfs_block_map_shrink+0x220><== NOT EXECUTED
203eccc: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
{
map->last_map_block = 0;
203ecd0: c0 26 60 1c clr [ %i1 + 0x1c ] <== NOT EXECUTED
map->last_data_block = 0;
203ecd4: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
203ecd8: ba 10 00 16 mov %l6, %i5 <== NOT EXECUTED
}
/*
* Keep the position inside the map.
*/
if (rtems_rfs_block_pos_past_end (&map->bpos, &map->size))
203ecdc: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
203ece0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203ece4: 12 80 00 31 bne 203eda8 <rtems_rfs_block_map_shrink+0x2e8><== NOT EXECUTED
203ece8: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
203ecec: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203ecf0: 28 80 00 31 bleu,a 203edb4 <rtems_rfs_block_map_shrink+0x2f4><== NOT EXECUTED
203ecf4: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
203ecf8: 84 07 7f ff add %i5, -1, %g2 <== NOT EXECUTED
203ecfc: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
203ed00: 22 80 00 38 be,a 203ede0 <rtems_rfs_block_map_shrink+0x320><== NOT EXECUTED
203ed04: c4 06 60 14 ld [ %i1 + 0x14 ], %g2 <== NOT EXECUTED
rtems_rfs_block_size_get_bpos (&map->size, &map->bpos);
203ed08: 90 10 20 00 clr %o0 <== NOT EXECUTED
return 0;
}
203ed0c: 81 c7 e0 08 ret <== NOT EXECUTED
203ed10: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
{
/*
* Request the indirect block and then obtain the block number from the
* indirect block.
*/
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
203ed14: 82 02 20 08 add %o0, 8, %g1 <== NOT EXECUTED
203ed18: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED
203ed1c: 82 06 40 01 add %i1, %g1, %g1 <== NOT EXECUTED
203ed20: d4 00 60 04 ld [ %g1 + 4 ], %o2 <== NOT EXECUTED
203ed24: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ed28: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
203ed2c: 40 00 02 fc call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203ed30: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
map->blocks[singly], true);
if (rc > 0)
203ed34: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ed38: 14 bf ff f5 bg 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203ed3c: 87 2c a0 02 sll %l2, 2, %g3 <== NOT EXECUTED
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ed40: c2 06 60 40 ld [ %i1 + 0x40 ], %g1 <== NOT EXECUTED
203ed44: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
direct);
rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
203ed48: 96 10 00 17 mov %l7, %o3 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
map->blocks[singly], true);
if (rc > 0)
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ed4c: 84 00 40 03 add %g1, %g3, %g2 <== NOT EXECUTED
direct);
rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
203ed50: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
map->blocks[singly], true);
if (rc > 0)
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ed54: ee 08 a0 03 ldub [ %g2 + 3 ], %l7 <== NOT EXECUTED
203ed58: a4 00 e0 02 add %g3, 2, %l2 <== NOT EXECUTED
203ed5c: e2 08 40 03 ldub [ %g1 + %g3 ], %l1 <== NOT EXECUTED
203ed60: ec 08 a0 01 ldub [ %g2 + 1 ], %l6 <== NOT EXECUTED
203ed64: e4 08 40 12 ldub [ %g1 + %l2 ], %l2 <== NOT EXECUTED
direct);
rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
203ed68: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ed6c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203ed70: 7f ff ff 27 call 203ea0c <rtems_rfs_block_map_indirect_shrink><== NOT EXECUTED
203ed74: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
singly, direct);
if (rc)
203ed78: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203ed7c: 12 bf ff e4 bne 203ed0c <rtems_rfs_block_map_shrink+0x24c><== NOT EXECUTED
203ed80: ae 0d e0 ff and %l7, 0xff, %l7 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
map->blocks[singly], true);
if (rc > 0)
return rc;
block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
203ed84: a3 2c 60 18 sll %l1, 0x18, %l1 <== NOT EXECUTED
203ed88: ac 0d a0 ff and %l6, 0xff, %l6 <== NOT EXECUTED
203ed8c: a2 15 c0 11 or %l7, %l1, %l1 <== NOT EXECUTED
203ed90: a4 0c a0 ff and %l2, 0xff, %l2 <== NOT EXECUTED
203ed94: ad 2d a0 10 sll %l6, 0x10, %l6 <== NOT EXECUTED
203ed98: a5 2c a0 08 sll %l2, 8, %l2 <== NOT EXECUTED
203ed9c: a2 14 40 16 or %l1, %l6, %l1 <== NOT EXECUTED
203eda0: 10 bf ff 5c b 203eb10 <rtems_rfs_block_map_shrink+0x50> <== NOT EXECUTED
203eda4: a2 14 40 12 or %l1, %l2, %l1 <== NOT EXECUTED
}
/*
* Keep the position inside the map.
*/
if (rtems_rfs_block_pos_past_end (&map->bpos, &map->size))
203eda8: 12 bf ff d2 bne 203ecf0 <rtems_rfs_block_map_shrink+0x230><== NOT EXECUTED
203edac: 80 a7 40 01 cmp %i5, %g1 <== NOT EXECUTED
203edb0: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
rtems_rfs_block_size_get_bpos (&map->size, &map->bpos);
203edb4: fa 26 60 10 st %i5, [ %i1 + 0x10 ] <== NOT EXECUTED
203edb8: c2 26 60 14 st %g1, [ %i1 + 0x14 ] <== NOT EXECUTED
203edbc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203edc0: 02 bf ff d2 be 203ed08 <rtems_rfs_block_map_shrink+0x248> <== NOT EXECUTED
203edc4: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
203edc8: ba 07 7f ff add %i5, -1, %i5 <== NOT EXECUTED
203edcc: 90 10 20 00 clr %o0 <== NOT EXECUTED
203edd0: fa 26 60 10 st %i5, [ %i1 + 0x10 ] <== NOT EXECUTED
return 0;
}
203edd4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
203edd8: 81 c7 e0 08 ret <== NOT EXECUTED
203eddc: 81 e8 00 00 restore <== NOT EXECUTED
}
/*
* Keep the position inside the map.
*/
if (rtems_rfs_block_pos_past_end (&map->bpos, &map->size))
203ede0: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
203ede4: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
203ede8: 38 bf ff f4 bgu,a 203edb8 <rtems_rfs_block_map_shrink+0x2f8><== NOT EXECUTED
203edec: fa 26 60 10 st %i5, [ %i1 + 0x10 ] <== NOT EXECUTED
rtems_rfs_block_size_get_bpos (&map->size, &map->bpos);
203edf0: 10 bf ff c7 b 203ed0c <rtems_rfs_block_map_shrink+0x24c> <== NOT EXECUTED
203edf4: 90 10 20 00 clr %o0 <== NOT EXECUTED
02049bf4 <rtems_rfs_buffer_bdbuf_release>:
}
int
rtems_rfs_buffer_bdbuf_release (rtems_rfs_buffer* buffer,
bool modified)
{
2049bf4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_RELEASE))
printf ("rtems-rfs: bdbuf-release: block=%" PRIuPTR " bdbuf=%" PRIu32 " %s\n",
((intptr_t) buffer->user),
buffer->block, modified ? "(modified)" : "");
if (modified)
2049bf8: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
2049bfc: 02 80 00 09 be 2049c20 <rtems_rfs_buffer_bdbuf_release+0x2c><== NOT EXECUTED
2049c00: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
sc = rtems_bdbuf_release_modified (buffer);
2049c04: 7f fe ec 33 call 2004cd0 <rtems_bdbuf_release_modified> <== NOT EXECUTED
2049c08: 01 00 00 00 nop <== NOT EXECUTED
else
sc = rtems_bdbuf_release (buffer);
if (sc != RTEMS_SUCCESSFUL)
2049c0c: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2049c10: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
2049c14: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
#endif
rc = EIO;
}
return rc;
}
2049c18: 81 c7 e0 08 ret <== NOT EXECUTED
2049c1c: 91 ee 20 05 restore %i0, 5, %o0 <== NOT EXECUTED
buffer->block, modified ? "(modified)" : "");
if (modified)
sc = rtems_bdbuf_release_modified (buffer);
else
sc = rtems_bdbuf_release (buffer);
2049c20: 7f fe ec 4f call 2004d5c <rtems_bdbuf_release> <== NOT EXECUTED
2049c24: 01 00 00 00 nop <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2049c28: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2049c2c: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
2049c30: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
#endif
rc = EIO;
}
return rc;
}
2049c34: 81 c7 e0 08 ret <== NOT EXECUTED
2049c38: 91 ee 20 05 restore %i0, 5, %o0 <== NOT EXECUTED
02049c3c <rtems_rfs_buffer_bdbuf_request>:
int
rtems_rfs_buffer_bdbuf_request (rtems_rfs_file_system* fs,
rtems_rfs_buffer_block block,
bool read,
rtems_rfs_buffer** buffer)
{
2049c3c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc;
int rc = 0;
if (read)
2049c40: 80 8e a0 ff btst 0xff, %i2 <== NOT EXECUTED
int
rtems_rfs_buffer_bdbuf_request (rtems_rfs_file_system* fs,
rtems_rfs_buffer_block block,
bool read,
rtems_rfs_buffer** buffer)
{
2049c44: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
rtems_status_code sc;
int rc = 0;
if (read)
2049c48: 02 80 00 0a be 2049c70 <rtems_rfs_buffer_bdbuf_request+0x34><== NOT EXECUTED
2049c4c: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
sc = rtems_bdbuf_read (rtems_rfs_fs_device (fs), block, buffer);
2049c50: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2049c54: 7f fe f1 1d call 20060c8 <rtems_bdbuf_read> <== NOT EXECUTED
2049c58: d0 18 40 00 ldd [ %g1 ], %o0 <== NOT EXECUTED
else
sc = rtems_bdbuf_get (rtems_rfs_fs_device (fs), block, buffer);
if (sc != RTEMS_SUCCESSFUL)
2049c5c: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2049c60: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
2049c64: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
#endif
rc = EIO;
}
return rc;
}
2049c68: 81 c7 e0 08 ret <== NOT EXECUTED
2049c6c: 91 ee 20 05 restore %i0, 5, %o0 <== NOT EXECUTED
int rc = 0;
if (read)
sc = rtems_bdbuf_read (rtems_rfs_fs_device (fs), block, buffer);
else
sc = rtems_bdbuf_get (rtems_rfs_fs_device (fs), block, buffer);
2049c70: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2049c74: 7f fe f0 e0 call 2005ff4 <rtems_bdbuf_get> <== NOT EXECUTED
2049c78: d0 18 40 00 ldd [ %g1 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2049c7c: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2049c80: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
2049c84: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
#endif
rc = EIO;
}
return rc;
}
2049c88: 81 c7 e0 08 ret <== NOT EXECUTED
2049c8c: 91 ee 20 05 restore %i0, 5, %o0 <== NOT EXECUTED
0203f770 <rtems_rfs_buffer_close>:
return 0;
}
int
rtems_rfs_buffer_close (rtems_rfs_file_system* fs)
{
203f770: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* Change the block size to the media device size. It will release and sync
* all buffers.
*/
rc = rtems_rfs_buffer_setblksize (fs, rtems_rfs_fs_media_block_size (fs));
203f774: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
203f778: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203f77c: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
203f780: 7f ff ff e6 call 203f718 <rtems_rfs_buffer_setblksize> <== NOT EXECUTED
203f784: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
203f788: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CLOSE))
printf ("rtems-rfs: buffer-close: set media block size failed: %d: %s\n",
rc, strerror (rc));
#if RTEMS_RFS_USE_LIBBLOCK
rtems_disk_release (fs->disk);
203f78c: 7f ff 1f 2c call 200743c <rtems_disk_release> <== NOT EXECUTED
203f790: d0 04 20 0c ld [ %l0 + 0xc ], %o0 <== NOT EXECUTED
rc, strerror (rc));
}
#endif
return rc;
}
203f794: 81 c7 e0 08 ret <== NOT EXECUTED
203f798: 81 e8 00 00 restore <== NOT EXECUTED
0203fb58 <rtems_rfs_buffer_handle_close>:
* @return int The error number (errno). No error if 0.
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
203fb58: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_buffer_handle_release (fs, handle);
203fb5c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203fb60: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203fb64: 7f ff ff 25 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203fb68: b0 10 20 00 clr %i0 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
203fb6c: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
203fb70: c0 2e 40 00 clrb [ %i1 ] <== NOT EXECUTED
handle->bnum = 0;
203fb74: c0 26 60 04 clr [ %i1 + 4 ] <== NOT EXECUTED
handle->buffer = NULL;
return 0;
}
203fb78: 81 c7 e0 08 ret <== NOT EXECUTED
203fb7c: 81 e8 00 00 restore <== NOT EXECUTED
0203f7f8 <rtems_rfs_buffer_handle_release>:
}
int
rtems_rfs_buffer_handle_release (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
203f7f8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc = 0;
if (rtems_rfs_buffer_handle_has_block (handle))
203f7fc: d0 06 60 08 ld [ %i1 + 8 ], %o0 <== NOT EXECUTED
203f800: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f804: 02 80 00 0c be 203f834 <rtems_rfs_buffer_handle_release+0x3c><== NOT EXECUTED
203f808: a0 10 20 00 clr %l0 <== NOT EXECUTED
rtems_rfs_buffer_bnum (handle),
rtems_rfs_buffer_dirty (handle) ? "(dirty)" : "",
rtems_rfs_buffer_refs (handle),
rtems_rfs_buffer_refs (handle) == 0 ? "BAD REF COUNT" : "");
if (rtems_rfs_buffer_refs (handle) > 0)
203f80c: e2 02 20 38 ld [ %o0 + 0x38 ], %l1 <== NOT EXECUTED
203f810: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203f814: 04 80 00 05 ble 203f828 <rtems_rfs_buffer_handle_release+0x30><== NOT EXECUTED
203f818: 01 00 00 00 nop <== NOT EXECUTED
rtems_rfs_buffer_refs_down (handle);
203f81c: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
203f820: e2 22 20 38 st %l1, [ %o0 + 0x38 ] <== NOT EXECUTED
if (rtems_rfs_buffer_refs (handle) == 0)
203f824: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203f828: 02 80 00 05 be 203f83c <rtems_rfs_buffer_handle_release+0x44><== NOT EXECUTED
203f82c: a0 10 20 00 clr %l0 <== NOT EXECUTED
rtems_chain_append (&fs->release, rtems_rfs_buffer_link (handle));
fs->release_count++;
}
}
}
handle->buffer = NULL;
203f830: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
}
return rc;
}
203f834: 81 c7 e0 08 ret <== NOT EXECUTED
203f838: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
203f83c: 7f ff 3a e0 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
203f840: 01 00 00 00 nop <== NOT EXECUTED
rtems_rfs_buffer_refs_down (handle);
if (rtems_rfs_buffer_refs (handle) == 0)
{
rtems_chain_extract (rtems_rfs_buffer_link (handle));
fs->buffers_count--;
203f844: c4 06 20 4c ld [ %i0 + 0x4c ], %g2 <== NOT EXECUTED
if (rtems_rfs_fs_no_local_cache (fs))
203f848: c2 06 00 00 ld [ %i0 ], %g1 <== NOT EXECUTED
rtems_rfs_buffer_refs_down (handle);
if (rtems_rfs_buffer_refs (handle) == 0)
{
rtems_chain_extract (rtems_rfs_buffer_link (handle));
fs->buffers_count--;
203f84c: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
if (rtems_rfs_fs_no_local_cache (fs))
203f850: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
203f854: 12 80 00 20 bne 203f8d4 <rtems_rfs_buffer_handle_release+0xdc><== NOT EXECUTED
203f858: c4 26 20 4c st %g2, [ %i0 + 0x4c ] <== NOT EXECUTED
* head.
*
* This code stops a large series of transactions causing all the
* buffers in the cache being held in queues of this file system.
*/
if ((fs->release_count +
203f85c: c4 06 20 5c ld [ %i0 + 0x5c ], %g2 <== NOT EXECUTED
203f860: c2 06 20 6c ld [ %i0 + 0x6c ], %g1 <== NOT EXECUTED
fs->release_modified_count) >= fs->max_held_buffers)
203f864: c6 06 20 3c ld [ %i0 + 0x3c ], %g3 <== NOT EXECUTED
* head.
*
* This code stops a large series of transactions causing all the
* buffers in the cache being held in queues of this file system.
*/
if ((fs->release_count +
203f868: 88 00 40 02 add %g1, %g2, %g4 <== NOT EXECUTED
fs->release_modified_count) >= fs->max_held_buffers)
203f86c: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED
203f870: 0a 80 00 0f bcs 203f8ac <rtems_rfs_buffer_handle_release+0xb4><== NOT EXECUTED
203f874: a0 10 20 00 clr %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_RELEASE))
printf ("rtems-rfs: buffer-release: local cache overflow:"
" %" PRIu32 "\n", fs->release_count + fs->release_modified_count);
if (fs->release_count > fs->release_modified_count)
203f878: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
203f87c: 18 80 00 22 bgu 203f904 <rtems_rfs_buffer_handle_release+0x10c><== NOT EXECUTED
203f880: 01 00 00 00 nop <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
203f884: 7f ff 3a d8 call 200e3e4 <_Chain_Get> <== NOT EXECUTED
203f888: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
}
else
{
buffer =
(rtems_rfs_buffer*) rtems_chain_get (&fs->release_modified);
fs->release_modified_count--;
203f88c: c2 06 20 6c ld [ %i0 + 0x6c ], %g1 <== NOT EXECUTED
203f890: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
203f894: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
203f898: c2 26 20 6c st %g1, [ %i0 + 0x6c ] <== NOT EXECUTED
modified = true;
}
buffer->user = (void*) 0;
203f89c: c0 22 20 3c clr [ %o0 + 0x3c ] <== NOT EXECUTED
rc = rtems_rfs_buffer_io_release (buffer, modified);
203f8a0: 40 00 28 d5 call 2049bf4 <rtems_rfs_buffer_bdbuf_release> <== NOT EXECUTED
203f8a4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203f8a8: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
}
if (rtems_rfs_buffer_dirty (handle))
203f8ac: c2 0e 40 00 ldub [ %i1 ], %g1 <== NOT EXECUTED
203f8b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203f8b4: 02 80 00 0e be 203f8ec <rtems_rfs_buffer_handle_release+0xf4><== NOT EXECUTED
203f8b8: d2 06 60 08 ld [ %i1 + 8 ], %o1 <== 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 );
203f8bc: 7f ff 3a b4 call 200e38c <_Chain_Append> <== NOT EXECUTED
203f8c0: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
{
rtems_chain_append (&fs->release_modified,
rtems_rfs_buffer_link (handle));
fs->release_modified_count++;
203f8c4: c2 06 20 6c ld [ %i0 + 0x6c ], %g1 <== NOT EXECUTED
203f8c8: 82 00 60 01 inc %g1 <== NOT EXECUTED
203f8cc: 10 bf ff d9 b 203f830 <rtems_rfs_buffer_handle_release+0x38><== NOT EXECUTED
203f8d0: c2 26 20 6c st %g1, [ %i0 + 0x6c ] <== NOT EXECUTED
rtems_chain_extract (rtems_rfs_buffer_link (handle));
fs->buffers_count--;
if (rtems_rfs_fs_no_local_cache (fs))
{
handle->buffer->user = (void*) 0;
203f8d4: d0 06 60 08 ld [ %i1 + 8 ], %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_io_release (handle->buffer,
203f8d8: d2 0e 40 00 ldub [ %i1 ], %o1 <== NOT EXECUTED
203f8dc: 40 00 28 c6 call 2049bf4 <rtems_rfs_buffer_bdbuf_release> <== NOT EXECUTED
203f8e0: c0 22 20 3c clr [ %o0 + 0x3c ] <== NOT EXECUTED
203f8e4: 10 bf ff d3 b 203f830 <rtems_rfs_buffer_handle_release+0x38><== NOT EXECUTED
203f8e8: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
203f8ec: 7f ff 3a a8 call 200e38c <_Chain_Append> <== NOT EXECUTED
203f8f0: 90 06 20 50 add %i0, 0x50, %o0 <== NOT EXECUTED
fs->release_modified_count++;
}
else
{
rtems_chain_append (&fs->release, rtems_rfs_buffer_link (handle));
fs->release_count++;
203f8f4: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 <== NOT EXECUTED
203f8f8: 82 00 60 01 inc %g1 <== NOT EXECUTED
203f8fc: 10 bf ff cd b 203f830 <rtems_rfs_buffer_handle_release+0x38><== NOT EXECUTED
203f900: c2 26 20 5c st %g1, [ %i0 + 0x5c ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
203f904: 7f ff 3a b8 call 200e3e4 <_Chain_Get> <== NOT EXECUTED
203f908: 90 06 20 50 add %i0, 0x50, %o0 <== NOT EXECUTED
" %" PRIu32 "\n", fs->release_count + fs->release_modified_count);
if (fs->release_count > fs->release_modified_count)
{
buffer = (rtems_rfs_buffer*) rtems_chain_get (&fs->release);
fs->release_count--;
203f90c: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 <== NOT EXECUTED
203f910: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
203f914: 10 bf ff e2 b 203f89c <rtems_rfs_buffer_handle_release+0xa4><== NOT EXECUTED
203f918: c2 26 20 5c st %g1, [ %i0 + 0x5c ] <== NOT EXECUTED
0203f91c <rtems_rfs_buffer_handle_request>:
int
rtems_rfs_buffer_handle_request (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle,
rtems_rfs_buffer_block block,
bool read)
{
203f91c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* If the handle has a buffer release it. This allows a handle to be reused
* without needing to close then open it again.
*/
if (rtems_rfs_buffer_handle_has_block (handle))
203f920: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
203f924: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
203f928: 02 80 00 12 be 203f970 <rtems_rfs_buffer_handle_request+0x54><== NOT EXECUTED
203f92c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{
/*
* Treat block 0 as special to handle the loading of the super block.
*/
if (block && (rtems_rfs_buffer_bnum (handle) == block))
203f930: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
203f934: 02 80 00 07 be 203f950 <rtems_rfs_buffer_handle_request+0x34><== NOT EXECUTED
203f938: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f93c: c2 06 60 04 ld [ %i1 + 4 ], %g1 <== NOT EXECUTED
203f940: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203f944: 02 80 00 08 be 203f964 <rtems_rfs_buffer_handle_request+0x48><== NOT EXECUTED
203f948: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))
printf ("rtems-rfs: buffer-request: handle has buffer: %" PRIu32 "\n",
rtems_rfs_buffer_bnum (handle));
rc = rtems_rfs_buffer_handle_release (fs, handle);
203f94c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203f950: 7f ff ff aa call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
203f954: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (rc > 0)
203f958: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203f95c: 24 80 00 04 ble,a 203f96c <rtems_rfs_buffer_handle_request+0x50><== NOT EXECUTED
203f960: c0 2e 40 00 clrb [ %i1 ] <== NOT EXECUTED
printf ("rtems-rfs: buffer-request: block=%" PRIu32 " bdbuf-%s=%" PRIu32 " refs=%d\n",
block, read ? "read" : "get", handle->buffer->block,
handle->buffer->references);
return 0;
}
203f964: 81 c7 e0 08 ret <== NOT EXECUTED
203f968: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_release (fs, handle);
if (rc > 0)
return rc;
handle->dirty = false;
handle->bnum = 0;
203f96c: c0 26 60 04 clr [ %i1 + 4 ] <== NOT EXECUTED
* currently attached to a handle. If it is share the access. A buffer could
* be shared where different parts of the block have separate functions. An
* example is an inode block and the file system needs to handle 2 inodes in
* the same block at the same time.
*/
if (fs->buffers_count)
203f970: c6 04 20 4c ld [ %l0 + 0x4c ], %g3 <== NOT EXECUTED
203f974: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
203f978: 32 80 00 3c bne,a 203fa68 <rtems_rfs_buffer_handle_request+0x14c><== NOT EXECUTED
203f97c: e4 04 20 48 ld [ %l0 + 0x48 ], %l2 <== NOT EXECUTED
203f980: e2 06 60 08 ld [ %i1 + 8 ], %l1 <== NOT EXECUTED
/*
* If the buffer has not been found check the local cache of released
* buffers. There are release and released modified lists to preserve the
* state.
*/
if (!rtems_rfs_fs_no_local_cache (fs) &&
203f984: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
203f988: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
203f98c: 12 80 00 33 bne 203fa58 <rtems_rfs_buffer_handle_request+0x13c><== NOT EXECUTED
203f990: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203f994: 22 80 00 11 be,a 203f9d8 <rtems_rfs_buffer_handle_request+0xbc><== NOT EXECUTED
203f998: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
fs->release_modified_count)
{
handle->buffer = rtems_rfs_scan_chain (&fs->release_modified,
203f99c: d2 06 60 08 ld [ %i1 + 8 ], %o1 <== NOT EXECUTED
203f9a0: a2 10 00 09 mov %o1, %l1 <== NOT EXECUTED
}
/*
* Increase the reference count of the buffer.
*/
rtems_rfs_buffer_refs_up (handle);
203f9a4: c2 04 60 38 ld [ %l1 + 0x38 ], %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 );
203f9a8: 90 04 20 40 add %l0, 0x40, %o0 <== NOT EXECUTED
203f9ac: 82 00 60 01 inc %g1 <== NOT EXECUTED
203f9b0: 7f ff 3a 77 call 200e38c <_Chain_Append> <== NOT EXECUTED
203f9b4: c2 24 60 38 st %g1, [ %l1 + 0x38 ] <== NOT EXECUTED
rtems_chain_append (&fs->buffers, rtems_rfs_buffer_link (handle));
fs->buffers_count++;
203f9b8: c4 04 20 4c ld [ %l0 + 0x4c ], %g2 <== NOT EXECUTED
handle->buffer->user = (void*) ((intptr_t) block);
203f9bc: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
/*
* Increase the reference count of the buffer.
*/
rtems_rfs_buffer_refs_up (handle);
rtems_chain_append (&fs->buffers, rtems_rfs_buffer_link (handle));
fs->buffers_count++;
203f9c0: 84 00 a0 01 inc %g2 <== NOT EXECUTED
203f9c4: c4 24 20 4c st %g2, [ %l0 + 0x4c ] <== NOT EXECUTED
handle->buffer->user = (void*) ((intptr_t) block);
handle->bnum = block;
203f9c8: f4 26 60 04 st %i2, [ %i1 + 4 ] <== NOT EXECUTED
*/
rtems_rfs_buffer_refs_up (handle);
rtems_chain_append (&fs->buffers, rtems_rfs_buffer_link (handle));
fs->buffers_count++;
handle->buffer->user = (void*) ((intptr_t) block);
203f9cc: f4 20 60 3c st %i2, [ %g1 + 0x3c ] <== NOT EXECUTED
printf ("rtems-rfs: buffer-request: block=%" PRIu32 " bdbuf-%s=%" PRIu32 " refs=%d\n",
block, read ? "read" : "get", handle->buffer->block,
handle->buffer->references);
return 0;
}
203f9d0: 81 c7 e0 08 ret <== NOT EXECUTED
203f9d4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
!rtems_rfs_buffer_handle_has_block (handle))
{
/*
* Check the local cache of released buffers.
*/
if (fs->release_count)
203f9d8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
203f9dc: 32 80 00 47 bne,a 203faf8 <rtems_rfs_buffer_handle_request+0x1dc><== NOT EXECUTED
203f9e0: e2 04 20 58 ld [ %l0 + 0x58 ], %l1 <== NOT EXECUTED
handle->buffer = rtems_rfs_scan_chain (&fs->release,
&fs->release_count,
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
fs->release_modified_count)
203f9e4: c6 04 20 6c ld [ %l0 + 0x6c ], %g3 <== NOT EXECUTED
if (fs->release_count)
handle->buffer = rtems_rfs_scan_chain (&fs->release,
&fs->release_count,
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
203f9e8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
203f9ec: 02 80 00 37 be 203fac8 <rtems_rfs_buffer_handle_request+0x1ac><== NOT EXECUTED
203f9f0: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Last(
Chain_Control *the_chain
)
{
return the_chain->last;
203f9f4: e4 04 20 68 ld [ %l0 + 0x68 ], %l2 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head(
Chain_Control *the_chain
)
{
return (Chain_Node *) the_chain;
203f9f8: 84 04 20 60 add %l0, 0x60, %g2 <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203f9fc: 80 a4 80 02 cmp %l2, %g2 <== NOT EXECUTED
203fa00: 32 80 00 09 bne,a 203fa24 <rtems_rfs_buffer_handle_request+0x108><== NOT EXECUTED
203fa04: c2 04 a0 3c ld [ %l2 + 0x3c ], %g1 <== NOT EXECUTED
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
fs->release_modified_count)
{
handle->buffer = rtems_rfs_scan_chain (&fs->release_modified,
203fa08: 10 80 00 30 b 203fac8 <rtems_rfs_buffer_handle_request+0x1ac><== NOT EXECUTED
203fa0c: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Previous(
Chain_Node *the_node
)
{
return the_node->previous;
203fa10: e4 04 a0 04 ld [ %l2 + 4 ], %l2 <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203fa14: 80 a0 80 12 cmp %g2, %l2 <== NOT EXECUTED
203fa18: 22 80 00 2b be,a 203fac4 <rtems_rfs_buffer_handle_request+0x1a8><== NOT EXECUTED
203fa1c: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
buffer = (rtems_rfs_buffer*) node;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("%" PRIuPTR " ", ((intptr_t) buffer->user));
if (((rtems_rfs_buffer_block) ((intptr_t)(buffer->user))) == block)
203fa20: c2 04 a0 3c ld [ %l2 + 0x3c ], %g1 <== NOT EXECUTED
203fa24: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203fa28: 12 bf ff fa bne 203fa10 <rtems_rfs_buffer_handle_request+0xf4><== NOT EXECUTED
203fa2c: a2 10 00 12 mov %l2, %l1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf (": found block=%" PRIuPTR "\n",
((intptr_t)(buffer->user)));
(*count)--;
203fa30: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
203fa34: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
203fa38: 7f ff 3a 61 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
203fa3c: c6 24 20 6c st %g3, [ %l0 + 0x6c ] <== NOT EXECUTED
block);
/*
* If we found a buffer retain the dirty buffer state.
*/
if (rtems_rfs_buffer_handle_has_block (handle))
rtems_rfs_buffer_mark_dirty (handle);
203fa40: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
fs->release_modified_count)
{
handle->buffer = rtems_rfs_scan_chain (&fs->release_modified,
203fa44: e4 26 60 08 st %l2, [ %i1 + 8 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(
Chain_Node *node
)
{
node->next = node->previous = NULL;
203fa48: c0 24 a0 04 clr [ %l2 + 4 ] <== NOT EXECUTED
203fa4c: c0 24 80 00 clr [ %l2 ] <== NOT EXECUTED
block);
/*
* If we found a buffer retain the dirty buffer state.
*/
if (rtems_rfs_buffer_handle_has_block (handle))
rtems_rfs_buffer_mark_dirty (handle);
203fa50: c2 2e 40 00 stb %g1, [ %i1 ] <== NOT EXECUTED
}
/*
* If not located we request the buffer from the I/O layer.
*/
if (!rtems_rfs_buffer_handle_has_block (handle))
203fa54: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203fa58: 22 80 00 1c be,a 203fac8 <rtems_rfs_buffer_handle_request+0x1ac><== NOT EXECUTED
203fa5c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203fa60: 10 bf ff d1 b 203f9a4 <rtems_rfs_buffer_handle_request+0x88><== NOT EXECUTED
203fa64: d2 06 60 08 ld [ %i1 + 8 ], %o1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head(
Chain_Control *the_chain
)
{
return (Chain_Node *) the_chain;
203fa68: 84 04 20 40 add %l0, 0x40, %g2 <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203fa6c: 80 a4 80 02 cmp %l2, %g2 <== NOT EXECUTED
203fa70: 32 80 00 0a bne,a 203fa98 <rtems_rfs_buffer_handle_request+0x17c><== NOT EXECUTED
203fa74: c2 04 a0 3c ld [ %l2 + 0x3c ], %g1 <== NOT EXECUTED
203fa78: a2 10 20 00 clr %l1 <== NOT EXECUTED
* Check the active buffer list for shared buffers.
*/
handle->buffer = rtems_rfs_scan_chain (&fs->buffers,
&fs->buffers_count,
block);
if (rtems_rfs_buffer_handle_has_block (handle) &&
203fa7c: 10 bf ff c2 b 203f984 <rtems_rfs_buffer_handle_request+0x68><== NOT EXECUTED
203fa80: e2 26 60 08 st %l1, [ %i1 + 8 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Previous(
Chain_Node *the_node
)
{
return the_node->previous;
203fa84: e4 04 a0 04 ld [ %l2 + 4 ], %l2 <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203fa88: 80 a4 80 02 cmp %l2, %g2 <== NOT EXECUTED
203fa8c: 02 bf ff fc be 203fa7c <rtems_rfs_buffer_handle_request+0x160><== NOT EXECUTED
203fa90: a2 10 20 00 clr %l1 <== NOT EXECUTED
buffer = (rtems_rfs_buffer*) node;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("%" PRIuPTR " ", ((intptr_t) buffer->user));
if (((rtems_rfs_buffer_block) ((intptr_t)(buffer->user))) == block)
203fa94: c2 04 a0 3c ld [ %l2 + 0x3c ], %g1 <== NOT EXECUTED
203fa98: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203fa9c: 12 bf ff fa bne 203fa84 <rtems_rfs_buffer_handle_request+0x168><== NOT EXECUTED
203faa0: a2 10 00 12 mov %l2, %l1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf (": found block=%" PRIuPTR "\n",
((intptr_t)(buffer->user)));
(*count)--;
203faa4: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
203faa8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
203faac: 7f ff 3a 44 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
203fab0: c6 24 20 4c st %g3, [ %l0 + 0x4c ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(
Chain_Node *node
)
{
node->next = node->previous = NULL;
203fab4: c0 24 80 00 clr [ %l2 ] <== NOT EXECUTED
203fab8: c0 24 a0 04 clr [ %l2 + 4 ] <== NOT EXECUTED
if (fs->buffers_count)
{
/*
* Check the active buffer list for shared buffers.
*/
handle->buffer = rtems_rfs_scan_chain (&fs->buffers,
203fabc: 10 bf ff b2 b 203f984 <rtems_rfs_buffer_handle_request+0x68><== NOT EXECUTED
203fac0: e2 26 60 08 st %l1, [ %i1 + 8 ] <== NOT EXECUTED
/*
* If not located we request the buffer from the I/O layer.
*/
if (!rtems_rfs_buffer_handle_has_block (handle))
{
rc = rtems_rfs_buffer_io_request (fs, block, read, &handle->buffer);
203fac4: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203fac8: 94 0e e0 ff and %i3, 0xff, %o2 <== NOT EXECUTED
203facc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203fad0: 40 00 28 5b call 2049c3c <rtems_rfs_buffer_bdbuf_request> <== NOT EXECUTED
203fad4: 96 06 60 08 add %i1, 8, %o3 <== NOT EXECUTED
rtems_chain_set_off_chain (rtems_rfs_buffer_link(handle));
203fad8: d2 06 60 08 ld [ %i1 + 8 ], %o1 <== NOT EXECUTED
/*
* If not located we request the buffer from the I/O layer.
*/
if (!rtems_rfs_buffer_handle_has_block (handle))
{
rc = rtems_rfs_buffer_io_request (fs, block, read, &handle->buffer);
203fadc: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
203fae0: c0 22 60 04 clr [ %o1 + 4 ] <== NOT EXECUTED
rtems_chain_set_off_chain (rtems_rfs_buffer_link(handle));
if (rc > 0)
203fae4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203fae8: 14 bf ff 9f bg 203f964 <rtems_rfs_buffer_handle_request+0x48><== NOT EXECUTED
203faec: c0 22 40 00 clr [ %o1 ] <== NOT EXECUTED
203faf0: 10 bf ff ad b 203f9a4 <rtems_rfs_buffer_handle_request+0x88><== NOT EXECUTED
203faf4: a2 10 00 09 mov %o1, %l1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head(
Chain_Control *the_chain
)
{
return (Chain_Node *) the_chain;
203faf8: 84 04 20 50 add %l0, 0x50, %g2 <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203fafc: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED
203fb00: 32 80 00 08 bne,a 203fb20 <rtems_rfs_buffer_handle_request+0x204><== NOT EXECUTED
203fb04: c2 04 60 3c ld [ %l1 + 0x3c ], %g1 <== NOT EXECUTED
{
/*
* Check the local cache of released buffers.
*/
if (fs->release_count)
handle->buffer = rtems_rfs_scan_chain (&fs->release,
203fb08: 10 bf ff b7 b 203f9e4 <rtems_rfs_buffer_handle_request+0xc8><== NOT EXECUTED
203fb0c: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
node = rtems_chain_last (chain);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
while (!rtems_chain_is_head (chain, node))
203fb10: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED
203fb14: 22 bf ff b4 be,a 203f9e4 <rtems_rfs_buffer_handle_request+0xc8><== NOT EXECUTED
203fb18: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
buffer = (rtems_rfs_buffer*) node;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("%" PRIuPTR " ", ((intptr_t) buffer->user));
if (((rtems_rfs_buffer_block) ((intptr_t)(buffer->user))) == block)
203fb1c: c2 04 60 3c ld [ %l1 + 0x3c ], %g1 <== NOT EXECUTED
203fb20: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED
203fb24: 32 bf ff fb bne,a 203fb10 <rtems_rfs_buffer_handle_request+0x1f4><== NOT EXECUTED
203fb28: e2 04 60 04 ld [ %l1 + 4 ], %l1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf (": found block=%" PRIuPTR "\n",
((intptr_t)(buffer->user)));
(*count)--;
203fb2c: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
203fb30: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
203fb34: 7f ff 3a 22 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
203fb38: c6 24 20 5c st %g3, [ %l0 + 0x5c ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(
Chain_Node *node
)
{
node->next = node->previous = NULL;
203fb3c: c0 24 60 04 clr [ %l1 + 4 ] <== NOT EXECUTED
203fb40: c0 24 40 00 clr [ %l1 ] <== NOT EXECUTED
if (fs->release_count)
handle->buffer = rtems_rfs_scan_chain (&fs->release,
&fs->release_count,
block);
if (!rtems_rfs_buffer_handle_has_block (handle) &&
203fb44: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
203fb48: 12 bf ff 95 bne 203f99c <rtems_rfs_buffer_handle_request+0x80><== NOT EXECUTED
203fb4c: e2 26 60 08 st %l1, [ %i1 + 8 ] <== NOT EXECUTED
fs->release_modified_count)
203fb50: 10 bf ff a6 b 203f9e8 <rtems_rfs_buffer_handle_request+0xcc><== NOT EXECUTED
203fb54: c6 04 20 6c ld [ %l0 + 0x6c ], %g3 <== NOT EXECUTED
0203f79c <rtems_rfs_buffer_open>:
return rc;
}
int
rtems_rfs_buffer_open (const char* name, rtems_rfs_file_system* fs)
{
203f79c: 9d e3 bf 58 save %sp, -168, %sp <== NOT EXECUTED
struct stat st;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))
printf ("rtems-rfs: buffer-open: opening: %s\n", name);
if (stat (name, &st) < 0)
203f7a0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
203f7a4: 92 07 bf b8 add %fp, -72, %o1 <== NOT EXECUTED
203f7a8: 7f ff 2a fe call 200a3a0 <stat> <== NOT EXECUTED
203f7ac: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
203f7b0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f7b4: 06 80 00 0f bl 203f7f0 <rtems_rfs_buffer_open+0x54> <== NOT EXECUTED
203f7b8: c4 07 bf c4 ld [ %fp + -60 ], %g2 <== NOT EXECUTED
#if RTEMS_RFS_USE_LIBBLOCK
/*
* Is the device a block device ?
*/
if (!S_ISBLK (st.st_mode))
203f7bc: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
203f7c0: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
203f7c4: 03 00 00 18 sethi %hi(0x6000), %g1 <== NOT EXECUTED
203f7c8: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
203f7cc: 02 80 00 04 be 203f7dc <rtems_rfs_buffer_open+0x40> <== NOT EXECUTED
203f7d0: d0 1f bf d0 ldd [ %fp + -48 ], %o0 <== NOT EXECUTED
printf ("rtems-rfs: buffer-open: blks=%" PRId32 ", blk-size=%" PRId32 "\n",
rtems_rfs_fs_media_blocks (fs),
rtems_rfs_fs_media_block_size (fs));
return 0;
}
203f7d4: 81 c7 e0 08 ret <== NOT EXECUTED
203f7d8: 91 e8 20 05 restore %g0, 5, %o0 <== NOT EXECUTED
}
/*
* Check that device is registred as a block device and lock it.
*/
fs->disk = rtems_disk_obtain (st.st_rdev);
203f7dc: 7f ff 1f 2d call 2007490 <rtems_disk_obtain> <== NOT EXECUTED
203f7e0: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (!fs->disk)
203f7e4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f7e8: 02 bf ff fb be 203f7d4 <rtems_rfs_buffer_open+0x38> <== NOT EXECUTED
203f7ec: d0 26 60 0c st %o0, [ %i1 + 0xc ] <== NOT EXECUTED
printf ("rtems-rfs: buffer-open: blks=%" PRId32 ", blk-size=%" PRId32 "\n",
rtems_rfs_fs_media_blocks (fs),
rtems_rfs_fs_media_block_size (fs));
return 0;
}
203f7f0: 81 c7 e0 08 ret <== NOT EXECUTED
203f7f4: 81 e8 00 00 restore <== NOT EXECUTED
0203f718 <rtems_rfs_buffer_setblksize>:
int
rtems_rfs_buffer_setblksize (rtems_rfs_file_system* fs, size_t size)
{
203f718: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
203f71c: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))
printf ("rtems-rfs: buffer-setblksize: block size: %zu\n", size);
rc = rtems_rfs_buffers_release (fs);
203f720: 7f ff ff df call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
203f724: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))
printf ("rtems-rfs: buffer-setblksize: buffer release failed: %d: %s\n",
rc, strerror (rc));
rc = rtems_rfs_buffer_sync (fs);
203f728: 7f ff ff f0 call 203f6e8 <rtems_rfs_buffer_sync> <== NOT EXECUTED
203f72c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))
printf ("rtems-rfs: buffer-setblksize: device sync failed: %d: %s\n",
rc, strerror (rc));
#if RTEMS_RFS_USE_LIBBLOCK
rc = fs->disk->ioctl (fs->disk, RTEMS_BLKIO_SETBLKSIZE, &size);
203f730: d0 06 20 0c ld [ %i0 + 0xc ], %o0 <== NOT EXECUTED
203f734: 13 20 01 10 sethi %hi(0x80044000), %o1 <== NOT EXECUTED
203f738: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED
203f73c: 92 12 62 04 or %o1, 0x204, %o1 <== NOT EXECUTED
203f740: 9f c0 40 00 call %g1 <== NOT EXECUTED
203f744: 94 07 a0 48 add %fp, 0x48, %o2 <== NOT EXECUTED
if (rc < 0)
203f748: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f74c: 06 80 00 04 bl 203f75c <rtems_rfs_buffer_setblksize+0x44> <== NOT EXECUTED
203f750: 01 00 00 00 nop <== NOT EXECUTED
rc = errno;
#endif
return rc;
}
203f754: 81 c7 e0 08 ret <== NOT EXECUTED
203f758: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rc, strerror (rc));
#if RTEMS_RFS_USE_LIBBLOCK
rc = fs->disk->ioctl (fs->disk, RTEMS_BLKIO_SETBLKSIZE, &size);
if (rc < 0)
rc = errno;
203f75c: 40 00 2b 49 call 204a480 <__errno> <== NOT EXECUTED
203f760: 01 00 00 00 nop <== NOT EXECUTED
203f764: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
#endif
return rc;
}
203f768: 81 c7 e0 08 ret <== NOT EXECUTED
203f76c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0203f6e8 <rtems_rfs_buffer_sync>:
return rc;
}
int
rtems_rfs_buffer_sync (rtems_rfs_file_system* fs)
{
203f6e8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* @todo Split in the separate files for each type.
*/
#if RTEMS_RFS_USE_LIBBLOCK
sc = rtems_bdbuf_syncdev (rtems_rfs_fs_device (fs));
203f6ec: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
203f6f0: 7f ff 12 ba call 20041d8 <rtems_bdbuf_syncdev> <== NOT EXECUTED
203f6f4: d0 18 40 00 ldd [ %g1 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
203f6f8: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))
printf ("rtems-rfs: buffer-sync: device sync failed: %s\n",
rtems_status_text (sc));
result = EIO;
}
rtems_disk_release (fs->disk);
203f6fc: d0 06 20 0c ld [ %i0 + 0xc ], %o0 <== NOT EXECUTED
/*
* @todo Split in the separate files for each type.
*/
#if RTEMS_RFS_USE_LIBBLOCK
sc = rtems_bdbuf_syncdev (rtems_rfs_fs_device (fs));
if (sc != RTEMS_SUCCESSFUL)
203f700: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
203f704: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))
printf ("rtems-rfs: buffer-sync: device sync failed: %s\n",
rtems_status_text (sc));
result = EIO;
}
rtems_disk_release (fs->disk);
203f708: 7f ff 1f 4d call 200743c <rtems_disk_release> <== NOT EXECUTED
203f70c: b0 06 20 05 add %i0, 5, %i0 <== NOT EXECUTED
printf ("rtems-rfs: buffer-sync: file sync failed: %d: %s\n",
result, strerror (result));
}
#endif
return result;
}
203f710: 81 c7 e0 08 ret <== NOT EXECUTED
203f714: 81 e8 00 00 restore <== NOT EXECUTED
0203f69c <rtems_rfs_buffers_release>:
int
rtems_rfs_buffers_release (rtems_rfs_file_system* fs)
{
203f69c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_RELEASE))
printf ("rtems-rfs: buffers-release: active:%" PRIu32 " "
"release:%" PRIu32 " release-modified:%" PRIu32 "\n",
fs->buffers_count, fs->release_count, fs->release_modified_count);
rc = rtems_rfs_release_chain (&fs->release,
203f6a0: 94 10 20 00 clr %o2 <== NOT EXECUTED
203f6a4: 92 06 20 5c add %i0, 0x5c, %o1 <== NOT EXECUTED
203f6a8: 7f ff ff e0 call 203f628 <rtems_rfs_release_chain> <== NOT EXECUTED
203f6ac: 90 06 20 50 add %i0, 0x50, %o0 <== NOT EXECUTED
203f6b0: 82 38 00 08 xnor %g0, %o0, %g1 <== NOT EXECUTED
203f6b4: 83 38 60 1f sra %g1, 0x1f, %g1 <== NOT EXECUTED
&fs->release_count,
false);
if ((rc > 0) && (rrc == 0))
rrc = rc;
rc = rtems_rfs_release_chain (&fs->release_modified,
203f6b8: 92 06 20 6c add %i0, 0x6c, %o1 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_RELEASE))
printf ("rtems-rfs: buffers-release: active:%" PRIu32 " "
"release:%" PRIu32 " release-modified:%" PRIu32 "\n",
fs->buffers_count, fs->release_count, fs->release_modified_count);
rc = rtems_rfs_release_chain (&fs->release,
203f6bc: a0 0a 00 01 and %o0, %g1, %l0 <== NOT EXECUTED
&fs->release_count,
false);
if ((rc > 0) && (rrc == 0))
rrc = rc;
rc = rtems_rfs_release_chain (&fs->release_modified,
203f6c0: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
203f6c4: 7f ff ff d9 call 203f628 <rtems_rfs_release_chain> <== NOT EXECUTED
203f6c8: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED
&fs->release_modified_count,
true);
if ((rc > 0) && (rrc == 0))
203f6cc: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
203f6d0: 12 80 00 04 bne 203f6e0 <rtems_rfs_buffers_release+0x44> <== NOT EXECUTED
203f6d4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f6d8: 34 80 00 02 bg,a 203f6e0 <rtems_rfs_buffers_release+0x44><== NOT EXECUTED
203f6dc: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
rrc = rc;
return rrc;
}
203f6e0: 81 c7 e0 08 ret <== NOT EXECUTED
203f6e4: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
0204018c <rtems_rfs_dir_add_entry>:
rtems_rfs_dir_add_entry (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
const char* name,
size_t length,
rtems_rfs_ino ino)
{
204018c: 9d e3 bf 28 save %sp, -216, %sp <== NOT EXECUTED
for (c = 0; c < length; c++)
printf ("%c", name[c]);
printf (", len=%zd\n", length);
}
rc = rtems_rfs_block_map_open (fs, dir, &map);
2040190: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_dir_add_entry (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
const char* name,
size_t length,
rtems_rfs_ino ino)
{
2040194: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
for (c = 0; c < length; c++)
printf ("%c", name[c]);
printf (", len=%zd\n", length);
}
rc = rtems_rfs_block_map_open (fs, dir, &map);
2040198: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
204019c: a2 07 bf 94 add %fp, -108, %l1 <== NOT EXECUTED
20401a0: 7f ff fc c1 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
20401a4: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
20401a8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20401ac: 14 80 00 87 bg 20403c8 <rtems_rfs_dir_add_entry+0x23c> <== NOT EXECUTED
20401b0: 2d 00 00 3f sethi %hi(0xfc00), %l6 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
20401b4: c0 2f bf e4 clrb [ %fp + -28 ] <== NOT EXECUTED
handle->bnum = 0;
20401b8: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
handle->buffer = NULL;
20401bc: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
* @param bpos A pointer to the block position.
*/
static inline void
rtems_rfs_block_set_bpos_zero (rtems_rfs_block_pos* bpos)
{
bpos->bno = 0;
20401c0: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
bpos->boff = 0;
20401c4: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
bpos->block = 0;
20401c8: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
20401cc: ac 15 a3 ff or %l6, 0x3ff, %l6 <== NOT EXECUTED
20401d0: aa 07 bf f0 add %fp, -16, %l5 <== NOT EXECUTED
20401d4: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
20401d8: a8 07 bf e4 add %fp, -28, %l4 <== NOT EXECUTED
{
if ((length + RTEMS_RFS_DIR_ENTRY_SIZE) <
20401dc: 10 80 00 06 b 20401f4 <rtems_rfs_dir_add_entry+0x68> <== NOT EXECUTED
20401e0: ae 06 e0 0a add %i3, 0xa, %l7 <== NOT EXECUTED
if (!read)
memset (entry, 0xff, rtems_rfs_fs_block_size (fs));
offset = 0;
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
20401e4: c6 04 20 08 ld [ %l0 + 8 ], %g3 <== NOT EXECUTED
20401e8: 88 80 ff f6 addcc %g3, -10, %g4 <== NOT EXECUTED
20401ec: 32 80 00 2c bne,a 204029c <rtems_rfs_dir_add_entry+0x110><== NOT EXECUTED
20401f0: c2 0c a0 09 ldub [ %l2 + 9 ], %g1 <== NOT EXECUTED
/*
* Locate the first block. If an error the block will be 0. If the map is
* empty which happens when creating a directory and adding the first entry
* the seek will return ENXIO. In this case we need to grow the directory.
*/
rc = rtems_rfs_block_map_find (fs, &map, &bpos, &block);
20401f4: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
20401f8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20401fc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040200: 7f ff f9 7e call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
2040204: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
if (rc > 0)
2040208: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
204020c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040210: 04 80 00 0d ble 2040244 <rtems_rfs_dir_add_entry+0xb8> <== NOT EXECUTED
2040214: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
{
if (rc != ENXIO)
2040218: 80 a6 20 06 cmp %i0, 6 <== NOT EXECUTED
204021c: 12 80 00 6d bne 20403d0 <rtems_rfs_dir_add_entry+0x244> <== NOT EXECUTED
2040220: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
/*
* We have reached the end of the directory so add a block.
*/
rc = rtems_rfs_block_map_grow (fs, &map, 1, &block);
2040224: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040228: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
204022c: 7f ff fb 3f call 203ef28 <rtems_rfs_block_map_grow> <== NOT EXECUTED
2040230: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
if (rc > 0)
2040234: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040238: 14 80 00 66 bg 20403d0 <rtems_rfs_dir_add_entry+0x244> <== NOT EXECUTED
204023c: 96 10 20 00 clr %o3 <== NOT EXECUTED
2040240: a4 10 20 00 clr %l2 <== NOT EXECUTED
}
read = false;
}
bpos.bno++;
2040244: c2 07 bf f0 ld [ %fp + -16 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);
2040248: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
}
read = false;
}
bpos.bno++;
204024c: 82 00 60 01 inc %g1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);
2040250: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
read = false;
}
bpos.bno++;
2040254: c2 27 bf f0 st %g1, [ %fp + -16 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);
2040258: 7f ff fd b1 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
204025c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
if (rc > 0)
2040260: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040264: 14 80 00 5b bg 20403d0 <rtems_rfs_dir_add_entry+0x244> <== NOT EXECUTED
2040268: c2 07 bf ec ld [ %fp + -20 ], %g1 <== NOT EXECUTED
break;
}
entry = rtems_rfs_buffer_data (&buffer);
if (!read)
204026c: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
2040270: 12 bf ff dd bne 20401e4 <rtems_rfs_dir_add_entry+0x58> <== NOT EXECUTED
2040274: e4 00 60 24 ld [ %g1 + 0x24 ], %l2 <== NOT EXECUTED
memset (entry, 0xff, rtems_rfs_fs_block_size (fs));
2040278: d4 04 20 08 ld [ %l0 + 8 ], %o2 <== NOT EXECUTED
204027c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2040280: 40 00 36 5f call 204dbfc <memset> <== NOT EXECUTED
2040284: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
offset = 0;
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
2040288: c6 04 20 08 ld [ %l0 + 8 ], %g3 <== NOT EXECUTED
204028c: 88 80 ff f6 addcc %g3, -10, %g4 <== NOT EXECUTED
2040290: 02 bf ff da be 20401f8 <rtems_rfs_dir_add_entry+0x6c> <== NOT EXECUTED
2040294: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040298: c2 0c a0 09 ldub [ %l2 + 9 ], %g1 <== NOT EXECUTED
204029c: da 0c a0 08 ldub [ %l2 + 8 ], %o5 <== NOT EXECUTED
20402a0: ba 04 a0 08 add %l2, 8, %i5 <== NOT EXECUTED
20402a4: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
20402a8: b0 04 a0 09 add %l2, 9, %i0 <== NOT EXECUTED
20402ac: 9a 13 40 01 or %o5, %g1, %o5 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
20402b0: d0 0c 80 00 ldub [ %l2 ], %o0 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
20402b4: 80 a3 40 16 cmp %o5, %l6 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
20402b8: 84 04 a0 01 add %l2, 1, %g2 <== NOT EXECUTED
20402bc: d8 0c a0 01 ldub [ %l2 + 1 ], %o4 <== NOT EXECUTED
20402c0: 82 04 a0 02 add %l2, 2, %g1 <== NOT EXECUTED
20402c4: d2 0c a0 02 ldub [ %l2 + 2 ], %o1 <== NOT EXECUTED
20402c8: b2 04 a0 03 add %l2, 3, %i1 <== NOT EXECUTED
20402cc: d6 0c a0 03 ldub [ %l2 + 3 ], %o3 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
20402d0: 02 80 00 4b be 20403fc <rtems_rfs_dir_add_entry+0x270> <== NOT EXECUTED
20402d4: 94 10 20 00 clr %o2 <== NOT EXECUTED
}
break;
}
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
20402d8: 80 a3 60 0a cmp %o5, 0xa <== NOT EXECUTED
20402dc: 04 80 00 34 ble 20403ac <rtems_rfs_dir_add_entry+0x220> <== NOT EXECUTED
20402e0: 92 0a 60 ff and %o1, 0xff, %o1 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
20402e4: 93 2a 60 08 sll %o1, 8, %o1 <== NOT EXECUTED
20402e8: 96 0a e0 ff and %o3, 0xff, %o3 <== NOT EXECUTED
20402ec: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
20402f0: 96 12 c0 08 or %o3, %o0, %o3 <== NOT EXECUTED
20402f4: 96 12 c0 09 or %o3, %o1, %o3 <== NOT EXECUTED
20402f8: d2 04 20 18 ld [ %l0 + 0x18 ], %o1 <== NOT EXECUTED
20402fc: 98 0b 20 ff and %o4, 0xff, %o4 <== NOT EXECUTED
2040300: 99 2b 20 10 sll %o4, 0x10, %o4 <== NOT EXECUTED
2040304: 96 12 c0 0c or %o3, %o4, %o3 <== NOT EXECUTED
2040308: 98 10 20 00 clr %o4 <== NOT EXECUTED
}
break;
}
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
204030c: 80 a3 40 09 cmp %o5, %o1 <== NOT EXECUTED
2040310: 1a 80 00 27 bcc 20403ac <rtems_rfs_dir_add_entry+0x220> <== NOT EXECUTED
2040314: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
2040318: 22 80 00 26 be,a 20403b0 <rtems_rfs_dir_add_entry+0x224> <== NOT EXECUTED
204031c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2040320: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2040324: 80 a0 40 0b cmp %g1, %o3 <== NOT EXECUTED
2040328: 0a 80 00 21 bcs 20403ac <rtems_rfs_dir_add_entry+0x220> <== NOT EXECUTED
204032c: 98 03 00 0d add %o4, %o5, %o4 <== NOT EXECUTED
if (!read)
memset (entry, 0xff, rtems_rfs_fs_block_size (fs));
offset = 0;
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
2040330: 80 a3 00 04 cmp %o4, %g4 <== NOT EXECUTED
2040334: 1a bf ff b0 bcc 20401f4 <rtems_rfs_dir_add_entry+0x68> <== NOT EXECUTED
2040338: 94 10 00 0c mov %o4, %o2 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
return EIO;
}
entry += elength;
204033c: a4 04 80 0d add %l2, %o5, %l2 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040340: c2 0c a0 09 ldub [ %l2 + 9 ], %g1 <== NOT EXECUTED
2040344: da 0c a0 08 ldub [ %l2 + 8 ], %o5 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040348: c4 0c a0 01 ldub [ %l2 + 1 ], %g2 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
204034c: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
2040350: 9a 13 40 01 or %o5, %g1, %o5 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040354: c2 0c a0 02 ldub [ %l2 + 2 ], %g1 <== NOT EXECUTED
2040358: d0 0c 80 00 ldub [ %l2 ], %o0 <== NOT EXECUTED
204035c: d6 0c a0 03 ldub [ %l2 + 3 ], %o3 <== NOT EXECUTED
2040360: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
2040364: 82 08 60 ff and %g1, 0xff, %g1 <== NOT EXECUTED
2040368: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
204036c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2040370: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
2040374: 96 0a e0 ff and %o3, 0xff, %o3 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040378: 80 a3 40 16 cmp %o5, %l6 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
204037c: 96 12 c0 08 or %o3, %o0, %o3 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040380: ba 04 a0 08 add %l2, 8, %i5 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040384: 96 12 c0 02 or %o3, %g2, %o3 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040388: b0 04 a0 09 add %l2, 9, %i0 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
204038c: 96 12 c0 01 or %o3, %g1, %o3 <== NOT EXECUTED
2040390: 84 04 a0 01 add %l2, 1, %g2 <== NOT EXECUTED
2040394: 82 04 a0 02 add %l2, 2, %g1 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040398: 02 80 00 19 be 20403fc <rtems_rfs_dir_add_entry+0x270> <== NOT EXECUTED
204039c: b2 04 a0 03 add %l2, 3, %i1 <== NOT EXECUTED
}
break;
}
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
20403a0: 80 a3 60 0a cmp %o5, 0xa <== NOT EXECUTED
20403a4: 14 bf ff db bg 2040310 <rtems_rfs_dir_add_entry+0x184> <== NOT EXECUTED
20403a8: 80 a3 40 09 cmp %o5, %o1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))
printf ("rtems-rfs: dir-add-entry: "
"bad length or ino for ino %" PRIu32 ": %u/%" PRId32 " @ %04x\n",
rtems_rfs_inode_ino (dir), elength, eino, offset);
rtems_rfs_buffer_handle_close (fs, &buffer);
20403ac: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20403b0: 7f ff fd ea call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
20403b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
20403b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20403bc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20403c0: 7f ff fb c8 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
20403c4: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
return EIO;
20403c8: 81 c7 e0 08 ret <== NOT EXECUTED
20403cc: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20403d0: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20403d4: 7f ff fd 09 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20403d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
offset += elength;
}
}
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
20403dc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
20403e0: c0 2f bf e4 clrb [ %fp + -28 ] <== NOT EXECUTED
handle->bnum = 0;
20403e4: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
handle->buffer = NULL;
20403e8: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
20403ec: 7f ff fb bd call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
20403f0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
20403f4: 81 c7 e0 08 ret <== NOT EXECUTED
20403f8: 81 e8 00 00 restore <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
{
if ((length + RTEMS_RFS_DIR_ENTRY_SIZE) <
20403fc: 86 20 c0 0a sub %g3, %o2, %g3 <== NOT EXECUTED
2040400: 80 a5 c0 03 cmp %l7, %g3 <== NOT EXECUTED
2040404: 1a bf ff 7d bcc 20401f8 <rtems_rfs_dir_add_entry+0x6c> <== NOT EXECUTED
2040408: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
(rtems_rfs_fs_block_size (fs) - offset))
{
uint32_t hash;
hash = rtems_rfs_dir_hash (name, length);
204040c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2040410: c2 27 bf 8c st %g1, [ %fp + -116 ] <== NOT EXECUTED
2040414: c4 27 bf 88 st %g2, [ %fp + -120 ] <== NOT EXECUTED
2040418: 40 00 26 2b call 2049cc4 <rtems_rfs_dir_hash> <== NOT EXECUTED
204041c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
rtems_rfs_dir_set_entry_hash (entry, hash);
2040420: 87 32 20 18 srl %o0, 0x18, %g3 <== NOT EXECUTED
2040424: c6 2c a0 04 stb %g3, [ %l2 + 4 ] <== NOT EXECUTED
2040428: 87 32 20 10 srl %o0, 0x10, %g3 <== NOT EXECUTED
204042c: d0 2c a0 07 stb %o0, [ %l2 + 7 ] <== NOT EXECUTED
2040430: c6 2c a0 05 stb %g3, [ %l2 + 5 ] <== NOT EXECUTED
2040434: 91 32 20 08 srl %o0, 8, %o0 <== NOT EXECUTED
rtems_rfs_dir_set_entry_ino (entry, ino);
2040438: 87 37 20 18 srl %i4, 0x18, %g3 <== NOT EXECUTED
if ((length + RTEMS_RFS_DIR_ENTRY_SIZE) <
(rtems_rfs_fs_block_size (fs) - offset))
{
uint32_t hash;
hash = rtems_rfs_dir_hash (name, length);
rtems_rfs_dir_set_entry_hash (entry, hash);
204043c: d0 2c a0 06 stb %o0, [ %l2 + 6 ] <== NOT EXECUTED
rtems_rfs_dir_set_entry_ino (entry, ino);
2040440: c6 2c 80 00 stb %g3, [ %l2 ] <== NOT EXECUTED
2040444: c4 07 bf 88 ld [ %fp + -120 ], %g2 <== NOT EXECUTED
2040448: 87 37 20 10 srl %i4, 0x10, %g3 <== NOT EXECUTED
204044c: c6 28 80 00 stb %g3, [ %g2 ] <== NOT EXECUTED
2040450: c2 07 bf 8c ld [ %fp + -116 ], %g1 <== NOT EXECUTED
2040454: 85 37 20 08 srl %i4, 8, %g2 <== NOT EXECUTED
2040458: c4 28 40 00 stb %g2, [ %g1 ] <== NOT EXECUTED
204045c: f8 2e 40 00 stb %i4, [ %i1 ] <== NOT EXECUTED
rtems_rfs_dir_set_entry_length (entry,
2040460: af 35 e0 08 srl %l7, 8, %l7 <== NOT EXECUTED
2040464: ee 2f 40 00 stb %l7, [ %i5 ] <== NOT EXECUTED
RTEMS_RFS_DIR_ENTRY_SIZE + length);
memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);
2040468: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
204046c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2040470: 90 04 a0 0a add %l2, 0xa, %o0 <== NOT EXECUTED
{
uint32_t hash;
hash = rtems_rfs_dir_hash (name, length);
rtems_rfs_dir_set_entry_hash (entry, hash);
rtems_rfs_dir_set_entry_ino (entry, ino);
rtems_rfs_dir_set_entry_length (entry,
2040474: b6 06 e0 0a add %i3, 0xa, %i3 <== NOT EXECUTED
RTEMS_RFS_DIR_ENTRY_SIZE + length);
memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);
2040478: 40 00 35 4e call 204d9b0 <memcpy> <== NOT EXECUTED
204047c: f6 2e 00 00 stb %i3, [ %i0 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&buffer);
2040480: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
2040484: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
rtems_rfs_dir_set_entry_hash (entry, hash);
rtems_rfs_dir_set_entry_ino (entry, ino);
rtems_rfs_dir_set_entry_length (entry,
RTEMS_RFS_DIR_ENTRY_SIZE + length);
memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);
rtems_rfs_buffer_mark_dirty (&buffer);
2040488: c2 2f bf e4 stb %g1, [ %fp + -28 ] <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
204048c: 7f ff fd b3 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2040490: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
2040494: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040498: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
204049c: 7f ff fb 91 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
20404a0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
20404a4: 81 c7 e0 08 ret <== NOT EXECUTED
20404a8: 81 e8 00 00 restore <== NOT EXECUTED
0203fe70 <rtems_rfs_dir_del_entry>:
int
rtems_rfs_dir_del_entry (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
rtems_rfs_ino ino,
uint32_t offset)
{
203fe70: 9d e3 bf 38 save %sp, -200, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))
printf ("rtems-rfs: dir-del-entry: dir=%" PRId32 ", entry=%" PRId32 " offset=%" PRIu32 "\n",
rtems_rfs_inode_ino (dir), ino, offset);
rc = rtems_rfs_block_map_open (fs, dir, &map);
203fe74: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
int
rtems_rfs_dir_del_entry (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
rtems_rfs_ino ino,
uint32_t offset)
{
203fe78: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))
printf ("rtems-rfs: dir-del-entry: dir=%" PRId32 ", entry=%" PRId32 " offset=%" PRIu32 "\n",
rtems_rfs_inode_ino (dir), ino, offset);
rc = rtems_rfs_block_map_open (fs, dir, &map);
203fe7c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
203fe80: a2 07 bf a0 add %fp, -96, %l1 <== NOT EXECUTED
203fe84: 7f ff fd 88 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
203fe88: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
203fe8c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203fe90: 14 80 00 10 bg 203fed0 <rtems_rfs_dir_del_entry+0x60> <== NOT EXECUTED
203fe94: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
return rc;
rc = rtems_rfs_block_map_seek (fs, &map, offset, &block);
203fe98: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203fe9c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203fea0: 94 10 20 00 clr %o2 <== NOT EXECUTED
203fea4: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
203fea8: 7f ff fa bf call 203e9a4 <rtems_rfs_block_map_seek> <== NOT EXECUTED
203feac: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
if (rc > 0)
203feb0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203feb4: 04 80 00 09 ble 203fed8 <rtems_rfs_dir_del_entry+0x68> <== NOT EXECUTED
203feb8: 80 a6 20 06 cmp %i0, 6 <== NOT EXECUTED
{
if (rc == ENXIO)
203febc: 22 80 00 02 be,a 203fec4 <rtems_rfs_dir_del_entry+0x54> <== NOT EXECUTED
203fec0: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
rc = ENOENT;
rtems_rfs_block_map_close (fs, &map);
203fec4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203fec8: 7f ff fd 06 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
203fecc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
203fed0: 81 c7 e0 08 ret <== NOT EXECUTED
203fed4: 81 e8 00 00 restore <== NOT EXECUTED
/*
* If we are searching start at the beginning of the block. If not searching
* skip to the offset in the block.
*/
if (search)
203fed8: 80 a0 00 1b cmp %g0, %i3 <== NOT EXECUTED
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
203fedc: 29 00 00 3f sethi %hi(0xfc00), %l4 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
203fee0: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
203fee4: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
203fee8: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
/*
* If we are searching start at the beginning of the block. If not searching
* skip to the offset in the block.
*/
if (search)
203feec: a6 60 3f ff subx %g0, -1, %l3 <== NOT EXECUTED
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
203fef0: a8 15 23 ff or %l4, 0x3ff, %l4 <== NOT EXECUTED
203fef4: aa 07 bf f0 add %fp, -16, %l5 <== NOT EXECUTED
while (rc == 0)
{
uint8_t* entry;
int eoffset;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
203fef8: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
203fefc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203ff00: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
203ff04: 7f ff fe 86 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203ff08: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
203ff0c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203ff10: 14 80 00 5a bg 2040078 <rtems_rfs_dir_del_entry+0x208> <== NOT EXECUTED
203ff14: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
/*
* If we are searching start at the beginning of the block. If not searching
* skip to the offset in the block.
*/
if (search)
203ff18: 02 80 00 4d be 204004c <rtems_rfs_dir_del_entry+0x1dc> <== NOT EXECUTED
203ff1c: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
203ff20: 84 10 20 00 clr %g2 <== NOT EXECUTED
203ff24: ba 10 20 00 clr %i5 <== NOT EXECUTED
eoffset = 0;
else
eoffset = offset % rtems_rfs_fs_block_size (fs);
entry = rtems_rfs_buffer_data (&buffer) + eoffset;
203ff28: c6 07 bf f8 ld [ %fp + -8 ], %g3 <== NOT EXECUTED
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
203ff2c: 98 00 7f f6 add %g1, -10, %o4 <== NOT EXECUTED
203ff30: 80 a0 80 0c cmp %g2, %o4 <== NOT EXECUTED
203ff34: 1a 80 00 4e bcc 204006c <rtems_rfs_dir_del_entry+0x1fc> <== NOT EXECUTED
203ff38: c6 00 e0 24 ld [ %g3 + 0x24 ], %g3 <== NOT EXECUTED
if (search)
eoffset = 0;
else
eoffset = offset % rtems_rfs_fs_block_size (fs);
entry = rtems_rfs_buffer_data (&buffer) + eoffset;
203ff3c: ac 00 c0 02 add %g3, %g2, %l6 <== NOT EXECUTED
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
203ff40: c8 0d a0 09 ldub [ %l6 + 9 ], %g4 <== NOT EXECUTED
203ff44: ee 0d a0 08 ldub [ %l6 + 8 ], %l7 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203ff48: da 08 c0 02 ldub [ %g3 + %g2 ], %o5 <== NOT EXECUTED
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
203ff4c: af 2d e0 08 sll %l7, 8, %l7 <== NOT EXECUTED
203ff50: b2 05 a0 08 add %l6, 8, %i1 <== NOT EXECUTED
203ff54: ae 15 c0 04 or %l7, %g4, %l7 <== NOT EXECUTED
203ff58: b8 05 a0 09 add %l6, 9, %i4 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
203ff5c: 80 a5 c0 14 cmp %l7, %l4 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
203ff60: c8 0d a0 01 ldub [ %l6 + 1 ], %g4 <== NOT EXECUTED
203ff64: c6 0d a0 02 ldub [ %l6 + 2 ], %g3 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
203ff68: 02 80 00 41 be 204006c <rtems_rfs_dir_del_entry+0x1fc> <== NOT EXECUTED
203ff6c: c4 0d a0 03 ldub [ %l6 + 3 ], %g2 <== NOT EXECUTED
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
203ff70: 80 a5 e0 0a cmp %l7, 0xa <== NOT EXECUTED
203ff74: 04 80 00 34 ble 2040044 <rtems_rfs_dir_del_entry+0x1d4> <== NOT EXECUTED
203ff78: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
203ff7c: 9b 2b 60 18 sll %o5, 0x18, %o5 <== NOT EXECUTED
203ff80: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
203ff84: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
203ff88: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
203ff8c: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
203ff90: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
203ff94: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
203ff98: d6 04 20 18 ld [ %l0 + 0x18 ], %o3 <== NOT EXECUTED
203ff9c: 10 80 00 27 b 2040038 <rtems_rfs_dir_del_entry+0x1c8> <== NOT EXECUTED
203ffa0: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
203ffa4: 22 80 00 35 be,a 2040078 <rtems_rfs_dir_del_entry+0x208> <== NOT EXECUTED
203ffa8: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
203ffac: c6 04 20 10 ld [ %l0 + 0x10 ], %g3 <== NOT EXECUTED
203ffb0: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
203ffb4: 0a 80 00 24 bcs 2040044 <rtems_rfs_dir_del_entry+0x1d4> <== NOT EXECUTED
203ffb8: 80 a0 80 1a cmp %g2, %i2 <== NOT EXECUTED
rtems_rfs_inode_ino (dir), elength, eino, block, eoffset);
rc = EIO;
break;
}
if (ino == rtems_rfs_dir_entry_ino (entry))
203ffbc: 02 80 00 37 be 2040098 <rtems_rfs_dir_del_entry+0x228> <== NOT EXECUTED
203ffc0: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
return 0;
}
if (!search)
203ffc4: 02 80 00 20 be 2040044 <rtems_rfs_dir_del_entry+0x1d4> <== NOT EXECUTED
203ffc8: ac 05 80 17 add %l6, %l7, %l6 <== NOT EXECUTED
rc = EIO;
break;
}
entry += elength;
eoffset += elength;
203ffcc: ba 07 40 17 add %i5, %l7, %i5 <== NOT EXECUTED
else
eoffset = offset % rtems_rfs_fs_block_size (fs);
entry = rtems_rfs_buffer_data (&buffer) + eoffset;
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
203ffd0: 80 a7 40 0c cmp %i5, %o4 <== NOT EXECUTED
203ffd4: 1a 80 00 26 bcc 204006c <rtems_rfs_dir_del_entry+0x1fc> <== NOT EXECUTED
203ffd8: b2 05 a0 08 add %l6, 8, %i1 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
203ffdc: c4 0d a0 09 ldub [ %l6 + 9 ], %g2 <== NOT EXECUTED
203ffe0: ee 0d a0 08 ldub [ %l6 + 8 ], %l7 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203ffe4: da 0d 80 00 ldub [ %l6 ], %o5 <== NOT EXECUTED
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
203ffe8: af 2d e0 08 sll %l7, 8, %l7 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203ffec: c8 0d a0 01 ldub [ %l6 + 1 ], %g4 <== NOT EXECUTED
while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
203fff0: ae 15 c0 02 or %l7, %g2, %l7 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203fff4: c6 0d a0 02 ldub [ %l6 + 2 ], %g3 <== NOT EXECUTED
203fff8: c4 0d a0 03 ldub [ %l6 + 3 ], %g2 <== NOT EXECUTED
203fffc: 9b 2b 60 18 sll %o5, 0x18, %o5 <== NOT EXECUTED
2040000: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
2040004: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
2040008: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
204000c: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
2040010: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
2040014: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040018: 80 a5 c0 14 cmp %l7, %l4 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
204001c: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
2040020: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040024: 02 80 00 12 be 204006c <rtems_rfs_dir_del_entry+0x1fc> <== NOT EXECUTED
2040028: b8 05 a0 09 add %l6, 9, %i4 <== NOT EXECUTED
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
204002c: 80 a5 e0 0a cmp %l7, 0xa <== NOT EXECUTED
2040030: 24 80 00 12 ble,a 2040078 <rtems_rfs_dir_del_entry+0x208><== NOT EXECUTED
2040034: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
2040038: 80 a5 c0 0b cmp %l7, %o3 <== NOT EXECUTED
204003c: 0a bf ff da bcs 203ffa4 <rtems_rfs_dir_del_entry+0x134> <== NOT EXECUTED
2040040: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
/*
* Only search if the offset is 0 else we are at that position.
*/
search = offset ? false : true;
while (rc == 0)
2040044: 10 80 00 0d b 2040078 <rtems_rfs_dir_del_entry+0x208> <== NOT EXECUTED
2040048: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
* skip to the offset in the block.
*/
if (search)
eoffset = 0;
else
eoffset = offset % rtems_rfs_fs_block_size (fs);
204004c: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
2040050: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
2040054: 40 00 8a f8 call 2062c34 <.urem> <== NOT EXECUTED
2040058: c2 27 bf 9c st %g1, [ %fp + -100 ] <== NOT EXECUTED
204005c: c2 07 bf 9c ld [ %fp + -100 ], %g1 <== NOT EXECUTED
2040060: ba 10 00 08 mov %o0, %i5 <== NOT EXECUTED
2040064: 10 bf ff b1 b 203ff28 <rtems_rfs_dir_del_entry+0xb8> <== NOT EXECUTED
2040068: 84 10 00 08 mov %o0, %g2 <== NOT EXECUTED
entry += elength;
eoffset += elength;
}
if (rc == 0)
204006c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2040070: 02 80 00 31 be 2040134 <rtems_rfs_dir_del_entry+0x2c4> <== NOT EXECUTED
2040074: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc == ENXIO)
rc = ENOENT;
}
}
rtems_rfs_buffer_handle_close (fs, &buffer);
2040078: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
204007c: 7f ff fe b7 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2040080: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
2040084: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040088: 7f ff fc 96 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
204008c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
2040090: 81 c7 e0 08 ret <== NOT EXECUTED
2040094: 81 e8 00 00 restore <== NOT EXECUTED
if (ino == rtems_rfs_dir_entry_ino (entry))
{
uint32_t remaining;
remaining = rtems_rfs_fs_block_size (fs) - (eoffset + elength);
memmove (entry, entry + elength, remaining);
2040098: 92 05 80 17 add %l6, %l7, %o1 <== NOT EXECUTED
}
if (ino == rtems_rfs_dir_entry_ino (entry))
{
uint32_t remaining;
remaining = rtems_rfs_fs_block_size (fs) - (eoffset + elength);
204009c: a4 07 40 17 add %i5, %l7, %l2 <== NOT EXECUTED
memmove (entry, entry + elength, remaining);
20400a0: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
}
if (ino == rtems_rfs_dir_entry_ino (entry))
{
uint32_t remaining;
remaining = rtems_rfs_fs_block_size (fs) - (eoffset + elength);
20400a4: a4 20 40 12 sub %g1, %l2, %l2 <== NOT EXECUTED
memmove (entry, entry + elength, remaining);
20400a8: 40 00 36 81 call 204daac <memmove> <== NOT EXECUTED
20400ac: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
memset (entry + remaining, 0xff, elength);
20400b0: 90 05 80 12 add %l6, %l2, %o0 <== NOT EXECUTED
20400b4: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
20400b8: 40 00 36 d1 call 204dbfc <memset> <== NOT EXECUTED
20400bc: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
* block and it is the last block in the map shrink the map.
*
* @note We could check again to see if the new end block in the map is
* also empty. This way we could clean up an empty directory.
*/
elength = rtems_rfs_dir_entry_length (entry);
20400c0: c2 0f 00 00 ldub [ %i4 ], %g1 <== NOT EXECUTED
20400c4: c4 0e 40 00 ldub [ %i1 ], %g2 <== NOT EXECUTED
20400c8: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
20400cc: 84 10 80 01 or %g2, %g1, %g2 <== NOT EXECUTED
20400d0: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED
20400d4: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
20400d8: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
20400dc: 12 80 00 0b bne 2040108 <rtems_rfs_dir_del_entry+0x298> <== NOT EXECUTED
20400e0: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
20400e4: 12 80 00 09 bne 2040108 <rtems_rfs_dir_del_entry+0x298> <== NOT EXECUTED
20400e8: c2 07 bf b0 ld [ %fp + -80 ], %g1 <== NOT EXECUTED
"last block free for ino %" PRIu32 ": elength=%i block=%" PRIu32
" offset=%d last=%s\n",
ino, elength, block, eoffset,
rtems_rfs_block_map_last (&map) ? "yes" : "no");
if ((elength == RTEMS_RFS_DIR_ENTRY_EMPTY) &&
20400ec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20400f0: 02 80 00 1c be 2040160 <rtems_rfs_dir_del_entry+0x2f0> <== NOT EXECUTED
20400f4: c4 07 bf a8 ld [ %fp + -88 ], %g2 <== NOT EXECUTED
20400f8: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
20400fc: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2040100: 02 80 00 1c be 2040170 <rtems_rfs_dir_del_entry+0x300> <== NOT EXECUTED
2040104: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
"block map shrink failed for ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (dir), rc, strerror (rc));
}
}
rtems_rfs_buffer_mark_dirty (&buffer);
2040108: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
204010c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
"block map shrink failed for ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (dir), rc, strerror (rc));
}
}
rtems_rfs_buffer_mark_dirty (&buffer);
2040110: c2 2f bf f0 stb %g1, [ %fp + -16 ] <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
2040114: 7f ff fe 91 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2040118: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
204011c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040120: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040124: 7f ff fc 6f call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2040128: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
204012c: 81 c7 e0 08 ret <== NOT EXECUTED
2040130: 81 e8 00 00 restore <== NOT EXECUTED
eoffset += elength;
}
if (rc == 0)
{
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
2040134: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040138: 7f ff fa 0e call 203e970 <rtems_rfs_block_map_next_block> <== NOT EXECUTED
204013c: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if (rc == ENXIO)
2040140: 80 a2 20 06 cmp %o0, 6 <== NOT EXECUTED
2040144: 02 80 00 10 be 2040184 <rtems_rfs_dir_del_entry+0x314> <== NOT EXECUTED
2040148: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
/*
* Only search if the offset is 0 else we are at that position.
*/
search = offset ? false : true;
while (rc == 0)
204014c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040150: 02 bf ff 6b be 203fefc <rtems_rfs_dir_del_entry+0x8c> <== NOT EXECUTED
2040154: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
if (rc == ENXIO)
rc = ENOENT;
}
}
rtems_rfs_buffer_handle_close (fs, &buffer);
2040158: 10 bf ff c9 b 204007c <rtems_rfs_dir_del_entry+0x20c> <== NOT EXECUTED
204015c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
"last block free for ino %" PRIu32 ": elength=%i block=%" PRIu32
" offset=%d last=%s\n",
ino, elength, block, eoffset,
rtems_rfs_block_map_last (&map) ? "yes" : "no");
if ((elength == RTEMS_RFS_DIR_ENTRY_EMPTY) &&
2040160: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2040164: 12 bf ff e6 bne 20400fc <rtems_rfs_dir_del_entry+0x28c> <== NOT EXECUTED
2040168: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
(eoffset == 0) && rtems_rfs_block_map_last (&map))
{
rc = rtems_rfs_block_map_shrink (fs, &map, 1);
204016c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040170: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040174: 7f ff fa 53 call 203eac0 <rtems_rfs_block_map_shrink> <== NOT EXECUTED
2040178: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
"block map shrink failed for ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (dir), rc, strerror (rc));
}
}
rtems_rfs_buffer_mark_dirty (&buffer);
204017c: 10 bf ff e4 b 204010c <rtems_rfs_dir_del_entry+0x29c> <== NOT EXECUTED
2040180: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
}
if (rc == 0)
{
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
if (rc == ENXIO)
2040184: 10 bf ff bd b 2040078 <rtems_rfs_dir_del_entry+0x208> <== NOT EXECUTED
2040188: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
02040728 <rtems_rfs_dir_empty>:
}
int
rtems_rfs_dir_empty (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir)
{
2040728: 9d e3 bf 40 save %sp, -192, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-empty: dir=%" PRId32 "\n", rtems_rfs_inode_ino (dir));
empty = true;
rc = rtems_rfs_block_map_open (fs, dir, &map);
204072c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
}
int
rtems_rfs_dir_empty (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir)
{
2040730: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-empty: dir=%" PRId32 "\n", rtems_rfs_inode_ino (dir));
empty = true;
rc = rtems_rfs_block_map_open (fs, dir, &map);
2040734: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2040738: a2 07 bf a0 add %fp, -96, %l1 <== NOT EXECUTED
204073c: 7f ff fb 5a call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
2040740: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
2040744: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040748: 14 80 00 71 bg 204090c <rtems_rfs_dir_empty+0x1e4> <== NOT EXECUTED
204074c: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
return rc;
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
2040750: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040754: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040758: 94 10 20 00 clr %o2 <== NOT EXECUTED
204075c: 96 10 20 00 clr %o3 <== NOT EXECUTED
2040760: 7f ff f8 91 call 203e9a4 <rtems_rfs_block_map_seek> <== NOT EXECUTED
2040764: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
if (rc > 0)
2040768: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
204076c: 14 80 00 76 bg 2040944 <rtems_rfs_dir_empty+0x21c> <== NOT EXECUTED
2040770: 27 00 00 3f sethi %hi(0xfc00), %l3 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2040774: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2040778: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
204077c: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040780: a6 14 e3 ff or %l3, 0x3ff, %l3 <== NOT EXECUTED
2040784: a8 07 bf f0 add %fp, -16, %l4 <== NOT EXECUTED
while (empty)
{
uint8_t* entry;
int offset;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
2040788: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
204078c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040790: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2040794: 7f ff fc 62 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2040798: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
204079c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20407a0: 14 80 00 52 bg 20408e8 <rtems_rfs_dir_empty+0x1c0> <== NOT EXECUTED
20407a4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
break;
entry = rtems_rfs_buffer_data (&buffer);
offset = 0;
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
20407a8: d2 04 20 08 ld [ %l0 + 8 ], %o1 <== NOT EXECUTED
20407ac: 92 82 7f f6 addcc %o1, -10, %o1 <== NOT EXECUTED
20407b0: 02 80 00 59 be 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
20407b4: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
20407b8: c6 08 60 09 ldub [ %g1 + 9 ], %g3 <== NOT EXECUTED
20407bc: c4 08 60 08 ldub [ %g1 + 8 ], %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
20407c0: d8 08 40 00 ldub [ %g1 ], %o4 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
20407c4: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
20407c8: da 08 60 01 ldub [ %g1 + 1 ], %o5 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
20407cc: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
20407d0: c8 08 60 02 ldub [ %g1 + 2 ], %g4 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
20407d4: 80 a0 80 13 cmp %g2, %l3 <== NOT EXECUTED
20407d8: 02 80 00 4f be 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
20407dc: c6 08 60 03 ldub [ %g1 + 3 ], %g3 <== NOT EXECUTED
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
20407e0: 80 a0 a0 0a cmp %g2, 0xa <== NOT EXECUTED
20407e4: 04 80 00 4c ble 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
20407e8: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
20407ec: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
20407f0: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
20407f4: 99 2b 20 18 sll %o4, 0x18, %o4 <== NOT EXECUTED
20407f8: 9a 0b 60 ff and %o5, 0xff, %o5 <== NOT EXECUTED
20407fc: 86 10 c0 0c or %g3, %o4, %g3 <== NOT EXECUTED
2040800: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
2040804: d4 04 20 18 ld [ %l0 + 0x18 ], %o2 <== NOT EXECUTED
2040808: 86 10 c0 0d or %g3, %o5, %g3 <== NOT EXECUTED
204080c: 86 10 c0 04 or %g3, %g4, %g3 <== NOT EXECUTED
2040810: 10 80 00 25 b 20408a4 <rtems_rfs_dir_empty+0x17c> <== NOT EXECUTED
2040814: 88 10 20 00 clr %g4 <== NOT EXECUTED
/*
* Ignore the current (.) and parent (..) entries. Anything else means
* the directory is not empty.
*/
if (((elength != (RTEMS_RFS_DIR_ENTRY_SIZE + 1)) ||
2040818: 12 80 00 32 bne 20408e0 <rtems_rfs_dir_empty+0x1b8> <== NOT EXECUTED
204081c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
(entry[RTEMS_RFS_DIR_ENTRY_SIZE] != '.')) &&
((elength != (RTEMS_RFS_DIR_ENTRY_SIZE + 2)) ||
(entry[RTEMS_RFS_DIR_ENTRY_SIZE] != '.') ||
2040820: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
2040824: 80 a0 e0 2e cmp %g3, 0x2e <== NOT EXECUTED
2040828: 12 80 00 2e bne 20408e0 <rtems_rfs_dir_empty+0x1b8> <== NOT EXECUTED
204082c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
(entry[RTEMS_RFS_DIR_ENTRY_SIZE + 1] != '.')))
2040830: c6 08 60 0b ldub [ %g1 + 0xb ], %g3 <== NOT EXECUTED
2040834: 80 a0 e0 2e cmp %g3, 0x2e <== NOT EXECUTED
2040838: 12 80 00 2a bne 20408e0 <rtems_rfs_dir_empty+0x1b8> <== NOT EXECUTED
204083c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
empty = false;
break;
}
entry += elength;
offset += elength;
2040840: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
break;
entry = rtems_rfs_buffer_data (&buffer);
offset = 0;
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
2040844: 80 a1 00 09 cmp %g4, %o1 <== NOT EXECUTED
2040848: 1a 80 00 33 bcc 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
204084c: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040850: c6 08 60 09 ldub [ %g1 + 9 ], %g3 <== NOT EXECUTED
2040854: c4 08 60 08 ldub [ %g1 + 8 ], %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040858: d6 08 40 00 ldub [ %g1 ], %o3 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
204085c: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040860: d8 08 60 01 ldub [ %g1 + 1 ], %o4 <== NOT EXECUTED
while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
2040864: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
2040868: da 08 60 02 ldub [ %g1 + 2 ], %o5 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
204086c: 80 a0 80 13 cmp %g2, %l3 <== NOT EXECUTED
2040870: 02 80 00 29 be 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
2040874: c6 08 60 03 ldub [ %g1 + 3 ], %g3 <== NOT EXECUTED
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
2040878: 80 a0 a0 0a cmp %g2, 0xa <== NOT EXECUTED
204087c: 04 80 00 26 ble 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
2040880: 86 08 e0 ff and %g3, 0xff, %g3 <== NOT EXECUTED
{
rtems_rfs_ino eino;
int elength;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
2040884: 97 2a e0 18 sll %o3, 0x18, %o3 <== NOT EXECUTED
2040888: 98 0b 20 ff and %o4, 0xff, %o4 <== NOT EXECUTED
204088c: 86 10 c0 0b or %g3, %o3, %g3 <== NOT EXECUTED
2040890: 9a 0b 60 ff and %o5, 0xff, %o5 <== NOT EXECUTED
2040894: 99 2b 20 10 sll %o4, 0x10, %o4 <== NOT EXECUTED
2040898: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
204089c: 86 10 c0 0c or %g3, %o4, %g3 <== NOT EXECUTED
20408a0: 86 10 c0 0d or %g3, %o5, %g3 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
break;
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
20408a4: 80 a0 80 0a cmp %g2, %o2 <== NOT EXECUTED
20408a8: 1a 80 00 1b bcc 2040914 <rtems_rfs_dir_empty+0x1ec> <== NOT EXECUTED
20408ac: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
20408b0: 02 80 00 1a be 2040918 <rtems_rfs_dir_empty+0x1f0> <== NOT EXECUTED
20408b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20408b8: da 04 20 10 ld [ %l0 + 0x10 ], %o5 <== NOT EXECUTED
20408bc: 80 a3 40 03 cmp %o5, %g3 <== NOT EXECUTED
20408c0: 0a 80 00 16 bcs 2040918 <rtems_rfs_dir_empty+0x1f0> <== NOT EXECUTED
20408c4: 80 a0 a0 0b cmp %g2, 0xb <== NOT EXECUTED
/*
* Ignore the current (.) and parent (..) entries. Anything else means
* the directory is not empty.
*/
if (((elength != (RTEMS_RFS_DIR_ENTRY_SIZE + 1)) ||
20408c8: 12 bf ff d4 bne 2040818 <rtems_rfs_dir_empty+0xf0> <== NOT EXECUTED
20408cc: 80 a0 a0 0c cmp %g2, 0xc <== NOT EXECUTED
(entry[RTEMS_RFS_DIR_ENTRY_SIZE] != '.')) &&
20408d0: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
20408d4: 80 a0 e0 2e cmp %g3, 0x2e <== NOT EXECUTED
20408d8: 02 bf ff da be 2040840 <rtems_rfs_dir_empty+0x118> <== NOT EXECUTED
20408dc: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
break;
}
}
}
if ((rc == 0) && !empty)
20408e0: 22 80 00 02 be,a 20408e8 <rtems_rfs_dir_empty+0x1c0> <== NOT EXECUTED
20408e4: b0 10 20 5a mov 0x5a, %i0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20408e8: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20408ec: 7f ff fb c3 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20408f0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = ENOTEMPTY;
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
20408f4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
20408f8: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
20408fc: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2040900: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2040904: 7f ff fa 77 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2040908: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
204090c: 81 c7 e0 08 ret <== NOT EXECUTED
2040910: 81 e8 00 00 restore <== NOT EXECUTED
offset += elength;
}
if (empty)
{
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
2040914: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040918: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
204091c: 7f ff f8 15 call 203e970 <rtems_rfs_block_map_next_block> <== NOT EXECUTED
2040920: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if (rc > 0)
2040924: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040928: 04 bf ff 99 ble 204078c <rtems_rfs_dir_empty+0x64> <== NOT EXECUTED
204092c: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
{
if (rc == ENXIO)
2040930: 82 1e 20 06 xor %i0, 6, %g1 <== NOT EXECUTED
2040934: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2040938: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
204093c: 10 bf ff eb b 20408e8 <rtems_rfs_dir_empty+0x1c0> <== NOT EXECUTED
2040940: b0 0e 00 01 and %i0, %g1, %i0 <== NOT EXECUTED
return rc;
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
2040944: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040948: 7f ff fa 66 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
204094c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2040950: 81 c7 e0 08 ret <== NOT EXECUTED
2040954: 81 e8 00 00 restore <== NOT EXECUTED
02049cc4 <rtems_rfs_dir_hash>:
*/
#define initval (20010928)
uint32_t
rtems_rfs_dir_hash (const void *key, size_t length)
{
2049cc4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
break;
case 0 : return c; /* zero length requires no mixing */
}
} else { /* need to read the key one byte at a time */
const uint8_t *k = (const uint8_t *)key;
2049cc8: 82 10 00 18 mov %i0, %g1 <== NOT EXECUTED
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
2049ccc: 80 a6 60 0c cmp %i1, 0xc <== NOT EXECUTED
{
uint32_t a,b,c; /* internal state */
union { const void *ptr; size_t i; } u; /* needed for Mac Powerbook G4 */
/* Set up the internal state */
a = b = c = 0xdeadbeef + ((uint32_t)length) + initval;
2049cd0: 31 37 f7 c5 sethi %hi(0xdfdf1400), %i0 <== NOT EXECUTED
2049cd4: b0 16 22 9f or %i0, 0x29f, %i0 ! dfdf169f <RAM_END+0xdd9f169f><== NOT EXECUTED
2049cd8: b0 06 40 18 add %i1, %i0, %i0 <== NOT EXECUTED
} else { /* need to read the key one byte at a time */
const uint8_t *k = (const uint8_t *)key;
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
2049cdc: 98 10 00 18 mov %i0, %o4 <== NOT EXECUTED
2049ce0: 08 80 00 4b bleu 2049e0c <rtems_rfs_dir_hash+0x148> <== NOT EXECUTED
2049ce4: 88 10 00 18 mov %i0, %g4 <== NOT EXECUTED
{
a += k[0];
2049ce8: e6 08 60 01 ldub [ %g1 + 1 ], %l3 <== NOT EXECUTED
2049cec: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
a += ((uint32_t)k[1])<<8;
2049cf0: e4 08 40 00 ldub [ %g1 ], %l2 <== NOT EXECUTED
a += ((uint32_t)k[2])<<16;
2049cf4: e2 08 60 03 ldub [ %g1 + 3 ], %l1 <== NOT EXECUTED
a += ((uint32_t)k[3])<<24;
b += k[4];
2049cf8: e0 08 60 06 ldub [ %g1 + 6 ], %l0 <== NOT EXECUTED
b += ((uint32_t)k[5])<<8;
b += ((uint32_t)k[6])<<16;
2049cfc: da 08 60 07 ldub [ %g1 + 7 ], %o5 <== NOT EXECUTED
{
a += k[0];
a += ((uint32_t)k[1])<<8;
a += ((uint32_t)k[2])<<16;
a += ((uint32_t)k[3])<<24;
b += k[4];
2049d00: d6 08 60 05 ldub [ %g1 + 5 ], %o3 <== NOT EXECUTED
b += ((uint32_t)k[5])<<8;
2049d04: de 08 60 04 ldub [ %g1 + 4 ], %o7 <== NOT EXECUTED
b += ((uint32_t)k[6])<<16;
b += ((uint32_t)k[7])<<24;
c += k[8];
2049d08: d0 08 60 09 ldub [ %g1 + 9 ], %o0 <== NOT EXECUTED
const uint8_t *k = (const uint8_t *)key;
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
{
a += k[0];
2049d0c: a7 2c e0 08 sll %l3, 8, %l3 <== NOT EXECUTED
2049d10: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
a += ((uint32_t)k[1])<<8;
a += ((uint32_t)k[2])<<16;
2049d14: a3 2c 60 18 sll %l1, 0x18, %l1 <== NOT EXECUTED
const uint8_t *k = (const uint8_t *)key;
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
{
a += k[0];
2049d18: 84 04 c0 02 add %l3, %g2, %g2 <== NOT EXECUTED
a += ((uint32_t)k[1])<<8;
2049d1c: 84 00 80 12 add %g2, %l2, %g2 <== NOT EXECUTED
a += ((uint32_t)k[2])<<16;
2049d20: 84 00 80 11 add %g2, %l1, %g2 <== NOT EXECUTED
a += ((uint32_t)k[3])<<24;
2049d24: 84 00 80 04 add %g2, %g4, %g2 <== NOT EXECUTED
b += k[4];
2049d28: 89 2c 20 10 sll %l0, 0x10, %g4 <== NOT EXECUTED
b += ((uint32_t)k[5])<<8;
b += ((uint32_t)k[6])<<16;
b += ((uint32_t)k[7])<<24;
c += k[8];
2049d2c: c6 08 60 0a ldub [ %g1 + 0xa ], %g3 <== NOT EXECUTED
c += ((uint32_t)k[9])<<8;
c += ((uint32_t)k[10])<<16;
2049d30: d4 08 60 0b ldub [ %g1 + 0xb ], %o2 <== NOT EXECUTED
{
a += k[0];
a += ((uint32_t)k[1])<<8;
a += ((uint32_t)k[2])<<16;
a += ((uint32_t)k[3])<<24;
b += k[4];
2049d34: 97 2a e0 08 sll %o3, 8, %o3 <== NOT EXECUTED
2049d38: 96 02 c0 04 add %o3, %g4, %o3 <== NOT EXECUTED
b += ((uint32_t)k[5])<<8;
b += ((uint32_t)k[6])<<16;
2049d3c: 89 2b 60 18 sll %o5, 0x18, %g4 <== NOT EXECUTED
b += ((uint32_t)k[7])<<24;
c += k[8];
c += ((uint32_t)k[9])<<8;
2049d40: d2 08 60 08 ldub [ %g1 + 8 ], %o1 <== NOT EXECUTED
a += k[0];
a += ((uint32_t)k[1])<<8;
a += ((uint32_t)k[2])<<16;
a += ((uint32_t)k[3])<<24;
b += k[4];
b += ((uint32_t)k[5])<<8;
2049d44: 96 02 c0 0f add %o3, %o7, %o3 <== NOT EXECUTED
b += ((uint32_t)k[6])<<16;
2049d48: 96 02 c0 04 add %o3, %g4, %o3 <== NOT EXECUTED
b += ((uint32_t)k[7])<<24;
c += k[8];
2049d4c: 89 2a 20 08 sll %o0, 8, %g4 <== NOT EXECUTED
2049d50: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2049d54: 86 01 00 03 add %g4, %g3, %g3 <== NOT EXECUTED
c += ((uint32_t)k[9])<<8;
c += ((uint32_t)k[10])<<16;
2049d58: 89 2a a0 18 sll %o2, 0x18, %g4 <== NOT EXECUTED
a += ((uint32_t)k[2])<<16;
a += ((uint32_t)k[3])<<24;
b += k[4];
b += ((uint32_t)k[5])<<8;
b += ((uint32_t)k[6])<<16;
b += ((uint32_t)k[7])<<24;
2049d5c: 96 02 c0 0c add %o3, %o4, %o3 <== NOT EXECUTED
c += k[8];
c += ((uint32_t)k[9])<<8;
2049d60: 86 00 c0 09 add %g3, %o1, %g3 <== NOT EXECUTED
c += ((uint32_t)k[10])<<16;
2049d64: 86 00 c0 04 add %g3, %g4, %g3 <== NOT EXECUTED
c += ((uint32_t)k[11])<<24;
2049d68: 86 00 c0 18 add %g3, %i0, %g3 <== NOT EXECUTED
mix(a,b,c);
2049d6c: 98 00 c0 0b add %g3, %o3, %o4 <== NOT EXECUTED
2049d70: 89 30 e0 1c srl %g3, 0x1c, %g4 <== NOT EXECUTED
2049d74: 84 20 80 03 sub %g2, %g3, %g2 <== NOT EXECUTED
2049d78: 87 28 e0 04 sll %g3, 4, %g3 <== NOT EXECUTED
2049d7c: 86 11 00 03 or %g4, %g3, %g3 <== NOT EXECUTED
2049d80: 84 18 80 03 xor %g2, %g3, %g2 <== NOT EXECUTED
2049d84: 86 00 80 0c add %g2, %o4, %g3 <== NOT EXECUTED
2049d88: 96 22 c0 02 sub %o3, %g2, %o3 <== NOT EXECUTED
2049d8c: 9b 30 a0 1a srl %g2, 0x1a, %o5 <== NOT EXECUTED
2049d90: 85 28 a0 06 sll %g2, 6, %g2 <== NOT EXECUTED
2049d94: 9a 13 40 02 or %o5, %g2, %o5 <== NOT EXECUTED
2049d98: 9a 1b 40 0b xor %o5, %o3, %o5 <== NOT EXECUTED
2049d9c: 98 23 00 0d sub %o4, %o5, %o4 <== NOT EXECUTED
2049da0: 84 03 40 03 add %o5, %g3, %g2 <== NOT EXECUTED
2049da4: 89 33 60 18 srl %o5, 0x18, %g4 <== NOT EXECUTED
2049da8: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
2049dac: 88 11 00 0d or %g4, %o5, %g4 <== NOT EXECUTED
2049db0: 88 19 00 0c xor %g4, %o4, %g4 <== NOT EXECUTED
2049db4: 99 31 20 10 srl %g4, 0x10, %o4 <== NOT EXECUTED
2049db8: 9a 01 00 02 add %g4, %g2, %o5 <== NOT EXECUTED
2049dbc: 86 20 c0 04 sub %g3, %g4, %g3 <== NOT EXECUTED
2049dc0: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
2049dc4: 88 13 00 04 or %o4, %g4, %g4 <== NOT EXECUTED
2049dc8: 86 19 00 03 xor %g4, %g3, %g3 <== NOT EXECUTED
2049dcc: 99 30 e0 0d srl %g3, 0xd, %o4 <== NOT EXECUTED
2049dd0: 88 00 c0 0d add %g3, %o5, %g4 <== NOT EXECUTED
2049dd4: 84 20 80 03 sub %g2, %g3, %g2 <== NOT EXECUTED
length -= 12;
2049dd8: b2 06 7f f4 add %i1, -12, %i1 <== NOT EXECUTED
b += ((uint32_t)k[7])<<24;
c += k[8];
c += ((uint32_t)k[9])<<8;
c += ((uint32_t)k[10])<<16;
c += ((uint32_t)k[11])<<24;
mix(a,b,c);
2049ddc: 87 28 e0 13 sll %g3, 0x13, %g3 <== NOT EXECUTED
length -= 12;
k += 12;
2049de0: 82 00 60 0c add %g1, 0xc, %g1 <== NOT EXECUTED
b += ((uint32_t)k[7])<<24;
c += k[8];
c += ((uint32_t)k[9])<<8;
c += ((uint32_t)k[10])<<16;
c += ((uint32_t)k[11])<<24;
mix(a,b,c);
2049de4: 86 13 00 03 or %o4, %g3, %g3 <== NOT EXECUTED
} else { /* need to read the key one byte at a time */
const uint8_t *k = (const uint8_t *)key;
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
2049de8: 80 a6 60 0c cmp %i1, 0xc <== NOT EXECUTED
b += ((uint32_t)k[7])<<24;
c += k[8];
c += ((uint32_t)k[9])<<8;
c += ((uint32_t)k[10])<<16;
c += ((uint32_t)k[11])<<24;
mix(a,b,c);
2049dec: 84 18 c0 02 xor %g3, %g2, %g2 <== NOT EXECUTED
2049df0: 9a 23 40 02 sub %o5, %g2, %o5 <== NOT EXECUTED
2049df4: b1 30 a0 1c srl %g2, 0x1c, %i0 <== NOT EXECUTED
2049df8: 98 00 80 04 add %g2, %g4, %o4 <== NOT EXECUTED
2049dfc: 85 28 a0 04 sll %g2, 4, %g2 <== NOT EXECUTED
2049e00: b0 16 00 02 or %i0, %g2, %i0 <== NOT EXECUTED
} else { /* need to read the key one byte at a time */
const uint8_t *k = (const uint8_t *)key;
/*--------------- all but the last block: affect some 32 bits of (a,b,c) */
while (length > 12)
2049e04: 18 bf ff b9 bgu 2049ce8 <rtems_rfs_dir_hash+0x24> <== NOT EXECUTED
2049e08: b0 1e 00 0d xor %i0, %o5, %i0 <== NOT EXECUTED
length -= 12;
k += 12;
}
/*-------------------------------- last block: affect all 32 bits of (c) */
switch(length) /* all the case statements fall through */
2049e0c: b3 2e 60 02 sll %i1, 2, %i1 <== NOT EXECUTED
2049e10: 05 00 81 27 sethi %hi(0x2049c00), %g2 <== NOT EXECUTED
2049e14: 84 10 a0 90 or %g2, 0x90, %g2 ! 2049c90 <rtems_rfs_buffer_bdbuf_request+0x54><== NOT EXECUTED
2049e18: c4 00 80 19 ld [ %g2 + %i1 ], %g2 <== NOT EXECUTED
2049e1c: 81 c0 80 00 jmp %g2 <== NOT EXECUTED
2049e20: 01 00 00 00 nop <== NOT EXECUTED
{
case 12: c+=((uint32_t)k[11])<<24;
2049e24: c4 08 60 0b ldub [ %g1 + 0xb ], %g2 <== NOT EXECUTED
2049e28: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
2049e2c: b0 06 00 02 add %i0, %g2, %i0 <== NOT EXECUTED
case 11: c+=((uint32_t)k[10])<<16;
2049e30: c4 08 60 0a ldub [ %g1 + 0xa ], %g2 <== NOT EXECUTED
2049e34: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2049e38: b0 06 00 02 add %i0, %g2, %i0 <== NOT EXECUTED
case 10: c+=((uint32_t)k[9])<<8;
2049e3c: c4 08 60 09 ldub [ %g1 + 9 ], %g2 <== NOT EXECUTED
2049e40: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2049e44: b0 06 00 02 add %i0, %g2, %i0 <== NOT EXECUTED
case 9 : c+=k[8];
2049e48: c4 08 60 08 ldub [ %g1 + 8 ], %g2 <== NOT EXECUTED
2049e4c: b0 06 00 02 add %i0, %g2, %i0 <== NOT EXECUTED
case 8 : b+=((uint32_t)k[7])<<24;
2049e50: c4 08 60 07 ldub [ %g1 + 7 ], %g2 <== NOT EXECUTED
2049e54: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
2049e58: 98 03 00 02 add %o4, %g2, %o4 <== NOT EXECUTED
case 7 : b+=((uint32_t)k[6])<<16;
2049e5c: c4 08 60 06 ldub [ %g1 + 6 ], %g2 <== NOT EXECUTED
2049e60: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2049e64: 98 03 00 02 add %o4, %g2, %o4 <== NOT EXECUTED
case 6 : b+=((uint32_t)k[5])<<8;
2049e68: c4 08 60 05 ldub [ %g1 + 5 ], %g2 <== NOT EXECUTED
2049e6c: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2049e70: 98 03 00 02 add %o4, %g2, %o4 <== NOT EXECUTED
case 5 : b+=k[4];
2049e74: c4 08 60 04 ldub [ %g1 + 4 ], %g2 <== NOT EXECUTED
2049e78: 98 03 00 02 add %o4, %g2, %o4 <== NOT EXECUTED
case 4 : a+=((uint32_t)k[3])<<24;
2049e7c: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2049e80: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
2049e84: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
case 3 : a+=((uint32_t)k[2])<<16;
2049e88: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
2049e8c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2049e90: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
case 2 : a+=((uint32_t)k[1])<<8;
2049e94: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
2049e98: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2049e9c: 88 01 00 02 add %g4, %g2, %g4 <== NOT EXECUTED
case 1 : a+=k[0];
2049ea0: c2 08 40 00 ldub [ %g1 ], %g1 <== NOT EXECUTED
break;
case 0 : return c;
}
}
final(a,b,c);
2049ea4: 85 33 20 12 srl %o4, 0x12, %g2 <== NOT EXECUTED
case 6 : b+=((uint32_t)k[5])<<8;
case 5 : b+=k[4];
case 4 : a+=((uint32_t)k[3])<<24;
case 3 : a+=((uint32_t)k[2])<<16;
case 2 : a+=((uint32_t)k[1])<<8;
case 1 : a+=k[0];
2049ea8: 88 01 00 01 add %g4, %g1, %g4 <== NOT EXECUTED
break;
case 0 : return c;
}
}
final(a,b,c);
2049eac: 83 2b 20 0e sll %o4, 0xe, %g1 <== NOT EXECUTED
2049eb0: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2049eb4: b0 1e 00 0c xor %i0, %o4, %i0 <== NOT EXECUTED
2049eb8: b0 26 00 01 sub %i0, %g1, %i0 <== NOT EXECUTED
2049ebc: 85 36 20 15 srl %i0, 0x15, %g2 <== NOT EXECUTED
2049ec0: 83 2e 20 0b sll %i0, 0xb, %g1 <== NOT EXECUTED
2049ec4: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2049ec8: 88 1e 00 04 xor %i0, %g4, %g4 <== NOT EXECUTED
2049ecc: 88 21 00 01 sub %g4, %g1, %g4 <== NOT EXECUTED
2049ed0: 85 31 20 07 srl %g4, 7, %g2 <== NOT EXECUTED
2049ed4: 83 29 20 19 sll %g4, 0x19, %g1 <== NOT EXECUTED
2049ed8: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2049edc: 98 19 00 0c xor %g4, %o4, %o4 <== NOT EXECUTED
2049ee0: 98 23 00 01 sub %o4, %g1, %o4 <== NOT EXECUTED
2049ee4: 85 33 20 10 srl %o4, 0x10, %g2 <== NOT EXECUTED
2049ee8: 83 2b 20 10 sll %o4, 0x10, %g1 <== NOT EXECUTED
2049eec: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2049ef0: b0 1b 00 18 xor %o4, %i0, %i0 <== NOT EXECUTED
2049ef4: b0 26 00 01 sub %i0, %g1, %i0 <== NOT EXECUTED
2049ef8: 85 36 20 1c srl %i0, 0x1c, %g2 <== NOT EXECUTED
2049efc: 83 2e 20 04 sll %i0, 4, %g1 <== NOT EXECUTED
2049f00: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2049f04: 88 1e 00 04 xor %i0, %g4, %g4 <== NOT EXECUTED
2049f08: 88 21 00 01 sub %g4, %g1, %g4 <== NOT EXECUTED
2049f0c: 83 29 20 0e sll %g4, 0xe, %g1 <== NOT EXECUTED
2049f10: 98 19 00 0c xor %g4, %o4, %o4 <== NOT EXECUTED
2049f14: 89 31 20 12 srl %g4, 0x12, %g4 <== NOT EXECUTED
2049f18: 88 11 00 01 or %g4, %g1, %g4 <== NOT EXECUTED
2049f1c: 98 23 00 04 sub %o4, %g4, %o4 <== NOT EXECUTED
2049f20: b0 1b 00 18 xor %o4, %i0, %i0 <== NOT EXECUTED
2049f24: 83 2b 20 18 sll %o4, 0x18, %g1 <== NOT EXECUTED
2049f28: 99 33 20 08 srl %o4, 8, %o4 <== NOT EXECUTED
2049f2c: 98 13 00 01 or %o4, %g1, %o4 <== NOT EXECUTED
2049f30: b0 26 00 0c sub %i0, %o4, %i0 <== NOT EXECUTED
return c;
}
2049f34: 81 c7 e0 08 ret <== NOT EXECUTED
2049f38: 81 e8 00 00 restore <== NOT EXECUTED
020404ac <rtems_rfs_dir_lookup_ino>:
rtems_rfs_inode_handle* inode,
const char* name,
int length,
rtems_rfs_ino* ino,
uint32_t* offset)
{
20404ac: 9d e3 bf 38 save %sp, -200, %sp <== NOT EXECUTED
for (c = 0; c < length; c++)
printf ("%c", name[c]);
printf (", len=%d\n", length);
}
*ino = RTEMS_RFS_EMPTY_INO;
20404b0: c0 27 00 00 clr [ %i4 ] <== NOT EXECUTED
*offset = 0;
rc = rtems_rfs_block_map_open (fs, inode, &map);
20404b4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_inode_handle* inode,
const char* name,
int length,
rtems_rfs_ino* ino,
uint32_t* offset)
{
20404b8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
}
*ino = RTEMS_RFS_EMPTY_INO;
*offset = 0;
rc = rtems_rfs_block_map_open (fs, inode, &map);
20404bc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
printf ("%c", name[c]);
printf (", len=%d\n", length);
}
*ino = RTEMS_RFS_EMPTY_INO;
*offset = 0;
20404c0: c0 27 40 00 clr [ %i5 ] <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, inode, &map);
20404c4: a2 07 bf a0 add %fp, -96, %l1 <== NOT EXECUTED
20404c8: 7f ff fb f7 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
20404cc: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
20404d0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20404d4: 14 80 00 20 bg 2040554 <rtems_rfs_dir_lookup_ino+0xa8> <== NOT EXECUTED
20404d8: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
20404dc: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
20404e0: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
20404e4: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
uint32_t hash;
/*
* Calculate the hash of the look up string.
*/
hash = rtems_rfs_dir_hash (name, length);
20404e8: 40 00 25 f7 call 2049cc4 <rtems_rfs_dir_hash> <== NOT EXECUTED
20404ec: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
/*
* Locate the first block. The map points to the start after open so just
* seek 0. If an error the block will be 0.
*/
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
20404f0: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
uint32_t hash;
/*
* Calculate the hash of the look up string.
*/
hash = rtems_rfs_dir_hash (name, length);
20404f4: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
/*
* Locate the first block. The map points to the start after open so just
* seek 0. If an error the block will be 0.
*/
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
20404f8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20404fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040500: 94 10 20 00 clr %o2 <== NOT EXECUTED
2040504: 96 10 20 00 clr %o3 <== NOT EXECUTED
2040508: 98 10 00 13 mov %l3, %o4 <== NOT EXECUTED
204050c: 7f ff f9 26 call 203e9a4 <rtems_rfs_block_map_seek> <== NOT EXECUTED
2040510: 29 00 00 3f sethi %hi(0xfc00), %l4 <== NOT EXECUTED
ehash = rtems_rfs_dir_entry_hash (entry);
elength = rtems_rfs_dir_entry_length (entry);
*ino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040514: a8 15 23 ff or %l4, 0x3ff, %l4 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
/*
* Locate the first block. The map points to the start after open so just
* seek 0. If an error the block will be 0.
*/
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
if (rc > 0)
2040518: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
204051c: 04 80 00 1b ble 2040588 <rtems_rfs_dir_lookup_ino+0xdc> <== NOT EXECUTED
2040520: aa 07 bf f0 add %fp, -16, %l5 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))
printf ("rtems-rfs: dir-lookup-ino: block map find failed: %d: %s\n",
rc, strerror (rc));
if (rc == ENXIO)
2040524: 80 a6 20 06 cmp %i0, 6 <== NOT EXECUTED
2040528: 22 80 00 02 be,a 2040530 <rtems_rfs_dir_lookup_ino+0x84> <== NOT EXECUTED
204052c: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2040530: 92 07 bf f0 add %fp, -16, %o1 <== NOT EXECUTED
2040534: 7f ff fc b1 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040538: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = ENOENT;
rtems_rfs_buffer_handle_close (fs, &entries);
rtems_rfs_block_map_close (fs, &map);
204053c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
2040540: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2040544: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2040548: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
204054c: 7f ff fb 65 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2040550: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2040554: 81 c7 e0 08 ret <== NOT EXECUTED
2040558: 81 e8 00 00 restore <== NOT EXECUTED
map.bpos.boff += elength;
entry += elength;
}
if (rc == 0)
204055c: c2 07 bf 9c ld [ %fp + -100 ], %g1 <== NOT EXECUTED
2040560: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040564: 12 80 00 65 bne 20406f8 <rtems_rfs_dir_lookup_ino+0x24c> <== NOT EXECUTED
2040568: f0 07 bf 9c ld [ %fp + -100 ], %i0 <== NOT EXECUTED
{
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
204056c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040570: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2040574: 7f ff f8 ff call 203e970 <rtems_rfs_block_map_next_block> <== NOT EXECUTED
2040578: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))
printf ("rtems-rfs: dir-lookup-ino: "
"block map next block failed in ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (inode), rc, strerror (rc));
}
if (rc == ENXIO)
204057c: 80 a2 20 06 cmp %o0, 6 <== NOT EXECUTED
2040580: 02 80 00 66 be 2040718 <rtems_rfs_dir_lookup_ino+0x26c> <== NOT EXECUTED
2040584: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &entries);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
while ((rc == 0) && block)
2040588: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
204058c: 12 80 00 5b bne 20406f8 <rtems_rfs_dir_lookup_ino+0x24c> <== NOT EXECUTED
2040590: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
2040594: 80 a2 a0 00 cmp %o2, 0 <== NOT EXECUTED
2040598: 02 80 00 62 be 2040720 <rtems_rfs_dir_lookup_ino+0x274> <== NOT EXECUTED
204059c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))
printf ("rtems-rfs: dir-lookup-ino: block read, ino=%" PRIu32 " bno=%" PRId32 "\n",
rtems_rfs_inode_ino (inode), map.bpos.bno);
rc = rtems_rfs_buffer_handle_request (fs, &entries, block, true);
20405a0: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20405a4: 7f ff fc de call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
20405a8: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
20405ac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20405b0: 14 80 00 51 bg 20406f4 <rtems_rfs_dir_lookup_ino+0x248> <== NOT EXECUTED
20405b4: d0 27 bf 9c st %o0, [ %fp + -100 ] <== NOT EXECUTED
entry = rtems_rfs_buffer_data (&entries);
map.bpos.boff = 0;
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
20405b8: f2 04 20 08 ld [ %l0 + 8 ], %i1 <== NOT EXECUTED
/*
* Search the block to see if the name matches. A hash of 0xffff or 0x0
* means the entry is empty.
*/
entry = rtems_rfs_buffer_data (&entries);
20405bc: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
map.bpos.boff = 0;
20405c0: c0 27 bf b4 clr [ %fp + -76 ] <== NOT EXECUTED
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
20405c4: 80 a6 60 0a cmp %i1, 0xa <== NOT EXECUTED
20405c8: 02 bf ff e5 be 204055c <rtems_rfs_dir_lookup_ino+0xb0> <== NOT EXECUTED
20405cc: ec 00 60 24 ld [ %g1 + 0x24 ], %l6 <== NOT EXECUTED
20405d0: 10 80 00 07 b 20405ec <rtems_rfs_dir_lookup_ino+0x140> <== NOT EXECUTED
20405d4: b2 06 7f f6 add %i1, -10, %i1 <== NOT EXECUTED
return 0;
}
}
map.bpos.boff += elength;
entry += elength;
20405d8: ac 05 80 17 add %l6, %l7, %l6 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
return 0;
}
}
map.bpos.boff += elength;
20405dc: ae 05 c0 01 add %l7, %g1, %l7 <== NOT EXECUTED
entry = rtems_rfs_buffer_data (&entries);
map.bpos.boff = 0;
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
20405e0: 80 a6 40 17 cmp %i1, %l7 <== NOT EXECUTED
20405e4: 08 bf ff de bleu 204055c <rtems_rfs_dir_lookup_ino+0xb0> <== NOT EXECUTED
20405e8: ee 27 bf b4 st %l7, [ %fp + -76 ] <== NOT EXECUTED
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
elength = rtems_rfs_dir_entry_length (entry);
*ino = rtems_rfs_dir_entry_ino (entry);
20405ec: c8 0d a0 01 ldub [ %l6 + 1 ], %g4 <== NOT EXECUTED
20405f0: c6 0d a0 02 ldub [ %l6 + 2 ], %g3 <== NOT EXECUTED
20405f4: da 0d a0 03 ldub [ %l6 + 3 ], %o5 <== NOT EXECUTED
20405f8: c2 0d 80 00 ldub [ %l6 ], %g1 <== NOT EXECUTED
{
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
elength = rtems_rfs_dir_entry_length (entry);
20405fc: ee 0d a0 08 ldub [ %l6 + 8 ], %l7 <== NOT EXECUTED
2040600: c4 0d a0 09 ldub [ %l6 + 9 ], %g2 <== NOT EXECUTED
*ino = rtems_rfs_dir_entry_ino (entry);
2040604: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
2040608: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
204060c: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
2040610: d8 0d a0 07 ldub [ %l6 + 7 ], %o4 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
*ino = rtems_rfs_dir_entry_ino (entry);
2040614: 82 13 40 01 or %o5, %g1, %g1 <== NOT EXECUTED
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
2040618: da 0d a0 06 ldub [ %l6 + 6 ], %o5 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
*ino = rtems_rfs_dir_entry_ino (entry);
204061c: 82 10 40 04 or %g1, %g4, %g1 <== NOT EXECUTED
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
2040620: c8 0d a0 05 ldub [ %l6 + 5 ], %g4 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
*ino = rtems_rfs_dir_entry_ino (entry);
2040624: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
{
uint32_t ehash;
int elength;
ehash = rtems_rfs_dir_entry_hash (entry);
2040628: c6 0d a0 04 ldub [ %l6 + 4 ], %g3 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
204062c: af 2d e0 08 sll %l7, 8, %l7 <== NOT EXECUTED
2040630: ae 15 c0 02 or %l7, %g2, %l7 <== NOT EXECUTED
*ino = rtems_rfs_dir_entry_ino (entry);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2040634: 80 a5 c0 14 cmp %l7, %l4 <== NOT EXECUTED
2040638: 02 bf ff c9 be 204055c <rtems_rfs_dir_lookup_ino+0xb0> <== NOT EXECUTED
204063c: c2 27 00 00 st %g1, [ %i4 ] <== NOT EXECUTED
break;
if (rtems_rfs_dir_entry_valid (fs, elength, *ino))
2040640: 80 a5 e0 0a cmp %l7, 0xa <== NOT EXECUTED
2040644: 24 80 00 2b ble,a 20406f0 <rtems_rfs_dir_lookup_ino+0x244><== NOT EXECUTED
2040648: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
204064c: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 <== NOT EXECUTED
2040650: 80 a5 c0 02 cmp %l7, %g2 <== NOT EXECUTED
2040654: 1a 80 00 26 bcc 20406ec <rtems_rfs_dir_lookup_ino+0x240> <== NOT EXECUTED
2040658: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
204065c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040660: 22 80 00 24 be,a 20406f0 <rtems_rfs_dir_lookup_ino+0x244><== NOT EXECUTED
2040664: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2040668: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
204066c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2040670: 18 80 00 1f bgu 20406ec <rtems_rfs_dir_lookup_ino+0x240> <== NOT EXECUTED
2040674: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
rtems_rfs_inode_ino (inode), elength, *ino, map.bpos.boff);
rc = EIO;
break;
}
if (ehash == hash)
2040678: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
204067c: 98 0b 20 ff and %o4, 0xff, %o4 <== NOT EXECUTED
2040680: 86 10 c0 04 or %g3, %g4, %g3 <== NOT EXECUTED
2040684: 9a 0b 60 ff and %o5, 0xff, %o5 <== NOT EXECUTED
2040688: 86 10 c0 0c or %g3, %o4, %g3 <== NOT EXECUTED
204068c: 9b 2b 60 08 sll %o5, 8, %o5 <== NOT EXECUTED
2040690: 86 10 c0 0d or %g3, %o5, %g3 <== NOT EXECUTED
2040694: 80 a4 80 03 cmp %l2, %g3 <== NOT EXECUTED
2040698: 12 bf ff d0 bne 20405d8 <rtems_rfs_dir_lookup_ino+0x12c> <== NOT EXECUTED
204069c: c2 07 bf b4 ld [ %fp + -76 ], %g1 <== NOT EXECUTED
"checking entry for ino %" PRId32 ": bno=%04" PRIx32 "/off=%04" PRIx32
" length:%d ino:%" PRId32 "\n",
rtems_rfs_inode_ino (inode), map.bpos.bno, map.bpos.boff,
elength, rtems_rfs_dir_entry_ino (entry));
if (memcmp (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length) == 0)
20406a0: 90 05 a0 0a add %l6, 0xa, %o0 <== NOT EXECUTED
20406a4: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
20406a8: 40 00 34 91 call 204d8ec <memcmp> <== NOT EXECUTED
20406ac: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
20406b0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20406b4: 12 bf ff c9 bne 20405d8 <rtems_rfs_dir_lookup_ino+0x12c> <== NOT EXECUTED
20406b8: c2 07 bf b4 ld [ %fp + -76 ], %g1 <== NOT EXECUTED
{
*offset = rtems_rfs_block_map_pos (fs, &map);
20406bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20406c0: 7f ff f7 f3 call 203e68c <rtems_rfs_block_get_pos> <== NOT EXECUTED
20406c4: 92 07 bf b0 add %fp, -80, %o1 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_FOUND))
printf ("rtems-rfs: dir-lookup-ino: "
"entry found in ino %" PRIu32 ", ino=%" PRIu32 " offset=%" PRIu32 "\n",
rtems_rfs_inode_ino (inode), *ino, *offset);
rtems_rfs_buffer_handle_close (fs, &entries);
20406c8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_ino (inode), map.bpos.bno, map.bpos.boff,
elength, rtems_rfs_dir_entry_ino (entry));
if (memcmp (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length) == 0)
{
*offset = rtems_rfs_block_map_pos (fs, &map);
20406cc: d2 27 40 00 st %o1, [ %i5 ] <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_FOUND))
printf ("rtems-rfs: dir-lookup-ino: "
"entry found in ino %" PRIu32 ", ino=%" PRIu32 " offset=%" PRIu32 "\n",
rtems_rfs_inode_ino (inode), *ino, *offset);
rtems_rfs_buffer_handle_close (fs, &entries);
20406d0: 7f ff fd 22 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
20406d4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
20406d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20406dc: 7f ff fb 01 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
20406e0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return 0;
20406e4: 81 c7 e0 08 ret <== NOT EXECUTED
20406e8: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &entries);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
while ((rc == 0) && block)
20406ec: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20406f0: c2 27 bf 9c st %g1, [ %fp + -100 ] <== NOT EXECUTED
20406f4: f0 07 bf 9c ld [ %fp + -100 ], %i0 <== NOT EXECUTED
printf ("rtems-rfs: dir-lookup-ino: block is 0 in ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (inode), rc, strerror (rc));
}
}
rtems_rfs_buffer_handle_close (fs, &entries);
20406f8: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20406fc: 7f ff fd 17 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2040700: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
2040704: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040708: 7f ff fa f6 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
204070c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
2040710: 81 c7 e0 08 ret <== NOT EXECUTED
2040714: 81 e8 00 00 restore <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))
printf ("rtems-rfs: dir-lookup-ino: "
"block map next block failed in ino %" PRIu32 ": %d: %s\n",
rtems_rfs_inode_ino (inode), rc, strerror (rc));
}
if (rc == ENXIO)
2040718: 10 bf ff f8 b 20406f8 <rtems_rfs_dir_lookup_ino+0x24c> <== NOT EXECUTED
204071c: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &entries);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
while ((rc == 0) && block)
2040720: 10 bf ff f6 b 20406f8 <rtems_rfs_dir_lookup_ino+0x24c> <== NOT EXECUTED
2040724: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
0203fb80 <rtems_rfs_dir_read>:
rtems_rfs_dir_read (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
rtems_rfs_pos_rel offset,
struct dirent* dirent,
size_t* length)
{
203fb80: 9d e3 bf 38 save %sp, -200, %sp <== NOT EXECUTED
printf ("rtems-rfs: dir-read: dir=%" PRId32 " offset=%" PRId64 "\n",
rtems_rfs_inode_ino (dir), offset);
*length = 0;
rc = rtems_rfs_block_map_open (fs, dir, &map);
203fb84: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_dir_read (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* dir,
rtems_rfs_pos_rel offset,
struct dirent* dirent,
size_t* length)
{
203fb88: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
printf ("rtems-rfs: dir-read: dir=%" PRId32 " offset=%" PRId64 "\n",
rtems_rfs_inode_ino (dir), offset);
*length = 0;
rc = rtems_rfs_block_map_open (fs, dir, &map);
203fb8c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-read: dir=%" PRId32 " offset=%" PRId64 "\n",
rtems_rfs_inode_ino (dir), offset);
*length = 0;
203fb90: c0 27 40 00 clr [ %i5 ] <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, dir, &map);
203fb94: a2 07 bf a0 add %fp, -96, %l1 <== NOT EXECUTED
203fb98: 7f ff fe 43 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
203fb9c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
203fba0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203fba4: 24 80 00 04 ble,a 203fbb4 <rtems_rfs_dir_read+0x34> <== NOT EXECUTED
203fba8: e4 04 20 08 ld [ %l0 + 8 ], %l2 <== NOT EXECUTED
}
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
203fbac: 81 c7 e0 08 ret <== NOT EXECUTED
203fbb0: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, dir, &map);
if (rc > 0)
return rc;
if (((rtems_rfs_fs_block_size (fs) -
203fbb4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
(offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
203fbb8: a6 10 00 12 mov %l2, %l3 <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, dir, &map);
if (rc > 0)
return rc;
if (((rtems_rfs_fs_block_size (fs) -
203fbbc: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
(offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
203fbc0: a4 10 20 00 clr %l2 <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, dir, &map);
if (rc > 0)
return rc;
if (((rtems_rfs_fs_block_size (fs) -
203fbc4: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203fbc8: 40 00 8e 14 call 2063418 <__moddi3> <== NOT EXECUTED
203fbcc: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
203fbd0: 86 a4 c0 09 subcc %l3, %o1, %g3 <== NOT EXECUTED
203fbd4: 84 64 80 08 subx %l2, %o0, %g2 <== NOT EXECUTED
203fbd8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
203fbdc: 04 80 00 12 ble 203fc24 <rtems_rfs_dir_read+0xa4> <== NOT EXECUTED
203fbe0: 01 00 00 00 nop <== NOT EXECUTED
(offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
offset = (((offset / rtems_rfs_fs_block_size (fs)) + 1) *
rtems_rfs_fs_block_size (fs));
rc = rtems_rfs_block_map_seek (fs, &map, offset, &block);
203fbe4: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
203fbe8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203fbec: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
203fbf0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
203fbf4: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
203fbf8: 7f ff fb 6b call 203e9a4 <rtems_rfs_block_map_seek> <== NOT EXECUTED
203fbfc: 98 10 00 12 mov %l2, %o4 <== NOT EXECUTED
if (rc > 0)
203fc00: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
203fc04: 04 80 00 1f ble 203fc80 <rtems_rfs_dir_read+0x100> <== NOT EXECUTED
203fc08: 80 a6 20 06 cmp %i0, 6 <== NOT EXECUTED
{
if (rc == ENXIO)
203fc0c: 02 80 00 18 be 203fc6c <rtems_rfs_dir_read+0xec> <== NOT EXECUTED
203fc10: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
203fc14: 7f ff fd b3 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
203fc18: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
203fc1c: 81 c7 e0 08 ret <== NOT EXECUTED
203fc20: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_block_map_open (fs, dir, &map);
if (rc > 0)
return rc;
if (((rtems_rfs_fs_block_size (fs) -
203fc24: 12 80 00 06 bne 203fc3c <rtems_rfs_dir_read+0xbc> <== NOT EXECUTED
203fc28: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
203fc2c: 80 a0 e0 0a cmp %g3, 0xa <== NOT EXECUTED
203fc30: 38 bf ff ee bgu,a 203fbe8 <rtems_rfs_dir_read+0x68> <== NOT EXECUTED
203fc34: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
(offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
offset = (((offset / rtems_rfs_fs_block_size (fs)) + 1) *
203fc38: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
203fc3c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
203fc40: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
203fc44: 40 00 8d 0e call 206307c <__divdi3> <== NOT EXECUTED
203fc48: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203fc4c: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
203fc50: 92 82 60 01 inccc %o1 <== NOT EXECUTED
203fc54: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED
203fc58: 40 00 8c a3 call 2062ee4 <__muldi3> <== NOT EXECUTED
203fc5c: 90 42 20 00 addx %o0, 0, %o0 <== NOT EXECUTED
203fc60: b4 10 00 08 mov %o0, %i2 <== NOT EXECUTED
203fc64: 10 bf ff e0 b 203fbe4 <rtems_rfs_dir_read+0x64> <== NOT EXECUTED
203fc68: b6 10 00 09 mov %o1, %i3 <== NOT EXECUTED
rtems_rfs_fs_block_size (fs));
rc = rtems_rfs_block_map_seek (fs, &map, offset, &block);
if (rc > 0)
{
if (rc == ENXIO)
203fc6c: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
203fc70: 7f ff fd 9c call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
203fc74: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
203fc78: 81 c7 e0 08 ret <== NOT EXECUTED
203fc7c: 81 e8 00 00 restore <== NOT EXECUTED
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)
203fc80: 29 00 00 3f sethi %hi(0xfc00), %l4 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
203fc84: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
203fc88: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
203fc8c: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
203fc90: a8 15 23 ff or %l4, 0x3ff, %l4 <== NOT EXECUTED
203fc94: 10 80 00 05 b 203fca8 <rtems_rfs_dir_read+0x128> <== NOT EXECUTED
203fc98: a6 07 bf f0 add %fp, -16, %l3 <== NOT EXECUTED
/*
* Look for an empty entry and if this is the last block that is the end of
* the directory.
*/
while (rc == 0)
203fc9c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203fca0: 12 80 00 2f bne 203fd5c <rtems_rfs_dir_read+0x1dc> <== NOT EXECUTED
203fca4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
uint8_t* entry;
rtems_rfs_ino eino;
int elength;
int remaining;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
203fca8: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
203fcac: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
203fcb0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
203fcb4: 7f ff ff 1a call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
203fcb8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
offset, *length);
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
203fcbc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
uint8_t* entry;
rtems_rfs_ino eino;
int elength;
int remaining;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
203fcc0: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
offset, *length);
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
203fcc4: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int remaining;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
203fcc8: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203fccc: 14 80 00 2b bg 203fd78 <rtems_rfs_dir_read+0x1f8> <== NOT EXECUTED
203fcd0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
entry = rtems_rfs_buffer_data (&buffer);
203fcd4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
entry += map.bpos.boff;
203fcd8: c4 07 bf b4 ld [ %fp + -76 ], %g2 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_block_map_close (fs, &map);
return rc;
}
entry = rtems_rfs_buffer_data (&buffer);
203fcdc: ea 00 60 24 ld [ %g1 + 0x24 ], %l5 <== NOT EXECUTED
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
203fce0: c6 0d 40 02 ldub [ %l5 + %g2 ], %g3 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
return rc;
}
entry = rtems_rfs_buffer_data (&buffer);
entry += map.bpos.boff;
203fce4: aa 05 40 02 add %l5, %g2, %l5 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
203fce8: c2 0d 60 02 ldub [ %l5 + 2 ], %g1 <== NOT EXECUTED
}
entry = rtems_rfs_buffer_data (&buffer);
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
203fcec: ec 0d 60 08 ldub [ %l5 + 8 ], %l6 <== NOT EXECUTED
203fcf0: d8 0d 60 09 ldub [ %l5 + 9 ], %o4 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203fcf4: da 0d 60 03 ldub [ %l5 + 3 ], %o5 <== NOT EXECUTED
203fcf8: c8 0d 60 01 ldub [ %l5 + 1 ], %g4 <== NOT EXECUTED
203fcfc: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
}
entry = rtems_rfs_buffer_data (&buffer);
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
203fd00: ad 2d a0 08 sll %l6, 8, %l6 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203fd04: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
}
entry = rtems_rfs_buffer_data (&buffer);
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
203fd08: ac 15 80 0c or %l6, %o4, %l6 <== NOT EXECUTED
eino = rtems_rfs_dir_entry_ino (entry);
203fd0c: 86 13 40 03 or %o5, %g3, %g3 <== NOT EXECUTED
203fd10: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)
203fd14: 80 a5 80 14 cmp %l6, %l4 <== NOT EXECUTED
entry = rtems_rfs_buffer_data (&buffer);
entry += map.bpos.boff;
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
203fd18: 86 10 c0 04 or %g3, %g4, %g3 <== NOT EXECUTED
203fd1c: ae 05 60 02 add %l5, 2, %l7 <== NOT EXECUTED
203fd20: 86 10 c0 01 or %g3, %g1, %g3 <== NOT EXECUTED
203fd24: b2 05 60 03 add %l5, 3, %i1 <== NOT EXECUTED
if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)
203fd28: 12 80 00 18 bne 203fd88 <rtems_rfs_dir_read+0x208> <== NOT EXECUTED
203fd2c: 82 05 60 01 add %l5, 1, %g1 <== NOT EXECUTED
printf ("rtems-rfs: dir-read: found off:%" PRIdoff_t " ino:%ld name=%s\n",
dirent->d_off, dirent->d_ino, dirent->d_name);
break;
}
*length += rtems_rfs_fs_block_size (fs) - map.bpos.boff;
203fd30: c6 04 20 08 ld [ %l0 + 8 ], %g3 <== NOT EXECUTED
203fd34: c2 07 40 00 ld [ %i5 ], %g1 <== NOT EXECUTED
203fd38: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
203fd3c: 84 00 40 02 add %g1, %g2, %g2 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
offset, *length);
rc = rtems_rfs_block_map_next_block (fs, &map, &block);
203fd40: 7f ff fb 0c call 203e970 <rtems_rfs_block_map_next_block> <== NOT EXECUTED
203fd44: c4 27 40 00 st %g2, [ %i5 ] <== NOT EXECUTED
if (rc == ENXIO)
203fd48: 80 a2 20 06 cmp %o0, 6 <== NOT EXECUTED
203fd4c: 12 bf ff d4 bne 203fc9c <rtems_rfs_dir_read+0x11c> <== NOT EXECUTED
203fd50: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
203fd54: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
rc = ENOENT;
}
rtems_rfs_buffer_handle_close (fs, &buffer);
203fd58: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
203fd5c: 7f ff ff 7f call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
203fd60: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
203fd64: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
203fd68: 7f ff fd 5e call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
203fd6c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
203fd70: 81 c7 e0 08 ret <== NOT EXECUTED
203fd74: 81 e8 00 00 restore <== NOT EXECUTED
int remaining;
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &buffer);
203fd78: 7f ff ff 78 call 203fb58 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
203fd7c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
203fd80: 10 bf ff a5 b 203fc14 <rtems_rfs_dir_read+0x94> <== NOT EXECUTED
203fd84: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)
{
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
203fd88: 80 a5 a0 0a cmp %l6, 0xa <== NOT EXECUTED
203fd8c: 34 80 00 04 bg,a 203fd9c <rtems_rfs_dir_read+0x21c> <== NOT EXECUTED
203fd90: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 <== NOT EXECUTED
/*
* Look for an empty entry and if this is the last block that is the end of
* the directory.
*/
while (rc == 0)
203fd94: 10 bf ff f1 b 203fd58 <rtems_rfs_dir_read+0x1d8> <== NOT EXECUTED
203fd98: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (entry);
eino = rtems_rfs_dir_entry_ino (entry);
if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)
{
if (rtems_rfs_dir_entry_valid (fs, elength, eino))
203fd9c: 80 a5 80 02 cmp %l6, %g2 <== NOT EXECUTED
203fda0: 3a bf ff ee bcc,a 203fd58 <rtems_rfs_dir_read+0x1d8> <== NOT EXECUTED
203fda4: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
203fda8: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
203fdac: 22 bf ff eb be,a 203fd58 <rtems_rfs_dir_read+0x1d8> <== NOT EXECUTED
203fdb0: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
203fdb4: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
203fdb8: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
203fdbc: 38 bf ff e7 bgu,a 203fd58 <rtems_rfs_dir_read+0x1d8> <== NOT EXECUTED
203fdc0: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
rtems_rfs_inode_ino (dir), elength, eino, map.bpos.boff);
rc = EIO;
break;
}
memset (dirent, 0, sizeof (struct dirent));
203fdc4: c2 27 bf 9c st %g1, [ %fp + -100 ] <== NOT EXECUTED
203fdc8: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
203fdcc: 92 10 20 00 clr %o1 <== NOT EXECUTED
203fdd0: 40 00 37 8b call 204dbfc <memset> <== NOT EXECUTED
203fdd4: 94 10 21 18 mov 0x118, %o2 <== NOT EXECUTED
dirent->d_off = offset;
dirent->d_reclen = sizeof (struct dirent);
*length += elength;
203fdd8: c4 07 40 00 ld [ %i5 ], %g2 <== NOT EXECUTED
rtems_rfs_inode_ino (dir), elength, eino, map.bpos.boff);
rc = EIO;
break;
}
memset (dirent, 0, sizeof (struct dirent));
203fddc: 86 10 21 18 mov 0x118, %g3 <== NOT EXECUTED
dirent->d_off = offset;
dirent->d_reclen = sizeof (struct dirent);
*length += elength;
203fde0: 84 05 80 02 add %l6, %g2, %g2 <== NOT EXECUTED
break;
}
memset (dirent, 0, sizeof (struct dirent));
dirent->d_off = offset;
dirent->d_reclen = sizeof (struct dirent);
203fde4: c6 37 20 10 sth %g3, [ %i4 + 0x10 ] <== NOT EXECUTED
*length += elength;
203fde8: c4 27 40 00 st %g2, [ %i5 ] <== NOT EXECUTED
remaining = rtems_rfs_fs_block_size (fs) - (map.bpos.boff + elength);
203fdec: c6 07 bf b4 ld [ %fp + -76 ], %g3 <== NOT EXECUTED
203fdf0: c8 04 20 08 ld [ %l0 + 8 ], %g4 <== NOT EXECUTED
rc = EIO;
break;
}
memset (dirent, 0, sizeof (struct dirent));
dirent->d_off = offset;
203fdf4: f4 3f 20 08 std %i2, [ %i4 + 8 ] <== NOT EXECUTED
dirent->d_reclen = sizeof (struct dirent);
*length += elength;
remaining = rtems_rfs_fs_block_size (fs) - (map.bpos.boff + elength);
203fdf8: 86 21 00 03 sub %g4, %g3, %g3 <== NOT EXECUTED
203fdfc: 86 20 c0 16 sub %g3, %l6, %g3 <== NOT EXECUTED
if (remaining <= RTEMS_RFS_DIR_ENTRY_SIZE)
203fe00: 80 a0 e0 0a cmp %g3, 0xa <== NOT EXECUTED
203fe04: 14 80 00 04 bg 203fe14 <rtems_rfs_dir_read+0x294> <== NOT EXECUTED
203fe08: c2 07 bf 9c ld [ %fp + -100 ], %g1 <== NOT EXECUTED
*length += remaining;
203fe0c: 84 00 c0 02 add %g3, %g2, %g2 <== NOT EXECUTED
203fe10: c4 27 40 00 st %g2, [ %i5 ] <== NOT EXECUTED
elength -= RTEMS_RFS_DIR_ENTRY_SIZE;
203fe14: ac 05 bf f6 add %l6, -10, %l6 <== NOT EXECUTED
203fe18: 80 a5 a0 ff cmp %l6, 0xff <== NOT EXECUTED
203fe1c: 34 80 00 02 bg,a 203fe24 <rtems_rfs_dir_read+0x2a4> <== NOT EXECUTED
203fe20: ac 10 20 ff mov 0xff, %l6 <== NOT EXECUTED
if (elength > NAME_MAX)
elength = NAME_MAX;
memcpy (dirent->d_name, entry + RTEMS_RFS_DIR_ENTRY_SIZE, elength);
203fe24: c2 27 bf 9c st %g1, [ %fp + -100 ] <== NOT EXECUTED
203fe28: 90 07 20 14 add %i4, 0x14, %o0 <== NOT EXECUTED
203fe2c: 92 05 60 0a add %l5, 0xa, %o1 <== NOT EXECUTED
203fe30: 40 00 36 e0 call 204d9b0 <memcpy> <== NOT EXECUTED
203fe34: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
dirent->d_ino = rtems_rfs_dir_entry_ino (entry);
203fe38: c2 07 bf 9c ld [ %fp + -100 ], %g1 <== NOT EXECUTED
203fe3c: c8 0d 40 00 ldub [ %l5 ], %g4 <== NOT EXECUTED
203fe40: c6 08 40 00 ldub [ %g1 ], %g3 <== NOT EXECUTED
203fe44: c4 0e 40 00 ldub [ %i1 ], %g2 <== NOT EXECUTED
203fe48: c2 0d c0 00 ldub [ %l7 ], %g1 <== NOT EXECUTED
203fe4c: 89 29 20 18 sll %g4, 0x18, %g4 <== NOT EXECUTED
203fe50: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
203fe54: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
203fe58: 86 11 00 03 or %g4, %g3, %g3 <== NOT EXECUTED
dirent->d_namlen = elength;
203fe5c: ec 37 20 12 sth %l6, [ %i4 + 0x12 ] <== NOT EXECUTED
if (elength > NAME_MAX)
elength = NAME_MAX;
memcpy (dirent->d_name, entry + RTEMS_RFS_DIR_ENTRY_SIZE, elength);
dirent->d_ino = rtems_rfs_dir_entry_ino (entry);
203fe60: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
203fe64: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
dirent->d_namlen = elength;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))
printf ("rtems-rfs: dir-read: found off:%" PRIdoff_t " ino:%ld name=%s\n",
dirent->d_off, dirent->d_ino, dirent->d_name);
break;
203fe68: 10 bf ff bc b 203fd58 <rtems_rfs_dir_read+0x1d8> <== NOT EXECUTED
203fe6c: c2 27 00 00 st %g1, [ %i4 ] <== NOT EXECUTED
02041160 <rtems_rfs_file_close>:
}
int
rtems_rfs_file_close (rtems_rfs_file_system* fs,
rtems_rfs_file_handle* handle)
{
2041160: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))
printf ("rtems-rfs: file-close: entry: ino=%" PRId32 "\n",
handle->shared->inode.ino);
if (handle->shared->references > 0)
2041164: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
2041168: c2 02 60 08 ld [ %o1 + 8 ], %g1 <== NOT EXECUTED
204116c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041170: 04 80 00 04 ble 2041180 <rtems_rfs_file_close+0x20> <== NOT EXECUTED
2041174: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
handle->shared->references--;
2041178: c2 22 60 08 st %g1, [ %o1 + 8 ] <== NOT EXECUTED
if (handle->shared->references == 0)
204117c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041180: 12 80 00 51 bne 20412c4 <rtems_rfs_file_close+0x164> <== NOT EXECUTED
2041184: a0 10 20 00 clr %l0 <== NOT EXECUTED
{
if (!rtems_rfs_inode_is_loaded (&handle->shared->inode))
2041188: c2 02 60 18 ld [ %o1 + 0x18 ], %g1 <== NOT EXECUTED
204118c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041190: 22 80 00 5f be,a 204130c <rtems_rfs_file_close+0x1ac> <== NOT EXECUTED
2041194: 92 02 60 0c add %o1, 0xc, %o1 <== NOT EXECUTED
if (rrc == 0)
{
/*
* @todo This could be clever and only update if different.
*/
rtems_rfs_inode_set_atime (&handle->shared->inode,
2041198: c4 02 60 8c ld [ %o1 + 0x8c ], %g2 <== NOT EXECUTED
static inline void
rtems_rfs_inode_set_atime (rtems_rfs_inode_handle* handle,
rtems_rfs_time atime)
{
rtems_rfs_write_u32 (&handle->node->atime, atime);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
204119c: 86 10 20 01 mov 1, %g3 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_atime (rtems_rfs_inode_handle* handle,
rtems_rfs_time atime)
{
rtems_rfs_write_u32 (&handle->node->atime, atime);
20411a0: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
20411a4: c8 28 60 10 stb %g4, [ %g1 + 0x10 ] <== NOT EXECUTED
20411a8: c2 02 60 18 ld [ %o1 + 0x18 ], %g1 <== NOT EXECUTED
20411ac: 89 30 a0 10 srl %g2, 0x10, %g4 <== NOT EXECUTED
20411b0: c8 28 60 11 stb %g4, [ %g1 + 0x11 ] <== NOT EXECUTED
20411b4: c2 02 60 18 ld [ %o1 + 0x18 ], %g1 <== NOT EXECUTED
20411b8: 89 30 a0 08 srl %g2, 8, %g4 <== NOT EXECUTED
20411bc: c8 28 60 12 stb %g4, [ %g1 + 0x12 ] <== NOT EXECUTED
20411c0: c2 02 60 18 ld [ %o1 + 0x18 ], %g1 <== NOT EXECUTED
20411c4: c4 28 60 13 stb %g2, [ %g1 + 0x13 ] <== NOT EXECUTED
handle->shared->atime);
rtems_rfs_inode_set_mtime (&handle->shared->inode,
20411c8: c4 06 60 1c ld [ %i1 + 0x1c ], %g2 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20411cc: c6 2a 60 1c stb %g3, [ %o1 + 0x1c ] <== NOT EXECUTED
20411d0: c2 00 a0 90 ld [ %g2 + 0x90 ], %g1 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_mtime (rtems_rfs_inode_handle* handle,
rtems_rfs_time mtime)
{
rtems_rfs_write_u32 (&handle->node->mtime, mtime);
20411d4: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4 <== NOT EXECUTED
20411d8: 9b 30 60 18 srl %g1, 0x18, %o5 <== NOT EXECUTED
20411dc: da 29 20 14 stb %o5, [ %g4 + 0x14 ] <== NOT EXECUTED
20411e0: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4 <== NOT EXECUTED
20411e4: 9b 30 60 10 srl %g1, 0x10, %o5 <== NOT EXECUTED
20411e8: da 29 20 15 stb %o5, [ %g4 + 0x15 ] <== NOT EXECUTED
20411ec: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4 <== NOT EXECUTED
20411f0: 9b 30 60 08 srl %g1, 8, %o5 <== NOT EXECUTED
20411f4: da 29 20 16 stb %o5, [ %g4 + 0x16 ] <== NOT EXECUTED
20411f8: c8 00 a0 18 ld [ %g2 + 0x18 ], %g4 <== NOT EXECUTED
20411fc: c2 29 20 17 stb %g1, [ %g4 + 0x17 ] <== NOT EXECUTED
handle->shared->mtime);
rtems_rfs_inode_set_ctime (&handle->shared->inode,
2041200: c2 06 60 1c ld [ %i1 + 0x1c ], %g1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2041204: c6 28 a0 1c stb %g3, [ %g2 + 0x1c ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_ctime (rtems_rfs_inode_handle* handle,
rtems_rfs_time ctime)
{
rtems_rfs_write_u32 (&handle->node->ctime, ctime);
2041208: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 <== NOT EXECUTED
204120c: c4 00 60 94 ld [ %g1 + 0x94 ], %g2 <== NOT EXECUTED
2041210: 9b 30 a0 18 srl %g2, 0x18, %o5 <== NOT EXECUTED
2041214: da 29 20 18 stb %o5, [ %g4 + 0x18 ] <== NOT EXECUTED
2041218: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 <== NOT EXECUTED
204121c: 9b 30 a0 10 srl %g2, 0x10, %o5 <== NOT EXECUTED
2041220: da 29 20 19 stb %o5, [ %g4 + 0x19 ] <== NOT EXECUTED
2041224: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 <== NOT EXECUTED
2041228: 9b 30 a0 08 srl %g2, 8, %o5 <== NOT EXECUTED
204122c: da 29 20 1a stb %o5, [ %g4 + 0x1a ] <== NOT EXECUTED
2041230: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 <== NOT EXECUTED
2041234: c4 29 20 1b stb %g2, [ %g4 + 0x1b ] <== NOT EXECUTED
handle->shared->ctime);
if (!rtems_rfs_block_size_equal (&handle->shared->size,
2041238: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
204123c: c6 28 60 1c stb %g3, [ %g1 + 0x1c ] <== NOT EXECUTED
2041240: c4 02 60 84 ld [ %o1 + 0x84 ], %g2 <== NOT EXECUTED
2041244: c6 02 60 3c ld [ %o1 + 0x3c ], %g3 <== NOT EXECUTED
2041248: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
204124c: 02 80 00 29 be 20412f0 <rtems_rfs_file_close+0x190> <== NOT EXECUTED
2041250: 82 10 00 09 mov %o1, %g1 <== NOT EXECUTED
2041254: c6 02 60 88 ld [ %o1 + 0x88 ], %g3 <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size (rtems_rfs_block_map* map,
rtems_rfs_block_size* size)
{
rtems_rfs_block_copy_size (&map->size, size);
2041258: c4 20 60 3c st %g2, [ %g1 + 0x3c ] <== NOT EXECUTED
204125c: c6 20 60 40 st %g3, [ %g1 + 0x40 ] <== NOT EXECUTED
map->dirty = true;
2041260: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2041264: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
2041268: c4 28 60 34 stb %g2, [ %g1 + 0x34 ] <== NOT EXECUTED
204126c: a0 10 20 00 clr %l0 <== NOT EXECUTED
&handle->shared->map.size))
rtems_rfs_block_map_set_size (&handle->shared->map,
&handle->shared->size);
}
rc = rtems_rfs_block_map_close (fs, &handle->shared->map);
2041270: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
2041274: 7f ff f8 1b call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2041278: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
204127c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041280: 04 80 00 04 ble 2041290 <rtems_rfs_file_close+0x130> <== NOT EXECUTED
2041284: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))
printf ("rtems-rfs: file-close: map close error: ino=%" PRId32 ": %d: %s\n",
handle->shared->inode.ino, rc, strerror (rc));
if (rrc == 0)
2041288: 22 80 00 02 be,a 2041290 <rtems_rfs_file_close+0x130> <== NOT EXECUTED
204128c: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
rrc = rc;
}
rc = rtems_rfs_inode_close (fs, &handle->shared->inode);
2041290: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
2041294: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041298: 40 00 08 5d call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
204129c: 92 02 60 0c add %o1, 0xc, %o1 <== NOT EXECUTED
if (rc > 0)
20412a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20412a4: 04 80 00 04 ble 20412b4 <rtems_rfs_file_close+0x154> <== NOT EXECUTED
20412a8: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))
printf ("rtems-rfs: file-close: inode close error: ino=%" PRId32 ": %d: %s\n",
handle->shared->inode.ino, rc, strerror (rc));
if (rrc == 0)
20412ac: 22 80 00 02 be,a 20412b4 <rtems_rfs_file_close+0x154> <== NOT EXECUTED
20412b0: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
20412b4: 7f ff 34 42 call 200e3bc <_Chain_Extract> <== NOT EXECUTED
20412b8: d0 06 60 1c ld [ %i1 + 0x1c ], %o0 <== NOT EXECUTED
rrc = rc;
}
rtems_chain_extract (&handle->shared->link);
free (handle->shared);
20412bc: 7f ff 1d 88 call 20088dc <free> <== NOT EXECUTED
20412c0: d0 06 60 1c ld [ %i1 + 0x1c ], %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20412c4: 92 06 60 04 add %i1, 4, %o1 <== NOT EXECUTED
20412c8: 7f ff f9 4c call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20412cc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))
printf ("rtems-rfs: file-close: result: %d: %s\n", rrc, strerror (rrc));
}
free (handle);
20412d0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
handle->dirty = false;
20412d4: c0 2e 60 04 clrb [ %i1 + 4 ] <== NOT EXECUTED
handle->bnum = 0;
20412d8: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
handle->buffer = NULL;
20412dc: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
20412e0: 7f ff 1d 7f call 20088dc <free> <== NOT EXECUTED
20412e4: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
return rrc;
}
20412e8: 81 c7 e0 08 ret <== NOT EXECUTED
20412ec: 81 e8 00 00 restore <== NOT EXECUTED
handle->shared->atime);
rtems_rfs_inode_set_mtime (&handle->shared->inode,
handle->shared->mtime);
rtems_rfs_inode_set_ctime (&handle->shared->inode,
handle->shared->ctime);
if (!rtems_rfs_block_size_equal (&handle->shared->size,
20412f0: c6 02 60 88 ld [ %o1 + 0x88 ], %g3 <== NOT EXECUTED
20412f4: c8 02 60 40 ld [ %o1 + 0x40 ], %g4 <== NOT EXECUTED
20412f8: 80 a0 c0 04 cmp %g3, %g4 <== NOT EXECUTED
20412fc: 12 bf ff d7 bne 2041258 <rtems_rfs_file_close+0xf8> <== NOT EXECUTED
2041300: a0 10 20 00 clr %l0 <== NOT EXECUTED
&handle->shared->map.size))
rtems_rfs_block_map_set_size (&handle->shared->map,
&handle->shared->size);
}
rc = rtems_rfs_block_map_close (fs, &handle->shared->map);
2041304: 10 bf ff dc b 2041274 <rtems_rfs_file_close+0x114> <== NOT EXECUTED
2041308: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
handle->shared->references--;
if (handle->shared->references == 0)
{
if (!rtems_rfs_inode_is_loaded (&handle->shared->inode))
rrc = rtems_rfs_inode_load (fs, &handle->shared->inode);
204130c: 40 00 08 4f call 2043448 <rtems_rfs_inode_load> <== NOT EXECUTED
2041310: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rrc == 0)
2041314: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2041318: 02 80 00 04 be 2041328 <rtems_rfs_file_close+0x1c8> <== NOT EXECUTED
204131c: d2 06 60 1c ld [ %i1 + 0x1c ], %o1 <== NOT EXECUTED
&handle->shared->map.size))
rtems_rfs_block_map_set_size (&handle->shared->map,
&handle->shared->size);
}
rc = rtems_rfs_block_map_close (fs, &handle->shared->map);
2041320: 10 bf ff d5 b 2041274 <rtems_rfs_file_close+0x114> <== NOT EXECUTED
2041324: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
if (handle->shared->references == 0)
{
if (!rtems_rfs_inode_is_loaded (&handle->shared->inode))
rrc = rtems_rfs_inode_load (fs, &handle->shared->inode);
if (rrc == 0)
2041328: 10 bf ff 9c b 2041198 <rtems_rfs_file_close+0x38> <== NOT EXECUTED
204132c: c2 02 60 18 ld [ %o1 + 0x18 ], %g1 <== NOT EXECUTED
02040958 <rtems_rfs_file_get_shared>:
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
2040958: c2 02 20 70 ld [ %o0 + 0x70 ], %g1 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
204095c: 84 02 20 74 add %o0, 0x74, %g2 <== NOT EXECUTED
rtems_rfs_file_get_shared (rtems_rfs_file_system* fs,
rtems_rfs_ino ino)
{
rtems_chain_node* node;
node = rtems_chain_first (&fs->file_shares);
while (!rtems_chain_is_tail (&fs->file_shares, node))
2040960: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2040964: 02 80 00 10 be 20409a4 <rtems_rfs_file_get_shared+0x4c> <== NOT EXECUTED
2040968: 90 10 20 00 clr %o0 <== NOT EXECUTED
{
rtems_rfs_file_shared* shared;
shared = (rtems_rfs_file_shared*) node;
if (shared->inode.ino == ino)
204096c: c6 00 60 14 ld [ %g1 + 0x14 ], %g3 <== NOT EXECUTED
2040970: 80 a0 c0 09 cmp %g3, %o1 <== NOT EXECUTED
2040974: 12 80 00 06 bne 204098c <rtems_rfs_file_get_shared+0x34> <== NOT EXECUTED
2040978: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
204097c: 30 80 00 0a b,a 20409a4 <rtems_rfs_file_get_shared+0x4c> <== NOT EXECUTED
2040980: 80 a0 c0 09 cmp %g3, %o1 <== NOT EXECUTED
2040984: 02 80 00 08 be 20409a4 <rtems_rfs_file_get_shared+0x4c> <== NOT EXECUTED
2040988: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
204098c: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
rtems_rfs_file_get_shared (rtems_rfs_file_system* fs,
rtems_rfs_ino ino)
{
rtems_chain_node* node;
node = rtems_chain_first (&fs->file_shares);
while (!rtems_chain_is_tail (&fs->file_shares, node))
2040990: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2040994: 32 bf ff fb bne,a 2040980 <rtems_rfs_file_get_shared+0x28><== NOT EXECUTED
2040998: c6 00 60 14 ld [ %g1 + 0x14 ], %g3 <== NOT EXECUTED
if (shared->inode.ino == ino)
return shared;
node = rtems_chain_next (node);
}
return NULL;
}
204099c: 81 c3 e0 08 retl <== NOT EXECUTED
20409a0: 90 10 20 00 clr %o0 <== NOT EXECUTED
20409a4: 81 c3 e0 08 retl <== NOT EXECUTED
02040f40 <rtems_rfs_file_io_end>:
int
rtems_rfs_file_io_end (rtems_rfs_file_handle* handle,
size_t size,
bool read)
{
2040f40: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: end: %s size=%zu\n",
read ? "read" : "write", size);
if (rtems_rfs_buffer_handle_has_block (&handle->buffer))
2040f44: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2040f48: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040f4c: 22 80 00 6a be,a 20410f4 <rtems_rfs_file_io_end+0x1b4> <== NOT EXECUTED
2040f50: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
{
if (!read)
2040f54: b4 8e a0 ff andcc %i2, 0xff, %i2 <== NOT EXECUTED
2040f58: 02 80 00 1a be 2040fc0 <rtems_rfs_file_io_end+0x80> <== NOT EXECUTED
2040f5c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040f60: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
2040f64: 92 06 20 04 add %i0, 4, %o1 <== NOT EXECUTED
2040f68: 7f ff fa 24 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040f6c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
rtems_rfs_file_buffer (handle));
if (rc > 0)
2040f70: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2040f74: 24 80 00 1c ble,a 2040fe4 <rtems_rfs_file_io_end+0xa4> <== NOT EXECUTED
2040f78: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
{
printf (
2040f7c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2040f80: 35 00 81 b9 sethi %hi(0x206e400), %i2 <== NOT EXECUTED
2040f84: 12 80 00 04 bne 2040f94 <rtems_rfs_file_io_end+0x54> <== NOT EXECUTED
2040f88: b4 16 a0 10 or %i2, 0x10, %i2 ! 206e410 <__FUNCTION__.7699+0x30><== NOT EXECUTED
2040f8c: 35 00 81 b9 sethi %hi(0x206e400), %i2 <== NOT EXECUTED
2040f90: b4 16 a0 08 or %i2, 8, %i2 ! 206e408 <__FUNCTION__.7699+0x28><== NOT EXECUTED
2040f94: 40 00 3f eb call 2050f40 <strerror> <== NOT EXECUTED
2040f98: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2040f9c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2040fa0: 98 10 00 08 mov %o0, %o4 <== NOT EXECUTED
2040fa4: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
2040fa8: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2040fac: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2040fb0: 40 00 37 2f call 204ec6c <printf> <== NOT EXECUTED
2040fb4: 90 12 20 18 or %o0, 0x18, %o0 <== NOT EXECUTED
handle->shared->size.offset =
rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));
}
return rc;
}
2040fb8: 81 c7 e0 08 ret <== NOT EXECUTED
2040fbc: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
read ? "read" : "write", size);
if (rtems_rfs_buffer_handle_has_block (&handle->buffer))
{
if (!read)
rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));
2040fc0: c2 2e 20 04 stb %g1, [ %i0 + 4 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040fc4: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
2040fc8: 92 06 20 04 add %i0, 4, %o1 <== NOT EXECUTED
2040fcc: 7f ff fa 0b call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040fd0: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
rtems_rfs_file_buffer (handle));
if (rc > 0)
2040fd4: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2040fd8: 14 bf ff ea bg 2040f80 <rtems_rfs_file_io_end+0x40> <== NOT EXECUTED
2040fdc: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
2040fe0: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
* increase the block number and adjust the offset.
*
* If we are the last block and the position is past the current size update
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
2040fe4: c6 06 20 14 ld [ %i0 + 0x14 ], %g3 <== NOT EXECUTED
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
2040fe8: c4 00 60 98 ld [ %g1 + 0x98 ], %g2 <== NOT EXECUTED
* increase the block number and adjust the offset.
*
* If we are the last block and the position is past the current size update
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
2040fec: b2 06 40 03 add %i1, %g3, %i1 <== NOT EXECUTED
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
2040ff0: c4 00 a0 08 ld [ %g2 + 8 ], %g2 <== NOT EXECUTED
2040ff4: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
2040ff8: 0a 80 00 07 bcs 2041014 <rtems_rfs_file_io_end+0xd4> <== NOT EXECUTED
2040ffc: f2 26 20 14 st %i1, [ %i0 + 0x14 ] <== NOT EXECUTED
{
handle->bpos.bno++;
2041000: c6 06 20 10 ld [ %i0 + 0x10 ], %g3 <== NOT EXECUTED
handle->bpos.boff -= rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
2041004: b2 26 40 02 sub %i1, %g2, %i1 <== NOT EXECUTED
handle->bpos.boff += size;
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
{
handle->bpos.bno++;
2041008: 84 00 e0 01 add %g3, 1, %g2 <== NOT EXECUTED
handle->bpos.boff -= rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
204100c: f2 26 20 14 st %i1, [ %i0 + 0x14 ] <== NOT EXECUTED
handle->bpos.boff += size;
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
{
handle->bpos.bno++;
2041010: c4 26 20 10 st %g2, [ %i0 + 0x10 ] <== NOT EXECUTED
}
length = false;
mtime = false;
if (!read &&
2041014: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2041018: 12 80 00 0e bne 2041050 <rtems_rfs_file_io_end+0x110> <== NOT EXECUTED
204101c: a2 10 20 00 clr %l1 <== NOT EXECUTED
rtems_rfs_block_map_past_end (rtems_rfs_file_map (handle),
2041020: c4 06 20 10 ld [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
}
length = false;
mtime = false;
if (!read &&
2041024: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2041028: 12 80 00 3e bne 2041120 <rtems_rfs_file_io_end+0x1e0> <== NOT EXECUTED
204102c: c6 00 60 3c ld [ %g1 + 0x3c ], %g3 <== NOT EXECUTED
2041030: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2041034: 3a 80 00 3f bcc,a 2041130 <rtems_rfs_file_io_end+0x1f0> <== NOT EXECUTED
2041038: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
204103c: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
2041040: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2041044: 22 80 00 41 be,a 2041148 <rtems_rfs_file_io_end+0x208> <== NOT EXECUTED
2041048: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
204104c: a2 10 20 00 clr %l1 <== NOT EXECUTED
2041050: b2 10 20 00 clr %i1 <== NOT EXECUTED
handle->bpos.boff);
length = true;
mtime = true;
}
atime = rtems_rfs_file_update_atime (handle);
2041054: e4 06 00 00 ld [ %i0 ], %l2 <== NOT EXECUTED
mtime = rtems_rfs_file_update_mtime (handle) && mtime;
2041058: 82 0c a0 02 and %l2, 2, %g1 <== NOT EXECUTED
204105c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
length = rtems_rfs_file_update_length (handle) && length;
2041060: 84 0c a0 04 and %l2, 4, %g2 <== NOT EXECUTED
length = true;
mtime = true;
}
atime = rtems_rfs_file_update_atime (handle);
mtime = rtems_rfs_file_update_mtime (handle) && mtime;
2041064: 82 40 3f ff addx %g0, -1, %g1 <== NOT EXECUTED
length = rtems_rfs_file_update_length (handle) && length;
2041068: 80 a0 00 02 cmp %g0, %g2 <== NOT EXECUTED
length = true;
mtime = true;
}
atime = rtems_rfs_file_update_atime (handle);
mtime = rtems_rfs_file_update_mtime (handle) && mtime;
204106c: b2 0e 40 01 and %i1, %g1, %i1 <== NOT EXECUTED
handle->bpos.boff);
length = true;
mtime = true;
}
atime = rtems_rfs_file_update_atime (handle);
2041070: a4 1c a0 01 xor %l2, 1, %l2 <== NOT EXECUTED
mtime = rtems_rfs_file_update_mtime (handle) && mtime;
length = rtems_rfs_file_update_length (handle) && length;
2041074: 82 60 3f ff subx %g0, -1, %g1 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: end: pos=%" PRIu32 ":%" PRIu32 " %c %c %c\n",
handle->bpos.bno, handle->bpos.boff,
atime ? 'A' : '-', mtime ? 'M' : '-', length ? 'L' : '-');
if (atime || mtime)
2041078: a4 8c a0 01 andcc %l2, 1, %l2 <== NOT EXECUTED
204107c: 12 80 00 0e bne 20410b4 <rtems_rfs_file_io_end+0x174> <== NOT EXECUTED
2041080: a2 08 40 11 and %g1, %l1, %l1 <== NOT EXECUTED
2041084: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
2041088: 12 80 00 0b bne 20410b4 <rtems_rfs_file_io_end+0x174> <== NOT EXECUTED
204108c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
if (read && atime)
handle->shared->atime = now;
if (!read && mtime)
handle->shared->mtime = now;
}
if (length)
2041090: 02 bf ff ca be 2040fb8 <rtems_rfs_file_io_end+0x78> <== NOT EXECUTED
2041094: 01 00 00 00 nop <== NOT EXECUTED
{
handle->shared->size.count =
rtems_rfs_block_map_count (rtems_rfs_file_map (handle));
2041098: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
if (!read && mtime)
handle->shared->mtime = now;
}
if (length)
{
handle->shared->size.count =
204109c: c6 00 60 3c ld [ %g1 + 0x3c ], %g3 <== NOT EXECUTED
rtems_rfs_block_map_count (rtems_rfs_file_map (handle));
handle->shared->size.offset =
20410a0: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 <== NOT EXECUTED
if (!read && mtime)
handle->shared->mtime = now;
}
if (length)
{
handle->shared->size.count =
20410a4: c6 20 60 84 st %g3, [ %g1 + 0x84 ] <== NOT EXECUTED
rtems_rfs_block_map_count (rtems_rfs_file_map (handle));
handle->shared->size.offset =
20410a8: c4 20 60 88 st %g2, [ %g1 + 0x88 ] <== NOT EXECUTED
rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));
}
return rc;
}
20410ac: 81 c7 e0 08 ret <== NOT EXECUTED
20410b0: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
handle->bpos.bno, handle->bpos.boff,
atime ? 'A' : '-', mtime ? 'M' : '-', length ? 'L' : '-');
if (atime || mtime)
{
time_t now = time (NULL);
20410b4: 40 00 55 a9 call 2056758 <time> <== NOT EXECUTED
20410b8: 90 10 20 00 clr %o0 <== NOT EXECUTED
if (read && atime)
20410bc: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
20410c0: 02 80 00 08 be 20410e0 <rtems_rfs_file_io_end+0x1a0> <== NOT EXECUTED
20410c4: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
20410c8: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
20410cc: 02 bf ff f1 be 2041090 <rtems_rfs_file_io_end+0x150> <== NOT EXECUTED
20410d0: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
handle->shared->atime = now;
20410d4: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
20410d8: 10 bf ff ee b 2041090 <rtems_rfs_file_io_end+0x150> <== NOT EXECUTED
20410dc: d0 20 60 8c st %o0, [ %g1 + 0x8c ] <== NOT EXECUTED
if (!read && mtime)
20410e0: 02 bf ff ec be 2041090 <rtems_rfs_file_io_end+0x150> <== NOT EXECUTED
20410e4: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
handle->shared->mtime = now;
20410e8: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
20410ec: 10 bf ff e9 b 2041090 <rtems_rfs_file_io_end+0x150> <== NOT EXECUTED
20410f0: d0 20 60 90 st %o0, [ %g1 + 0x90 ] <== NOT EXECUTED
* increase the block number and adjust the offset.
*
* If we are the last block and the position is past the current size update
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
20410f4: c6 06 20 14 ld [ %i0 + 0x14 ], %g3 <== NOT EXECUTED
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
20410f8: c4 00 60 98 ld [ %g1 + 0x98 ], %g2 <== NOT EXECUTED
* increase the block number and adjust the offset.
*
* If we are the last block and the position is past the current size update
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
20410fc: b2 06 40 03 add %i1, %g3, %i1 <== NOT EXECUTED
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
2041100: c4 00 a0 08 ld [ %g2 + 8 ], %g2 <== NOT EXECUTED
* increase the block number and adjust the offset.
*
* If we are the last block and the position is past the current size update
* the size with the new length. The map holds the block count.
*/
handle->bpos.boff += size;
2041104: f2 26 20 14 st %i1, [ %i0 + 0x14 ] <== NOT EXECUTED
2041108: b4 0e a0 ff and %i2, 0xff, %i2 <== NOT EXECUTED
if (handle->bpos.boff >=
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))
204110c: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
2041110: 0a bf ff c1 bcs 2041014 <rtems_rfs_file_io_end+0xd4> <== NOT EXECUTED
2041114: a0 10 20 00 clr %l0 <== NOT EXECUTED
{
handle->bpos.bno++;
2041118: 10 bf ff bb b 2041004 <rtems_rfs_file_io_end+0xc4> <== NOT EXECUTED
204111c: c6 06 20 10 ld [ %i0 + 0x10 ], %g3 <== NOT EXECUTED
}
length = false;
mtime = false;
if (!read &&
2041120: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2041124: 12 bf ff c4 bne 2041034 <rtems_rfs_file_io_end+0xf4> <== NOT EXECUTED
2041128: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
204112c: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
2041130: c4 20 60 40 st %g2, [ %g1 + 0x40 ] <== NOT EXECUTED
map->dirty = true;
2041134: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
2041138: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
204113c: b2 10 20 01 mov 1, %i1 <== NOT EXECUTED
2041140: 10 bf ff c5 b 2041054 <rtems_rfs_file_io_end+0x114> <== NOT EXECUTED
2041144: c4 28 60 34 stb %g2, [ %g1 + 0x34 ] <== NOT EXECUTED
2041148: c6 00 60 40 ld [ %g1 + 0x40 ], %g3 <== NOT EXECUTED
204114c: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2041150: 28 bf ff c0 bleu,a 2041050 <rtems_rfs_file_io_end+0x110> <== NOT EXECUTED
2041154: a2 10 20 00 clr %l1 <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
2041158: 10 bf ff f7 b 2041134 <rtems_rfs_file_io_end+0x1f4> <== NOT EXECUTED
204115c: c4 20 60 40 st %g2, [ %g1 + 0x40 ] <== NOT EXECUTED
02040b18 <rtems_rfs_file_io_release>:
int
rtems_rfs_file_io_release (rtems_rfs_file_handle* handle)
{
int rc = 0;
if (rtems_rfs_buffer_handle_has_block (&handle->buffer))
2040b18: c2 02 20 0c ld [ %o0 + 0xc ], %g1 <== NOT EXECUTED
2040b1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040b20: 02 80 00 07 be 2040b3c <rtems_rfs_file_io_release+0x24> <== NOT EXECUTED
2040b24: 92 02 20 04 add %o0, 4, %o1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040b28: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 <== NOT EXECUTED
2040b2c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040b30: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2040b34: 7f ff fb 31 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040b38: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
rtems_rfs_file_buffer (handle));
return rc;
}
2040b3c: 81 c3 e0 08 retl <== NOT EXECUTED
2040b40: 90 10 20 00 clr %o0 <== NOT EXECUTED
020409ac <rtems_rfs_file_io_start>:
int
rtems_rfs_file_io_start (rtems_rfs_file_handle* handle,
size_t* available,
bool read)
{
20409ac: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: %s pos=%" PRIu32 ":%" PRIu32 "\n",
read ? "read" : "write", handle->bpos.bno, handle->bpos.boff);
if (!rtems_rfs_buffer_handle_has_block (&handle->buffer))
20409b0: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
int
rtems_rfs_file_io_start (rtems_rfs_file_handle* handle,
size_t* available,
bool read)
{
20409b4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: %s pos=%" PRIu32 ":%" PRIu32 "\n",
read ? "read" : "write", handle->bpos.bno, handle->bpos.boff);
if (!rtems_rfs_buffer_handle_has_block (&handle->buffer))
20409b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20409bc: 02 80 00 1d be 2040a30 <rtems_rfs_file_io_start+0x84> <== NOT EXECUTED
20409c0: b4 0e a0 ff and %i2, 0xff, %i2 <== NOT EXECUTED
block, request_read);
if (rc > 0)
return rc;
}
if (read
20409c4: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
20409c8: 02 80 00 0a be 20409f0 <rtems_rfs_file_io_start+0x44> <== NOT EXECUTED
20409cc: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
&& rtems_rfs_block_map_last (rtems_rfs_file_map (handle))
20409d0: c4 00 60 44 ld [ %g1 + 0x44 ], %g2 <== NOT EXECUTED
block, request_read);
if (rc > 0)
return rc;
}
if (read
20409d4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20409d8: 02 80 00 0d be 2040a0c <rtems_rfs_file_io_start+0x60> <== NOT EXECUTED
20409dc: c6 00 60 3c ld [ %g1 + 0x3c ], %g3 <== NOT EXECUTED
20409e0: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
20409e4: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
20409e8: 22 80 00 0d be,a 2040a1c <rtems_rfs_file_io_start+0x70> <== NOT EXECUTED
20409ec: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 <== NOT EXECUTED
&& rtems_rfs_block_map_last (rtems_rfs_file_map (handle))
&& rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle)))
size = rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));
else
size = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
20409f0: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
20409f4: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
*available = size - rtems_rfs_file_block_offset (handle);
20409f8: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
20409fc: 84 20 80 01 sub %g2, %g1, %g2 <== NOT EXECUTED
2040a00: c4 26 40 00 st %g2, [ %i1 ] <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: available=%zu (%zu)\n",
*available, size);
return 0;
}
2040a04: 81 c7 e0 08 ret <== NOT EXECUTED
2040a08: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
block, request_read);
if (rc > 0)
return rc;
}
if (read
2040a0c: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2040a10: 32 bf ff f5 bne,a 20409e4 <rtems_rfs_file_io_start+0x38> <== NOT EXECUTED
2040a14: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED
&& rtems_rfs_block_map_last (rtems_rfs_file_map (handle))
&& rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle)))
2040a18: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 <== NOT EXECUTED
block, request_read);
if (rc > 0)
return rc;
}
if (read
2040a1c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2040a20: 32 bf ff f7 bne,a 20409fc <rtems_rfs_file_io_start+0x50> <== NOT EXECUTED
2040a24: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
&& rtems_rfs_block_map_last (rtems_rfs_file_map (handle))
&& rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle)))
size = rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));
else
size = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
2040a28: 10 bf ff f3 b 20409f4 <rtems_rfs_file_io_start+0x48> <== NOT EXECUTED
2040a2c: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
bool request_read;
int rc;
request_read = read;
rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),
2040a30: d2 06 20 1c ld [ %i0 + 0x1c ], %o1 <== NOT EXECUTED
2040a34: 94 06 20 10 add %i0, 0x10, %o2 <== NOT EXECUTED
2040a38: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2040a3c: a2 07 bf fc add %fp, -4, %l1 <== NOT EXECUTED
2040a40: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
2040a44: 7f ff f7 6d call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
2040a48: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
rtems_rfs_file_map (handle),
rtems_rfs_file_bpos (handle),
&block);
if (rc > 0)
2040a4c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040a50: 04 80 00 09 ble 2040a74 <rtems_rfs_file_io_start+0xc8> <== NOT EXECUTED
2040a54: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
{
/*
* Has the read reached the EOF ?
*/
if (read && (rc == ENXIO))
2040a58: 02 80 00 14 be 2040aa8 <rtems_rfs_file_io_start+0xfc> <== NOT EXECUTED
2040a5c: 80 a6 20 06 cmp %i0, 6 <== NOT EXECUTED
2040a60: 12 80 00 10 bne 2040aa0 <rtems_rfs_file_io_start+0xf4> <== NOT EXECUTED
2040a64: 01 00 00 00 nop <== NOT EXECUTED
{
*available = 0;
2040a68: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
return 0;
2040a6c: 81 c7 e0 08 ret <== NOT EXECUTED
2040a70: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
/*
* If this is a write check if the write starts within a block or the
* amount of data is less than a block size. If it is read the block
* rather than getting a block to fill.
*/
if (!read &&
2040a74: 22 80 00 1a be,a 2040adc <rtems_rfs_file_io_start+0x130> <== NOT EXECUTED
2040a78: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
2040a7c: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040a80: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2040a84: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: block=%" PRIu32 " request-read=%s\n",
block, request_read ? "yes" : "no");
rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle),
2040a88: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
2040a8c: 7f ff fb a4 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2040a90: 92 04 20 04 add %l0, 4, %o1 <== NOT EXECUTED
rtems_rfs_file_buffer (handle),
block, request_read);
if (rc > 0)
2040a94: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040a98: 04 bf ff cc ble 20409c8 <rtems_rfs_file_io_start+0x1c> <== NOT EXECUTED
2040a9c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: available=%zu (%zu)\n",
*available, size);
return 0;
}
2040aa0: 81 c7 e0 08 ret <== NOT EXECUTED
2040aa4: 81 e8 00 00 restore <== NOT EXECUTED
{
*available = 0;
return 0;
}
if (rc != ENXIO)
2040aa8: 12 bf ff fe bne 2040aa0 <rtems_rfs_file_io_start+0xf4> <== NOT EXECUTED
2040aac: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
return rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))
printf ("rtems-rfs: file-io: start: grow\n");
rc = rtems_rfs_block_map_grow (rtems_rfs_file_fs (handle),
2040ab0: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
2040ab4: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2040ab8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2040abc: 7f ff f9 1b call 203ef28 <rtems_rfs_block_map_grow> <== NOT EXECUTED
2040ac0: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
rtems_rfs_file_map (handle),
1, &block);
if (rc > 0)
2040ac4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040ac8: 14 bf ff f6 bg 2040aa0 <rtems_rfs_file_io_start+0xf4> <== NOT EXECUTED
2040acc: 96 10 20 00 clr %o3 <== NOT EXECUTED
2040ad0: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040ad4: 10 bf ff ed b 2040a88 <rtems_rfs_file_io_start+0xdc> <== NOT EXECUTED
2040ad8: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
* If this is a write check if the write starts within a block or the
* amount of data is less than a block size. If it is read the block
* rather than getting a block to fill.
*/
if (!read &&
(rtems_rfs_file_block_offset (handle) ||
2040adc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040ae0: 02 80 00 05 be 2040af4 <rtems_rfs_file_io_start+0x148> <== NOT EXECUTED
2040ae4: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
(*available < rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))))
2040ae8: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2040aec: 10 bf ff e7 b 2040a88 <rtems_rfs_file_io_start+0xdc> <== NOT EXECUTED
2040af0: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040af4: c6 06 40 00 ld [ %i1 ], %g3 <== NOT EXECUTED
2040af8: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040afc: c4 02 20 08 ld [ %o0 + 8 ], %g2 <== NOT EXECUTED
2040b00: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
2040b04: 1a bf ff e1 bcc 2040a88 <rtems_rfs_file_io_start+0xdc> <== NOT EXECUTED
2040b08: 96 10 20 00 clr %o3 <== NOT EXECUTED
2040b0c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040b10: 10 bf ff de b 2040a88 <rtems_rfs_file_io_start+0xdc> <== NOT EXECUTED
2040b14: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
02041330 <rtems_rfs_file_open>:
int
rtems_rfs_file_open (rtems_rfs_file_system* fs,
rtems_rfs_ino ino,
uint32_t flags,
rtems_rfs_file_handle** file)
{
2041330: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* Allocate a new handle and initialise it. Do this before we deal with the
* shared node data so we do not have to be concerned with reference
* counting.
*/
handle = malloc (sizeof (rtems_rfs_file_handle));
2041334: 90 10 20 20 mov 0x20, %o0 <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))
printf ("rtems-rfs: file-open: ino=%" PRId32 "\n", ino);
*file = NULL;
2041338: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED
/*
* Allocate a new handle and initialise it. Do this before we deal with the
* shared node data so we do not have to be concerned with reference
* counting.
*/
handle = malloc (sizeof (rtems_rfs_file_handle));
204133c: 7f ff 1f 49 call 2009060 <malloc> <== NOT EXECUTED
2041340: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
if (!handle)
2041344: b0 10 20 0c mov 0xc, %i0 <== NOT EXECUTED
2041348: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
204134c: 02 80 00 39 be 2041430 <rtems_rfs_file_open+0x100> <== NOT EXECUTED
2041350: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(
Chain_Control *the_chain
)
{
return the_chain->first;
2041354: c2 04 60 70 ld [ %l1 + 0x70 ], %g1 <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
handle->bnum = 0;
2041358: c0 22 20 08 clr [ %o0 + 8 ] <== NOT EXECUTED
return ENOMEM;
memset (handle, 0, sizeof (rtems_rfs_file_handle));
204135c: c0 22 00 00 clr [ %o0 ] <== NOT EXECUTED
2041360: c0 22 20 04 clr [ %o0 + 4 ] <== NOT EXECUTED
2041364: c0 22 20 10 clr [ %o0 + 0x10 ] <== NOT EXECUTED
2041368: c0 22 20 14 clr [ %o0 + 0x14 ] <== NOT EXECUTED
204136c: c0 22 20 18 clr [ %o0 + 0x18 ] <== NOT EXECUTED
2041370: c0 22 20 1c clr [ %o0 + 0x1c ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2041374: 86 04 60 74 add %l1, 0x74, %g3 <== NOT EXECUTED
rtems_rfs_file_get_shared (rtems_rfs_file_system* fs,
rtems_rfs_ino ino)
{
rtems_chain_node* node;
node = rtems_chain_first (&fs->file_shares);
while (!rtems_chain_is_tail (&fs->file_shares, node))
2041378: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
204137c: 12 80 00 07 bne 2041398 <rtems_rfs_file_open+0x68> <== NOT EXECUTED
2041380: c0 22 20 0c clr [ %o0 + 0xc ] <== NOT EXECUTED
2041384: 30 80 00 11 b,a 20413c8 <rtems_rfs_file_open+0x98> <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next(
Chain_Node *the_node
)
{
return the_node->next;
2041388: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
204138c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
2041390: 02 80 00 0e be 20413c8 <rtems_rfs_file_open+0x98> <== NOT EXECUTED
2041394: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_rfs_file_shared* shared;
shared = (rtems_rfs_file_shared*) node;
if (shared->inode.ino == ino)
2041398: c4 00 60 14 ld [ %g1 + 0x14 ], %g2 <== NOT EXECUTED
204139c: 80 a6 40 02 cmp %i1, %g2 <== NOT EXECUTED
20413a0: 12 bf ff fa bne 2041388 <rtems_rfs_file_open+0x58> <== NOT EXECUTED
20413a4: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
* the reference count and return the pointer to the data.
*/
shared = rtems_rfs_file_get_shared (fs, ino);
if (shared)
{
shared->references++;
20413a8: c4 00 60 08 ld [ %g1 + 8 ], %g2 <== NOT EXECUTED
20413ac: 84 00 a0 01 inc %g2 <== NOT EXECUTED
20413b0: c4 20 60 08 st %g2, [ %g1 + 8 ] <== NOT EXECUTED
}
handle->flags = flags;
handle->shared = shared;
*file = handle;
20413b4: e0 26 c0 00 st %l0, [ %i3 ] <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))
printf ("rtems-rfs: file-open: ino=%" PRId32 " share created\n", ino);
}
handle->flags = flags;
20413b8: f4 24 00 00 st %i2, [ %l0 ] <== NOT EXECUTED
handle->shared = shared;
20413bc: e4 24 20 1c st %l2, [ %l0 + 0x1c ] <== NOT EXECUTED
*file = handle;
return 0;
}
20413c0: 81 c7 e0 08 ret <== NOT EXECUTED
20413c4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
{
/*
* None exists so create. Copy in the shared parts of the inode we hold in
* memory.
*/
shared = malloc (sizeof (rtems_rfs_file_shared));
20413c8: 7f ff 1f 26 call 2009060 <malloc> <== NOT EXECUTED
20413cc: 90 10 20 9c mov 0x9c, %o0 <== NOT EXECUTED
if (!shared)
20413d0: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20413d4: 02 80 00 19 be 2041438 <rtems_rfs_file_open+0x108> <== NOT EXECUTED
20413d8: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle->buffer);
free (handle);
return ENOMEM;
}
memset (shared, 0, sizeof (rtems_rfs_file_shared));
20413dc: 40 00 32 08 call 204dbfc <memset> <== NOT EXECUTED
20413e0: 94 10 20 9c mov 0x9c, %o2 <== NOT EXECUTED
rc = rtems_rfs_inode_open (fs, ino, &shared->inode, true);
20413e4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20413e8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20413ec: b2 04 a0 0c add %l2, 0xc, %i1 <== NOT EXECUTED
20413f0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
20413f4: 40 00 08 30 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20413f8: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
if (rc > 0)
20413fc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2041400: 04 80 00 19 ble 2041464 <rtems_rfs_file_open+0x134> <== NOT EXECUTED
2041404: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))
printf ("rtems-rfs: file-open: block map open failed: %d: %s\n",
rc, strerror (rc));
rtems_rfs_inode_close (fs, &shared->inode);
free (shared);
2041408: 7f ff 1d 35 call 20088dc <free> <== NOT EXECUTED
204140c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2041410: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2041414: 7f ff f8 f9 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2041418: 92 04 20 04 add %l0, 4, %o1 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle->buffer);
free (handle);
204141c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
2041420: c0 2c 20 04 clrb [ %l0 + 4 ] <== NOT EXECUTED
handle->bnum = 0;
2041424: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
2041428: 7f ff 1d 2d call 20088dc <free> <== NOT EXECUTED
204142c: c0 24 20 0c clr [ %l0 + 0xc ] <== NOT EXECUTED
return rc;
2041430: 81 c7 e0 08 ret <== NOT EXECUTED
2041434: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2041438: 92 04 20 04 add %l0, 4, %o1 <== NOT EXECUTED
204143c: 7f ff f8 ef call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2041440: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
*/
shared = malloc (sizeof (rtems_rfs_file_shared));
if (!shared)
{
rtems_rfs_buffer_handle_close (fs, &handle->buffer);
free (handle);
2041444: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
2041448: c0 2c 20 04 clrb [ %l0 + 4 ] <== NOT EXECUTED
handle->bnum = 0;
204144c: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
handle->buffer = NULL;
2041450: c0 24 20 0c clr [ %l0 + 0xc ] <== NOT EXECUTED
2041454: 7f ff 1d 22 call 20088dc <free> <== NOT EXECUTED
2041458: b0 10 20 0c mov 0xc, %i0 <== NOT EXECUTED
return ENOMEM;
204145c: 81 c7 e0 08 ret <== NOT EXECUTED
2041460: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle->buffer);
free (handle);
return rc;
}
rc = rtems_rfs_block_map_open (fs, &shared->inode, &shared->map);
2041464: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2041468: 7f ff f8 0f call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
204146c: 94 04 a0 34 add %l2, 0x34, %o2 <== NOT EXECUTED
if (rc > 0)
2041470: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2041474: 04 80 00 05 ble 2041488 <rtems_rfs_file_open+0x158> <== NOT EXECUTED
2041478: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))
printf ("rtems-rfs: file-open: block map open failed: %d: %s\n",
rc, strerror (rc));
rtems_rfs_inode_close (fs, &shared->inode);
204147c: 40 00 07 e4 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2041480: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2041484: 30 bf ff e1 b,a 2041408 <rtems_rfs_file_open+0xd8> <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
2041488: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle->buffer);
free (handle);
return rc;
}
shared->references = 1;
204148c: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2041490: c4 24 a0 08 st %g2, [ %l2 + 8 ] <== NOT EXECUTED
2041494: 84 00 60 0c add %g1, 0xc, %g2 <== NOT EXECUTED
shared->size.count = rtems_rfs_inode_get_block_count (&shared->inode);
2041498: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
204149c: da 08 a0 03 ldub [ %g2 + 3 ], %o5 <== NOT EXECUTED
20414a0: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED
20414a4: c6 08 60 0c ldub [ %g1 + 0xc ], %g3 <== NOT EXECUTED
20414a8: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20414ac: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
20414b0: 86 13 40 03 or %o5, %g3, %g3 <== NOT EXECUTED
20414b4: 86 10 c0 02 or %g3, %g2, %g3 <== NOT EXECUTED
20414b8: 85 29 20 08 sll %g4, 8, %g2 <== NOT EXECUTED
20414bc: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
20414c0: c4 24 a0 84 st %g2, [ %l2 + 0x84 ] <== NOT EXECUTED
shared->size.offset = rtems_rfs_inode_get_block_offset (&shared->inode);
20414c4: c6 08 60 0b ldub [ %g1 + 0xb ], %g3 <== NOT EXECUTED
20414c8: c4 08 60 0a ldub [ %g1 + 0xa ], %g2 <== 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 );
20414cc: 90 04 60 70 add %l1, 0x70, %o0 <== NOT EXECUTED
20414d0: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
20414d4: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
20414d8: c4 24 a0 88 st %g2, [ %l2 + 0x88 ] <== NOT EXECUTED
* @return rtems_rfs_time The atime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_atime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->atime);
20414dc: 84 00 60 10 add %g1, 0x10, %g2 <== NOT EXECUTED
shared->atime = rtems_rfs_inode_get_atime (&shared->inode);
20414e0: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
20414e4: da 08 a0 03 ldub [ %g2 + 3 ], %o5 <== NOT EXECUTED
20414e8: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED
20414ec: c6 08 60 10 ldub [ %g1 + 0x10 ], %g3 <== NOT EXECUTED
20414f0: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20414f4: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
20414f8: 86 13 40 03 or %o5, %g3, %g3 <== NOT EXECUTED
20414fc: 86 10 c0 02 or %g3, %g2, %g3 <== NOT EXECUTED
2041500: 85 29 20 08 sll %g4, 8, %g2 <== NOT EXECUTED
2041504: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
2041508: c4 24 a0 8c st %g2, [ %l2 + 0x8c ] <== NOT EXECUTED
* @return rtems_rfs_time The mtime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_mtime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->mtime);
204150c: 84 00 60 14 add %g1, 0x14, %g2 <== NOT EXECUTED
shared->mtime = rtems_rfs_inode_get_mtime (&shared->inode);
2041510: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
2041514: da 08 a0 03 ldub [ %g2 + 3 ], %o5 <== NOT EXECUTED
2041518: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED
204151c: c6 08 60 14 ldub [ %g1 + 0x14 ], %g3 <== NOT EXECUTED
2041520: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2041524: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
2041528: 86 13 40 03 or %o5, %g3, %g3 <== NOT EXECUTED
204152c: 86 10 c0 02 or %g3, %g2, %g3 <== NOT EXECUTED
2041530: 85 29 20 08 sll %g4, 8, %g2 <== NOT EXECUTED
2041534: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
2041538: c4 24 a0 90 st %g2, [ %l2 + 0x90 ] <== NOT EXECUTED
shared->ctime = rtems_rfs_inode_get_ctime (&shared->inode);
204153c: c4 08 60 18 ldub [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
* @return rtems_rfs_time The ctime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_ctime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->ctime);
2041540: 82 00 60 18 add %g1, 0x18, %g1 <== NOT EXECUTED
2041544: c6 08 60 02 ldub [ %g1 + 2 ], %g3 <== NOT EXECUTED
2041548: c8 08 60 03 ldub [ %g1 + 3 ], %g4 <== NOT EXECUTED
204154c: c2 08 60 01 ldub [ %g1 + 1 ], %g1 <== NOT EXECUTED
2041550: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
2041554: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
2041558: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
204155c: 84 10 80 01 or %g2, %g1, %g2 <== NOT EXECUTED
2041560: 83 28 e0 08 sll %g3, 8, %g1 <== NOT EXECUTED
2041564: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2041568: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
204156c: c2 24 a0 94 st %g1, [ %l2 + 0x94 ] <== NOT EXECUTED
2041570: 7f ff 33 87 call 200e38c <_Chain_Append> <== NOT EXECUTED
2041574: e2 24 a0 98 st %l1, [ %l2 + 0x98 ] <== NOT EXECUTED
shared->fs = fs;
rtems_chain_append (&fs->file_shares, &shared->link);
rtems_rfs_inode_unload (fs, &shared->inode, false);
2041578: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
204157c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2041580: 40 00 07 76 call 2043358 <rtems_rfs_inode_unload> <== NOT EXECUTED
2041584: 94 10 20 00 clr %o2 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))
2041588: 10 bf ff 8c b 20413b8 <rtems_rfs_file_open+0x88> <== NOT EXECUTED
204158c: e0 26 c0 00 st %l0, [ %i3 ] <== NOT EXECUTED
02040e68 <rtems_rfs_file_seek>:
int
rtems_rfs_file_seek (rtems_rfs_file_handle* handle,
rtems_rfs_pos pos,
rtems_rfs_pos* new_pos)
{
2040e68: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
* file, this function does not itself extend the size of the file."
*
* This means the file needs to set the file size to the pos only when a
* write occurs.
*/
if (pos < rtems_rfs_file_shared_get_size (rtems_rfs_file_fs (handle),
2040e6c: d2 06 20 1c ld [ %i0 + 0x1c ], %o1 <== NOT EXECUTED
int
rtems_rfs_file_seek (rtems_rfs_file_handle* handle,
rtems_rfs_pos pos,
rtems_rfs_pos* new_pos)
{
2040e70: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
2040e74: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2040e78: 7f ff f6 24 call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2040e7c: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
* file, this function does not itself extend the size of the file."
*
* This means the file needs to set the file size to the pos only when a
* write occurs.
*/
if (pos < rtems_rfs_file_shared_get_size (rtems_rfs_file_fs (handle),
2040e80: 80 a2 00 19 cmp %o0, %i1 <== NOT EXECUTED
2040e84: 38 80 00 0f bgu,a 2040ec0 <rtems_rfs_file_seek+0x58> <== NOT EXECUTED
2040e88: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040e8c: 80 a2 00 19 cmp %o0, %i1 <== NOT EXECUTED
2040e90: 02 80 00 09 be 2040eb4 <rtems_rfs_file_seek+0x4c> <== NOT EXECUTED
2040e94: 80 a2 40 1a cmp %o1, %i2 <== NOT EXECUTED
{
/*
* The seek is outside the current file so release any buffer. A write will
* extend the file.
*/
int rc = rtems_rfs_file_io_release (handle);
2040e98: 7f ff ff 20 call 2040b18 <rtems_rfs_file_io_release> <== NOT EXECUTED
2040e9c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2040ea0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040ea4: 24 80 00 24 ble,a 2040f34 <rtems_rfs_file_seek+0xcc> <== NOT EXECUTED
2040ea8: f4 26 e0 04 st %i2, [ %i3 + 4 ] <== NOT EXECUTED
return rc;
}
*new_pos = pos;
return 0;
}
2040eac: 81 c7 e0 08 ret <== NOT EXECUTED
2040eb0: 81 e8 00 00 restore <== NOT EXECUTED
* file, this function does not itself extend the size of the file."
*
* This means the file needs to set the file size to the pos only when a
* write occurs.
*/
if (pos < rtems_rfs_file_shared_get_size (rtems_rfs_file_fs (handle),
2040eb4: 08 bf ff f9 bleu 2040e98 <rtems_rfs_file_seek+0x30> <== NOT EXECUTED
2040eb8: 01 00 00 00 nop <== NOT EXECUTED
handle->shared))
{
rtems_rfs_file_set_bpos (handle, pos);
2040ebc: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040ec0: a2 04 20 10 add %l0, 0x10, %l1 <== NOT EXECUTED
2040ec4: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040ec8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2040ecc: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
2040ed0: 7f ff f5 df call 203e64c <rtems_rfs_block_get_bpos> <== NOT EXECUTED
2040ed4: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
/*
* If the file has a block check if it maps to the current position and it
* does not release it. That will force us to get the block at the new
* position when the I/O starts.
*/
if (rtems_rfs_buffer_handle_has_block (&handle->buffer))
2040ed8: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
2040edc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040ee0: 02 80 00 14 be 2040f30 <rtems_rfs_file_seek+0xc8> <== NOT EXECUTED
2040ee4: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
{
rtems_rfs_buffer_block block;
int rc;
rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),
2040ee8: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
2040eec: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2040ef0: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
2040ef4: 7f ff f6 41 call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
2040ef8: 92 02 60 34 add %o1, 0x34, %o1 <== NOT EXECUTED
rtems_rfs_file_map (handle),
rtems_rfs_file_bpos (handle),
&block);
if (rc > 0)
2040efc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040f00: 14 bf ff eb bg 2040eac <rtems_rfs_file_seek+0x44> <== NOT EXECUTED
2040f04: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
return rc;
if (rtems_rfs_buffer_bnum (&handle->buffer) != block)
2040f08: c4 04 20 08 ld [ %l0 + 8 ], %g2 <== NOT EXECUTED
2040f0c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2040f10: 02 80 00 08 be 2040f30 <rtems_rfs_file_seek+0xc8> <== NOT EXECUTED
2040f14: 92 04 20 04 add %l0, 4, %o1 <== NOT EXECUTED
{
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040f18: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040f1c: 7f ff fa 37 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040f20: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
rtems_rfs_file_buffer (handle));
if (rc > 0)
2040f24: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2040f28: 14 bf ff e1 bg 2040eac <rtems_rfs_file_seek+0x44> <== NOT EXECUTED
2040f2c: 01 00 00 00 nop <== NOT EXECUTED
int rc = rtems_rfs_file_io_release (handle);
if (rc > 0)
return rc;
}
*new_pos = pos;
2040f30: f4 26 e0 04 st %i2, [ %i3 + 4 ] <== NOT EXECUTED
2040f34: f2 26 c0 00 st %i1, [ %i3 ] <== NOT EXECUTED
return 0;
}
2040f38: 81 c7 e0 08 ret <== NOT EXECUTED
2040f3c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02040b44 <rtems_rfs_file_set_size>:
}
int
rtems_rfs_file_set_size (rtems_rfs_file_handle* handle,
rtems_rfs_pos new_size)
{
2040b44: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_rfs_block_map* map = rtems_rfs_file_map (handle);
2040b48: e2 06 20 1c ld [ %i0 + 0x1c ], %l1 <== NOT EXECUTED
}
int
rtems_rfs_file_set_size (rtems_rfs_file_handle* handle,
rtems_rfs_pos new_size)
{
2040b4c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
2040b50: d0 04 60 98 ld [ %l1 + 0x98 ], %o0 <== NOT EXECUTED
2040b54: 92 04 60 84 add %l1, 0x84, %o1 <== NOT EXECUTED
2040b58: 7f ff f6 ec call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2040b5c: a4 10 00 19 mov %i1, %l2 <== NOT EXECUTED
/*
* If the file is same size do nothing else grow or shrink it ?
*
* If the file does not change size do not update the times.
*/
if (size != new_size)
2040b60: 80 a6 40 08 cmp %i1, %o0 <== NOT EXECUTED
2040b64: 02 80 00 af be 2040e20 <rtems_rfs_file_set_size+0x2dc> <== NOT EXECUTED
2040b68: a6 10 00 1a mov %i2, %l3 <== NOT EXECUTED
{
/*
* Short cut for the common truncate on open call.
*/
if (new_size == 0)
2040b6c: 80 94 80 13 orcc %l2, %l3, %g0 <== NOT EXECUTED
2040b70: 02 80 00 85 be 2040d84 <rtems_rfs_file_set_size+0x240> <== NOT EXECUTED
2040b74: aa 04 60 34 add %l1, 0x34, %l5 <== NOT EXECUTED
if (rc > 0)
return rc;
}
else
{
if (size < new_size)
2040b78: 80 a4 80 08 cmp %l2, %o0 <== NOT EXECUTED
2040b7c: 08 80 00 57 bleu 2040cd8 <rtems_rfs_file_set_size+0x194> <== NOT EXECUTED
2040b80: 01 00 00 00 nop <== NOT EXECUTED
rtems_rfs_pos count;
uint32_t length;
bool read_block;
count = new_size - size;
length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
2040b84: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
*/
rtems_rfs_pos count;
uint32_t length;
bool read_block;
count = new_size - size;
2040b88: a6 a4 c0 09 subcc %l3, %o1, %l3 <== NOT EXECUTED
2040b8c: a4 64 80 08 subx %l2, %o0, %l2 <== NOT EXECUTED
length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
2040b90: d0 05 a0 98 ld [ %l6 + 0x98 ], %o0 <== NOT EXECUTED
read_block = false;
while (count)
2040b94: 80 94 80 13 orcc %l2, %l3, %g0 <== NOT EXECUTED
2040b98: 02 80 00 a0 be 2040e18 <rtems_rfs_file_set_size+0x2d4> <== NOT EXECUTED
2040b9c: e8 02 20 08 ld [ %o0 + 8 ], %l4 <== NOT EXECUTED
}
/*
* Only read the block if the length is not the block size.
*/
rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle),
2040ba0: ac 04 20 04 add %l0, 4, %l6 <== NOT EXECUTED
2040ba4: b6 10 20 00 clr %i3 <== NOT EXECUTED
2040ba8: b8 07 bf f0 add %fp, -16, %i4 <== NOT EXECUTED
2040bac: ba 07 bf fc add %fp, -4, %i5 <== NOT EXECUTED
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
map->dirty = true;
2040bb0: 10 80 00 28 b 2040c50 <rtems_rfs_file_set_size+0x10c> <== NOT EXECUTED
2040bb4: ae 10 20 01 mov 1, %l7 <== NOT EXECUTED
map, 1, &block);
if (rc > 0)
return rc;
}
if (count < (length - bpos.boff))
2040bb8: 80 a0 80 13 cmp %g2, %l3 <== NOT EXECUTED
2040bbc: 28 80 00 44 bleu,a 2040ccc <rtems_rfs_file_set_size+0x188><== NOT EXECUTED
2040bc0: c0 24 60 40 clr [ %l1 + 0x40 ] <== NOT EXECUTED
{
length = count + bpos.boff;
2040bc4: a8 00 40 13 add %g1, %l3, %l4 <== NOT EXECUTED
2040bc8: ee 2c 60 34 stb %l7, [ %l1 + 0x34 ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
2040bcc: e8 24 60 40 st %l4, [ %l1 + 0x40 ] <== NOT EXECUTED
map->dirty = true;
2040bd0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2040bd4: b6 10 20 01 mov 1, %i3 <== NOT EXECUTED
}
/*
* Only read the block if the length is not the block size.
*/
rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle),
2040bd8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040bdc: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
2040be0: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040be4: 7f ff fb 4e call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2040be8: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
rtems_rfs_file_buffer (handle),
block, read_block);
if (rc > 0)
2040bec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040bf0: 14 80 00 63 bg 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040bf4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return rc;
dst = rtems_rfs_buffer_data (&handle->buffer);
memset (dst + bpos.boff, 0, length - bpos.boff);
2040bf8: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2040bfc: d0 00 a0 24 ld [ %g2 + 0x24 ], %o0 <== NOT EXECUTED
2040c00: 94 25 00 01 sub %l4, %g1, %o2 <== NOT EXECUTED
2040c04: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
2040c08: 40 00 33 fd call 204dbfc <memset> <== NOT EXECUTED
2040c0c: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040c10: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
return rc;
dst = rtems_rfs_buffer_data (&handle->buffer);
memset (dst + bpos.boff, 0, length - bpos.boff);
rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));
2040c14: ee 2c 20 04 stb %l7, [ %l0 + 4 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
2040c18: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040c1c: 7f ff fa f7 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2040c20: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
rtems_rfs_file_buffer (handle));
if (rc > 0)
2040c24: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040c28: 14 80 00 55 bg 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040c2c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return rc;
count -= length - bpos.boff;
2040c30: 82 25 00 01 sub %l4, %g1, %g1 <== NOT EXECUTED
2040c34: a6 a4 c0 01 subcc %l3, %g1, %l3 <== NOT EXECUTED
2040c38: a4 64 a0 00 subx %l2, 0, %l2 <== NOT EXECUTED
count = new_size - size;
length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
read_block = false;
while (count)
2040c3c: 80 94 80 13 orcc %l2, %l3, %g0 <== NOT EXECUTED
2040c40: 22 80 00 59 be,a 2040da4 <rtems_rfs_file_set_size+0x260> <== NOT EXECUTED
2040c44: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
2040c48: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040c4c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
/*
* Get the block position for the current end of the file as seen by
* the map. If not found and the EOF grow the map then fill the block
* with 0.
*/
rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map), &bpos);
2040c50: c4 04 60 3c ld [ %l1 + 0x3c ], %g2 <== NOT EXECUTED
2040c54: c4 27 bf f0 st %g2, [ %fp + -16 ] <== NOT EXECUTED
2040c58: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 <== NOT EXECUTED
2040c5c: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2040c60: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040c64: 02 80 00 04 be 2040c74 <rtems_rfs_file_set_size+0x130> <== NOT EXECUTED
2040c68: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED
2040c6c: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
2040c70: c4 27 bf f0 st %g2, [ %fp + -16 ] <== NOT EXECUTED
rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),
2040c74: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2040c78: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2040c7c: 7f ff f6 df call 203e7f8 <rtems_rfs_block_map_find> <== NOT EXECUTED
2040c80: 96 10 00 1d mov %i5, %o3 <== NOT EXECUTED
map, &bpos, &block);
if (rc > 0)
2040c84: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040c88: 04 80 00 0c ble 2040cb8 <rtems_rfs_file_set_size+0x174> <== NOT EXECUTED
2040c8c: 80 a2 20 06 cmp %o0, 6 <== NOT EXECUTED
{
/*
* Have we reached the EOF ?
*/
if (rc != ENXIO)
2040c90: 12 80 00 3b bne 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040c94: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
return rc;
rc = rtems_rfs_block_map_grow (rtems_rfs_file_fs (handle),
2040c98: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040c9c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2040ca0: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2040ca4: 7f ff f8 a1 call 203ef28 <rtems_rfs_block_map_grow> <== NOT EXECUTED
2040ca8: 96 10 00 1d mov %i5, %o3 <== NOT EXECUTED
map, 1, &block);
if (rc > 0)
2040cac: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040cb0: 14 80 00 33 bg 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040cb4: 01 00 00 00 nop <== NOT EXECUTED
return rc;
}
if (count < (length - bpos.boff))
2040cb8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
2040cbc: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
2040cc0: 02 bf ff be be 2040bb8 <rtems_rfs_file_set_size+0x74> <== NOT EXECUTED
2040cc4: 84 25 00 01 sub %l4, %g1, %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
2040cc8: c0 24 60 40 clr [ %l1 + 0x40 ] <== NOT EXECUTED
map->dirty = true;
2040ccc: ee 2c 60 34 stb %l7, [ %l1 + 0x34 ] <== NOT EXECUTED
2040cd0: 10 bf ff c2 b 2040bd8 <rtems_rfs_file_set_size+0x94> <== NOT EXECUTED
2040cd4: 96 0e e0 ff and %i3, 0xff, %o3 <== NOT EXECUTED
if (rc > 0)
return rc;
}
else
{
if (size < new_size)
2040cd8: 02 80 00 41 be 2040ddc <rtems_rfs_file_set_size+0x298> <== NOT EXECUTED
2040cdc: 80 a4 c0 09 cmp %l3, %o1 <== NOT EXECUTED
uint32_t offset;
blocks =
rtems_rfs_block_map_count (map) -
(((new_size - 1) /
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
2040ce0: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
* Shrink
*/
rtems_rfs_block_no blocks;
uint32_t offset;
blocks =
2040ce4: 92 84 ff ff addcc %l3, -1, %o1 <== NOT EXECUTED
rtems_rfs_block_map_count (map) -
(((new_size - 1) /
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
2040ce8: ee 05 a0 98 ld [ %l6 + 0x98 ], %l7 <== NOT EXECUTED
* Shrink
*/
rtems_rfs_block_no blocks;
uint32_t offset;
blocks =
2040cec: 90 44 bf ff addx %l2, -1, %o0 <== NOT EXECUTED
rtems_rfs_block_map_count (map) -
(((new_size - 1) /
2040cf0: ea 05 e0 08 ld [ %l7 + 8 ], %l5 <== NOT EXECUTED
* Shrink
*/
rtems_rfs_block_no blocks;
uint32_t offset;
blocks =
2040cf4: 94 10 20 00 clr %o2 <== NOT EXECUTED
2040cf8: 40 00 8a c0 call 20637f8 <__udivdi3> <== NOT EXECUTED
2040cfc: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
2040d00: e8 04 60 3c ld [ %l1 + 0x3c ], %l4 <== NOT EXECUTED
2040d04: 94 38 00 09 xnor %g0, %o1, %o2 <== NOT EXECUTED
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
offset =
new_size % rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
if (blocks)
2040d08: 94 82 80 14 addcc %o2, %l4, %o2 <== NOT EXECUTED
2040d0c: 12 80 00 4a bne 2040e34 <rtems_rfs_file_set_size+0x2f0> <== NOT EXECUTED
2040d10: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
blocks =
rtems_rfs_block_map_count (map) -
(((new_size - 1) /
rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
offset =
2040d14: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2040d18: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2040d1c: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
2040d20: 40 00 8b 87 call 2063b3c <__umoddi3> <== NOT EXECUTED
2040d24: 94 10 20 00 clr %o2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,
rtems_rfs_block_off offset)
{
map->size.offset = offset;
2040d28: d2 24 60 40 st %o1, [ %l1 + 0x40 ] <== NOT EXECUTED
return rc;
}
rtems_rfs_block_map_set_size_offset (map, offset);
if (rtems_rfs_block_pos_past_end (rtems_rfs_file_bpos (handle),
2040d2c: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
map->dirty = true;
2040d30: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2040d34: c2 2c 60 34 stb %g1, [ %l1 + 0x34 ] <== NOT EXECUTED
2040d38: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2040d3c: 12 80 00 2c bne 2040dec <rtems_rfs_file_set_size+0x2a8> <== NOT EXECUTED
2040d40: 82 10 00 14 mov %l4, %g1 <== NOT EXECUTED
2040d44: 80 a5 00 02 cmp %l4, %g2 <== NOT EXECUTED
2040d48: 28 80 00 2d bleu,a 2040dfc <rtems_rfs_file_set_size+0x2b8><== NOT EXECUTED
2040d4c: e8 24 20 10 st %l4, [ %l0 + 0x10 ] <== NOT EXECUTED
2040d50: 86 05 3f ff add %l4, -1, %g3 <== NOT EXECUTED
2040d54: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2040d58: 22 80 00 3f be,a 2040e54 <rtems_rfs_file_set_size+0x310> <== NOT EXECUTED
2040d5c: c4 04 20 14 ld [ %l0 + 0x14 ], %g2 <== NOT EXECUTED
rtems_rfs_file_bpos (handle));
}
}
handle->shared->size.count = rtems_rfs_block_map_count (map);
handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
2040d60: c4 04 60 40 ld [ %l1 + 0x40 ], %g2 <== NOT EXECUTED
rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map),
rtems_rfs_file_bpos (handle));
}
}
handle->shared->size.count = rtems_rfs_block_map_count (map);
2040d64: c2 25 a0 84 st %g1, [ %l6 + 0x84 ] <== NOT EXECUTED
handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
2040d68: c4 25 a0 88 st %g2, [ %l6 + 0x88 ] <== NOT EXECUTED
if (rtems_rfs_file_update_mtime (handle))
2040d6c: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
2040d70: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2040d74: 02 80 00 14 be 2040dc4 <rtems_rfs_file_set_size+0x280> <== NOT EXECUTED
2040d78: 90 10 20 00 clr %o0 <== NOT EXECUTED
handle->shared->mtime = time (NULL);
}
return 0;
}
2040d7c: 81 c7 e0 08 ret <== NOT EXECUTED
2040d80: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
/*
* Short cut for the common truncate on open call.
*/
if (new_size == 0)
{
rc = rtems_rfs_block_map_free_all (rtems_rfs_file_fs (handle), map);
2040d84: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2040d88: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2040d8c: 7f ff f8 1b call 203edf8 <rtems_rfs_block_map_free_all> <== NOT EXECUTED
2040d90: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
if (rc > 0)
2040d94: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040d98: 14 bf ff f9 bg 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040d9c: 01 00 00 00 nop <== NOT EXECUTED
count = new_size - size;
length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
read_block = false;
while (count)
2040da0: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
2040da4: c2 04 60 3c ld [ %l1 + 0x3c ], %g1 <== NOT EXECUTED
rtems_rfs_file_bpos (handle));
}
}
handle->shared->size.count = rtems_rfs_block_map_count (map);
handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
2040da8: c4 04 60 40 ld [ %l1 + 0x40 ], %g2 <== NOT EXECUTED
rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map),
rtems_rfs_file_bpos (handle));
}
}
handle->shared->size.count = rtems_rfs_block_map_count (map);
2040dac: c2 25 a0 84 st %g1, [ %l6 + 0x84 ] <== NOT EXECUTED
handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
2040db0: c4 25 a0 88 st %g2, [ %l6 + 0x88 ] <== NOT EXECUTED
if (rtems_rfs_file_update_mtime (handle))
2040db4: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
2040db8: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2040dbc: 12 bf ff f0 bne 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040dc0: 90 10 20 00 clr %o0 <== NOT EXECUTED
handle->shared->mtime = time (NULL);
2040dc4: 40 00 56 65 call 2056758 <time> <== NOT EXECUTED
2040dc8: 90 10 20 00 clr %o0 <== NOT EXECUTED
2040dcc: d0 25 a0 90 st %o0, [ %l6 + 0x90 ] <== NOT EXECUTED
2040dd0: 90 10 20 00 clr %o0 <== NOT EXECUTED
}
return 0;
}
2040dd4: 81 c7 e0 08 ret <== NOT EXECUTED
2040dd8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
if (rc > 0)
return rc;
}
else
{
if (size < new_size)
2040ddc: 08 bf ff c2 bleu 2040ce4 <rtems_rfs_file_set_size+0x1a0> <== NOT EXECUTED
2040de0: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
*/
rtems_rfs_pos count;
uint32_t length;
bool read_block;
count = new_size - size;
2040de4: 10 bf ff 6a b 2040b8c <rtems_rfs_file_set_size+0x48> <== NOT EXECUTED
2040de8: a6 a4 c0 09 subcc %l3, %o1, %l3 <== NOT EXECUTED
return rc;
}
rtems_rfs_block_map_set_size_offset (map, offset);
if (rtems_rfs_block_pos_past_end (rtems_rfs_file_bpos (handle),
2040dec: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
2040df0: 12 bf ff d6 bne 2040d48 <rtems_rfs_file_set_size+0x204> <== NOT EXECUTED
2040df4: 80 a5 00 02 cmp %l4, %g2 <== NOT EXECUTED
rtems_rfs_block_map_size (map)))
rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map),
2040df8: e8 24 20 10 st %l4, [ %l0 + 0x10 ] <== NOT EXECUTED
2040dfc: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 <== NOT EXECUTED
2040e00: c0 24 20 18 clr [ %l0 + 0x18 ] <== NOT EXECUTED
2040e04: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2040e08: 02 80 00 04 be 2040e18 <rtems_rfs_file_set_size+0x2d4> <== NOT EXECUTED
2040e0c: c2 24 20 14 st %g1, [ %l0 + 0x14 ] <== NOT EXECUTED
2040e10: a8 05 3f ff add %l4, -1, %l4 <== NOT EXECUTED
2040e14: e8 24 20 10 st %l4, [ %l0 + 0x10 ] <== NOT EXECUTED
2040e18: 10 bf ff d2 b 2040d60 <rtems_rfs_file_set_size+0x21c> <== NOT EXECUTED
2040e1c: c2 04 60 3c ld [ %l1 + 0x3c ], %g1 <== NOT EXECUTED
/*
* If the file is same size do nothing else grow or shrink it ?
*
* If the file does not change size do not update the times.
*/
if (size != new_size)
2040e20: 80 a6 80 09 cmp %i2, %o1 <== NOT EXECUTED
2040e24: 12 bf ff 53 bne 2040b70 <rtems_rfs_file_set_size+0x2c> <== NOT EXECUTED
2040e28: 80 94 80 13 orcc %l2, %l3, %g0 <== NOT EXECUTED
handle->shared->size.count = rtems_rfs_block_map_count (map);
handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
if (rtems_rfs_file_update_mtime (handle))
handle->shared->mtime = time (NULL);
2040e2c: 10 bf ff d4 b 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040e30: 90 10 20 00 clr %o0 <== NOT EXECUTED
new_size % rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
if (blocks)
{
int rc;
rc = rtems_rfs_block_map_shrink (rtems_rfs_file_fs (handle),
2040e34: 7f ff f7 23 call 203eac0 <rtems_rfs_block_map_shrink> <== NOT EXECUTED
2040e38: 92 05 a0 34 add %l6, 0x34, %o1 <== NOT EXECUTED
rtems_rfs_file_map (handle),
blocks);
if (rc > 0)
2040e3c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2040e40: 14 bf ff cf bg 2040d7c <rtems_rfs_file_set_size+0x238> <== NOT EXECUTED
2040e44: 01 00 00 00 nop <== NOT EXECUTED
2040e48: ec 04 20 1c ld [ %l0 + 0x1c ], %l6 <== NOT EXECUTED
2040e4c: 10 bf ff b2 b 2040d14 <rtems_rfs_file_set_size+0x1d0> <== NOT EXECUTED
2040e50: e8 04 60 3c ld [ %l1 + 0x3c ], %l4 <== NOT EXECUTED
return rc;
}
rtems_rfs_block_map_set_size_offset (map, offset);
if (rtems_rfs_block_pos_past_end (rtems_rfs_file_bpos (handle),
2040e54: 80 a2 40 02 cmp %o1, %g2 <== NOT EXECUTED
2040e58: 3a bf ff c3 bcc,a 2040d64 <rtems_rfs_file_set_size+0x220><== NOT EXECUTED
2040e5c: c4 04 60 40 ld [ %l1 + 0x40 ], %g2 <== NOT EXECUTED
rtems_rfs_block_map_size (map)))
rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map),
2040e60: 10 bf ff e7 b 2040dfc <rtems_rfs_file_set_size+0x2b8> <== NOT EXECUTED
2040e64: e8 24 20 10 st %l4, [ %l0 + 0x10 ] <== NOT EXECUTED
02041cf8 <rtems_rfs_format>:
return rc;
}
int
rtems_rfs_format (const char* name, const rtems_rfs_format_config* config)
{
2041cf8: 9d e3 be c0 save %sp, -320, %sp <== NOT EXECUTED
rtems_rfs_file_system fs;
int group;
int rc;
if (config->verbose)
2041cfc: c2 0e 60 15 ldub [ %i1 + 0x15 ], %g1 <== NOT EXECUTED
2041d00: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041d04: 12 80 00 f5 bne 20420d8 <rtems_rfs_format+0x3e0> <== NOT EXECUTED
2041d08: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
printf ("rtems-rfs: format: %s\n", name);
memset (&fs, 0, sizeof (rtems_rfs_file_system));
2041d0c: a4 07 bf 2c add %fp, -212, %l2 <== NOT EXECUTED
2041d10: 92 10 20 00 clr %o1 <== NOT EXECUTED
2041d14: 94 10 20 80 mov 0x80, %o2 <== NOT EXECUTED
2041d18: 40 00 2f b9 call 204dbfc <memset> <== NOT EXECUTED
2041d1c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2041d20: 82 07 bf 70 add %fp, -144, %g1 <== NOT EXECUTED
2041d24: c2 27 bf 6c st %g1, [ %fp + -148 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2041d28: 82 07 bf 6c add %fp, -148, %g1 <== NOT EXECUTED
2041d2c: c2 27 bf 74 st %g1, [ %fp + -140 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2041d30: 82 07 bf 80 add %fp, -128, %g1 <== NOT EXECUTED
2041d34: c2 27 bf 7c st %g1, [ %fp + -132 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2041d38: 82 07 bf 7c add %fp, -132, %g1 <== NOT EXECUTED
2041d3c: c2 27 bf 84 st %g1, [ %fp + -124 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2041d40: 82 07 bf 90 add %fp, -112, %g1 <== NOT EXECUTED
2041d44: c2 27 bf 8c st %g1, [ %fp + -116 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2041d48: 82 07 bf 8c add %fp, -116, %g1 <== NOT EXECUTED
2041d4c: c2 27 bf 94 st %g1, [ %fp + -108 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2041d50: 82 07 bf a0 add %fp, -96, %g1 <== NOT EXECUTED
2041d54: c2 27 bf 9c st %g1, [ %fp + -100 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2041d58: 82 07 bf 9c add %fp, -100, %g1 <== NOT EXECUTED
2041d5c: c2 27 bf a4 st %g1, [ %fp + -92 ] <== NOT EXECUTED
rtems_chain_initialize_empty (&fs.buffers);
rtems_chain_initialize_empty (&fs.release);
rtems_chain_initialize_empty (&fs.release_modified);
rtems_chain_initialize_empty (&fs.file_shares);
fs.max_held_buffers = RTEMS_RFS_FS_MAX_HELD_BUFFERS;
2041d60: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
2041d64: c2 27 bf 68 st %g1, [ %fp + -152 ] <== NOT EXECUTED
fs.release_count = 0;
fs.release_modified_count = 0;
fs.flags = RTEMS_RFS_FS_NO_LOCAL_CACHE;
2041d68: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED
/*
* Open the buffer interface.
*/
rc = rtems_rfs_buffer_open (name, &fs);
2041d6c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
fs.max_held_buffers = RTEMS_RFS_FS_MAX_HELD_BUFFERS;
fs.release_count = 0;
fs.release_modified_count = 0;
fs.flags = RTEMS_RFS_FS_NO_LOCAL_CACHE;
2041d70: c2 27 bf 2c st %g1, [ %fp + -212 ] <== NOT EXECUTED
/*
* Open the buffer interface.
*/
rc = rtems_rfs_buffer_open (name, &fs);
2041d74: 7f ff f6 8a call 203f79c <rtems_rfs_buffer_open> <== NOT EXECUTED
2041d78: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
if (rc > 0)
2041d7c: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2041d80: 14 80 01 82 bg 2042388 <rtems_rfs_format+0x690> <== NOT EXECUTED
2041d84: c2 07 bf 38 ld [ %fp + -200 ], %g1 <== NOT EXECUTED
}
/*
* Check the media.
*/
if (rtems_rfs_fs_media_block_size (&fs) == 0)
2041d88: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
2041d8c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2041d90: 02 80 00 cc be 20420c0 <rtems_rfs_format+0x3c8> <== NOT EXECUTED
2041d94: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
static bool
rtems_rfs_check_config (rtems_rfs_file_system* fs,
const rtems_rfs_format_config* config)
{
fs->block_size = config->block_size;
2041d98: e0 06 40 00 ld [ %i1 ], %l0 <== NOT EXECUTED
if (!fs->block_size)
2041d9c: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
2041da0: 02 80 00 df be 204211c <rtems_rfs_format+0x424> <== NOT EXECUTED
2041da4: e0 27 bf 34 st %l0, [ %fp + -204 ] <== NOT EXECUTED
if (fs->block_size > (4 * 1024))
fs->block_size = (4 * 1024);
}
if ((fs->block_size % rtems_rfs_fs_media_block_size (fs)) != 0)
2041da8: e2 00 60 24 ld [ %g1 + 0x24 ], %l1 <== NOT EXECUTED
2041dac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2041db0: 40 00 83 a1 call 2062c34 <.urem> <== NOT EXECUTED
2041db4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2041db8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041dbc: 32 80 00 fb bne,a 20421a8 <rtems_rfs_format+0x4b0> <== NOT EXECUTED
2041dc0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
printf ("block size (%zd) is not a multiple of media block size (%" PRId32 ")\n",
fs->block_size, rtems_rfs_fs_media_block_size (fs));
return false;
}
fs->group_blocks = config->group_blocks;
2041dc4: c2 06 60 04 ld [ %i1 + 4 ], %g1 <== NOT EXECUTED
if (!fs->group_blocks)
2041dc8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041dcc: 02 80 00 c8 be 20420ec <rtems_rfs_format+0x3f4> <== NOT EXECUTED
2041dd0: c2 27 bf 50 st %g1, [ %fp + -176 ] <== NOT EXECUTED
2041dd4: e0 07 bf 34 ld [ %fp + -204 ], %l0 <== NOT EXECUTED
* block.
*/
fs->group_blocks = rtems_rfs_bitmap_numof_bits (fs->block_size);
}
if (fs->group_blocks > rtems_rfs_bitmap_numof_bits (fs->block_size))
2041dd8: a1 2c 20 03 sll %l0, 3, %l0 <== NOT EXECUTED
2041ddc: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
2041de0: 0a 80 00 ca bcs 2042108 <rtems_rfs_format+0x410> <== NOT EXECUTED
2041de4: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
{
printf ("group block count is higher than bits in block\n");
return false;
}
fs->blocks = rtems_rfs_fs_media_size (fs) / fs->block_size;
2041de8: 7f ff fd f3 call 20415b4 <rtems_rfs_fs_media_size> <== NOT EXECUTED
2041dec: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2041df0: e0 07 bf 34 ld [ %fp + -204 ], %l0 <== NOT EXECUTED
2041df4: 94 10 20 00 clr %o2 <== NOT EXECUTED
2041df8: 40 00 86 80 call 20637f8 <__udivdi3> <== NOT EXECUTED
2041dfc: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2041e00: d2 27 bf 30 st %o1, [ %fp + -208 ] <== NOT EXECUTED
2041e04: a2 10 00 09 mov %o1, %l1 <== NOT EXECUTED
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
2041e08: 80 a2 60 00 cmp %o1, 0 <== NOT EXECUTED
2041e0c: 02 80 00 06 be 2041e24 <rtems_rfs_format+0x12c> <== NOT EXECUTED
2041e10: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
return 1;
return ((dividend - 1) / divisor) + 1;
2041e14: 90 02 7f ff add %o1, -1, %o0 <== NOT EXECUTED
2041e18: 40 00 82 db call 2062984 <.udiv> <== NOT EXECUTED
2041e1c: 93 2c 20 03 sll %l0, 3, %o1 <== NOT EXECUTED
2041e20: a6 02 20 01 add %o0, 1, %l3 <== NOT EXECUTED
* per block.
*/
fs->group_count = rtems_rfs_rup_quotient (rtems_rfs_fs_blocks (fs),
rtems_rfs_bits_per_block (fs));
fs->group_inodes = config->group_inodes;
2041e24: c2 06 60 08 ld [ %i1 + 8 ], %g1 <== NOT EXECUTED
/*
* The bits per block sets the upper limit for the number of blocks in a
* group. The disk will be divided into groups which are the number of bits
* per block.
*/
fs->group_count = rtems_rfs_rup_quotient (rtems_rfs_fs_blocks (fs),
2041e28: e6 27 bf 4c st %l3, [ %fp + -180 ] <== NOT EXECUTED
rtems_rfs_bits_per_block (fs));
fs->group_inodes = config->group_inodes;
if (!fs->group_inodes)
2041e2c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041e30: 12 80 00 19 bne 2041e94 <rtems_rfs_format+0x19c> <== NOT EXECUTED
2041e34: c2 27 bf 54 st %g1, [ %fp + -172 ] <== NOT EXECUTED
int inode_overhead = RTEMS_RFS_INODE_OVERHEAD_PERCENTAGE;
/*
* The number of inodes per group is set as a percentage.
*/
if (config->inode_overhead)
2041e38: d0 06 60 0c ld [ %i1 + 0xc ], %o0 <== NOT EXECUTED
2041e3c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041e40: 22 80 00 02 be,a 2041e48 <rtems_rfs_format+0x150> <== NOT EXECUTED
2041e44: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
static int
rtems_rfs_inodes_from_percent (rtems_rfs_file_system* fs,
int percentage)
{
int blocks;
blocks = ((rtems_rfs_fs_blocks (fs) -
2041e48: 7f ff 03 51 call 2002b8c <.umul> <== NOT EXECUTED
2041e4c: 92 04 7f ff add %l1, -1, %o1 <== NOT EXECUTED
2041e50: 92 10 20 64 mov 0x64, %o1 <== NOT EXECUTED
2041e54: 40 00 82 cc call 2062984 <.udiv> <== NOT EXECUTED
2041e58: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
2041e5c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041e60: 22 80 00 07 be,a 2041e7c <rtems_rfs_format+0x184> <== NOT EXECUTED
2041e64: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
2041e68: 90 02 3f ff add %o0, -1, %o0 <== NOT EXECUTED
2041e6c: 40 00 82 c6 call 2062984 <.udiv> <== NOT EXECUTED
2041e70: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2041e74: a2 02 20 01 add %o0, 1, %l1 <== NOT EXECUTED
* The number of inodes per group is set as a percentage.
*/
if (config->inode_overhead)
inode_overhead = config->inode_overhead;
fs->group_inodes = rtems_rfs_inodes_from_percent (fs, inode_overhead);
2041e78: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
2041e7c: 40 00 82 c2 call 2062984 <.udiv> <== NOT EXECUTED
2041e80: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2041e84: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2041e88: 7f ff 03 41 call 2002b8c <.umul> <== NOT EXECUTED
2041e8c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2041e90: d0 27 bf 54 st %o0, [ %fp + -172 ] <== NOT EXECUTED
}
/*
* Round up to fill a block because the minimum allocation unit is a block.
*/
fs->inodes_per_block = rtems_rfs_fs_block_size (fs) / RTEMS_RFS_INODE_SIZE;
2041e94: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2041e98: 40 00 82 bb call 2062984 <.udiv> <== NOT EXECUTED
2041e9c: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
fs->group_inodes =
rtems_rfs_rup_quotient (fs->group_inodes,
2041ea0: c2 07 bf 54 ld [ %fp + -172 ], %g1 <== NOT EXECUTED
}
/*
* Round up to fill a block because the minimum allocation unit is a block.
*/
fs->inodes_per_block = rtems_rfs_fs_block_size (fs) / RTEMS_RFS_INODE_SIZE;
2041ea4: d0 27 bf 58 st %o0, [ %fp + -168 ] <== NOT EXECUTED
2041ea8: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
2041eac: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041eb0: 02 80 00 06 be 2041ec8 <rtems_rfs_format+0x1d0> <== NOT EXECUTED
2041eb4: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
2041eb8: 90 00 7f ff add %g1, -1, %o0 <== NOT EXECUTED
2041ebc: 40 00 82 b2 call 2062984 <.udiv> <== NOT EXECUTED
2041ec0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2041ec4: 90 02 20 01 inc %o0 <== NOT EXECUTED
/*
* Round up to fill a block because the minimum allocation unit is a block.
*/
fs->inodes_per_block = rtems_rfs_fs_block_size (fs) / RTEMS_RFS_INODE_SIZE;
fs->group_inodes =
rtems_rfs_rup_quotient (fs->group_inodes,
2041ec8: 7f ff 03 31 call 2002b8c <.umul> <== NOT EXECUTED
2041ecc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
fs->inodes_per_block) * fs->inodes_per_block;
if (fs->group_inodes > rtems_rfs_bitmap_numof_bits (fs->block_size))
2041ed0: 83 2c 20 03 sll %l0, 3, %g1 <== NOT EXECUTED
2041ed4: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
2041ed8: 08 80 00 03 bleu 2041ee4 <rtems_rfs_format+0x1ec> <== NOT EXECUTED
2041edc: d0 27 bf 54 st %o0, [ %fp + -172 ] <== NOT EXECUTED
fs->group_inodes = rtems_rfs_bitmap_numof_bits (fs->block_size);
2041ee0: c2 27 bf 54 st %g1, [ %fp + -172 ] <== NOT EXECUTED
fs->max_name_length = config->max_name_length;
2041ee4: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
if (!fs->max_name_length)
2041ee8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041eec: 12 80 00 04 bne 2041efc <rtems_rfs_format+0x204> <== NOT EXECUTED
2041ef0: c2 27 bf 44 st %g1, [ %fp + -188 ] <== NOT EXECUTED
{
fs->max_name_length = 512;
2041ef4: 82 10 22 00 mov 0x200, %g1 <== NOT EXECUTED
2041ef8: c2 27 bf 44 st %g1, [ %fp + -188 ] <== NOT EXECUTED
* Check the configuration data.
*/
if (!rtems_rfs_check_config (&fs, config))
return -1;
if (config->verbose)
2041efc: c2 0e 60 15 ldub [ %i1 + 0x15 ], %g1 <== NOT EXECUTED
2041f00: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041f04: 02 80 00 4d be 2042038 <rtems_rfs_format+0x340> <== NOT EXECUTED
2041f08: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
{
printf ("rtems-rfs: format: media size = %" PRIu64 "\n",
2041f0c: 7f ff fd aa call 20415b4 <rtems_rfs_fs_media_size> <== NOT EXECUTED
2041f10: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2041f14: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
2041f18: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2041f1c: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f20: 40 00 33 53 call 204ec6c <printf> <== NOT EXECUTED
2041f24: 90 12 21 40 or %o0, 0x140, %o0 ! 206e540 <__FUNCTION__.7699+0x160><== NOT EXECUTED
rtems_rfs_fs_media_size (&fs));
printf ("rtems-rfs: format: media blocks = %" PRIu32 "\n",
2041f28: c2 07 bf 38 ld [ %fp + -200 ], %g1 <== NOT EXECUTED
2041f2c: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f30: d2 00 60 1c ld [ %g1 + 0x1c ], %o1 <== NOT EXECUTED
2041f34: 40 00 33 4e call 204ec6c <printf> <== NOT EXECUTED
2041f38: 90 12 21 68 or %o0, 0x168, %o0 <== NOT EXECUTED
rtems_rfs_fs_media_blocks (&fs));
printf ("rtems-rfs: format: media block size = %" PRIu32 "\n",
2041f3c: c2 07 bf 38 ld [ %fp + -200 ], %g1 <== NOT EXECUTED
2041f40: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f44: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2041f48: 40 00 33 49 call 204ec6c <printf> <== NOT EXECUTED
2041f4c: 90 12 21 90 or %o0, 0x190, %o0 <== NOT EXECUTED
rtems_rfs_fs_media_block_size (&fs));
printf ("rtems-rfs: format: size = %" PRIu64 "\n",
2041f50: 7f ff fd 90 call 2041590 <rtems_rfs_fs_size> <== NOT EXECUTED
2041f54: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2041f58: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
2041f5c: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2041f60: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f64: 40 00 33 42 call 204ec6c <printf> <== NOT EXECUTED
2041f68: 90 12 21 c0 or %o0, 0x1c0, %o0 ! 206e5c0 <__FUNCTION__.7699+0x1e0><== NOT EXECUTED
rtems_rfs_fs_size (&fs));
printf ("rtems-rfs: format: blocks = %zu\n",
2041f6c: d2 07 bf 30 ld [ %fp + -208 ], %o1 <== NOT EXECUTED
2041f70: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f74: 40 00 33 3e call 204ec6c <printf> <== NOT EXECUTED
2041f78: 90 12 21 e0 or %o0, 0x1e0, %o0 ! 206e5e0 <__FUNCTION__.7699+0x200><== NOT EXECUTED
rtems_rfs_fs_blocks (&fs));
printf ("rtems-rfs: format: block size = %zu\n",
2041f7c: d2 07 bf 34 ld [ %fp + -204 ], %o1 <== NOT EXECUTED
2041f80: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f84: 40 00 33 3a call 204ec6c <printf> <== NOT EXECUTED
2041f88: 90 12 22 08 or %o0, 0x208, %o0 ! 206e608 <__FUNCTION__.7699+0x228><== NOT EXECUTED
rtems_rfs_fs_block_size (&fs));
printf ("rtems-rfs: format: bits per block = %u\n",
2041f8c: d2 07 bf 34 ld [ %fp + -204 ], %o1 <== NOT EXECUTED
2041f90: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041f94: 93 2a 60 03 sll %o1, 3, %o1 <== NOT EXECUTED
2041f98: 40 00 33 35 call 204ec6c <printf> <== NOT EXECUTED
2041f9c: 90 12 22 30 or %o0, 0x230, %o0 <== NOT EXECUTED
rtems_rfs_bits_per_block (&fs));
printf ("rtems-rfs: format: inode size = %zu\n", RTEMS_RFS_INODE_SIZE);
2041fa0: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
2041fa4: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041fa8: 40 00 33 31 call 204ec6c <printf> <== NOT EXECUTED
2041fac: 90 12 22 58 or %o0, 0x258, %o0 ! 206e658 <__FUNCTION__.7699+0x278><== NOT EXECUTED
printf ("rtems-rfs: format: inodes = %zu (%d.%d%%)\n",
2041fb0: 7f ff ff 2d call 2041c64 <rtems_rfs_inode_overhead> <== NOT EXECUTED
2041fb4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2041fb8: d2 07 bf 54 ld [ %fp + -172 ], %o1 <== NOT EXECUTED
2041fbc: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2041fc0: 7f ff 02 f3 call 2002b8c <.umul> <== NOT EXECUTED
2041fc4: d0 07 bf 4c ld [ %fp + -180 ], %o0 <== NOT EXECUTED
2041fc8: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2041fcc: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
2041fd0: 40 00 82 6f call 206298c <.div> <== NOT EXECUTED
2041fd4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2041fd8: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2041fdc: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
2041fe0: 40 00 83 17 call 2062c3c <.rem> <== NOT EXECUTED
2041fe4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2041fe8: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
2041fec: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2041ff0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2041ff4: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2041ff8: 40 00 33 1d call 204ec6c <printf> <== NOT EXECUTED
2041ffc: 90 12 22 80 or %o0, 0x280, %o0 ! 206e680 <__FUNCTION__.7699+0x2a0><== NOT EXECUTED
fs.group_inodes * fs.group_count,
rtems_rfs_inode_overhead (&fs) / 10,
rtems_rfs_inode_overhead (&fs) % 10);
printf ("rtems-rfs: format: groups = %u\n", fs.group_count);
2042000: d2 07 bf 4c ld [ %fp + -180 ], %o1 <== NOT EXECUTED
2042004: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042008: 40 00 33 19 call 204ec6c <printf> <== NOT EXECUTED
204200c: 90 12 22 b0 or %o0, 0x2b0, %o0 ! 206e6b0 <__FUNCTION__.7699+0x2d0><== NOT EXECUTED
printf ("rtems-rfs: format: group blocks = %zu\n", fs.group_blocks);
2042010: d2 07 bf 50 ld [ %fp + -176 ], %o1 <== NOT EXECUTED
2042014: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042018: 40 00 33 15 call 204ec6c <printf> <== NOT EXECUTED
204201c: 90 12 22 d0 or %o0, 0x2d0, %o0 ! 206e6d0 <__FUNCTION__.7699+0x2f0><== NOT EXECUTED
printf ("rtems-rfs: format: group inodes = %zu\n", fs.group_inodes);
2042020: d2 07 bf 54 ld [ %fp + -172 ], %o1 <== NOT EXECUTED
2042024: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042028: 40 00 33 11 call 204ec6c <printf> <== NOT EXECUTED
204202c: 90 12 22 f8 or %o0, 0x2f8, %o0 ! 206e6f8 <__FUNCTION__.7699+0x318><== NOT EXECUTED
2042030: e0 07 bf 34 ld [ %fp + -204 ], %l0 <== NOT EXECUTED
}
rc = rtems_rfs_buffer_setblksize (&fs, rtems_rfs_fs_block_size (&fs));
2042034: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042038: 7f ff f5 b8 call 203f718 <rtems_rfs_buffer_setblksize> <== NOT EXECUTED
204203c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (rc > 0)
2042040: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042044: 14 80 01 ef bg 2042800 <rtems_rfs_format+0xb08> <== NOT EXECUTED
2042048: aa 07 bf ec add %fp, -20, %l5 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
204204c: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2042050: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
handle->buffer = NULL;
2042054: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
printf ("rtems-rfs: write-superblock: handle open failed: %d: %s\n",
rc, strerror (rc));
return false;
}
rc = rtems_rfs_buffer_handle_request (fs, &handle, 0, false);
2042058: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
204205c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2042060: 94 10 20 00 clr %o2 <== NOT EXECUTED
2042064: 7f ff f6 2e call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2042068: 96 10 20 00 clr %o3 <== NOT EXECUTED
if (rc > 0)
204206c: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042070: 04 80 00 55 ble 20421c4 <rtems_rfs_format+0x4cc> <== NOT EXECUTED
2042074: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042078: 7f ff f5 e0 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
204207c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
{
rtems_rfs_buffer_handle_close (fs, &handle);
printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",
2042080: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
2042084: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2042088: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
204208c: 40 00 3b ad call 2050f40 <strerror> <== NOT EXECUTED
2042090: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2042094: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042098: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
204209c: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
20420a0: 40 00 32 f3 call 204ec6c <printf> <== NOT EXECUTED
20420a4: 90 12 23 58 or %o0, 0x358, %o0 ! 206e758 <__FUNCTION__.7699+0x378><== NOT EXECUTED
return -1;
}
if (!rtems_rfs_write_superblock (&fs))
{
printf ("rtems-rfs: format: superblock write failed\n");
20420a8: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
20420ac: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20420b0: 40 00 33 9b call 204ef1c <puts> <== NOT EXECUTED
20420b4: 90 12 23 d0 or %o0, 0x3d0, %o0 <== NOT EXECUTED
return -1;
20420b8: 81 c7 e0 08 ret <== NOT EXECUTED
20420bc: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Check the media.
*/
if (rtems_rfs_fs_media_block_size (&fs) == 0)
{
printf ("rtems-rfs: media block is invalid: %" PRIu32 "\n",
20420c0: 92 10 20 00 clr %o1 <== NOT EXECUTED
20420c4: 90 12 20 a8 or %o0, 0xa8, %o0 <== NOT EXECUTED
20420c8: 40 00 32 e9 call 204ec6c <printf> <== NOT EXECUTED
20420cc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_rfs_fs_media_block_size (&fs));
return -1;
20420d0: 81 c7 e0 08 ret <== NOT EXECUTED
20420d4: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_file_system fs;
int group;
int rc;
if (config->verbose)
printf ("rtems-rfs: format: %s\n", name);
20420d8: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
20420dc: 40 00 32 e4 call 204ec6c <printf> <== NOT EXECUTED
20420e0: 90 12 20 60 or %o0, 0x60, %o0 <== NOT EXECUTED
memset (&fs, 0, sizeof (rtems_rfs_file_system));
20420e4: 10 bf ff 0b b 2041d10 <rtems_rfs_format+0x18> <== NOT EXECUTED
20420e8: a4 07 bf 2c add %fp, -212, %l2 <== NOT EXECUTED
{
/*
* The number of blocks per group is defined by the number of bits in a
* block.
*/
fs->group_blocks = rtems_rfs_bitmap_numof_bits (fs->block_size);
20420ec: e0 07 bf 34 ld [ %fp + -204 ], %l0 <== NOT EXECUTED
20420f0: 83 2c 20 03 sll %l0, 3, %g1 <== NOT EXECUTED
}
if (fs->group_blocks > rtems_rfs_bitmap_numof_bits (fs->block_size))
20420f4: a1 2c 20 03 sll %l0, 3, %l0 <== NOT EXECUTED
20420f8: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED
20420fc: 1a bf ff 3b bcc 2041de8 <rtems_rfs_format+0xf0> <== NOT EXECUTED
2042100: c2 27 bf 50 st %g1, [ %fp + -176 ] <== NOT EXECUTED
{
printf ("group block count is higher than bits in block\n");
2042104: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042108: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
204210c: 40 00 33 84 call 204ef1c <puts> <== NOT EXECUTED
2042110: 90 12 21 10 or %o0, 0x110, %o0 <== NOT EXECUTED
2042114: 81 c7 e0 08 ret <== NOT EXECUTED
2042118: 81 e8 00 00 restore <== NOT EXECUTED
const rtems_rfs_format_config* config)
{
fs->block_size = config->block_size;
if (!fs->block_size)
{
uint64_t total_size = rtems_rfs_fs_media_size (fs);
204211c: 7f ff fd 26 call 20415b4 <rtems_rfs_fs_media_size> <== NOT EXECUTED
2042120: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (total_size >= GIGS (1))
2042124: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2042128: 12 80 00 08 bne 2042148 <rtems_rfs_format+0x450> <== NOT EXECUTED
204212c: 84 10 20 00 clr %g2 <== NOT EXECUTED
2042130: 03 00 03 ff sethi %hi(0xffc00), %g1 <== NOT EXECUTED
2042134: 82 10 63 ff or %g1, 0x3ff, %g1 ! fffff <PROM_START+0xfffff><== NOT EXECUTED
2042138: 80 a2 40 01 cmp %o1, %g1 <== NOT EXECUTED
204213c: 08 80 00 13 bleu 2042188 <rtems_rfs_format+0x490> <== NOT EXECUTED
2042140: e0 07 bf 34 ld [ %fp + -204 ], %l0 <== NOT EXECUTED
{
uint32_t gigs = (total_size + GIGS (1)) / GIGS (1);
2042144: 84 10 20 00 clr %g2 <== NOT EXECUTED
2042148: 07 00 04 00 sethi %hi(0x100000), %g3 <== NOT EXECUTED
204214c: 92 82 40 03 addcc %o1, %g3, %o1 <== NOT EXECUTED
2042150: 83 32 60 14 srl %o1, 0x14, %g1 <== NOT EXECUTED
2042154: 90 42 00 02 addx %o0, %g2, %o0 <== NOT EXECUTED
int b;
for (b = 31; b > 0; b--)
if ((gigs & (1 << b)) != 0)
2042158: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
{
uint64_t total_size = rtems_rfs_fs_media_size (fs);
if (total_size >= GIGS (1))
{
uint32_t gigs = (total_size + GIGS (1)) / GIGS (1);
204215c: 91 2a 20 0c sll %o0, 0xc, %o0 <== NOT EXECUTED
2042160: 86 12 00 01 or %o0, %g1, %g3 <== NOT EXECUTED
2042164: 10 80 00 04 b 2042174 <rtems_rfs_format+0x47c> <== NOT EXECUTED
2042168: 82 10 20 1f mov 0x1f, %g1 <== NOT EXECUTED
int b;
for (b = 31; b > 0; b--)
204216c: 02 80 00 06 be 2042184 <rtems_rfs_format+0x48c> <== NOT EXECUTED
2042170: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
if ((gigs & (1 << b)) != 0)
2042174: a1 28 80 01 sll %g2, %g1, %l0 <== NOT EXECUTED
2042178: 80 8c 00 03 btst %l0, %g3 <== NOT EXECUTED
204217c: 22 bf ff fc be,a 204216c <rtems_rfs_format+0x474> <== NOT EXECUTED
2042180: 82 80 7f ff addcc %g1, -1, %g1 <== NOT EXECUTED
break;
fs->block_size = 1 << b;
2042184: e0 27 bf 34 st %l0, [ %fp + -204 ] <== NOT EXECUTED
}
if (fs->block_size < 512)
2042188: 80 a4 21 ff cmp %l0, 0x1ff <== NOT EXECUTED
204218c: 18 80 00 79 bgu 2042370 <rtems_rfs_format+0x678> <== NOT EXECUTED
2042190: 05 00 00 04 sethi %hi(0x1000), %g2 <== NOT EXECUTED
fs->block_size = 512;
2042194: 82 10 22 00 mov 0x200, %g1 <== NOT EXECUTED
2042198: a0 10 22 00 mov 0x200, %l0 <== NOT EXECUTED
204219c: c2 27 bf 34 st %g1, [ %fp + -204 ] <== NOT EXECUTED
20421a0: 10 bf ff 02 b 2041da8 <rtems_rfs_format+0xb0> <== NOT EXECUTED
20421a4: c2 07 bf 38 ld [ %fp + -200 ], %g1 <== NOT EXECUTED
fs->block_size = (4 * 1024);
}
if ((fs->block_size % rtems_rfs_fs_media_block_size (fs)) != 0)
{
printf ("block size (%zd) is not a multiple of media block size (%" PRId32 ")\n",
20421a8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20421ac: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
20421b0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20421b4: 40 00 32 ae call 204ec6c <printf> <== NOT EXECUTED
20421b8: 90 12 20 d0 or %o0, 0xd0, %o0 <== NOT EXECUTED
20421bc: 81 c7 e0 08 ret <== NOT EXECUTED
20421c0: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",
rc, strerror (rc));
return false;
}
sb = rtems_rfs_buffer_data (&handle);
20421c4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
#define write_sb(_o, _d) rtems_rfs_write_u32(sb + (_o), _d)
memset (sb, 0xff, rtems_rfs_fs_block_size (fs));
20421c8: d4 07 bf 34 ld [ %fp + -204 ], %o2 <== NOT EXECUTED
printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",
rc, strerror (rc));
return false;
}
sb = rtems_rfs_buffer_data (&handle);
20421cc: e0 00 60 24 ld [ %g1 + 0x24 ], %l0 <== NOT EXECUTED
#define write_sb(_o, _d) rtems_rfs_write_u32(sb + (_o), _d)
memset (sb, 0xff, rtems_rfs_fs_block_size (fs));
20421d0: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
20421d4: 40 00 2e 8a call 204dbfc <memset> <== NOT EXECUTED
20421d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_MAGIC, RTEMS_RFS_SB_MAGIC);
20421dc: 84 10 20 28 mov 0x28, %g2 <== NOT EXECUTED
20421e0: c4 2c 00 00 stb %g2, [ %l0 ] <== NOT EXECUTED
20421e4: 84 10 20 09 mov 9, %g2 <== NOT EXECUTED
20421e8: c4 2c 20 01 stb %g2, [ %l0 + 1 ] <== NOT EXECUTED
20421ec: 84 10 20 20 mov 0x20, %g2 <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);
20421f0: c0 2c 20 04 clrb [ %l0 + 4 ] <== NOT EXECUTED
20421f4: c0 2c 20 05 clrb [ %l0 + 5 ] <== NOT EXECUTED
20421f8: c0 2c 20 06 clrb [ %l0 + 6 ] <== NOT EXECUTED
20421fc: c0 2c 20 07 clrb [ %l0 + 7 ] <== NOT EXECUTED
#define write_sb(_o, _d) rtems_rfs_write_u32(sb + (_o), _d)
memset (sb, 0xff, rtems_rfs_fs_block_size (fs));
write_sb (RTEMS_RFS_SB_OFFSET_MAGIC, RTEMS_RFS_SB_MAGIC);
2042200: c4 2c 20 02 stb %g2, [ %l0 + 2 ] <== NOT EXECUTED
2042204: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2042208: c2 2c 20 03 stb %g1, [ %l0 + 3 ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);
write_sb (RTEMS_RFS_SB_OFFSET_BLOCKS, rtems_rfs_fs_blocks (fs));
204220c: c4 0f bf 30 ldub [ %fp + -208 ], %g2 <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES, fs->group_inodes);
write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);
rtems_rfs_buffer_mark_dirty (&handle);
rc = rtems_rfs_buffer_handle_release (fs, &handle);
2042210: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
memset (sb, 0xff, rtems_rfs_fs_block_size (fs));
write_sb (RTEMS_RFS_SB_OFFSET_MAGIC, RTEMS_RFS_SB_MAGIC);
write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);
write_sb (RTEMS_RFS_SB_OFFSET_BLOCKS, rtems_rfs_fs_blocks (fs));
2042214: c4 2c 20 0c stb %g2, [ %l0 + 0xc ] <== NOT EXECUTED
2042218: c4 17 bf 30 lduh [ %fp + -208 ], %g2 <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES, fs->group_inodes);
write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);
rtems_rfs_buffer_mark_dirty (&handle);
rc = rtems_rfs_buffer_handle_release (fs, &handle);
204221c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
memset (sb, 0xff, rtems_rfs_fs_block_size (fs));
write_sb (RTEMS_RFS_SB_OFFSET_MAGIC, RTEMS_RFS_SB_MAGIC);
write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);
write_sb (RTEMS_RFS_SB_OFFSET_BLOCKS, rtems_rfs_fs_blocks (fs));
2042220: c4 2c 20 0d stb %g2, [ %l0 + 0xd ] <== NOT EXECUTED
2042224: c4 07 bf 30 ld [ %fp + -208 ], %g2 <== NOT EXECUTED
2042228: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
204222c: c4 2c 20 0e stb %g2, [ %l0 + 0xe ] <== NOT EXECUTED
2042230: c4 07 bf 30 ld [ %fp + -208 ], %g2 <== NOT EXECUTED
2042234: c4 2c 20 0f stb %g2, [ %l0 + 0xf ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE, rtems_rfs_fs_block_size (fs));
2042238: c4 0f bf 34 ldub [ %fp + -204 ], %g2 <== NOT EXECUTED
204223c: c4 2c 20 08 stb %g2, [ %l0 + 8 ] <== NOT EXECUTED
2042240: c4 17 bf 34 lduh [ %fp + -204 ], %g2 <== NOT EXECUTED
2042244: c4 2c 20 09 stb %g2, [ %l0 + 9 ] <== NOT EXECUTED
2042248: c4 07 bf 34 ld [ %fp + -204 ], %g2 <== NOT EXECUTED
204224c: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
2042250: c4 2c 20 0a stb %g2, [ %l0 + 0xa ] <== NOT EXECUTED
2042254: c4 07 bf 34 ld [ %fp + -204 ], %g2 <== NOT EXECUTED
2042258: c4 2c 20 0b stb %g2, [ %l0 + 0xb ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS, fs->bad_blocks);
204225c: c4 0f bf 40 ldub [ %fp + -192 ], %g2 <== NOT EXECUTED
2042260: c4 2c 20 10 stb %g2, [ %l0 + 0x10 ] <== NOT EXECUTED
2042264: c4 17 bf 40 lduh [ %fp + -192 ], %g2 <== NOT EXECUTED
2042268: c4 2c 20 11 stb %g2, [ %l0 + 0x11 ] <== NOT EXECUTED
204226c: c4 07 bf 40 ld [ %fp + -192 ], %g2 <== NOT EXECUTED
2042270: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
2042274: c4 2c 20 12 stb %g2, [ %l0 + 0x12 ] <== NOT EXECUTED
2042278: c4 07 bf 40 ld [ %fp + -192 ], %g2 <== NOT EXECUTED
204227c: c4 2c 20 13 stb %g2, [ %l0 + 0x13 ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH, fs->max_name_length);
2042280: c4 0f bf 44 ldub [ %fp + -188 ], %g2 <== NOT EXECUTED
2042284: c4 2c 20 14 stb %g2, [ %l0 + 0x14 ] <== NOT EXECUTED
2042288: c4 17 bf 44 lduh [ %fp + -188 ], %g2 <== NOT EXECUTED
204228c: c4 2c 20 15 stb %g2, [ %l0 + 0x15 ] <== NOT EXECUTED
2042290: c4 07 bf 44 ld [ %fp + -188 ], %g2 <== NOT EXECUTED
2042294: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
2042298: c4 2c 20 16 stb %g2, [ %l0 + 0x16 ] <== NOT EXECUTED
204229c: c4 07 bf 44 ld [ %fp + -188 ], %g2 <== NOT EXECUTED
20422a0: c4 2c 20 17 stb %g2, [ %l0 + 0x17 ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_GROUPS, fs->group_count);
20422a4: c4 0f bf 4c ldub [ %fp + -180 ], %g2 <== NOT EXECUTED
20422a8: c4 2c 20 18 stb %g2, [ %l0 + 0x18 ] <== NOT EXECUTED
20422ac: c4 17 bf 4c lduh [ %fp + -180 ], %g2 <== NOT EXECUTED
20422b0: c4 2c 20 19 stb %g2, [ %l0 + 0x19 ] <== NOT EXECUTED
20422b4: c4 07 bf 4c ld [ %fp + -180 ], %g2 <== NOT EXECUTED
20422b8: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
20422bc: c4 2c 20 1a stb %g2, [ %l0 + 0x1a ] <== NOT EXECUTED
20422c0: c4 07 bf 4c ld [ %fp + -180 ], %g2 <== NOT EXECUTED
20422c4: c4 2c 20 1b stb %g2, [ %l0 + 0x1b ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS, fs->group_blocks);
20422c8: c4 0f bf 50 ldub [ %fp + -176 ], %g2 <== NOT EXECUTED
20422cc: c4 2c 20 1c stb %g2, [ %l0 + 0x1c ] <== NOT EXECUTED
20422d0: c4 17 bf 50 lduh [ %fp + -176 ], %g2 <== NOT EXECUTED
20422d4: c4 2c 20 1d stb %g2, [ %l0 + 0x1d ] <== NOT EXECUTED
20422d8: c4 07 bf 50 ld [ %fp + -176 ], %g2 <== NOT EXECUTED
20422dc: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
20422e0: c4 2c 20 1e stb %g2, [ %l0 + 0x1e ] <== NOT EXECUTED
20422e4: c4 07 bf 50 ld [ %fp + -176 ], %g2 <== NOT EXECUTED
20422e8: c4 2c 20 1f stb %g2, [ %l0 + 0x1f ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES, fs->group_inodes);
20422ec: c4 0f bf 54 ldub [ %fp + -172 ], %g2 <== NOT EXECUTED
20422f0: c4 2c 20 20 stb %g2, [ %l0 + 0x20 ] <== NOT EXECUTED
20422f4: c4 17 bf 54 lduh [ %fp + -172 ], %g2 <== NOT EXECUTED
20422f8: c4 2c 20 21 stb %g2, [ %l0 + 0x21 ] <== NOT EXECUTED
20422fc: c4 07 bf 54 ld [ %fp + -172 ], %g2 <== NOT EXECUTED
2042300: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
2042304: c4 2c 20 22 stb %g2, [ %l0 + 0x22 ] <== NOT EXECUTED
2042308: c4 07 bf 54 ld [ %fp + -172 ], %g2 <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);
204230c: c0 2c 20 24 clrb [ %l0 + 0x24 ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE, rtems_rfs_fs_block_size (fs));
write_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS, fs->bad_blocks);
write_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH, fs->max_name_length);
write_sb (RTEMS_RFS_SB_OFFSET_GROUPS, fs->group_count);
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS, fs->group_blocks);
write_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES, fs->group_inodes);
2042310: c4 2c 20 23 stb %g2, [ %l0 + 0x23 ] <== NOT EXECUTED
write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);
2042314: c0 2c 20 25 clrb [ %l0 + 0x25 ] <== NOT EXECUTED
2042318: c0 2c 20 26 clrb [ %l0 + 0x26 ] <== NOT EXECUTED
204231c: 84 10 20 38 mov 0x38, %g2 <== NOT EXECUTED
2042320: c4 2c 20 27 stb %g2, [ %l0 + 0x27 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle);
rc = rtems_rfs_buffer_handle_release (fs, &handle);
2042324: 7f ff f5 35 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042328: c2 2f bf ec stb %g1, [ %fp + -20 ] <== NOT EXECUTED
if (rc > 0)
204232c: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042330: 04 80 00 1f ble 20423ac <rtems_rfs_format+0x6b4> <== NOT EXECUTED
2042334: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042338: 7f ff f5 30 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
204233c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
{
rtems_rfs_buffer_handle_close (fs, &handle);
printf ("rtems-rfs: write-superblock: buffer release failed: %d: %s\n",
2042340: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
handle->dirty = false;
2042344: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2042348: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
204234c: 40 00 3a fd call 2050f40 <strerror> <== NOT EXECUTED
2042350: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2042354: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042358: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
204235c: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042360: 40 00 32 43 call 204ec6c <printf> <== NOT EXECUTED
2042364: 90 12 23 90 or %o0, 0x390, %o0 ! 206e790 <__FUNCTION__.7699+0x3b0><== NOT EXECUTED
return -1;
}
if (!rtems_rfs_write_superblock (&fs))
{
printf ("rtems-rfs: format: superblock write failed\n");
2042368: 10 bf ff 51 b 20420ac <rtems_rfs_format+0x3b4> <== NOT EXECUTED
204236c: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
}
if (fs->block_size < 512)
fs->block_size = 512;
if (fs->block_size > (4 * 1024))
2042370: 80 a4 00 02 cmp %l0, %g2 <== NOT EXECUTED
2042374: 08 bf fe 8d bleu 2041da8 <rtems_rfs_format+0xb0> <== NOT EXECUTED
2042378: c2 07 bf 38 ld [ %fp + -200 ], %g1 <== NOT EXECUTED
fs->block_size = (4 * 1024);
204237c: c4 27 bf 34 st %g2, [ %fp + -204 ] <== NOT EXECUTED
2042380: 10 bf fe 8a b 2041da8 <rtems_rfs_format+0xb0> <== NOT EXECUTED
2042384: a0 10 00 02 mov %g2, %l0 <== NOT EXECUTED
* Open the buffer interface.
*/
rc = rtems_rfs_buffer_open (name, &fs);
if (rc > 0)
{
printf ("rtems-rfs: format: buffer open failed: %d: %s\n",
2042388: 40 00 3a ee call 2050f40 <strerror> <== NOT EXECUTED
204238c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042390: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042394: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042398: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
204239c: 40 00 32 34 call 204ec6c <printf> <== NOT EXECUTED
20423a0: 90 12 20 78 or %o0, 0x78, %o0 ! 206e478 <__FUNCTION__.7699+0x98><== NOT EXECUTED
rc, strerror (rc));
return -1;
20423a4: 81 c7 e0 08 ret <== NOT EXECUTED
20423a8: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20423ac: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20423b0: 7f ff f5 12 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20423b4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
{
printf ("rtems-rfs: format: superblock write failed\n");
return -1;
}
for (group = 0; group < fs.group_count; group++)
20423b8: c2 07 bf 4c ld [ %fp + -180 ], %g1 <== NOT EXECUTED
handle->dirty = false;
20423bc: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
20423c0: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
20423c4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20423c8: 04 80 00 a8 ble 2042668 <rtems_rfs_format+0x970> <== NOT EXECUTED
20423cc: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
if (group_base > rtems_rfs_fs_blocks (fs))
20423d0: c2 07 bf 30 ld [ %fp + -208 ], %g1 <== NOT EXECUTED
return -1;
}
for (group = 0; group < fs.group_count; group++)
if (!rtems_rfs_write_group (&fs, group,
config->initialise_inodes, config->verbose))
20423d4: ee 0e 60 14 ldub [ %i1 + 0x14 ], %l7 <== NOT EXECUTED
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
if (group_base > rtems_rfs_fs_blocks (fs))
20423d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
return -1;
}
for (group = 0; group < fs.group_count; group++)
if (!rtems_rfs_write_group (&fs, group,
config->initialise_inodes, config->verbose))
20423dc: fa 0e 60 15 ldub [ %i1 + 0x15 ], %i5 <== NOT EXECUTED
size_t group_size;
int blocks;
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
20423e0: e0 07 bf 50 ld [ %fp + -176 ], %l0 <== NOT EXECUTED
if (group_base > rtems_rfs_fs_blocks (fs))
20423e4: 02 80 00 62 be 204256c <rtems_rfs_format+0x874> <== NOT EXECUTED
20423e8: a8 10 20 00 clr %l4 <== NOT EXECUTED
*/
if ((group_base + group_size) > rtems_rfs_fs_blocks (fs))
group_size = rtems_rfs_fs_blocks (fs) - group_base;
if (verbose)
printf ("\rrtems-rfs: format: group %3d: base = %" PRId32 ", size = %zd",
20423ec: 37 00 81 ba sethi %hi(0x206e800), %i3 <== NOT EXECUTED
rc, strerror (rc));
return false;
}
if (verbose)
printf (", blocks");
20423f0: 39 00 81 ba sethi %hi(0x206e800), %i4 <== NOT EXECUTED
*/
if ((group_base + group_size) > rtems_rfs_fs_blocks (fs))
group_size = rtems_rfs_fs_blocks (fs) - group_base;
if (verbose)
printf ("\rrtems-rfs: format: group %3d: base = %" PRId32 ", size = %zd",
20423f4: b6 16 e0 40 or %i3, 0x40, %i3 <== NOT EXECUTED
rc, strerror (rc));
return false;
}
if (verbose)
printf (", blocks");
20423f8: b8 17 20 78 or %i4, 0x78, %i4 <== NOT EXECUTED
group_base = rtems_rfs_fs_block (fs, group, 0);
if (group_base > rtems_rfs_fs_blocks (fs))
{
printf ("rtems-rfs: write-group: group %d base beyond disk limit\n",
20423fc: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
2042400: a8 10 20 00 clr %l4 <== NOT EXECUTED
2042404: a6 07 bf d4 add %fp, -44, %l3 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: close block bitmap failed: %d: %s\n",
group, rc, strerror (rc));
return false;
}
rtems_rfs_buffer_mark_dirty (&handle);
2042408: b4 10 20 01 mov 1, %i2 <== NOT EXECUTED
/*
* Be nice to strange sizes of disks. These are embedded systems after all
* and nice numbers do not always work out. Let the last block pick up the
* remainder of the blocks.
*/
if ((group_base + group_size) > rtems_rfs_fs_blocks (fs))
204240c: 84 04 00 11 add %l0, %l1, %g2 <== NOT EXECUTED
2042410: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2042414: 2a 80 00 02 bcs,a 204241c <rtems_rfs_format+0x724> <== NOT EXECUTED
2042418: a0 20 40 11 sub %g1, %l1, %l0 <== NOT EXECUTED
group_size = rtems_rfs_fs_blocks (fs) - group_base;
if (verbose)
204241c: ba 8f 60 ff andcc %i5, 0xff, %i5 <== NOT EXECUTED
2042420: 12 80 00 3b bne 204250c <rtems_rfs_format+0x814> <== NOT EXECUTED
2042424: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2042428: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
204242c: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
handle->buffer = NULL;
2042430: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
printf (", blocks");
/*
* Open the block bitmap using the new buffer.
*/
rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,
2042434: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2042438: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
204243c: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
2042440: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2042444: 40 00 1c 36 call 204951c <rtems_rfs_bitmap_open> <== NOT EXECUTED
2042448: 98 10 00 11 mov %l1, %o4 <== NOT EXECUTED
group_base + RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
if (rc > 0)
204244c: ac 92 20 00 orcc %o0, 0, %l6 <== NOT EXECUTED
2042450: 04 80 00 12 ble 2042498 <rtems_rfs_format+0x7a0> <== NOT EXECUTED
2042454: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042458: 7f ff f4 e8 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
204245c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
{
rtems_rfs_buffer_handle_close (fs, &handle);
printf ("\nrtems-rfs: write-group: group %3d: open block bitmap failed: %d: %s\n",
2042460: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
handle->dirty = false;
2042464: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2042468: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
204246c: 40 00 3a b5 call 2050f40 <strerror> <== NOT EXECUTED
2042470: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2042474: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042478: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
204247c: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
2042480: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042484: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042488: 40 00 31 f9 call 204ec6c <printf> <== NOT EXECUTED
204248c: 90 12 20 88 or %o0, 0x88, %o0 <== NOT EXECUTED
2042490: 81 c7 e0 08 ret <== NOT EXECUTED
2042494: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Force the whole buffer to a known state. The bit map may not occupy the
* whole block.
*/
memset (rtems_rfs_buffer_data (&handle), 0xff, rtems_rfs_fs_block_size (fs));
2042498: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
204249c: d4 07 bf 34 ld [ %fp + -204 ], %o2 <== NOT EXECUTED
20424a0: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
20424a4: 40 00 2d d6 call 204dbfc <memset> <== NOT EXECUTED
20424a8: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
/*
* Clear the bitmap.
*/
rc = rtems_rfs_bitmap_map_clear_all (&bitmap);
20424ac: 40 00 1c 2d call 2049560 <rtems_rfs_bitmap_map_clear_all> <== NOT EXECUTED
20424b0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (rc > 0)
20424b4: ac 92 20 00 orcc %o0, 0, %l6 <== NOT EXECUTED
20424b8: 04 80 00 34 ble 2042588 <rtems_rfs_format+0x890> <== NOT EXECUTED
20424bc: 92 10 20 00 clr %o1 <== NOT EXECUTED
{
rtems_rfs_bitmap_close (&bitmap);
20424c0: 40 00 1b c0 call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
20424c4: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20424c8: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20424cc: 7f ff f4 cb call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20424d0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle);
printf ("\nrtems-rfs: write-group: group %3d: block bitmap clear all failed: %d: %s\n",
20424d4: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
handle->dirty = false;
20424d8: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
20424dc: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
20424e0: 40 00 3a 98 call 2050f40 <strerror> <== NOT EXECUTED
20424e4: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
20424e8: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20424ec: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20424f0: 94 10 00 16 mov %l6, %o2 <== NOT EXECUTED
20424f4: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
20424f8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20424fc: 40 00 31 dc call 204ec6c <printf> <== NOT EXECUTED
2042500: 90 12 20 d0 or %o0, 0xd0, %o0 <== NOT EXECUTED
2042504: 81 c7 e0 08 ret <== NOT EXECUTED
2042508: 81 e8 00 00 restore <== NOT EXECUTED
*/
if ((group_base + group_size) > rtems_rfs_fs_blocks (fs))
group_size = rtems_rfs_fs_blocks (fs) - group_base;
if (verbose)
printf ("\rrtems-rfs: format: group %3d: base = %" PRId32 ", size = %zd",
204250c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042510: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2042514: 40 00 31 d6 call 204ec6c <printf> <== NOT EXECUTED
2042518: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
rc, strerror (rc));
return false;
}
if (verbose)
printf (", blocks");
204251c: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2042520: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2042524: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
2042528: 40 00 31 d1 call 204ec6c <printf> <== NOT EXECUTED
204252c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
/*
* Open the block bitmap using the new buffer.
*/
rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,
2042530: 10 bf ff c2 b 2042438 <rtems_rfs_format+0x740> <== NOT EXECUTED
2042534: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
{
printf ("rtems-rfs: format: superblock write failed\n");
return -1;
}
for (group = 0; group < fs.group_count; group++)
2042538: a8 05 20 01 inc %l4 <== NOT EXECUTED
204253c: 80 a0 40 14 cmp %g1, %l4 <== NOT EXECUTED
2042540: 04 80 00 4a ble 2042668 <rtems_rfs_format+0x970> <== NOT EXECUTED
2042544: e0 07 bf 50 ld [ %fp + -176 ], %l0 <== NOT EXECUTED
size_t group_size;
int blocks;
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
2042548: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
204254c: 7f ff 01 90 call 2002b8c <.umul> <== NOT EXECUTED
2042550: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (group_base > rtems_rfs_fs_blocks (fs))
2042554: c2 07 bf 30 ld [ %fp + -208 ], %g1 <== NOT EXECUTED
size_t group_size;
int blocks;
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
2042558: a2 02 20 01 add %o0, 1, %l1 <== NOT EXECUTED
return -1;
}
for (group = 0; group < fs.group_count; group++)
if (!rtems_rfs_write_group (&fs, group,
config->initialise_inodes, config->verbose))
204255c: ee 0e 60 14 ldub [ %i1 + 0x14 ], %l7 <== NOT EXECUTED
int b;
int rc;
group_base = rtems_rfs_fs_block (fs, group, 0);
if (group_base > rtems_rfs_fs_blocks (fs))
2042560: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2042564: 08 bf ff aa bleu 204240c <rtems_rfs_format+0x714> <== NOT EXECUTED
2042568: fa 0e 60 15 ldub [ %i1 + 0x15 ], %i5 <== NOT EXECUTED
{
printf ("rtems-rfs: write-group: group %d base beyond disk limit\n",
204256c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042570: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042574: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042578: 40 00 31 bd call 204ec6c <printf> <== NOT EXECUTED
204257c: 90 12 20 00 mov %o0, %o0 <== NOT EXECUTED
2042580: 81 c7 e0 08 ret <== NOT EXECUTED
2042584: 81 e8 00 00 restore <== NOT EXECUTED
}
/*
* Forced allocation of the block bitmap.
*/
rtems_rfs_bitmap_map_set (&bitmap, RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
2042588: 40 00 1c 8e call 20497c0 <rtems_rfs_bitmap_map_set> <== NOT EXECUTED
204258c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
/*
* Forced allocation of the inode bitmap.
*/
rtems_rfs_bitmap_map_set (&bitmap, RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
2042590: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2042594: 40 00 1c 8b call 20497c0 <rtems_rfs_bitmap_map_set> <== NOT EXECUTED
2042598: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
/*
* Determine the number of inodes blocks in the group.
*/
blocks = rtems_rfs_rup_quotient (fs->group_inodes, fs->inodes_per_block);
204259c: d0 07 bf 54 ld [ %fp + -172 ], %o0 <== NOT EXECUTED
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
20425a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20425a4: 12 80 00 2a bne 204264c <rtems_rfs_format+0x954> <== NOT EXECUTED
20425a8: d2 07 bf 58 ld [ %fp + -168 ], %o1 <== NOT EXECUTED
20425ac: ac 10 20 01 mov 1, %l6 <== NOT EXECUTED
20425b0: 82 10 20 00 clr %g1 <== NOT EXECUTED
/*
* Forced allocation of the inode blocks which follow the block bitmap.
*/
for (b = 0; b < blocks; b++)
rtems_rfs_bitmap_map_set (&bitmap, b + RTEMS_RFS_GROUP_INODE_BLOCK);
20425b4: 92 00 60 02 add %g1, 2, %o1 <== NOT EXECUTED
20425b8: c2 27 bf 24 st %g1, [ %fp + -220 ] <== NOT EXECUTED
20425bc: 40 00 1c 81 call 20497c0 <rtems_rfs_bitmap_map_set> <== NOT EXECUTED
20425c0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
blocks = rtems_rfs_rup_quotient (fs->group_inodes, fs->inodes_per_block);
/*
* Forced allocation of the inode blocks which follow the block bitmap.
*/
for (b = 0; b < blocks; b++)
20425c4: c2 07 bf 24 ld [ %fp + -220 ], %g1 <== NOT EXECUTED
20425c8: 82 00 60 01 inc %g1 <== NOT EXECUTED
20425cc: 80 a0 40 16 cmp %g1, %l6 <== NOT EXECUTED
20425d0: 06 bf ff fa bl 20425b8 <rtems_rfs_format+0x8c0> <== NOT EXECUTED
20425d4: 92 00 60 02 add %g1, 2, %o1 <== NOT EXECUTED
rtems_rfs_bitmap_map_set (&bitmap, b + RTEMS_RFS_GROUP_INODE_BLOCK);
/*
* Close the block bitmap.
*/
rc = rtems_rfs_bitmap_close (&bitmap);
20425d8: 40 00 1b 7a call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
20425dc: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (rc > 0)
20425e0: 94 92 20 00 orcc %o0, 0, %o2 <== NOT EXECUTED
20425e4: 14 80 00 42 bg 20426ec <rtems_rfs_format+0x9f4> <== NOT EXECUTED
20425e8: 80 a7 60 00 cmp %i5, 0 <== NOT EXECUTED
return false;
}
rtems_rfs_buffer_mark_dirty (&handle);
if (verbose)
20425ec: 12 80 00 6a bne 2042794 <rtems_rfs_format+0xa9c> <== NOT EXECUTED
20425f0: f4 2f bf ec stb %i2, [ %fp + -20 ] <== NOT EXECUTED
printf (", inodes");
/*
* Open the inode bitmap using the old buffer. Should release any changes.
*/
rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,
20425f4: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
20425f8: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
20425fc: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2042600: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED
2042604: 40 00 1b c6 call 204951c <rtems_rfs_bitmap_open> <== NOT EXECUTED
2042608: 98 04 60 01 add %l1, 1, %o4 <== NOT EXECUTED
group_base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
if (rc > 0)
204260c: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042610: 04 80 00 47 ble 204272c <rtems_rfs_format+0xa34> <== NOT EXECUTED
2042614: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
{
rtems_rfs_buffer_handle_close (fs, &handle);
2042618: 7f ff fd ae call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
204261c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: open inode bitmap failed: %d: %s\n",
2042620: 40 00 3a 48 call 2050f40 <strerror> <== NOT EXECUTED
2042624: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2042628: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
204262c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2042630: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2042634: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042638: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
204263c: 40 00 31 8c call 204ec6c <printf> <== NOT EXECUTED
2042640: 90 12 21 78 or %o0, 0x178, %o0 <== NOT EXECUTED
2042644: 81 c7 e0 08 ret <== NOT EXECUTED
2042648: 81 e8 00 00 restore <== NOT EXECUTED
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
return 1;
return ((dividend - 1) / divisor) + 1;
204264c: 40 00 80 ce call 2062984 <.udiv> <== NOT EXECUTED
2042650: 90 02 3f ff add %o0, -1, %o0 <== NOT EXECUTED
2042654: ac 02 20 01 add %o0, 1, %l6 <== NOT EXECUTED
blocks = rtems_rfs_rup_quotient (fs->group_inodes, fs->inodes_per_block);
/*
* Forced allocation of the inode blocks which follow the block bitmap.
*/
for (b = 0; b < blocks; b++)
2042658: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED
204265c: 14 bf ff d6 bg 20425b4 <rtems_rfs_format+0x8bc> <== NOT EXECUTED
2042660: 82 10 20 00 clr %g1 <== NOT EXECUTED
2042664: 30 bf ff dd b,a 20425d8 <rtems_rfs_format+0x8e0> <== NOT EXECUTED
for (group = 0; group < fs.group_count; group++)
if (!rtems_rfs_write_group (&fs, group,
config->initialise_inodes, config->verbose))
return -1;
if (config->verbose)
2042668: c2 0e 60 15 ldub [ %i1 + 0x15 ], %g1 <== NOT EXECUTED
204266c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2042670: 12 80 00 61 bne 20427f4 <rtems_rfs_format+0xafc> <== NOT EXECUTED
2042674: 01 00 00 00 nop <== NOT EXECUTED
printf ("\n");
rc = rtems_rfs_buffer_close (&fs);
2042678: 7f ff f4 3e call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
204267c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (rc > 0)
2042680: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042684: 14 80 00 ac bg 2042934 <rtems_rfs_format+0xc3c> <== NOT EXECUTED
2042688: 92 10 20 00 clr %o1 <== NOT EXECUTED
int rc;
/*
* External API so returns -1.
*/
rc = rtems_rfs_fs_open (name, NULL,
204268c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2042690: 94 10 20 06 mov 6, %o2 <== NOT EXECUTED
2042694: 96 10 20 00 clr %o3 <== NOT EXECUTED
2042698: 7f ff fb f2 call 2041660 <rtems_rfs_fs_open> <== NOT EXECUTED
204269c: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
RTEMS_RFS_FS_FORCE_OPEN | RTEMS_RFS_FS_NO_LOCAL_CACHE,
0, &fs);
if (rc < 0)
20426a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20426a4: 06 80 01 01 bl 2042aa8 <rtems_rfs_format+0xdb0> <== NOT EXECUTED
20426a8: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
printf ("rtems-rfs: format: file system open failed: %d: %s\n",
errno, strerror (errno));
return -1;
}
rc = rtems_rfs_inode_alloc (fs, RTEMS_RFS_ROOT_INO, &ino);
20426ac: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
20426b0: 40 00 03 db call 204361c <rtems_rfs_inode_alloc> <== NOT EXECUTED
20426b4: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
if (rc > 0)
20426b8: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20426bc: 14 80 00 3b bg 20427a8 <rtems_rfs_format+0xab0> <== NOT EXECUTED
20426c0: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
rc, strerror (rc));
rtems_rfs_fs_close (fs);
return rc;
}
if (ino != RTEMS_RFS_ROOT_INO)
20426c4: 80 a2 60 01 cmp %o1, 1 <== NOT EXECUTED
20426c8: 02 80 00 57 be 2042824 <rtems_rfs_format+0xb2c> <== NOT EXECUTED
20426cc: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
{
printf ("rtems-rfs: format: allocated inode not root ino: %" PRId32 "\n", ino);
20426d0: 40 00 31 67 call 204ec6c <printf> <== NOT EXECUTED
20426d4: 90 12 23 80 or %o0, 0x380, %o0 ! 206eb80 <__FUNCTION__.7699+0x7a0><== NOT EXECUTED
rtems_rfs_fs_close (fs);
20426d8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
20426dc: 7f ff fb c0 call 20415dc <rtems_rfs_fs_close> <== NOT EXECUTED
20426e0: b0 10 20 00 clr %i0 <== NOT EXECUTED
20426e4: 81 c7 e0 08 ret <== NOT EXECUTED
20426e8: 81 e8 00 00 restore <== NOT EXECUTED
* Close the block bitmap.
*/
rc = rtems_rfs_bitmap_close (&bitmap);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &handle);
20426ec: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20426f0: d4 27 bf 24 st %o2, [ %fp + -220 ] <== NOT EXECUTED
20426f4: 7f ff fd 77 call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
20426f8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: close block bitmap failed: %d: %s\n",
20426fc: d4 07 bf 24 ld [ %fp + -220 ], %o2 <== NOT EXECUTED
2042700: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042704: 40 00 3a 0f call 2050f40 <strerror> <== NOT EXECUTED
2042708: 90 10 00 0a mov %o2, %o0 <== NOT EXECUTED
204270c: d4 07 bf 24 ld [ %fp + -220 ], %o2 <== NOT EXECUTED
2042710: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2042714: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042718: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
204271c: 40 00 31 54 call 204ec6c <printf> <== NOT EXECUTED
2042720: 90 12 21 20 or %o0, 0x120, %o0 ! 206e920 <__FUNCTION__.7699+0x540><== NOT EXECUTED
2042724: 81 c7 e0 08 ret <== NOT EXECUTED
2042728: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Force the whole buffer to a known state. The bit map may not occupy the
* whole block.
*/
memset (rtems_rfs_buffer_data (&handle), 0x00, rtems_rfs_fs_block_size (fs));
204272c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
2042730: d4 07 bf 34 ld [ %fp + -204 ], %o2 <== NOT EXECUTED
2042734: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
2042738: 40 00 2d 31 call 204dbfc <memset> <== NOT EXECUTED
204273c: 92 10 20 00 clr %o1 <== NOT EXECUTED
/*
* Clear the inode bitmap.
*/
rc = rtems_rfs_bitmap_map_clear_all (&bitmap);
2042740: 40 00 1b 88 call 2049560 <rtems_rfs_bitmap_map_clear_all> <== NOT EXECUTED
2042744: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (rc > 0)
2042748: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
204274c: 04 80 00 4d ble 2042880 <rtems_rfs_format+0xb88> <== NOT EXECUTED
2042750: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_rfs_bitmap_close (&bitmap);
2042754: 40 00 1b 1b call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
2042758: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle);
204275c: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
2042760: 7f ff fd 5c call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2042764: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: inode bitmap" \
2042768: 40 00 39 f6 call 2050f40 <strerror> <== NOT EXECUTED
204276c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2042770: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042774: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2042778: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
204277c: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042780: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042784: 40 00 31 3a call 204ec6c <printf> <== NOT EXECUTED
2042788: 90 12 21 c0 or %o0, 0x1c0, %o0 <== NOT EXECUTED
204278c: 81 c7 e0 08 ret <== NOT EXECUTED
2042790: 81 e8 00 00 restore <== NOT EXECUTED
}
rtems_rfs_buffer_mark_dirty (&handle);
if (verbose)
printf (", inodes");
2042794: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042798: 40 00 31 35 call 204ec6c <printf> <== NOT EXECUTED
204279c: 90 12 21 68 or %o0, 0x168, %o0 ! 206e968 <__FUNCTION__.7699+0x588><== NOT EXECUTED
/*
* Open the inode bitmap using the old buffer. Should release any changes.
*/
rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,
20427a0: 10 bf ff 96 b 20425f8 <rtems_rfs_format+0x900> <== NOT EXECUTED
20427a4: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
}
rc = rtems_rfs_inode_alloc (fs, RTEMS_RFS_ROOT_INO, &ino);
if (rc > 0)
{
printf ("rtems-rfs: format: inode allocation failed: %d: %s\n",
20427a8: 40 00 39 e6 call 2050f40 <strerror> <== NOT EXECUTED
20427ac: 01 00 00 00 nop <== NOT EXECUTED
20427b0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20427b4: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
20427b8: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
20427bc: 40 00 31 2c call 204ec6c <printf> <== NOT EXECUTED
20427c0: 90 12 23 48 or %o0, 0x348, %o0 ! 206eb48 <__FUNCTION__.7699+0x768><== NOT EXECUTED
rc, strerror (rc));
rtems_rfs_fs_close (fs);
20427c4: 7f ff fb 86 call 20415dc <rtems_rfs_fs_close> <== NOT EXECUTED
20427c8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
}
rc = rtems_rfs_write_root_dir (name);
if (rc > 0)
{
printf ("rtems-rfs: format: writing root dir failed: %d: %s\n",
20427cc: 40 00 39 dd call 2050f40 <strerror> <== NOT EXECUTED
20427d0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20427d4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20427d8: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
20427dc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20427e0: 11 00 81 bb sethi %hi(0x206ec00), %o0 <== NOT EXECUTED
20427e4: 40 00 31 22 call 204ec6c <printf> <== NOT EXECUTED
20427e8: 90 12 20 c8 or %o0, 0xc8, %o0 ! 206ecc8 <__FUNCTION__.7699+0x8e8><== NOT EXECUTED
rc, strerror (rc));
return -1;
}
return 0;
}
20427ec: 81 c7 e0 08 ret <== NOT EXECUTED
20427f0: 81 e8 00 00 restore <== NOT EXECUTED
if (!rtems_rfs_write_group (&fs, group,
config->initialise_inodes, config->verbose))
return -1;
if (config->verbose)
printf ("\n");
20427f4: 40 00 31 96 call 204ee4c <putchar> <== NOT EXECUTED
20427f8: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED
20427fc: 30 bf ff 9f b,a 2042678 <rtems_rfs_format+0x980> <== NOT EXECUTED
}
rc = rtems_rfs_buffer_setblksize (&fs, rtems_rfs_fs_block_size (&fs));
if (rc > 0)
{
printf ("rtems-rfs: format: setting block size failed: %d: %s\n",
2042800: 40 00 39 d0 call 2050f40 <strerror> <== NOT EXECUTED
2042804: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042808: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
204280c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042810: 11 00 81 b9 sethi %hi(0x206e400), %o0 <== NOT EXECUTED
2042814: 40 00 31 16 call 204ec6c <printf> <== NOT EXECUTED
2042818: 90 12 23 20 or %o0, 0x320, %o0 ! 206e720 <__FUNCTION__.7699+0x340><== NOT EXECUTED
rc, strerror (rc));
return -1;
204281c: 81 c7 e0 08 ret <== NOT EXECUTED
2042820: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: format: allocated inode not root ino: %" PRId32 "\n", ino);
rtems_rfs_fs_close (fs);
return rc;
}
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2042824: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
2042828: a0 07 bf ac add %fp, -84, %l0 <== NOT EXECUTED
204282c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2042830: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2042834: 40 00 03 20 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2042838: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
204283c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2042840: 24 80 00 54 ble,a 2042990 <rtems_rfs_format+0xc98> <== NOT EXECUTED
2042844: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
{
printf ("rtems-rfs: format: inode open failed: %d: %s\n",
2042848: 40 00 39 be call 2050f40 <strerror> <== NOT EXECUTED
204284c: 01 00 00 00 nop <== NOT EXECUTED
2042850: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042854: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042858: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
204285c: 40 00 31 04 call 204ec6c <printf> <== NOT EXECUTED
2042860: 90 12 23 b8 or %o0, 0x3b8, %o0 ! 206ebb8 <__FUNCTION__.7699+0x7d8><== NOT EXECUTED
rc, strerror (rc));
rtems_rfs_group_bitmap_free (fs, true, ino);
2042864: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
2042868: d4 07 bf f8 ld [ %fp + -8 ], %o2 <== NOT EXECUTED
204286c: 40 00 01 10 call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
2042870: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
rtems_rfs_fs_close (fs);
2042874: 7f ff fb 5a call 20415dc <rtems_rfs_fs_close> <== NOT EXECUTED
2042878: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
204287c: 30 bf ff d4 b,a 20427cc <rtems_rfs_format+0xad4> <== NOT EXECUTED
}
/*
* Close the inode bitmap.
*/
rc = rtems_rfs_bitmap_close (&bitmap);
2042880: 40 00 1a d0 call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
2042884: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (rc > 0)
2042888: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
204288c: 14 80 00 33 bg 2042958 <rtems_rfs_format+0xc60> <== NOT EXECUTED
2042890: 80 8d e0 ff btst 0xff, %l7 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle);
/*
* Initialise the inode tables if required to do so.
*/
if (initialise_inodes)
2042894: 02 80 00 76 be 2042a6c <rtems_rfs_format+0xd74> <== NOT EXECUTED
2042898: f4 2f bf ec stb %i2, [ %fp + -20 ] <== NOT EXECUTED
{
for (b = 0; b < blocks; b++)
204289c: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED
20428a0: 04 80 00 73 ble 2042a6c <rtems_rfs_format+0xd74> <== NOT EXECUTED
20428a4: a2 04 60 02 add %l1, 2, %l1 <== NOT EXECUTED
20428a8: 10 80 00 0b b 20428d4 <rtems_rfs_format+0xbdc> <== NOT EXECUTED
20428ac: a0 10 20 00 clr %l0 <== NOT EXECUTED
/*
* Force the whole buffer to a known state. The bit map may not occupy the
* whole block.
*/
memset (rtems_rfs_buffer_data (&handle), 0xff, rtems_rfs_fs_block_size (fs));
20428b0: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
20428b4: d4 07 bf 34 ld [ %fp + -204 ], %o2 <== NOT EXECUTED
20428b8: d0 00 60 24 ld [ %g1 + 0x24 ], %o0 <== NOT EXECUTED
20428bc: 40 00 2c d0 call 204dbfc <memset> <== NOT EXECUTED
20428c0: a0 04 20 01 inc %l0 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle);
20428c4: f4 2f bf ec stb %i2, [ %fp + -20 ] <== NOT EXECUTED
/*
* Initialise the inode tables if required to do so.
*/
if (initialise_inodes)
{
for (b = 0; b < blocks; b++)
20428c8: 80 a4 00 16 cmp %l0, %l6 <== NOT EXECUTED
20428cc: 16 80 00 68 bge 2042a6c <rtems_rfs_format+0xd74> <== NOT EXECUTED
20428d0: a2 04 60 01 inc %l1 <== NOT EXECUTED
{
rc = rtems_rfs_buffer_handle_request (fs, &handle,
20428d4: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20428d8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20428dc: 96 10 20 00 clr %o3 <== NOT EXECUTED
20428e0: 7f ff f4 0f call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
20428e4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
/*
* Force the whole buffer to a known state. The bit map may not occupy the
* whole block.
*/
memset (rtems_rfs_buffer_data (&handle), 0xff, rtems_rfs_fs_block_size (fs));
20428e8: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
for (b = 0; b < blocks; b++)
{
rc = rtems_rfs_buffer_handle_request (fs, &handle,
group_base + b + RTEMS_RFS_GROUP_INODE_BLOCK,
false);
if (rc > 0)
20428ec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20428f0: 04 bf ff f0 ble 20428b0 <rtems_rfs_format+0xbb8> <== NOT EXECUTED
20428f4: ae 10 00 08 mov %o0, %l7 <== NOT EXECUTED
{
rtems_rfs_buffer_handle_close (fs, &handle);
20428f8: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
20428fc: 7f ff fc f5 call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2042900: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: block %" PRId32 " request failed: %d: %s\n",
2042904: 40 00 39 8f call 2050f40 <strerror> <== NOT EXECUTED
2042908: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
204290c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042910: 98 10 00 08 mov %o0, %o4 <== NOT EXECUTED
2042914: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2042918: 96 10 00 17 mov %l7, %o3 <== NOT EXECUTED
204291c: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042920: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042924: 40 00 30 d2 call 204ec6c <printf> <== NOT EXECUTED
2042928: 90 12 22 58 or %o0, 0x258, %o0 <== NOT EXECUTED
204292c: 81 c7 e0 08 ret <== NOT EXECUTED
2042930: 81 e8 00 00 restore <== NOT EXECUTED
printf ("\n");
rc = rtems_rfs_buffer_close (&fs);
if (rc > 0)
{
printf ("rtems-rfs: format: buffer close failed: %d: %s\n",
2042934: 40 00 39 83 call 2050f40 <strerror> <== NOT EXECUTED
2042938: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
204293c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042940: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042944: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042948: 40 00 30 c9 call 204ec6c <printf> <== NOT EXECUTED
204294c: 90 12 22 e0 or %o0, 0x2e0, %o0 ! 206eae0 <__FUNCTION__.7699+0x700><== NOT EXECUTED
rc, strerror (rc));
return -1;
2042950: 81 c7 e0 08 ret <== NOT EXECUTED
2042954: 81 e8 00 00 restore <== NOT EXECUTED
* Close the inode bitmap.
*/
rc = rtems_rfs_bitmap_close (&bitmap);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &handle);
2042958: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
204295c: 7f ff fc dd call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2042960: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
printf ("\nrtems-rfs: write-group: group %3d: close inode" \
2042964: 40 00 39 77 call 2050f40 <strerror> <== NOT EXECUTED
2042968: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204296c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2042970: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2042974: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2042978: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
204297c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042980: 40 00 30 bb call 204ec6c <printf> <== NOT EXECUTED
2042984: 90 12 22 10 or %o0, 0x210, %o0 <== NOT EXECUTED
2042988: 81 c7 e0 08 ret <== NOT EXECUTED
204298c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_group_bitmap_free (fs, true, ino);
rtems_rfs_fs_close (fs);
return rc;
}
rc = rtems_rfs_inode_initialise (&inode, 0,
2042990: 92 10 20 00 clr %o1 <== NOT EXECUTED
2042994: 15 00 00 10 sethi %hi(0x4000), %o2 <== NOT EXECUTED
2042998: 96 10 20 00 clr %o3 <== NOT EXECUTED
204299c: 94 12 a1 c9 or %o2, 0x1c9, %o2 <== NOT EXECUTED
20429a0: 40 00 02 18 call 2043200 <rtems_rfs_inode_initialise> <== NOT EXECUTED
20429a4: 98 10 20 00 clr %o4 <== NOT EXECUTED
(RTEMS_RFS_S_IFDIR | RTEMS_RFS_S_IRWXU |
RTEMS_RFS_S_IXGRP | RTEMS_RFS_S_IXOTH),
0, 0);
if (rc > 0)
20429a8: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20429ac: 24 80 00 0a ble,a 20429d4 <rtems_rfs_format+0xcdc> <== NOT EXECUTED
20429b0: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
printf ("rtems-rfs: format: inode initialise failed: %d: %s\n",
20429b4: 40 00 39 63 call 2050f40 <strerror> <== NOT EXECUTED
20429b8: 01 00 00 00 nop <== NOT EXECUTED
20429bc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20429c0: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
20429c4: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
20429c8: 40 00 30 a9 call 204ec6c <printf> <== NOT EXECUTED
20429cc: 90 12 23 e8 or %o0, 0x3e8, %o0 ! 206ebe8 <__FUNCTION__.7699+0x808><== NOT EXECUTED
rc, strerror (rc));
rc = rtems_rfs_dir_add_entry (fs, &inode, ".", 1, ino);
20429d0: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
20429d4: d8 07 bf f8 ld [ %fp + -8 ], %o4 <== NOT EXECUTED
20429d8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20429dc: 15 00 81 bb sethi %hi(0x206ec00), %o2 <== NOT EXECUTED
20429e0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
20429e4: 7f ff f5 ea call 204018c <rtems_rfs_dir_add_entry> <== NOT EXECUTED
20429e8: 94 12 a0 20 or %o2, 0x20, %o2 <== NOT EXECUTED
if (rc > 0)
20429ec: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20429f0: 24 80 00 0a ble,a 2042a18 <rtems_rfs_format+0xd20> <== NOT EXECUTED
20429f4: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
printf ("rtems-rfs: format: directory add failed: %d: %s\n",
20429f8: 40 00 39 52 call 2050f40 <strerror> <== NOT EXECUTED
20429fc: 01 00 00 00 nop <== NOT EXECUTED
2042a00: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042a04: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042a08: 11 00 81 bb sethi %hi(0x206ec00), %o0 <== NOT EXECUTED
2042a0c: 40 00 30 98 call 204ec6c <printf> <== NOT EXECUTED
2042a10: 90 12 20 28 or %o0, 0x28, %o0 ! 206ec28 <__FUNCTION__.7699+0x848><== NOT EXECUTED
rc, strerror (rc));
rc = rtems_rfs_inode_close (fs, &inode);
2042a14: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
2042a18: 40 00 02 7d call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2042a1c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (rc > 0)
2042a20: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042a24: 04 80 00 09 ble 2042a48 <rtems_rfs_format+0xd50> <== NOT EXECUTED
2042a28: 01 00 00 00 nop <== NOT EXECUTED
printf ("rtems-rfs: format: inode close failed: %d: %s\n",
2042a2c: 40 00 39 45 call 2050f40 <strerror> <== NOT EXECUTED
2042a30: 01 00 00 00 nop <== NOT EXECUTED
2042a34: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042a38: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042a3c: 11 00 81 bb sethi %hi(0x206ec00), %o0 <== NOT EXECUTED
2042a40: 40 00 30 8b call 204ec6c <printf> <== NOT EXECUTED
2042a44: 90 12 20 60 or %o0, 0x60, %o0 ! 206ec60 <__FUNCTION__.7699+0x880><== NOT EXECUTED
rc, strerror (rc));
rc = rtems_rfs_fs_close (fs);
2042a48: 7f ff fa e5 call 20415dc <rtems_rfs_fs_close> <== NOT EXECUTED
2042a4c: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
if (rc < 0)
2042a50: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2042a54: 06 80 00 22 bl 2042adc <rtems_rfs_format+0xde4> <== NOT EXECUTED
2042a58: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
rc, strerror (rc));
return -1;
}
rc = rtems_rfs_write_root_dir (name);
if (rc > 0)
2042a5c: 12 bf ff 5c bne 20427cc <rtems_rfs_format+0xad4> <== NOT EXECUTED
2042a60: b0 10 20 00 clr %i0 <== NOT EXECUTED
rc, strerror (rc));
return -1;
}
return 0;
}
2042a64: 81 c7 e0 08 ret <== NOT EXECUTED
2042a68: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle);
}
}
rc = rtems_rfs_buffer_handle_close (fs, &handle);
2042a6c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2042a70: 7f ff fc 98 call 2041cd0 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2042a74: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
if (rc > 0)
2042a78: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2042a7c: 04 bf fe af ble 2042538 <rtems_rfs_format+0x840> <== NOT EXECUTED
2042a80: c2 07 bf 4c ld [ %fp + -180 ], %g1 <== NOT EXECUTED
{
printf ("\nrtems-rfs: write-group: buffer handle close failed: %d: %s\n",
2042a84: 40 00 39 2f call 2050f40 <strerror> <== NOT EXECUTED
2042a88: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2042a8c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042a90: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042a94: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042a98: 40 00 30 75 call 204ec6c <printf> <== NOT EXECUTED
2042a9c: 90 12 22 a0 or %o0, 0x2a0, %o0 ! 206eaa0 <__FUNCTION__.7699+0x6c0><== NOT EXECUTED
2042aa0: 81 c7 e0 08 ret <== NOT EXECUTED
2042aa4: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_fs_open (name, NULL,
RTEMS_RFS_FS_FORCE_OPEN | RTEMS_RFS_FS_NO_LOCAL_CACHE,
0, &fs);
if (rc < 0)
{
printf ("rtems-rfs: format: file system open failed: %d: %s\n",
2042aa8: 40 00 1e 76 call 204a480 <__errno> <== NOT EXECUTED
2042aac: b0 10 20 00 clr %i0 <== NOT EXECUTED
2042ab0: 40 00 1e 74 call 204a480 <__errno> <== NOT EXECUTED
2042ab4: e0 02 00 00 ld [ %o0 ], %l0 <== NOT EXECUTED
2042ab8: 40 00 39 22 call 2050f40 <strerror> <== NOT EXECUTED
2042abc: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
2042ac0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042ac4: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042ac8: 11 00 81 ba sethi %hi(0x206e800), %o0 <== NOT EXECUTED
2042acc: 40 00 30 68 call 204ec6c <printf> <== NOT EXECUTED
2042ad0: 90 12 23 10 or %o0, 0x310, %o0 ! 206eb10 <__FUNCTION__.7699+0x730><== NOT EXECUTED
2042ad4: 81 c7 e0 08 ret <== NOT EXECUTED
2042ad8: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: format: inode close failed: %d: %s\n",
rc, strerror (rc));
rc = rtems_rfs_fs_close (fs);
if (rc < 0)
printf ("rtems-rfs: format: file system close failed: %d: %s\n",
2042adc: 40 00 1e 69 call 204a480 <__errno> <== NOT EXECUTED
2042ae0: b0 10 20 00 clr %i0 <== NOT EXECUTED
2042ae4: 40 00 1e 67 call 204a480 <__errno> <== NOT EXECUTED
2042ae8: e0 02 00 00 ld [ %o0 ], %l0 <== NOT EXECUTED
2042aec: 40 00 39 15 call 2050f40 <strerror> <== NOT EXECUTED
2042af0: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
2042af4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2042af8: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2042afc: 11 00 81 bb sethi %hi(0x206ec00), %o0 <== NOT EXECUTED
2042b00: 40 00 30 5b call 204ec6c <printf> <== NOT EXECUTED
2042b04: 90 12 20 90 or %o0, 0x90, %o0 ! 206ec90 <__FUNCTION__.7699+0x8b0><== NOT EXECUTED
2042b08: 81 c7 e0 08 ret <== NOT EXECUTED
2042b0c: 81 e8 00 00 restore <== NOT EXECUTED
020415dc <rtems_rfs_fs_close>:
return 0;
}
int
rtems_rfs_fs_close (rtems_rfs_file_system* fs)
{
20415dc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int group;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_CLOSE))
printf ("rtems-rfs: close\n");
for (group = 0; group < fs->group_count; group++)
20415e0: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
20415e4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20415e8: 04 80 00 0d ble 204161c <rtems_rfs_fs_close+0x40> <== NOT EXECUTED
20415ec: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
20415f0: a4 10 20 00 clr %l2 <== NOT EXECUTED
20415f4: a2 10 20 00 clr %l1 <== NOT EXECUTED
rtems_rfs_group_close (fs, &fs->groups[group]);
20415f8: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
20415fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2041600: 40 00 06 56 call 2042f58 <rtems_rfs_group_close> <== NOT EXECUTED
2041604: 92 02 40 12 add %o1, %l2, %o1 <== NOT EXECUTED
int group;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_CLOSE))
printf ("rtems-rfs: close\n");
for (group = 0; group < fs->group_count; group++)
2041608: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
204160c: a2 04 60 01 inc %l1 <== NOT EXECUTED
2041610: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2041614: 14 bf ff f9 bg 20415f8 <rtems_rfs_fs_close+0x1c> <== NOT EXECUTED
2041618: a4 04 a0 50 add %l2, 0x50, %l2 <== NOT EXECUTED
rtems_rfs_group_close (fs, &fs->groups[group]);
rtems_rfs_buffer_close (fs);
204161c: 7f ff f8 55 call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
2041620: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
free (fs);
return 0;
}
2041624: b0 10 20 00 clr %i0 <== NOT EXECUTED
for (group = 0; group < fs->group_count; group++)
rtems_rfs_group_close (fs, &fs->groups[group]);
rtems_rfs_buffer_close (fs);
free (fs);
2041628: 7f ff 1c ad call 20088dc <free> <== NOT EXECUTED
204162c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return 0;
}
2041630: 81 c7 e0 08 ret <== NOT EXECUTED
2041634: 81 e8 00 00 restore <== NOT EXECUTED
020415b4 <rtems_rfs_fs_media_size>:
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
20415b4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
20415b8: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
20415bc: 94 10 20 00 clr %o2 <== NOT EXECUTED
20415c0: d6 00 60 1c ld [ %g1 + 0x1c ], %o3 <== NOT EXECUTED
20415c4: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
20415c8: 40 00 86 47 call 2062ee4 <__muldi3> <== NOT EXECUTED
20415cc: 90 10 20 00 clr %o0 <== NOT EXECUTED
uint64_t media_block_size = (uint64_t) rtems_rfs_fs_media_block_size (fs);
return media_blocks * media_block_size;
}
20415d0: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
20415d4: 81 c7 e0 08 ret <== NOT EXECUTED
20415d8: 93 e8 00 09 restore %g0, %o1, %o1 <== NOT EXECUTED
02041660 <rtems_rfs_fs_open>:
rtems_rfs_fs_open (const char* name,
void* user,
uint32_t flags,
uint32_t max_held_buffers,
rtems_rfs_file_system** fs)
{
2041660: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: %s\n", name);
*fs = malloc (sizeof (rtems_rfs_file_system));
2041664: 7f ff 1e 7f call 2009060 <malloc> <== NOT EXECUTED
2041668: 90 10 20 80 mov 0x80, %o0 <== NOT EXECUTED
if (!*fs)
204166c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041670: 02 80 00 fd be 2041a64 <rtems_rfs_fs_open+0x404> <== NOT EXECUTED
2041674: d0 27 00 00 st %o0, [ %i4 ] <== NOT EXECUTED
printf ("rtems-rfs: open: no memory for file system data\n");
errno = ENOMEM;
return -1;
}
memset (*fs, 0, sizeof (rtems_rfs_file_system));
2041678: 92 10 20 00 clr %o1 <== NOT EXECUTED
204167c: 40 00 31 60 call 204dbfc <memset> <== NOT EXECUTED
2041680: 94 10 20 80 mov 0x80, %o2 <== NOT EXECUTED
(*fs)->user = user;
2041684: c2 07 00 00 ld [ %i4 ], %g1 <== NOT EXECUTED
group_base = 0;
/*
* Open the buffer interface.
*/
rc = rtems_rfs_buffer_open (name, *fs);
2041688: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
204168c: 84 00 60 44 add %g1, 0x44, %g2 <== NOT EXECUTED
2041690: c4 20 60 40 st %g2, [ %g1 + 0x40 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2041694: 84 00 60 40 add %g1, 0x40, %g2 <== NOT EXECUTED
2041698: c4 20 60 48 st %g2, [ %g1 + 0x48 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
204169c: 84 00 60 54 add %g1, 0x54, %g2 <== NOT EXECUTED
20416a0: c4 20 60 50 st %g2, [ %g1 + 0x50 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
20416a4: 84 00 60 50 add %g1, 0x50, %g2 <== NOT EXECUTED
20416a8: c4 20 60 58 st %g2, [ %g1 + 0x58 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
20416ac: 84 00 60 64 add %g1, 0x64, %g2 <== NOT EXECUTED
20416b0: c4 20 60 60 st %g2, [ %g1 + 0x60 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
20416b4: 84 00 60 60 add %g1, 0x60, %g2 <== NOT EXECUTED
20416b8: c4 20 60 68 st %g2, [ %g1 + 0x68 ] <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
20416bc: 84 00 60 74 add %g1, 0x74, %g2 <== NOT EXECUTED
20416c0: c4 20 60 70 st %g2, [ %g1 + 0x70 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
20416c4: 84 00 60 70 add %g1, 0x70, %g2 <== NOT EXECUTED
return -1;
}
memset (*fs, 0, sizeof (rtems_rfs_file_system));
(*fs)->user = user;
20416c8: f2 20 60 7c st %i1, [ %g1 + 0x7c ] <== NOT EXECUTED
rtems_chain_initialize_empty (&(*fs)->buffers);
rtems_chain_initialize_empty (&(*fs)->release);
rtems_chain_initialize_empty (&(*fs)->release_modified);
rtems_chain_initialize_empty (&(*fs)->file_shares);
(*fs)->max_held_buffers = max_held_buffers;
20416cc: f6 20 60 3c st %i3, [ %g1 + 0x3c ] <== NOT EXECUTED
(*fs)->buffers_count = 0;
(*fs)->release_count = 0;
(*fs)->release_modified_count = 0;
(*fs)->flags = flags;
20416d0: f4 20 40 00 st %i2, [ %g1 ] <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
20416d4: c0 20 60 44 clr [ %g1 + 0x44 ] <== NOT EXECUTED
20416d8: c0 20 60 54 clr [ %g1 + 0x54 ] <== NOT EXECUTED
20416dc: c0 20 60 64 clr [ %g1 + 0x64 ] <== NOT EXECUTED
20416e0: c0 20 60 74 clr [ %g1 + 0x74 ] <== NOT EXECUTED
rtems_chain_initialize_empty (&(*fs)->release);
rtems_chain_initialize_empty (&(*fs)->release_modified);
rtems_chain_initialize_empty (&(*fs)->file_shares);
(*fs)->max_held_buffers = max_held_buffers;
(*fs)->buffers_count = 0;
20416e4: c0 20 60 4c clr [ %g1 + 0x4c ] <== NOT EXECUTED
(*fs)->release_count = 0;
20416e8: c0 20 60 5c clr [ %g1 + 0x5c ] <== NOT EXECUTED
(*fs)->release_modified_count = 0;
20416ec: c0 20 60 6c clr [ %g1 + 0x6c ] <== NOT EXECUTED
group_base = 0;
/*
* Open the buffer interface.
*/
rc = rtems_rfs_buffer_open (name, *fs);
20416f0: 92 10 00 01 mov %g1, %o1 <== NOT EXECUTED
20416f4: 7f ff f8 2a call 203f79c <rtems_rfs_buffer_open> <== NOT EXECUTED
20416f8: c4 20 60 78 st %g2, [ %g1 + 0x78 ] <== NOT EXECUTED
if (rc > 0)
20416fc: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2041700: 14 80 00 3a bg 20417e8 <rtems_rfs_fs_open+0x188> <== NOT EXECUTED
2041704: 94 10 20 00 clr %o2 <== NOT EXECUTED
rc, strerror (rc));
errno = rc;
return -1;
}
rc = rtems_rfs_fs_read_superblock (*fs);
2041708: f0 07 00 00 ld [ %i4 ], %i0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
204170c: c0 2f bf f4 clrb [ %fp + -12 ] <== NOT EXECUTED
handle->bnum = 0;
2041710: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
handle->buffer = NULL;
2041714: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
printf ("rtems-rfs: read-superblock: handle open failed: %d: %s\n",
rc, strerror (rc));
return rc;
}
rc = rtems_rfs_buffer_handle_request (fs, &handle, 0, true);
2041718: a0 07 bf f4 add %fp, -12, %l0 <== NOT EXECUTED
204171c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041720: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2041724: 7f ff f8 7e call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2041728: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
204172c: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2041730: 04 80 00 0c ble 2041760 <rtems_rfs_fs_open+0x100> <== NOT EXECUTED
2041734: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
}
rc = rtems_rfs_fs_read_superblock (*fs);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
2041738: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
204173c: 7f ff f8 0d call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
2041740: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free (*fs);
2041744: 7f ff 1c 66 call 20088dc <free> <== NOT EXECUTED
2041748: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: reading superblock: %d: %s\n",
rc, strerror (rc));
errno = rc;
204174c: 40 00 23 4d call 204a480 <__errno> <== NOT EXECUTED
2041750: 01 00 00 00 nop <== NOT EXECUTED
2041754: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
return -1;
2041758: 81 c7 e0 08 ret <== NOT EXECUTED
204175c: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: read-superblock: request failed%d: %s\n",
rc, strerror (rc));
return rc;
}
sb = rtems_rfs_buffer_data (&handle);
2041760: e2 00 60 24 ld [ %g1 + 0x24 ], %l1 <== NOT EXECUTED
#define read_sb(_o) rtems_rfs_read_u32 (sb + (_o))
if (read_sb (RTEMS_RFS_SB_OFFSET_MAGIC) != RTEMS_RFS_SB_MAGIC)
2041764: c2 0c 60 02 ldub [ %l1 + 2 ], %g1 <== NOT EXECUTED
2041768: c8 0c 60 03 ldub [ %l1 + 3 ], %g4 <== NOT EXECUTED
204176c: c4 0c 40 00 ldub [ %l1 ], %g2 <== NOT EXECUTED
2041770: c6 0c 60 01 ldub [ %l1 + 1 ], %g3 <== NOT EXECUTED
2041774: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041778: 85 28 a0 18 sll %g2, 0x18, %g2 <== NOT EXECUTED
204177c: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2041780: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
2041784: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
2041788: 84 10 80 01 or %g2, %g1, %g2 <== NOT EXECUTED
204178c: 03 0a 02 48 sethi %hi(0x28092000), %g1 <== NOT EXECUTED
2041790: 82 10 60 01 or %g1, 1, %g1 ! 28092001 <RAM_END+0x25c92001><== NOT EXECUTED
2041794: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2041798: 22 80 00 1c be,a 2041808 <rtems_rfs_fs_open+0x1a8> <== NOT EXECUTED
204179c: c6 0c 60 0d ldub [ %l1 + 0xd ], %g3 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20417a0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20417a4: 7f ff f8 15 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20417a8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
}
rc = rtems_rfs_fs_read_superblock (*fs);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
20417ac: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
handle->dirty = false;
20417b0: c0 2f bf f4 clrb [ %fp + -12 ] <== NOT EXECUTED
handle->bnum = 0;
20417b4: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
20417b8: 7f ff f7 ee call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
20417bc: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
free (*fs);
20417c0: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
20417c4: 7f ff 1c 46 call 20088dc <free> <== NOT EXECUTED
20417c8: a4 10 20 05 mov 5, %l2 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: reading superblock: %d: %s\n",
rc, strerror (rc));
errno = rc;
20417cc: 40 00 23 2d call 204a480 <__errno> <== NOT EXECUTED
20417d0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20417d4: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
return -1;
20417d8: 81 c7 e0 08 ret <== NOT EXECUTED
20417dc: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_close (*fs, &inode);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
20417e0: 7f ff f7 e4 call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
20417e4: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
free (*fs);
20417e8: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
20417ec: 7f ff 1c 3c call 20088dc <free> <== NOT EXECUTED
20417f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: closing root inode: %d: %s\n", rc, strerror (rc));
errno = rc;
20417f4: 40 00 23 23 call 204a480 <__errno> <== NOT EXECUTED
20417f8: 01 00 00 00 nop <== NOT EXECUTED
20417fc: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
return -1;
2041800: 81 c7 e0 08 ret <== NOT EXECUTED
2041804: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: read-superblock: invalid superblock, bad magic\n");
rtems_rfs_buffer_handle_close (fs, &handle);
return EIO;
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
2041808: c2 0c 60 0e ldub [ %l1 + 0xe ], %g1 <== NOT EXECUTED
204180c: c4 0c 60 0f ldub [ %l1 + 0xf ], %g2 <== NOT EXECUTED
2041810: d6 0c 60 0c ldub [ %l1 + 0xc ], %o3 <== NOT EXECUTED
2041814: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2041818: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
204181c: 97 2a e0 18 sll %o3, 0x18, %o3 <== NOT EXECUTED
2041820: 96 12 c0 03 or %o3, %g3, %o3 <== NOT EXECUTED
2041824: 96 12 c0 02 or %o3, %g2, %o3 <== NOT EXECUTED
2041828: 96 12 c0 01 or %o3, %g1, %o3 <== NOT EXECUTED
204182c: d6 26 20 04 st %o3, [ %i0 + 4 ] <== NOT EXECUTED
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
2041830: c6 0c 60 09 ldub [ %l1 + 9 ], %g3 <== NOT EXECUTED
2041834: c2 0c 60 0a ldub [ %l1 + 0xa ], %g1 <== NOT EXECUTED
2041838: c4 0c 60 0b ldub [ %l1 + 0xb ], %g2 <== NOT EXECUTED
204183c: f4 0c 60 08 ldub [ %l1 + 8 ], %i2 <== NOT EXECUTED
2041840: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2041844: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
}
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
2041848: f2 06 20 0c ld [ %i0 + 0xc ], %i1 <== NOT EXECUTED
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
if (rtems_rfs_fs_size(fs) > rtems_rfs_fs_media_size (fs))
204184c: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle);
return EIO;
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
2041850: b5 2e a0 18 sll %i2, 0x18, %i2 <== NOT EXECUTED
if (rtems_rfs_fs_size(fs) > rtems_rfs_fs_media_size (fs))
2041854: 90 10 20 00 clr %o0 <== NOT EXECUTED
rtems_rfs_buffer_handle_close (fs, &handle);
return EIO;
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
2041858: b4 16 80 03 or %i2, %g3, %i2 <== NOT EXECUTED
204185c: b4 16 80 02 or %i2, %g2, %i2 <== NOT EXECUTED
2041860: b4 16 80 01 or %i2, %g1, %i2 <== NOT EXECUTED
2041864: f4 26 20 08 st %i2, [ %i0 + 8 ] <== NOT EXECUTED
if (rtems_rfs_fs_size(fs) > rtems_rfs_fs_media_size (fs))
2041868: 40 00 85 9f call 2062ee4 <__muldi3> <== NOT EXECUTED
204186c: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
}
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
2041870: d6 06 60 1c ld [ %i1 + 0x1c ], %o3 <== NOT EXECUTED
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
if (rtems_rfs_fs_size(fs) > rtems_rfs_fs_media_size (fs))
2041874: a6 10 00 09 mov %o1, %l3 <== NOT EXECUTED
}
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
2041878: d2 06 60 24 ld [ %i1 + 0x24 ], %o1 <== NOT EXECUTED
}
fs->blocks = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);
fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);
if (rtems_rfs_fs_size(fs) > rtems_rfs_fs_media_size (fs))
204187c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
}
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
2041880: 94 10 20 00 clr %o2 <== NOT EXECUTED
2041884: 40 00 85 98 call 2062ee4 <__muldi3> <== NOT EXECUTED
2041888: 90 10 20 00 clr %o0 <== NOT EXECUTED
204188c: 80 a4 80 08 cmp %l2, %o0 <== NOT EXECUTED
2041890: 38 80 00 12 bgu,a 20418d8 <rtems_rfs_fs_open+0x278> <== NOT EXECUTED
2041894: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041898: 02 80 00 15 be 20418ec <rtems_rfs_fs_open+0x28c> <== NOT EXECUTED
204189c: 80 a4 c0 09 cmp %l3, %o1 <== NOT EXECUTED
read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
rtems_rfs_buffer_handle_close (fs, &handle);
return EIO;
}
if (read_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE) != RTEMS_RFS_INODE_SIZE)
20418a0: c8 0c 60 24 ldub [ %l1 + 0x24 ], %g4 <== NOT EXECUTED
20418a4: c4 0c 60 25 ldub [ %l1 + 0x25 ], %g2 <== NOT EXECUTED
20418a8: c6 0c 60 27 ldub [ %l1 + 0x27 ], %g3 <== NOT EXECUTED
20418ac: c2 0c 60 26 ldub [ %l1 + 0x26 ], %g1 <== NOT EXECUTED
20418b0: 89 29 20 18 sll %g4, 0x18, %g4 <== NOT EXECUTED
20418b4: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20418b8: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20418bc: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
20418c0: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
20418c4: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
20418c8: 80 a0 60 38 cmp %g1, 0x38 <== NOT EXECUTED
20418cc: 22 80 00 0c be,a 20418fc <rtems_rfs_fs_open+0x29c> <== NOT EXECUTED
20418d0: c6 0c 60 13 ldub [ %l1 + 0x13 ], %g3 <== NOT EXECUTED
fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;
if (fs->group_blocks >
rtems_rfs_bitmap_numof_bits (rtems_rfs_fs_block_size (fs)))
{
rtems_rfs_buffer_handle_close (fs, &handle);
20418d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20418d8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20418dc: 7f ff ff 57 call 2041638 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
20418e0: a4 10 20 05 mov 5, %l2 <== NOT EXECUTED
}
rc = rtems_rfs_fs_read_superblock (*fs);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
20418e4: 10 bf ff 96 b 204173c <rtems_rfs_fs_open+0xdc> <== NOT EXECUTED
20418e8: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
}
uint64_t
rtems_rfs_fs_media_size (rtems_rfs_file_system* fs)
{
uint64_t media_blocks = (uint64_t) rtems_rfs_fs_media_blocks (fs);
20418ec: 28 bf ff ee bleu,a 20418a4 <rtems_rfs_fs_open+0x244> <== NOT EXECUTED
20418f0: c8 0c 60 24 ldub [ %l1 + 0x24 ], %g4 <== NOT EXECUTED
fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;
if (fs->group_blocks >
rtems_rfs_bitmap_numof_bits (rtems_rfs_fs_block_size (fs)))
{
rtems_rfs_buffer_handle_close (fs, &handle);
20418f4: 10 bf ff f9 b 20418d8 <rtems_rfs_fs_open+0x278> <== NOT EXECUTED
20418f8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
rtems_rfs_buffer_handle_close (fs, &handle);
return EIO;
}
fs->bad_blocks = read_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS);
20418fc: c8 0c 60 10 ldub [ %l1 + 0x10 ], %g4 <== NOT EXECUTED
2041900: c4 0c 60 11 ldub [ %l1 + 0x11 ], %g2 <== NOT EXECUTED
2041904: c2 0c 60 12 ldub [ %l1 + 0x12 ], %g1 <== NOT EXECUTED
2041908: 89 29 20 18 sll %g4, 0x18, %g4 <== NOT EXECUTED
204190c: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2041910: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041914: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
2041918: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
204191c: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2041920: c2 26 20 14 st %g1, [ %i0 + 0x14 ] <== NOT EXECUTED
fs->max_name_length = read_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH);
2041924: c6 0c 60 17 ldub [ %l1 + 0x17 ], %g3 <== NOT EXECUTED
2041928: c8 0c 60 14 ldub [ %l1 + 0x14 ], %g4 <== NOT EXECUTED
204192c: c4 0c 60 15 ldub [ %l1 + 0x15 ], %g2 <== NOT EXECUTED
2041930: c2 0c 60 16 ldub [ %l1 + 0x16 ], %g1 <== NOT EXECUTED
2041934: 89 29 20 18 sll %g4, 0x18, %g4 <== NOT EXECUTED
2041938: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
204193c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041940: 84 11 00 02 or %g4, %g2, %g2 <== NOT EXECUTED
2041944: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
2041948: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
204194c: c2 26 20 18 st %g1, [ %i0 + 0x18 ] <== NOT EXECUTED
fs->group_count = read_sb (RTEMS_RFS_SB_OFFSET_GROUPS);
2041950: c2 0c 60 1a ldub [ %l1 + 0x1a ], %g1 <== NOT EXECUTED
2041954: c4 0c 60 1b ldub [ %l1 + 0x1b ], %g2 <== NOT EXECUTED
2041958: e6 0c 60 18 ldub [ %l1 + 0x18 ], %l3 <== NOT EXECUTED
204195c: c6 0c 60 19 ldub [ %l1 + 0x19 ], %g3 <== NOT EXECUTED
2041960: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041964: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2041968: a7 2c e0 18 sll %l3, 0x18, %l3 <== NOT EXECUTED
204196c: a6 14 c0 03 or %l3, %g3, %l3 <== NOT EXECUTED
2041970: a6 14 c0 02 or %l3, %g2, %l3 <== NOT EXECUTED
2041974: a6 14 c0 01 or %l3, %g1, %l3 <== NOT EXECUTED
2041978: e6 26 20 20 st %l3, [ %i0 + 0x20 ] <== NOT EXECUTED
fs->group_blocks = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS);
204197c: c2 0c 60 1e ldub [ %l1 + 0x1e ], %g1 <== NOT EXECUTED
2041980: c4 0c 60 1f ldub [ %l1 + 0x1f ], %g2 <== NOT EXECUTED
2041984: e4 0c 60 1c ldub [ %l1 + 0x1c ], %l2 <== NOT EXECUTED
2041988: c6 0c 60 1d ldub [ %l1 + 0x1d ], %g3 <== NOT EXECUTED
204198c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041990: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2041994: a5 2c a0 18 sll %l2, 0x18, %l2 <== NOT EXECUTED
2041998: a4 14 80 03 or %l2, %g3, %l2 <== NOT EXECUTED
204199c: a4 14 80 02 or %l2, %g2, %l2 <== NOT EXECUTED
20419a0: a4 14 80 01 or %l2, %g1, %l2 <== NOT EXECUTED
20419a4: e4 26 20 24 st %l2, [ %i0 + 0x24 ] <== NOT EXECUTED
fs->group_inodes = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES);
20419a8: c2 0c 60 22 ldub [ %l1 + 0x22 ], %g1 <== NOT EXECUTED
20419ac: c8 0c 60 20 ldub [ %l1 + 0x20 ], %g4 <== NOT EXECUTED
20419b0: c4 0c 60 23 ldub [ %l1 + 0x23 ], %g2 <== NOT EXECUTED
20419b4: c6 0c 60 21 ldub [ %l1 + 0x21 ], %g3 <== NOT EXECUTED
20419b8: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20419bc: a3 29 20 18 sll %g4, 0x18, %l1 <== NOT EXECUTED
20419c0: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
20419c4: a2 14 40 03 or %l1, %g3, %l1 <== NOT EXECUTED
20419c8: a2 14 40 02 or %l1, %g2, %l1 <== NOT EXECUTED
20419cc: a2 14 40 01 or %l1, %g1, %l1 <== NOT EXECUTED
fs->blocks_per_block =
rtems_rfs_fs_block_size (fs) / sizeof (rtems_rfs_inode_block);
20419d0: 83 36 a0 02 srl %i2, 2, %g1 <== NOT EXECUTED
fs->block_map_singly_blocks =
20419d4: 85 28 60 02 sll %g1, 2, %g2 <== NOT EXECUTED
fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->block_map_doubly_blocks =
20419d8: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
fs->max_name_length = read_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH);
fs->group_count = read_sb (RTEMS_RFS_SB_OFFSET_GROUPS);
fs->group_blocks = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS);
fs->group_inodes = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES);
fs->blocks_per_block =
20419dc: c2 26 20 30 st %g1, [ %i0 + 0x30 ] <== NOT EXECUTED
rtems_rfs_fs_block_size (fs) / sizeof (rtems_rfs_inode_block);
fs->block_map_singly_blocks =
20419e0: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->block_map_doubly_blocks =
20419e4: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
fs->group_inodes = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES);
fs->blocks_per_block =
rtems_rfs_fs_block_size (fs) / sizeof (rtems_rfs_inode_block);
fs->block_map_singly_blocks =
20419e8: c2 26 20 34 st %g1, [ %i0 + 0x34 ] <== NOT EXECUTED
fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->block_map_doubly_blocks =
20419ec: 7f ff 04 68 call 2002b8c <.umul> <== NOT EXECUTED
20419f0: e2 26 20 28 st %l1, [ %i0 + 0x28 ] <== NOT EXECUTED
20419f4: 83 2a 20 02 sll %o0, 2, %g1 <== NOT EXECUTED
20419f8: 82 00 40 08 add %g1, %o0, %g1 <== NOT EXECUTED
fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->inodes = fs->group_count * fs->group_inodes;
20419fc: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
fs->blocks_per_block =
rtems_rfs_fs_block_size (fs) / sizeof (rtems_rfs_inode_block);
fs->block_map_singly_blocks =
fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->block_map_doubly_blocks =
2041a00: c2 26 20 38 st %g1, [ %i0 + 0x38 ] <== NOT EXECUTED
fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->inodes = fs->group_count * fs->group_inodes;
2041a04: 7f ff 04 62 call 2002b8c <.umul> <== NOT EXECUTED
2041a08: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;
2041a0c: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
fs->block_map_singly_blocks =
fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->block_map_doubly_blocks =
fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
fs->inodes = fs->group_count * fs->group_inodes;
2041a10: d0 26 20 10 st %o0, [ %i0 + 0x10 ] <== NOT EXECUTED
fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;
2041a14: 40 00 83 dc call 2062984 <.udiv> <== NOT EXECUTED
2041a18: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
if (fs->group_blocks >
2041a1c: b5 2e a0 03 sll %i2, 3, %i2 <== NOT EXECUTED
2041a20: 80 a4 80 1a cmp %l2, %i2 <== NOT EXECUTED
2041a24: 18 bf ff ac bgu 20418d4 <rtems_rfs_fs_open+0x274> <== NOT EXECUTED
2041a28: d0 26 20 2c st %o0, [ %i0 + 0x2c ] <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: read-superblock: groups blocks larger than block bits\n");
return EIO;
}
rtems_rfs_buffer_handle_close (fs, &handle);
2041a2c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2041a30: 7f ff ff 02 call 2041638 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2041a34: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
/*
* Change the block size to the value in the superblock.
*/
rc = rtems_rfs_buffer_setblksize (fs, rtems_rfs_fs_block_size (fs));
2041a38: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED
2041a3c: 7f ff f7 37 call 203f718 <rtems_rfs_buffer_setblksize> <== NOT EXECUTED
2041a40: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
2041a44: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2041a48: 24 80 00 0d ble,a 2041a7c <rtems_rfs_fs_open+0x41c> <== NOT EXECUTED
2041a4c: d0 06 20 20 ld [ %i0 + 0x20 ], %o0 <== NOT EXECUTED
if (rc > 0)
{
int g;
for (g = 0; g < group; g++)
rtems_rfs_group_close (fs, &fs->groups[g]);
rtems_rfs_buffer_handle_close (fs, &handle);
2041a50: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041a54: 7f ff fe f9 call 2041638 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2041a58: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
}
rc = rtems_rfs_fs_read_superblock (*fs);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
2041a5c: 10 bf ff 38 b 204173c <rtems_rfs_fs_open+0xdc> <== NOT EXECUTED
2041a60: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
*fs = malloc (sizeof (rtems_rfs_file_system));
if (!*fs)
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: no memory for file system data\n");
errno = ENOMEM;
2041a64: 40 00 22 87 call 204a480 <__errno> <== NOT EXECUTED
2041a68: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2041a6c: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
2041a70: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
2041a74: 81 c7 e0 08 ret <== NOT EXECUTED
2041a78: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: read-superblock: invalid superblock block size%d: %s\n",
rc, strerror (rc));
return rc;
}
fs->groups = calloc (fs->group_count, sizeof (rtems_rfs_group));
2041a7c: 7f ff 19 f6 call 2008254 <calloc> <== NOT EXECUTED
2041a80: 92 10 20 50 mov 0x50, %o1 <== NOT EXECUTED
2041a84: d0 26 20 1c st %o0, [ %i0 + 0x1c ] <== NOT EXECUTED
if (!fs->groups)
2041a88: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2041a8c: 02 80 00 66 be 2041c24 <rtems_rfs_fs_open+0x5c4> <== NOT EXECUTED
2041a90: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
/*
* Perform each phase of group initialisation at the same time. This way we
* know how far the initialisation has gone if an error occurs and we need to
* close everything.
*/
for (group = 0; group < fs->group_count; group++)
2041a94: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
2041a98: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2041a9c: 04 80 00 25 ble 2041b30 <rtems_rfs_fs_open+0x4d0> <== NOT EXECUTED
2041aa0: a2 10 20 00 clr %l1 <== NOT EXECUTED
fs->groups = calloc (fs->group_count, sizeof (rtems_rfs_group));
if (!fs->groups)
{
rtems_rfs_buffer_handle_close (fs, &handle);
2041aa4: e4 06 20 24 ld [ %i0 + 0x24 ], %l2 <== NOT EXECUTED
2041aa8: 10 80 00 08 b 2041ac8 <rtems_rfs_fs_open+0x468> <== NOT EXECUTED
2041aac: b2 10 20 00 clr %i1 <== NOT EXECUTED
/*
* Perform each phase of group initialisation at the same time. This way we
* know how far the initialisation has gone if an error occurs and we need to
* close everything.
*/
for (group = 0; group < fs->group_count; group++)
2041ab0: b2 06 60 01 inc %i1 <== NOT EXECUTED
2041ab4: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2041ab8: 16 80 00 1e bge 2041b30 <rtems_rfs_fs_open+0x4d0> <== NOT EXECUTED
2041abc: a2 04 60 50 add %l1, 0x50, %l1 <== NOT EXECUTED
2041ac0: e4 06 20 24 ld [ %i0 + 0x24 ], %l2 <== NOT EXECUTED
2041ac4: e6 06 20 1c ld [ %i0 + 0x1c ], %l3 <== NOT EXECUTED
{
rc = rtems_rfs_group_open (fs,
2041ac8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2041acc: 7f ff 04 30 call 2002b8c <.umul> <== NOT EXECUTED
2041ad0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2041ad4: d6 06 20 28 ld [ %i0 + 0x28 ], %o3 <== NOT EXECUTED
2041ad8: 92 02 20 01 add %o0, 1, %o1 <== NOT EXECUTED
2041adc: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2041ae0: 98 04 c0 11 add %l3, %l1, %o4 <== NOT EXECUTED
2041ae4: 40 00 05 3e call 2042fdc <rtems_rfs_group_open> <== NOT EXECUTED
2041ae8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_fs_block (fs, group, 0),
fs->group_blocks,
fs->group_inodes,
&fs->groups[group]);
if (rc > 0)
2041aec: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2041af0: 24 bf ff f0 ble,a 2041ab0 <rtems_rfs_fs_open+0x450> <== NOT EXECUTED
2041af4: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
{
int g;
for (g = 0; g < group; g++)
2041af8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2041afc: 02 bf ff d5 be 2041a50 <rtems_rfs_fs_open+0x3f0> <== NOT EXECUTED
2041b00: a6 10 20 00 clr %l3 <== NOT EXECUTED
2041b04: a2 10 20 00 clr %l1 <== NOT EXECUTED
rtems_rfs_group_close (fs, &fs->groups[g]);
2041b08: d2 06 20 1c ld [ %i0 + 0x1c ], %o1 <== NOT EXECUTED
2041b0c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041b10: 40 00 05 12 call 2042f58 <rtems_rfs_group_close> <== NOT EXECUTED
2041b14: 92 02 40 13 add %o1, %l3, %o1 <== NOT EXECUTED
fs->group_inodes,
&fs->groups[group]);
if (rc > 0)
{
int g;
for (g = 0; g < group; g++)
2041b18: a2 04 60 01 inc %l1 <== NOT EXECUTED
2041b1c: 80 a6 40 11 cmp %i1, %l1 <== NOT EXECUTED
2041b20: 14 bf ff fa bg 2041b08 <rtems_rfs_fs_open+0x4a8> <== NOT EXECUTED
2041b24: a6 04 e0 50 add %l3, 0x50, %l3 <== NOT EXECUTED
rtems_rfs_group_close (fs, &fs->groups[g]);
rtems_rfs_buffer_handle_close (fs, &handle);
2041b28: 10 bf ff cb b 2041a54 <rtems_rfs_fs_open+0x3f4> <== NOT EXECUTED
2041b2c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rc, strerror (rc));
errno = rc;
return -1;
}
rc = rtems_rfs_inode_open (*fs, RTEMS_RFS_ROOT_INO, &inode, true);
2041b30: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
2041b34: a0 07 bf cc add %fp, -52, %l0 <== NOT EXECUTED
2041b38: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2041b3c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2041b40: 40 00 06 5d call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2041b44: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2041b48: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2041b4c: 14 80 00 2d bg 2041c00 <rtems_rfs_fs_open+0x5a0> <== NOT EXECUTED
2041b50: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
rc, strerror (rc));
errno = rc;
return -1;
}
if (((*fs)->flags & RTEMS_RFS_FS_FORCE_OPEN) == 0)
2041b54: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED
2041b58: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
2041b5c: 12 80 00 12 bne 2041ba4 <rtems_rfs_fs_open+0x544> <== NOT EXECUTED
2041b60: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
2041b64: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2041b68: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
2041b6c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2041b70: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
{
mode = rtems_rfs_inode_get_mode (&inode);
if ((mode == 0xffff) || !RTEMS_RFS_S_ISDIR (mode))
2041b74: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
2041b78: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
2041b7c: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
2041b80: 83 30 60 10 srl %g1, 0x10, %g1 <== NOT EXECUTED
2041b84: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2041b88: 02 80 00 11 be 2041bcc <rtems_rfs_fs_open+0x56c> <== NOT EXECUTED
2041b8c: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
2041b90: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
2041b94: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
2041b98: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2041b9c: 12 80 00 0c bne 2041bcc <rtems_rfs_fs_open+0x56c> <== NOT EXECUTED
2041ba0: 01 00 00 00 nop <== NOT EXECUTED
errno = EIO;
return -1;
}
}
rc = rtems_rfs_inode_close (*fs, &inode);
2041ba4: 40 00 06 1a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2041ba8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (rc > 0)
2041bac: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
2041bb0: 14 bf ff 0c bg 20417e0 <rtems_rfs_fs_open+0x180> <== NOT EXECUTED
2041bb4: 01 00 00 00 nop <== NOT EXECUTED
printf ("rtems-rfs: open: closing root inode: %d: %s\n", rc, strerror (rc));
errno = rc;
return -1;
}
errno = 0;
2041bb8: 40 00 22 32 call 204a480 <__errno> <== NOT EXECUTED
2041bbc: b0 10 20 00 clr %i0 ! 0 <PROM_START> <== NOT EXECUTED
2041bc0: c0 22 00 00 clr [ %o0 ] <== NOT EXECUTED
return 0;
}
2041bc4: 81 c7 e0 08 ret <== NOT EXECUTED
2041bc8: 81 e8 00 00 restore <== NOT EXECUTED
{
mode = rtems_rfs_inode_get_mode (&inode);
if ((mode == 0xffff) || !RTEMS_RFS_S_ISDIR (mode))
{
rtems_rfs_inode_close (*fs, &inode);
2041bcc: 40 00 06 10 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2041bd0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
rtems_rfs_buffer_close (*fs);
2041bd4: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
2041bd8: 7f ff f6 e6 call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
2041bdc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free (*fs);
2041be0: 7f ff 1b 3f call 20088dc <free> <== NOT EXECUTED
2041be4: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: invalid root inode mode\n");
errno = EIO;
2041be8: 40 00 22 26 call 204a480 <__errno> <== NOT EXECUTED
2041bec: 01 00 00 00 nop <== NOT EXECUTED
2041bf0: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED
2041bf4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
2041bf8: 81 c7 e0 08 ret <== NOT EXECUTED
2041bfc: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_open (*fs, RTEMS_RFS_ROOT_INO, &inode, true);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
2041c00: 7f ff f6 dc call 203f770 <rtems_rfs_buffer_close> <== NOT EXECUTED
2041c04: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
free (*fs);
2041c08: 7f ff 1b 35 call 20088dc <free> <== NOT EXECUTED
2041c0c: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))
printf ("rtems-rfs: open: reading root inode: %d: %s\n",
rc, strerror (rc));
errno = rc;
2041c10: 40 00 22 1c call 204a480 <__errno> <== NOT EXECUTED
2041c14: 01 00 00 00 nop <== NOT EXECUTED
2041c18: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
return -1;
2041c1c: 81 c7 e0 08 ret <== NOT EXECUTED
2041c20: 81 e8 00 00 restore <== NOT EXECUTED
fs->groups = calloc (fs->group_count, sizeof (rtems_rfs_group));
if (!fs->groups)
{
rtems_rfs_buffer_handle_close (fs, &handle);
2041c24: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2041c28: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2041c2c: 7f ff fe 83 call 2041638 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
2041c30: a4 10 20 0c mov 0xc, %l2 <== NOT EXECUTED
}
rc = rtems_rfs_fs_read_superblock (*fs);
if (rc > 0)
{
rtems_rfs_buffer_close (*fs);
2041c34: 10 bf fe c2 b 204173c <rtems_rfs_fs_open+0xdc> <== NOT EXECUTED
2041c38: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
02041590 <rtems_rfs_fs_size>:
#include <rtems/rfs/rtems-rfs-inode.h>
#include <rtems/rfs/rtems-rfs-trace.h>
uint64_t
rtems_rfs_fs_size (rtems_rfs_file_system* fs)
{
2041590: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
2041594: d6 06 20 04 ld [ %i0 + 4 ], %o3 <== NOT EXECUTED
2041598: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED
204159c: 94 10 20 00 clr %o2 <== NOT EXECUTED
20415a0: 40 00 86 51 call 2062ee4 <__muldi3> <== NOT EXECUTED
20415a4: 90 10 20 00 clr %o0 <== NOT EXECUTED
uint64_t blocks = rtems_rfs_fs_blocks (fs);
uint64_t block_size = rtems_rfs_fs_block_size (fs);
return blocks * block_size;
}
20415a8: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
20415ac: 81 c7 e0 08 ret <== NOT EXECUTED
20415b0: 93 e8 00 09 restore %g0, %o1, %o1 <== NOT EXECUTED
02042d7c <rtems_rfs_group_bitmap_alloc>:
int
rtems_rfs_group_bitmap_alloc (rtems_rfs_file_system* fs,
rtems_rfs_bitmap_bit goal,
bool inode,
rtems_rfs_bitmap_bit* result)
{
2042d7c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_bit bit;
int offset;
bool updown;
int direction;
if (inode)
2042d80: b4 8e a0 ff andcc %i2, 0xff, %i2 <== NOT EXECUTED
2042d84: 02 80 00 56 be 2042edc <rtems_rfs_group_bitmap_alloc+0x160><== NOT EXECUTED
2042d88: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{
size = fs->group_inodes;
2042d8c: e2 06 20 28 ld [ %i0 + 0x28 ], %l1 <== NOT EXECUTED
goal -= RTEMS_RFS_ROOT_INO;
2042d90: b2 06 7f ff add %i1, -1, %i1 <== NOT EXECUTED
}
else
size = fs->group_blocks;
group_start = goal / size;
2042d94: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042d98: 40 00 7e fb call 2062984 <.udiv> <== NOT EXECUTED
2042d9c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (goal % size);
2042da0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
goal -= RTEMS_RFS_ROOT_INO;
}
else
size = fs->group_blocks;
group_start = goal / size;
2042da4: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (goal % size);
2042da8: 40 00 7f a3 call 2062c34 <.urem> <== NOT EXECUTED
2042dac: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
*/
while (true)
{
rtems_rfs_bitmap_control* bitmap;
int group;
bool allocated = false;
2042db0: c0 2f bf ff clrb [ %fp + -1 ] <== NOT EXECUTED
}
else
size = fs->group_blocks;
group_start = goal / size;
bit = (rtems_rfs_bitmap_bit) (goal % size);
2042db4: d0 27 bf f8 st %o0, [ %fp + -8 ] <== NOT EXECUTED
* We can start at any location and we move out from that point in each
* direction. The offset grows until we find a free bit or we hit an end.
*/
group = group_start + (direction * offset);
if (offset)
bit = direction > 0 ? 0 : size - 1;
2042db8: ac 04 7f ff add %l1, -1, %l6 <== NOT EXECUTED
*/
while (true)
{
rtems_rfs_bitmap_control* bitmap;
int group;
bool allocated = false;
2042dbc: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
2042dc0: a2 10 00 15 mov %l5, %l1 <== NOT EXECUTED
2042dc4: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
2042dc8: a6 10 20 00 clr %l3 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_alloc (bitmap, bit, &allocated, &bit);
2042dcc: ae 07 bf ff add %fp, -1, %l7 <== NOT EXECUTED
/*
* If we are still looking up and down and if the group is out of range we
* have reached one end. Stopping looking up and down and just move in the
* one direction one group at a time.
*/
if ((group < 0) || (group >= fs->group_count))
2042dd0: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2042dd4: 06 80 00 06 bl 2042dec <rtems_rfs_group_bitmap_alloc+0x70><== NOT EXECUTED
2042dd8: b2 07 bf f8 add %fp, -8, %i1 <== NOT EXECUTED
2042ddc: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
2042de0: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2042de4: 14 80 00 1d bg 2042e58 <rtems_rfs_group_bitmap_alloc+0xdc><== NOT EXECUTED
2042de8: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
{
if (!updown)
2042dec: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
2042df0: 02 80 00 38 be 2042ed0 <rtems_rfs_group_bitmap_alloc+0x154><== NOT EXECUTED
2042df4: a4 1c a0 01 xor %l2, 1, %l2 <== NOT EXECUTED
break;
direction = direction > 0 ? -1 : 1;
2042df8: 80 a0 00 12 cmp %g0, %l2 <== NOT EXECUTED
/*
* We can start at any location and we move out from that point in each
* direction. The offset grows until we find a free bit or we hit an end.
*/
group = group_start + (direction * offset);
if (offset)
2042dfc: a8 10 20 00 clr %l4 <== NOT EXECUTED
*/
if ((group < 0) || (group >= fs->group_count))
{
if (!updown)
break;
direction = direction > 0 ? -1 : 1;
2042e00: a4 40 3f ff addx %g0, -1, %l2 <== NOT EXECUTED
/*
* We can start at any location and we move out from that point in each
* direction. The offset grows until we find a free bit or we hit an end.
*/
group = group_start + (direction * offset);
if (offset)
2042e04: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2042e08: 02 80 00 07 be 2042e24 <rtems_rfs_group_bitmap_alloc+0xa8><== NOT EXECUTED
2042e0c: a4 14 a0 01 or %l2, 1, %l2 <== NOT EXECUTED
bit = direction > 0 ? 0 : size - 1;
2042e10: 82 1c a0 01 xor %l2, 1, %g1 <== NOT EXECUTED
2042e14: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2042e18: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
2042e1c: 82 0d 80 01 and %l6, %g1, %g1 <== NOT EXECUTED
2042e20: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
*/
while (true)
{
rtems_rfs_bitmap_control* bitmap;
int group;
bool allocated = false;
2042e24: c0 2f bf ff clrb [ %fp + -1 ] <== NOT EXECUTED
/*
* We can start at any location and we move out from that point in each
* direction. The offset grows until we find a free bit or we hit an end.
*/
group = group_start + (direction * offset);
2042e28: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2042e2c: 7f fe ff 58 call 2002b8c <.umul> <== NOT EXECUTED
2042e30: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2042e34: a2 02 00 15 add %o0, %l5, %l1 <== NOT EXECUTED
/*
* If we are still looking up and down and if the group is out of range we
* have reached one end. Stopping looking up and down and just move in the
* one direction one group at a time.
*/
if ((group < 0) || (group >= fs->group_count))
2042e38: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2042e3c: 06 bf ff ed bl 2042df0 <rtems_rfs_group_bitmap_alloc+0x74><== NOT EXECUTED
2042e40: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
2042e44: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
2042e48: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2042e4c: 04 bf ff e9 ble 2042df0 <rtems_rfs_group_bitmap_alloc+0x74><== NOT EXECUTED
2042e50: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
direction = direction > 0 ? -1 : 1;
updown = false;
continue;
}
if (inode)
2042e54: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2042e58: 12 80 00 23 bne 2042ee4 <rtems_rfs_group_bitmap_alloc+0x168><== NOT EXECUTED
2042e5c: fa 04 20 1c ld [ %l0 + 0x1c ], %i5 <== NOT EXECUTED
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042e60: b1 2c 60 04 sll %l1, 4, %i0 <== NOT EXECUTED
2042e64: b9 2c 60 06 sll %l1, 6, %i4 <== NOT EXECUTED
2042e68: 82 06 00 1c add %i0, %i4, %g1 <== NOT EXECUTED
2042e6c: ba 07 40 01 add %i5, %g1, %i5 <== NOT EXECUTED
2042e70: ba 07 60 08 add %i5, 8, %i5 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_alloc (bitmap, bit, &allocated, &bit);
2042e74: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
2042e78: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
2042e7c: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
2042e80: 40 00 1b 23 call 2049b0c <rtems_rfs_bitmap_map_alloc> <== NOT EXECUTED
2042e84: 96 10 00 19 mov %i1, %o3 <== NOT EXECUTED
if (rc > 0)
2042e88: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2042e8c: 14 80 00 12 bg 2042ed4 <rtems_rfs_group_bitmap_alloc+0x158><== NOT EXECUTED
2042e90: 01 00 00 00 nop <== NOT EXECUTED
return rc;
if (rtems_rfs_fs_release_bitmaps (fs))
2042e94: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
2042e98: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2042e9c: 22 80 00 18 be,a 2042efc <rtems_rfs_group_bitmap_alloc+0x180><== NOT EXECUTED
2042ea0: d2 07 40 00 ld [ %i5 ], %o1 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
if (allocated)
2042ea4: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
2042ea8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2042eac: 12 80 00 18 bne 2042f0c <rtems_rfs_group_bitmap_alloc+0x190><== NOT EXECUTED
2042eb0: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
printf ("rtems-rfs: group-bitmap-alloc: %s allocated: %" PRId32 "\n",
inode ? "inode" : "block", *result);
return 0;
}
if (updown)
2042eb4: 02 bf ff d7 be 2042e10 <rtems_rfs_group_bitmap_alloc+0x94><== NOT EXECUTED
2042eb8: a6 04 e0 01 inc %l3 <== NOT EXECUTED
direction = direction > 0 ? -1 : 1;
2042ebc: a4 1c a0 01 xor %l2, 1, %l2 <== NOT EXECUTED
2042ec0: 80 a0 00 12 cmp %g0, %l2 <== NOT EXECUTED
2042ec4: a4 40 3f ff addx %g0, -1, %l2 <== NOT EXECUTED
2042ec8: 10 bf ff d2 b 2042e10 <rtems_rfs_group_bitmap_alloc+0x94> <== NOT EXECUTED
2042ecc: a4 14 a0 01 or %l2, 1, %l2 <== NOT EXECUTED
offset++;
2042ed0: 90 10 20 1c mov 0x1c, %o0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))
printf ("rtems-rfs: group-bitmap-alloc: no blocks available\n");
return ENOSPC;
}
2042ed4: 81 c7 e0 08 ret <== NOT EXECUTED
2042ed8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
{
size = fs->group_inodes;
goal -= RTEMS_RFS_ROOT_INO;
}
else
size = fs->group_blocks;
2042edc: 10 bf ff ae b 2042d94 <rtems_rfs_group_bitmap_alloc+0x18> <== NOT EXECUTED
2042ee0: e2 06 20 24 ld [ %i0 + 0x24 ], %l1 <== NOT EXECUTED
updown = false;
continue;
}
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042ee4: b1 2c 60 04 sll %l1, 4, %i0 <== NOT EXECUTED
2042ee8: b9 2c 60 06 sll %l1, 6, %i4 <== NOT EXECUTED
2042eec: 82 06 00 1c add %i0, %i4, %g1 <== NOT EXECUTED
2042ef0: ba 07 40 01 add %i5, %g1, %i5 <== NOT EXECUTED
2042ef4: 10 bf ff e0 b 2042e74 <rtems_rfs_group_bitmap_alloc+0xf8> <== NOT EXECUTED
2042ef8: ba 07 60 2c add %i5, 0x2c, %i5 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_alloc (bitmap, bit, &allocated, &bit);
if (rc > 0)
return rc;
if (rtems_rfs_fs_release_bitmaps (fs))
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042efc: 7f ff f2 3f call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042f00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (allocated)
2042f04: 10 bf ff e9 b 2042ea8 <rtems_rfs_group_bitmap_alloc+0x12c><== NOT EXECUTED
2042f08: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
{
if (inode)
2042f0c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2042f10: 22 80 00 0b be,a 2042f3c <rtems_rfs_group_bitmap_alloc+0x1c0><== NOT EXECUTED
2042f14: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
*result = rtems_rfs_group_inode (fs, group, bit);
2042f18: d2 04 20 28 ld [ %l0 + 0x28 ], %o1 <== NOT EXECUTED
2042f1c: e0 07 bf f8 ld [ %fp + -8 ], %l0 <== NOT EXECUTED
2042f20: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2042f24: 7f fe ff 1a call 2002b8c <.umul> <== NOT EXECUTED
2042f28: a0 04 20 01 inc %l0 <== NOT EXECUTED
2042f2c: 90 04 00 08 add %l0, %o0, %o0 <== NOT EXECUTED
2042f30: d0 26 c0 00 st %o0, [ %i3 ] <== NOT EXECUTED
2042f34: 10 bf ff e8 b 2042ed4 <rtems_rfs_group_bitmap_alloc+0x158><== NOT EXECUTED
2042f38: 90 10 20 00 clr %o0 <== NOT EXECUTED
else
*result = rtems_rfs_group_block (&fs->groups[group], bit);
2042f3c: b8 06 00 1c add %i0, %i4, %i4 <== NOT EXECUTED
2042f40: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
2042f44: c2 00 40 1c ld [ %g1 + %i4 ], %g1 <== NOT EXECUTED
2042f48: 90 10 20 00 clr %o0 <== NOT EXECUTED
2042f4c: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2042f50: 10 bf ff e1 b 2042ed4 <rtems_rfs_group_bitmap_alloc+0x158><== NOT EXECUTED
2042f54: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
02042cac <rtems_rfs_group_bitmap_free>:
int
rtems_rfs_group_bitmap_free (rtems_rfs_file_system* fs,
bool inode,
rtems_rfs_bitmap_bit no)
{
2042cac: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))
printf ("rtems-rfs: group-bitmap-free: %s free: %" PRId32 "\n",
inode ? "inode" : "block", no);
if (inode)
2042cb0: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
2042cb4: 02 80 00 1a be 2042d1c <rtems_rfs_group_bitmap_free+0x70> <== NOT EXECUTED
2042cb8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{
no -= RTEMS_RFS_ROOT_INO;
size = fs->group_inodes;
2042cbc: e2 06 20 28 ld [ %i0 + 0x28 ], %l1 <== NOT EXECUTED
{
no -= RTEMS_RFS_SUPERBLOCK_SIZE;
size = fs->group_blocks;
}
group = no / size;
2042cc0: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (no % size);
2042cc4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042cc8: 40 00 7f db call 2062c34 <.urem> <== NOT EXECUTED
2042ccc: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042cd0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
no -= RTEMS_RFS_SUPERBLOCK_SIZE;
size = fs->group_blocks;
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042cd4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042cd8: 40 00 7f 2b call 2062984 <.udiv> <== NOT EXECUTED
2042cdc: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2042ce0: e2 04 20 1c ld [ %l0 + 0x1c ], %l1 <== NOT EXECUTED
2042ce4: 83 2a 20 06 sll %o0, 6, %g1 <== NOT EXECUTED
2042ce8: 91 2a 20 04 sll %o0, 4, %o0 <== NOT EXECUTED
2042cec: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042cf0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042cf4: a2 04 40 08 add %l1, %o0, %l1 <== NOT EXECUTED
2042cf8: a2 04 60 2c add %l1, 0x2c, %l1 <== NOT EXECUTED
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042cfc: 40 00 1a 8e call 2049734 <rtems_rfs_bitmap_map_clear> <== NOT EXECUTED
2042d00: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042d04: d2 04 40 00 ld [ %l1 ], %o1 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042d08: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042d0c: 7f ff f2 bb call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042d10: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
}
2042d14: 81 c7 e0 08 ret <== NOT EXECUTED
2042d18: 81 e8 00 00 restore <== NOT EXECUTED
size = fs->group_inodes;
}
else
{
no -= RTEMS_RFS_SUPERBLOCK_SIZE;
size = fs->group_blocks;
2042d1c: e2 06 20 24 ld [ %i0 + 0x24 ], %l1 <== NOT EXECUTED
}
group = no / size;
2042d20: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (no % size);
2042d24: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042d28: 40 00 7f c3 call 2062c34 <.urem> <== NOT EXECUTED
2042d2c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042d30: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
no -= RTEMS_RFS_SUPERBLOCK_SIZE;
size = fs->group_blocks;
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042d34: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042d38: 40 00 7f 13 call 2062984 <.udiv> <== NOT EXECUTED
2042d3c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2042d40: e2 04 20 1c ld [ %l0 + 0x1c ], %l1 <== NOT EXECUTED
2042d44: 83 2a 20 06 sll %o0, 6, %g1 <== NOT EXECUTED
2042d48: 91 2a 20 04 sll %o0, 4, %o0 <== NOT EXECUTED
2042d4c: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042d50: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042d54: a2 04 40 08 add %l1, %o0, %l1 <== NOT EXECUTED
2042d58: a2 04 60 08 add %l1, 8, %l1 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042d5c: 40 00 1a 76 call 2049734 <rtems_rfs_bitmap_map_clear> <== NOT EXECUTED
2042d60: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042d64: d2 04 40 00 ld [ %l1 ], %o1 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_clear (bitmap, bit);
2042d68: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042d6c: 7f ff f2 a3 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042d70: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
}
2042d74: 81 c7 e0 08 ret <== NOT EXECUTED
2042d78: 81 e8 00 00 restore <== NOT EXECUTED
02042bac <rtems_rfs_group_bitmap_test>:
int
rtems_rfs_group_bitmap_test (rtems_rfs_file_system* fs,
bool inode,
rtems_rfs_bitmap_bit no,
bool* state)
{
2042bac: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))
printf ("rtems-rfs: group-bitmap-test: %s test: %" PRId32 "\n",
inode ? "inode" : "block", no);
if (inode)
2042bb0: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
2042bb4: 02 80 00 21 be 2042c38 <rtems_rfs_group_bitmap_test+0x8c> <== NOT EXECUTED
2042bb8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{
if ((no < RTEMS_RFS_ROOT_INO) || (no > rtems_rfs_fs_inodes (fs)))
2042bbc: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2042bc0: 04 80 00 39 ble 2042ca4 <rtems_rfs_group_bitmap_test+0xf8><== NOT EXECUTED
2042bc4: 01 00 00 00 nop <== NOT EXECUTED
2042bc8: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
2042bcc: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED
2042bd0: 18 80 00 35 bgu 2042ca4 <rtems_rfs_group_bitmap_test+0xf8><== NOT EXECUTED
2042bd4: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
return EINVAL;
no -= RTEMS_RFS_ROOT_INO;
size = fs->group_inodes;
2042bd8: e2 06 20 28 ld [ %i0 + 0x28 ], %l1 <== NOT EXECUTED
return EINVAL;
size = fs->group_blocks;
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042bdc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2042be0: 40 00 80 15 call 2062c34 <.urem> <== NOT EXECUTED
2042be4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042be8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return EINVAL;
size = fs->group_blocks;
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042bec: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042bf0: 40 00 7f 65 call 2062984 <.udiv> <== NOT EXECUTED
2042bf4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2042bf8: f4 04 20 1c ld [ %l0 + 0x1c ], %i2 <== NOT EXECUTED
2042bfc: 83 2a 20 06 sll %o0, 6, %g1 <== NOT EXECUTED
2042c00: 91 2a 20 04 sll %o0, 4, %o0 <== NOT EXECUTED
2042c04: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c08: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042c0c: b4 06 80 08 add %i2, %o0, %i2 <== NOT EXECUTED
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c10: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
2042c14: b4 06 a0 2c add %i2, 0x2c, %i2 <== NOT EXECUTED
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c18: 40 00 1a ae call 20496d0 <rtems_rfs_bitmap_map_test> <== NOT EXECUTED
2042c1c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042c20: d2 06 80 00 ld [ %i2 ], %o1 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c24: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042c28: 7f ff f2 f4 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042c2c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
2042c30: 81 c7 e0 08 ret <== NOT EXECUTED
2042c34: 81 e8 00 00 restore <== NOT EXECUTED
no -= RTEMS_RFS_ROOT_INO;
size = fs->group_inodes;
}
else
{
if (no >= rtems_rfs_fs_blocks (fs))
2042c38: c2 06 20 04 ld [ %i0 + 4 ], %g1 <== NOT EXECUTED
2042c3c: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED
2042c40: 1a 80 00 19 bcc 2042ca4 <rtems_rfs_group_bitmap_test+0xf8><== NOT EXECUTED
2042c44: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
return EINVAL;
size = fs->group_blocks;
2042c48: e2 06 20 24 ld [ %i0 + 0x24 ], %l1 <== NOT EXECUTED
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042c4c: 40 00 7f fa call 2062c34 <.urem> <== NOT EXECUTED
2042c50: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042c54: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return EINVAL;
size = fs->group_blocks;
}
group = no / size;
bit = (rtems_rfs_bitmap_bit) (no % size);
2042c58: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042c5c: 40 00 7f 4a call 2062984 <.udiv> <== NOT EXECUTED
2042c60: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2042c64: f4 04 20 1c ld [ %l0 + 0x1c ], %i2 <== NOT EXECUTED
2042c68: 83 2a 20 06 sll %o0, 6, %g1 <== NOT EXECUTED
2042c6c: 91 2a 20 04 sll %o0, 4, %o0 <== NOT EXECUTED
2042c70: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c74: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042c78: b4 06 80 08 add %i2, %o0, %i2 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c7c: 94 10 00 1b mov %i3, %o2 <== NOT EXECUTED
bit = (rtems_rfs_bitmap_bit) (no % size);
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
2042c80: b4 06 a0 08 add %i2, 8, %i2 <== NOT EXECUTED
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c84: 40 00 1a 93 call 20496d0 <rtems_rfs_bitmap_map_test> <== NOT EXECUTED
2042c88: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042c8c: d2 06 80 00 ld [ %i2 ], %o1 <== NOT EXECUTED
if (inode)
bitmap = &fs->groups[group].inode_bitmap;
else
bitmap = &fs->groups[group].block_bitmap;
rc = rtems_rfs_bitmap_map_test (bitmap, bit, state);
2042c90: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, bitmap);
2042c94: 7f ff f2 d9 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042c98: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
2042c9c: 81 c7 e0 08 ret <== NOT EXECUTED
2042ca0: 81 e8 00 00 restore <== NOT EXECUTED
}
2042ca4: 81 c7 e0 08 ret <== NOT EXECUTED
2042ca8: 91 e8 20 16 restore %g0, 0x16, %o0 <== NOT EXECUTED
02042f58 <rtems_rfs_group_close>:
return 0;
}
int
rtems_rfs_group_close (rtems_rfs_file_system* fs, rtems_rfs_group* group)
{
2042f58: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* We need to close as much as possible and also return any error if one
* occurs but this may result in one even more important error being lost but
* we cannot OR the errors together so this is a reasonable compromise.
*/
rc = rtems_rfs_bitmap_close (&group->inode_bitmap);
2042f5c: 40 00 19 19 call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
2042f60: 90 06 60 2c add %i1, 0x2c, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042f64: 92 06 60 44 add %i1, 0x44, %o1 <== NOT EXECUTED
2042f68: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2042f6c: 7f ff f2 23 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042f70: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
return 0;
}
int
rtems_rfs_group_close (rtems_rfs_file_system* fs, rtems_rfs_group* group)
{
2042f74: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
handle->dirty = false;
2042f78: c0 2e 60 44 clrb [ %i1 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
2042f7c: c0 26 60 48 clr [ %i1 + 0x48 ] <== NOT EXECUTED
handle->buffer = NULL;
2042f80: c0 26 60 4c clr [ %i1 + 0x4c ] <== NOT EXECUTED
if (rc > 0)
result = rc;
rc = rtems_rfs_buffer_handle_close (fs, &group->inode_bitmap_buffer);
if (rc > 0)
result = rc;
rc = rtems_rfs_bitmap_close (&group->block_bitmap);
2042f84: 40 00 19 0f call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
2042f88: 90 06 60 08 add %i1, 8, %o0 <== NOT EXECUTED
if (rc > 0)
2042f8c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2042f90: 04 80 00 09 ble 2042fb4 <rtems_rfs_group_close+0x5c> <== NOT EXECUTED
2042f94: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042f98: 7f ff f2 18 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042f9c: 92 06 60 20 add %i1, 0x20, %o1 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
2042fa0: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
2042fa4: c0 2e 60 20 clrb [ %i1 + 0x20 ] <== NOT EXECUTED
handle->bnum = 0;
2042fa8: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_close (fs, &group->block_bitmap_buffer);
if (rc > 0)
result = rc;
return result;
}
2042fac: 81 c7 e0 08 ret <== NOT EXECUTED
2042fb0: 81 e8 00 00 restore <== NOT EXECUTED
result = rc;
rc = rtems_rfs_buffer_handle_close (fs, &group->inode_bitmap_buffer);
if (rc > 0)
result = rc;
rc = rtems_rfs_bitmap_close (&group->block_bitmap);
if (rc > 0)
2042fb4: b0 38 00 11 xnor %g0, %l1, %i0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2042fb8: 92 06 60 20 add %i1, 0x20, %o1 <== NOT EXECUTED
2042fbc: 7f ff f2 0f call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2042fc0: b1 3e 20 1f sra %i0, 0x1f, %i0 <== NOT EXECUTED
2042fc4: b0 0c 40 18 and %l1, %i0, %i0 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
2042fc8: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
2042fcc: c0 2e 60 20 clrb [ %i1 + 0x20 ] <== NOT EXECUTED
handle->bnum = 0;
2042fd0: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_close (fs, &group->block_bitmap_buffer);
if (rc > 0)
result = rc;
return result;
}
2042fd4: 81 c7 e0 08 ret <== NOT EXECUTED
2042fd8: 81 e8 00 00 restore <== NOT EXECUTED
02042fdc <rtems_rfs_group_open>:
rtems_rfs_group_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_block base,
size_t size,
size_t inodes,
rtems_rfs_group* group)
{
2042fdc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
if (base >= rtems_rfs_fs_blocks (fs))
2042fe0: c2 06 20 04 ld [ %i0 + 4 ], %g1 <== NOT EXECUTED
rtems_rfs_group_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_block base,
size_t size,
size_t inodes,
rtems_rfs_group* group)
{
2042fe4: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc;
if (base >= rtems_rfs_fs_blocks (fs))
2042fe8: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED
2042fec: 08 80 00 1b bleu 2043058 <rtems_rfs_group_open+0x7c> <== NOT EXECUTED
2042ff0: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
printf ("rtems-rfs: group-open: base outside file system range: %d: %s\n",
EIO, strerror (EIO));
return EIO;
}
if ((base + size) >= rtems_rfs_fs_blocks (fs))
2042ff4: 84 06 80 19 add %i2, %i1, %g2 <== NOT EXECUTED
2042ff8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2042ffc: 28 80 00 02 bleu,a 2043004 <rtems_rfs_group_open+0x28> <== NOT EXECUTED
2043000: b4 20 40 19 sub %g1, %i1, %i2 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_OPEN))
printf ("rtems-rfs: group-open: base=%" PRId32 ", blocks=%zd inodes=%zd\n",
base, size, inodes);
group->base = base;
2043004: f2 27 00 00 st %i1, [ %i4 ] <== NOT EXECUTED
group->size = size;
2043008: f4 27 20 04 st %i2, [ %i4 + 4 ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
204300c: c0 2f 20 20 clrb [ %i4 + 0x20 ] <== NOT EXECUTED
handle->bnum = 0;
2043010: c0 27 20 24 clr [ %i4 + 0x24 ] <== NOT EXECUTED
handle->buffer = NULL;
2043014: c0 27 20 28 clr [ %i4 + 0x28 ] <== NOT EXECUTED
printf ("rtems-rfs: group-open: could not open block bitmap handle: %d: %s\n",
rc, strerror (rc));
return rc;
}
rc = rtems_rfs_bitmap_open (&group->block_bitmap, fs,
2043018: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
204301c: a4 07 20 08 add %i4, 8, %l2 <== NOT EXECUTED
2043020: a2 07 20 20 add %i4, 0x20, %l1 <== NOT EXECUTED
2043024: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2043028: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
204302c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2043030: 40 00 19 3b call 204951c <rtems_rfs_bitmap_open> <== NOT EXECUTED
2043034: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
&group->block_bitmap_buffer, size,
group->base + RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
if (rc > 0)
2043038: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
204303c: 04 80 00 09 ble 2043060 <rtems_rfs_group_open+0x84> <== NOT EXECUTED
2043040: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2043044: 7f ff f1 ed call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2043048: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
handle->dirty = false;
handle->bnum = 0;
handle->buffer = NULL;
204304c: c0 27 20 28 clr [ %i4 + 0x28 ] <== NOT EXECUTED
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
handle->dirty = false;
2043050: c0 2f 20 20 clrb [ %i4 + 0x20 ] <== NOT EXECUTED
handle->bnum = 0;
2043054: c0 27 20 24 clr [ %i4 + 0x24 ] <== NOT EXECUTED
2043058: 81 c7 e0 08 ret <== NOT EXECUTED
204305c: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2043060: c0 2f 20 44 clrb [ %i4 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
2043064: c0 27 20 48 clr [ %i4 + 0x48 ] <== NOT EXECUTED
handle->buffer = NULL;
2043068: c0 27 20 4c clr [ %i4 + 0x4c ] <== NOT EXECUTED
printf ("rtems-rfs: group-open: could not open inode bitmap handle: %d: %s\n",
rc, strerror (rc));
return rc;
}
rc = rtems_rfs_bitmap_open (&group->inode_bitmap, fs,
204306c: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
2043070: 80 a6 80 1b cmp %i2, %i3 <== NOT EXECUTED
2043074: a6 07 20 44 add %i4, 0x44, %l3 <== NOT EXECUTED
2043078: 08 80 00 03 bleu 2043084 <rtems_rfs_group_open+0xa8> <== NOT EXECUTED
204307c: 90 07 20 2c add %i4, 0x2c, %o0 <== NOT EXECUTED
2043080: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2043084: d8 07 00 00 ld [ %i4 ], %o4 <== NOT EXECUTED
2043088: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
204308c: 98 03 20 01 inc %o4 <== NOT EXECUTED
2043090: 40 00 19 23 call 204951c <rtems_rfs_bitmap_open> <== NOT EXECUTED
2043094: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
&group->inode_bitmap_buffer, inodes,
group->base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
if (rc > 0)
2043098: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
204309c: 14 80 00 0e bg 20430d4 <rtems_rfs_group_open+0xf8> <== NOT EXECUTED
20430a0: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
printf ("rtems-rfs: group-open: could not open inode bitmap: %d: %s\n",
rc, strerror (rc));
return rc;
}
if (rtems_rfs_fs_release_bitmaps (fs))
20430a4: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
20430a8: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
20430ac: 12 bf ff eb bne 2043058 <rtems_rfs_group_open+0x7c> <== NOT EXECUTED
20430b0: b0 10 20 00 clr %i0 <== NOT EXECUTED
{
rtems_rfs_bitmap_release_buffer (fs, &group->block_bitmap);
20430b4: d2 07 20 08 ld [ %i4 + 8 ], %o1 <== NOT EXECUTED
20430b8: 7f ff f1 d0 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20430bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_bitmap_release_buffer (fs, &group->inode_bitmap);
20430c0: d2 07 20 2c ld [ %i4 + 0x2c ], %o1 <== NOT EXECUTED
20430c4: 7f ff f1 cd call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20430c8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
return 0;
}
20430cc: 81 c7 e0 08 ret <== NOT EXECUTED
20430d0: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20430d4: 7f ff f1 c9 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20430d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
&group->inode_bitmap_buffer, inodes,
group->base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &group->inode_bitmap_buffer);
rtems_rfs_bitmap_close (&group->block_bitmap);
20430dc: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
handle->dirty = false;
20430e0: c0 2f 20 44 clrb [ %i4 + 0x44 ] <== NOT EXECUTED
handle->bnum = 0;
20430e4: c0 27 20 48 clr [ %i4 + 0x48 ] <== NOT EXECUTED
20430e8: 40 00 18 b6 call 20493c0 <rtems_rfs_bitmap_close> <== NOT EXECUTED
20430ec: c0 27 20 4c clr [ %i4 + 0x4c ] <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
20430f0: 10 bf ff d5 b 2043044 <rtems_rfs_group_open+0x68> <== NOT EXECUTED
20430f4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
02042b10 <rtems_rfs_group_usage>:
int
rtems_rfs_group_usage (rtems_rfs_file_system* fs,
size_t* blocks,
size_t* inodes)
{
2042b10: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int g;
*blocks = 0;
2042b14: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
*inodes = 0;
2042b18: c0 26 80 00 clr [ %i2 ] <== NOT EXECUTED
for (g = 0; g < fs->group_count; g++)
2042b1c: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED
2042b20: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2042b24: 04 80 00 14 ble 2042b74 <rtems_rfs_group_usage+0x64> <== NOT EXECUTED
2042b28: 84 10 20 00 clr %g2 <== NOT EXECUTED
2042b2c: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
{
rtems_rfs_group* group = &fs->groups[g];
*blocks +=
2042b30: da 00 60 14 ld [ %g1 + 0x14 ], %o5 <== NOT EXECUTED
2042b34: c6 00 60 18 ld [ %g1 + 0x18 ], %g3 <== NOT EXECUTED
2042b38: c8 06 40 00 ld [ %i1 ], %g4 <== NOT EXECUTED
2042b3c: 86 23 40 03 sub %o5, %g3, %g3 <== NOT EXECUTED
2042b40: 86 01 00 03 add %g4, %g3, %g3 <== NOT EXECUTED
2042b44: c6 26 40 00 st %g3, [ %i1 ] <== NOT EXECUTED
rtems_rfs_bitmap_map_size(&group->block_bitmap) -
rtems_rfs_bitmap_map_free (&group->block_bitmap);
*inodes +=
2042b48: da 00 60 38 ld [ %g1 + 0x38 ], %o5 <== NOT EXECUTED
2042b4c: c6 00 60 3c ld [ %g1 + 0x3c ], %g3 <== NOT EXECUTED
2042b50: c8 06 80 00 ld [ %i2 ], %g4 <== NOT EXECUTED
2042b54: 86 23 40 03 sub %o5, %g3, %g3 <== NOT EXECUTED
2042b58: 86 01 00 03 add %g4, %g3, %g3 <== NOT EXECUTED
2042b5c: c6 26 80 00 st %g3, [ %i2 ] <== NOT EXECUTED
int g;
*blocks = 0;
*inodes = 0;
for (g = 0; g < fs->group_count; g++)
2042b60: c6 06 20 20 ld [ %i0 + 0x20 ], %g3 <== NOT EXECUTED
2042b64: 84 00 a0 01 inc %g2 <== NOT EXECUTED
2042b68: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
2042b6c: 14 bf ff f1 bg 2042b30 <rtems_rfs_group_usage+0x20> <== NOT EXECUTED
2042b70: 82 00 60 50 add %g1, 0x50, %g1 <== NOT EXECUTED
*inodes +=
rtems_rfs_bitmap_map_size (&group->inode_bitmap) -
rtems_rfs_bitmap_map_free (&group->inode_bitmap);
}
if (*blocks > rtems_rfs_fs_blocks (fs))
2042b74: c4 06 20 04 ld [ %i0 + 4 ], %g2 <== NOT EXECUTED
2042b78: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
2042b7c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2042b80: 38 80 00 02 bgu,a 2042b88 <rtems_rfs_group_usage+0x78> <== NOT EXECUTED
2042b84: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
2042b88: c2 26 40 00 st %g1, [ %i1 ] <== NOT EXECUTED
*blocks = rtems_rfs_fs_blocks (fs);
if (*inodes > rtems_rfs_fs_inodes (fs))
2042b8c: c4 06 20 10 ld [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
2042b90: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
2042b94: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2042b98: 38 80 00 02 bgu,a 2042ba0 <rtems_rfs_group_usage+0x90> <== NOT EXECUTED
2042b9c: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
2042ba0: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
*inodes = rtems_rfs_fs_inodes (fs);
return 0;
}
2042ba4: 81 c7 e0 08 ret <== NOT EXECUTED
2042ba8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0204361c <rtems_rfs_inode_alloc>:
int
rtems_rfs_inode_alloc (rtems_rfs_file_system* fs,
rtems_rfs_bitmap_bit goal,
rtems_rfs_ino* ino)
{
204361c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_bitmap_bit bit;
int rc;
rc = rtems_rfs_group_bitmap_alloc (fs, goal, true, &bit);
2043620: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2043624: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2043628: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
204362c: 7f ff fd d4 call 2042d7c <rtems_rfs_group_bitmap_alloc> <== NOT EXECUTED
2043630: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
*ino = bit;
2043634: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2043638: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
return rc;
}
204363c: 81 c7 e0 08 ret <== NOT EXECUTED
2043640: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0204340c <rtems_rfs_inode_close>:
}
int
rtems_rfs_inode_close (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
204340c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CLOSE))
printf ("rtems-rfs: inode-close: ino: %" PRIu32 "\n", handle->ino);
rc = rtems_rfs_inode_unload (fs, handle, true);
2043410: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2043414: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2043418: 7f ff ff d0 call 2043358 <rtems_rfs_inode_unload> <== NOT EXECUTED
204341c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if ((rc == 0) && (handle->loads > 0))
2043420: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2043424: 32 80 00 07 bne,a 2043440 <rtems_rfs_inode_close+0x34> <== NOT EXECUTED
2043428: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
204342c: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
2043430: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043434: 34 80 00 02 bg,a 204343c <rtems_rfs_inode_close+0x30> <== NOT EXECUTED
2043438: 90 10 20 05 mov 5, %o0 <== NOT EXECUTED
printf ("rtems-rfs: inode-close: bad loads number: %d\n",
handle->loads);
rc = EIO;
}
handle->ino = 0;
204343c: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
return rc;
}
2043440: 81 c7 e0 08 ret <== NOT EXECUTED
2043444: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02043644 <rtems_rfs_inode_create>:
uint16_t mode,
uint16_t links,
uid_t uid,
gid_t gid,
rtems_rfs_ino* ino)
{
2043644: 9d e3 bf 50 save %sp, -176, %sp <== NOT EXECUTED
}
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & RTEMS_RFS_S_IFMT)
2043648: 23 00 00 3c sethi %hi(0xf000), %l1 <== NOT EXECUTED
204364c: b9 2f 20 10 sll %i4, 0x10, %i4 <== NOT EXECUTED
2043650: 03 00 00 18 sethi %hi(0x6000), %g1 <== NOT EXECUTED
2043654: b9 37 20 10 srl %i4, 0x10, %i4 <== NOT EXECUTED
uint16_t mode,
uint16_t links,
uid_t uid,
gid_t gid,
rtems_rfs_ino* ino)
{
2043658: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
}
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & RTEMS_RFS_S_IFMT)
204365c: a2 0f 00 11 and %i4, %l1, %l1 <== NOT EXECUTED
uint16_t mode,
uint16_t links,
uid_t uid,
gid_t gid,
rtems_rfs_ino* ino)
{
2043660: ea 07 a0 5c ld [ %fp + 0x5c ], %l5 <== NOT EXECUTED
}
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & RTEMS_RFS_S_IFMT)
2043664: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
uint16_t mode,
uint16_t links,
uid_t uid,
gid_t gid,
rtems_rfs_ino* ino)
{
2043668: e8 07 a0 60 ld [ %fp + 0x60 ], %l4 <== NOT EXECUTED
}
/*
* The file type is field within the mode. Check we have a sane mode set.
*/
switch (mode & RTEMS_RFS_S_IFMT)
204366c: 02 80 00 14 be 20436bc <rtems_rfs_inode_create+0x78> <== NOT EXECUTED
2043670: e4 07 a0 64 ld [ %fp + 0x64 ], %l2 <== NOT EXECUTED
2043674: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2043678: 04 80 00 0b ble 20436a4 <rtems_rfs_inode_create+0x60> <== NOT EXECUTED
204367c: 03 00 00 08 sethi %hi(0x2000), %g1 <== NOT EXECUTED
2043680: 03 00 00 20 sethi %hi(0x8000), %g1 <== NOT EXECUTED
2043684: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2043688: 02 80 00 0d be 20436bc <rtems_rfs_inode_create+0x78> <== NOT EXECUTED
204368c: 03 00 00 28 sethi %hi(0xa000), %g1 <== NOT EXECUTED
2043690: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2043694: 02 80 00 0b be 20436c0 <rtems_rfs_inode_create+0x7c> <== NOT EXECUTED
2043698: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204369c: 81 c7 e0 08 ret <== NOT EXECUTED
20436a0: 91 e8 20 16 restore %g0, 0x16, %o0 <== NOT EXECUTED
20436a4: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
20436a8: 02 80 00 05 be 20436bc <rtems_rfs_inode_create+0x78> <== NOT EXECUTED
20436ac: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
20436b0: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
20436b4: 12 bf ff fa bne 204369c <rtems_rfs_inode_create+0x58> <== NOT EXECUTED
20436b8: 01 00 00 00 nop <== NOT EXECUTED
break;
default:
return EINVAL;
}
rc = rtems_rfs_inode_alloc (fs, parent, ino);
20436bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20436c0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20436c4: 7f ff ff d6 call 204361c <rtems_rfs_inode_alloc> <== NOT EXECUTED
20436c8: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if (rc > 0)
20436cc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20436d0: 24 80 00 04 ble,a 20436e0 <rtems_rfs_inode_create+0x9c> <== NOT EXECUTED
20436d4: d2 04 80 00 ld [ %l2 ], %o1 <== NOT EXECUTED
rtems_rfs_inode_free (fs, *ino);
return rc;
}
return 0;
}
20436d8: 81 c7 e0 08 ret <== NOT EXECUTED
20436dc: 81 e8 00 00 restore <== NOT EXECUTED
rc = rtems_rfs_inode_alloc (fs, parent, ino);
if (rc > 0)
return rc;
rc = rtems_rfs_inode_open (fs, *ino, &inode, true);
20436e0: a6 07 bf b0 add %fp, -80, %l3 <== NOT EXECUTED
20436e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20436e8: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
20436ec: 7f ff ff 72 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20436f0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
20436f4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20436f8: 04 80 00 07 ble 2043714 <rtems_rfs_inode_create+0xd0> <== NOT EXECUTED
20436fc: 93 2f 60 10 sll %i5, 0x10, %o1 <== NOT EXECUTED
{
rtems_rfs_inode_free (fs, *ino);
2043700: d2 04 80 00 ld [ %l2 ], %o1 <== NOT EXECUTED
2043704: 7f ff ff 99 call 2043568 <rtems_rfs_inode_free> <== NOT EXECUTED
2043708: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
204370c: 81 c7 e0 08 ret <== NOT EXECUTED
2043710: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_initialise (&inode, links, mode, uid, gid);
2043714: 97 2d 60 10 sll %l5, 0x10, %o3 <== NOT EXECUTED
2043718: 99 2d 20 10 sll %l4, 0x10, %o4 <== NOT EXECUTED
204371c: 93 32 60 10 srl %o1, 0x10, %o1 <== NOT EXECUTED
2043720: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2043724: 97 32 e0 10 srl %o3, 0x10, %o3 <== NOT EXECUTED
2043728: 99 33 20 10 srl %o4, 0x10, %o4 <== NOT EXECUTED
204372c: 7f ff fe b5 call 2043200 <rtems_rfs_inode_initialise> <== NOT EXECUTED
2043730: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (rc > 0)
2043734: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043738: 14 80 00 16 bg 2043790 <rtems_rfs_inode_create+0x14c> <== NOT EXECUTED
204373c: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
/*
* Only handle the specifics of a directory. Let caller handle the others.
*
* The inode delete will free the inode.
*/
if (RTEMS_RFS_S_ISDIR (mode))
2043740: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2043744: 22 80 00 36 be,a 204381c <rtems_rfs_inode_create+0x1d8> <== NOT EXECUTED
2043748: d8 04 80 00 ld [ %l2 ], %o4 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
return rc;
}
}
rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);
204374c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2043750: b8 07 bf d8 add %fp, -40, %i4 <== NOT EXECUTED
2043754: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043758: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
204375c: 7f ff ff 56 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043760: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2043764: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043768: 24 80 00 12 ble,a 20437b0 <rtems_rfs_inode_create+0x16c> <== NOT EXECUTED
204376c: d8 04 80 00 ld [ %l2 ], %o4 <== NOT EXECUTED
rtems_rfs_inode_get_links (&parent_inode) + 1);
rc = rtems_rfs_inode_close (fs, &parent_inode);
if (rc > 0)
{
rtems_rfs_inode_delete (fs, &inode);
2043770: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043774: 7f ff ff 83 call 2043580 <rtems_rfs_inode_delete> <== NOT EXECUTED
2043778: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
204377c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043780: 7f ff ff 23 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043784: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
return rc;
2043788: 81 c7 e0 08 ret <== NOT EXECUTED
204378c: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_initialise (&inode, links, mode, uid, gid);
if (rc > 0)
{
rtems_rfs_inode_close (fs, &inode);
2043790: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043794: 7f ff ff 1e call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043798: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_free (fs, *ino);
204379c: d2 04 80 00 ld [ %l2 ], %o1 <== NOT EXECUTED
20437a0: 7f ff ff 72 call 2043568 <rtems_rfs_inode_free> <== NOT EXECUTED
20437a4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
20437a8: 81 c7 e0 08 ret <== NOT EXECUTED
20437ac: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_inode_delete (fs, &inode);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_dir_add_entry (fs, &parent_inode, name, length, *ino);
20437b0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
20437b4: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
20437b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20437bc: 7f ff f2 74 call 204018c <rtems_rfs_dir_add_entry> <== NOT EXECUTED
20437c0: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
if (rc > 0)
20437c4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20437c8: 14 80 00 23 bg 2043854 <rtems_rfs_inode_create+0x210> <== NOT EXECUTED
20437cc: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
/*
* If the node is a directory update the parent link count as the
* new directory has the '..' link that points to the parent.
*/
if (RTEMS_RFS_S_ISDIR (mode))
20437d0: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
20437d4: 02 80 00 33 be 20438a0 <rtems_rfs_inode_create+0x25c> <== NOT EXECUTED
20437d8: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
rtems_rfs_inode_set_links (&parent_inode,
rtems_rfs_inode_get_links (&parent_inode) + 1);
rc = rtems_rfs_inode_close (fs, &parent_inode);
20437dc: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
20437e0: 7f ff ff 0b call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20437e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
20437e8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20437ec: 14 bf ff e2 bg 2043774 <rtems_rfs_inode_create+0x130> <== NOT EXECUTED
20437f0: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
rtems_rfs_inode_delete (fs, &inode);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_inode_close (fs, &inode);
20437f4: 7f ff ff 06 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20437f8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
20437fc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043800: 04 80 00 3e ble 20438f8 <rtems_rfs_inode_create+0x2b4> <== NOT EXECUTED
2043804: 01 00 00 00 nop <== NOT EXECUTED
{
rtems_rfs_inode_free (fs, *ino);
2043808: d2 04 80 00 ld [ %l2 ], %o1 <== NOT EXECUTED
204380c: 7f ff ff 57 call 2043568 <rtems_rfs_inode_free> <== NOT EXECUTED
2043810: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rc;
}
return 0;
}
2043814: 81 c7 e0 08 ret <== NOT EXECUTED
2043818: 81 e8 00 00 restore <== NOT EXECUTED
*
* The inode delete will free the inode.
*/
if (RTEMS_RFS_S_ISDIR (mode))
{
rc = rtems_rfs_dir_add_entry (fs, &inode, ".", 1, *ino);
204381c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043820: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043824: 15 00 81 bb sethi %hi(0x206ec00), %o2 <== NOT EXECUTED
2043828: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
204382c: 7f ff f2 58 call 204018c <rtems_rfs_dir_add_entry> <== NOT EXECUTED
2043830: 94 12 a1 00 or %o2, 0x100, %o2 <== NOT EXECUTED
if (rc == 0)
2043834: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043838: 02 80 00 12 be 2043880 <rtems_rfs_inode_create+0x23c> <== NOT EXECUTED
204383c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_dir_add_entry (fs, &inode, "..", 2, parent);
if (rc > 0)
2043840: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
2043844: 24 bf ff c3 ble,a 2043750 <rtems_rfs_inode_create+0x10c> <== NOT EXECUTED
2043848: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
rtems_rfs_inode_get_links (&parent_inode) + 1);
rc = rtems_rfs_inode_close (fs, &parent_inode);
if (rc > 0)
{
rtems_rfs_inode_delete (fs, &inode);
204384c: 10 bf ff ca b 2043774 <rtems_rfs_inode_create+0x130> <== NOT EXECUTED
2043850: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
}
rc = rtems_rfs_dir_add_entry (fs, &parent_inode, name, length, *ino);
if (rc > 0)
{
rtems_rfs_inode_delete (fs, &inode);
2043854: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043858: 7f ff ff 4a call 2043580 <rtems_rfs_inode_delete> <== NOT EXECUTED
204385c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
2043860: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043864: 7f ff fe ea call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043868: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &parent_inode);
204386c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043870: 7f ff fe e7 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043874: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
return rc;
2043878: 81 c7 e0 08 ret <== NOT EXECUTED
204387c: 81 e8 00 00 restore <== NOT EXECUTED
*/
if (RTEMS_RFS_S_ISDIR (mode))
{
rc = rtems_rfs_dir_add_entry (fs, &inode, ".", 1, *ino);
if (rc == 0)
rc = rtems_rfs_dir_add_entry (fs, &inode, "..", 2, parent);
2043880: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043884: 15 00 81 bb sethi %hi(0x206ec00), %o2 <== NOT EXECUTED
2043888: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
204388c: 94 12 a1 08 or %o2, 0x108, %o2 <== NOT EXECUTED
2043890: 7f ff f2 3f call 204018c <rtems_rfs_dir_add_entry> <== NOT EXECUTED
2043894: 98 10 00 19 mov %i1, %o4 <== NOT EXECUTED
2043898: 10 bf ff ea b 2043840 <rtems_rfs_inode_create+0x1fc> <== NOT EXECUTED
204389c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
20438a0: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
20438a4: c8 08 40 00 ldub [ %g1 ], %g4 <== NOT EXECUTED
20438a8: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
20438ac: 88 11 00 02 or %g4, %g2, %g4 <== NOT EXECUTED
if (links == 0xffff)
20438b0: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
20438b4: 87 29 20 10 sll %g4, 0x10, %g3 <== NOT EXECUTED
20438b8: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
20438bc: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
20438c0: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
20438c4: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
20438c8: 02 80 00 06 be 20438e0 <rtems_rfs_inode_create+0x29c> <== NOT EXECUTED
20438cc: 86 10 20 00 clr %g3 <== NOT EXECUTED
20438d0: 86 01 20 01 add %g4, 1, %g3 <== NOT EXECUTED
20438d4: 84 10 00 03 mov %g3, %g2 <== NOT EXECUTED
20438d8: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
20438dc: 87 30 e0 18 srl %g3, 0x18, %g3 <== NOT EXECUTED
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
20438e0: c6 28 40 00 stb %g3, [ %g1 ] <== NOT EXECUTED
20438e4: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
20438e8: c4 28 60 01 stb %g2, [ %g1 + 1 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20438ec: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20438f0: 10 bf ff bb b 20437dc <rtems_rfs_inode_create+0x198> <== NOT EXECUTED
20438f4: c2 2f bf e8 stb %g1, [ %fp + -24 ] <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_inode_close (fs, &inode);
if (rc > 0)
20438f8: 81 c7 e0 08 ret <== NOT EXECUTED
20438fc: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02043580 <rtems_rfs_inode_delete>:
}
int
rtems_rfs_inode_delete (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
2043580: 9d e3 bf 50 save %sp, -176, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_DELETE))
printf("rtems-rfs: inode-delete: ino:%" PRIu32 " loaded:%s\n",
rtems_rfs_inode_ino (handle),
rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");
if (rtems_rfs_inode_is_loaded (handle))
2043584: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
}
int
rtems_rfs_inode_delete (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
2043588: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_DELETE))
printf("rtems-rfs: inode-delete: ino:%" PRIu32 " loaded:%s\n",
rtems_rfs_inode_ino (handle),
rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");
if (rtems_rfs_inode_is_loaded (handle))
204358c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043590: 02 80 00 08 be 20435b0 <rtems_rfs_inode_delete+0x30> <== NOT EXECUTED
2043594: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_rfs_block_map map;
/*
* Free the ino number.
*/
rc = rtems_rfs_inode_free (fs, handle->ino);
2043598: d2 06 60 08 ld [ %i1 + 8 ], %o1 <== NOT EXECUTED
204359c: 7f ff ff f3 call 2043568 <rtems_rfs_inode_free> <== NOT EXECUTED
20435a0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
20435a4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20435a8: 04 80 00 04 ble 20435b8 <rtems_rfs_inode_delete+0x38> <== NOT EXECUTED
20435ac: a2 07 bf b0 add %fp, -80, %l1 <== NOT EXECUTED
handle->loads = 0;
handle->node = NULL;
}
}
return rc;
}
20435b0: 81 c7 e0 08 ret <== NOT EXECUTED
20435b4: 81 e8 00 00 restore <== NOT EXECUTED
return rc;
/*
* Free the blocks the inode may have attached.
*/
rc = rtems_rfs_block_map_open (fs, handle, &map);
20435b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20435bc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20435c0: 7f ff ef b9 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
20435c4: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc == 0)
20435c8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20435cc: 12 bf ff f9 bne 20435b0 <rtems_rfs_inode_delete+0x30> <== NOT EXECUTED
20435d0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
{
int rrc;
rrc = rtems_rfs_block_map_free_all (fs, &map);
20435d4: 7f ff ee 09 call 203edf8 <rtems_rfs_block_map_free_all> <== NOT EXECUTED
20435d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_block_map_close (fs, &map);
20435dc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20435e0: 7f ff ef 40 call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
20435e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
rrc = rc;
memset (handle->node, 0xff, RTEMS_RFS_INODE_SIZE);
20435e8: d0 06 60 0c ld [ %i1 + 0xc ], %o0 <== NOT EXECUTED
20435ec: 94 10 20 38 mov 0x38, %o2 <== NOT EXECUTED
20435f0: 40 00 29 83 call 204dbfc <memset> <== NOT EXECUTED
20435f4: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20435f8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
/*
* Do the release here to avoid the ctime field being set on a
* close. Also if there loads is greater then one then other loads
* active. Forcing the loads count to 0.
*/
rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);
20435fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rrc = rtems_rfs_block_map_free_all (fs, &map);
rc = rtems_rfs_block_map_close (fs, &map);
if (rc > 0)
rrc = rc;
memset (handle->node, 0xff, RTEMS_RFS_INODE_SIZE);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043600: c2 2e 60 10 stb %g1, [ %i1 + 0x10 ] <== NOT EXECUTED
/*
* Do the release here to avoid the ctime field being set on a
* close. Also if there loads is greater then one then other loads
* active. Forcing the loads count to 0.
*/
rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);
2043604: 7f ff f0 7d call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2043608: 92 06 60 10 add %i1, 0x10, %o1 <== NOT EXECUTED
handle->loads = 0;
handle->node = NULL;
204360c: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
* Do the release here to avoid the ctime field being set on a
* close. Also if there loads is greater then one then other loads
* active. Forcing the loads count to 0.
*/
rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);
handle->loads = 0;
2043610: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
handle->node = NULL;
}
}
return rc;
}
2043614: 81 c7 e0 08 ret <== NOT EXECUTED
2043618: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02043568 <rtems_rfs_inode_free>:
}
int
rtems_rfs_inode_free (rtems_rfs_file_system* fs,
rtems_rfs_ino ino)
{
2043568: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
rtems_rfs_bitmap_bit bit;
bit = ino;
return rtems_rfs_group_bitmap_free (fs, true, bit);
204356c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2043570: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2043574: 7f ff fd ce call 2042cac <rtems_rfs_group_bitmap_free> <== NOT EXECUTED
2043578: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020430f8 <rtems_rfs_inode_get_size>:
}
rtems_rfs_pos
rtems_rfs_inode_get_size (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
20430f8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
20430fc: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
rtems_rfs_block_size size;
size.count = rtems_rfs_inode_get_block_count (handle);
size.offset = rtems_rfs_inode_get_block_offset (handle);
return rtems_rfs_block_get_size (fs, &size);
2043100: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_pos
rtems_rfs_inode_get_size (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
rtems_rfs_block_size size;
size.count = rtems_rfs_inode_get_block_count (handle);
2043104: d8 08 60 0c ldub [ %g1 + 0xc ], %o4 <== NOT EXECUTED
2043108: 84 00 60 0c add %g1, 0xc, %g2 <== NOT EXECUTED
204310c: da 08 a0 03 ldub [ %g2 + 3 ], %o5 <== NOT EXECUTED
2043110: c6 08 a0 02 ldub [ %g2 + 2 ], %g3 <== NOT EXECUTED
2043114: c8 08 a0 01 ldub [ %g2 + 1 ], %g4 <== NOT EXECUTED
2043118: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
204311c: 85 2b 20 18 sll %o4, 0x18, %g2 <== NOT EXECUTED
2043120: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
2043124: 84 13 40 02 or %o5, %g2, %g2 <== NOT EXECUTED
2043128: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
204312c: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
2043130: c4 27 bf f8 st %g2, [ %fp + -8 ] <== NOT EXECUTED
size.offset = rtems_rfs_inode_get_block_offset (handle);
2043134: c4 08 60 0b ldub [ %g1 + 0xb ], %g2 <== NOT EXECUTED
2043138: c2 08 60 0a ldub [ %g1 + 0xa ], %g1 <== NOT EXECUTED
return rtems_rfs_block_get_size (fs, &size);
204313c: 92 07 bf f8 add %fp, -8, %o1 <== NOT EXECUTED
rtems_rfs_inode_get_size (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
rtems_rfs_block_size size;
size.count = rtems_rfs_inode_get_block_count (handle);
size.offset = rtems_rfs_inode_get_block_offset (handle);
2043140: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2043144: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
return rtems_rfs_block_get_size (fs, &size);
2043148: 7f ff ed 70 call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
204314c: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
}
2043150: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
2043154: 81 c7 e0 08 ret <== NOT EXECUTED
2043158: 93 e8 00 09 restore %g0, %o1, %o1 <== NOT EXECUTED
02043200 <rtems_rfs_inode_initialise>:
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
2043200: c4 02 20 0c ld [ %o0 + 0xc ], %g2 <== NOT EXECUTED
2043204: 87 32 60 08 srl %o1, 8, %g3 <== NOT EXECUTED
2043208: c6 28 80 00 stb %g3, [ %g2 ] <== NOT EXECUTED
204320c: c4 02 20 0c ld [ %o0 + 0xc ], %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_uid_gid (rtems_rfs_inode_handle* handle,
uint16_t uid, uint16_t gid)
{
rtems_rfs_write_u32 (&handle->node->owner, (((uint32_t) gid) << 16) | uid);
2043210: 99 2b 20 10 sll %o4, 0x10, %o4 <== NOT EXECUTED
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
2043214: d2 28 a0 01 stb %o1, [ %g2 + 1 ] <== NOT EXECUTED
* @prarm flags The flags.
*/
static inline void
rtems_rfs_inode_set_flags (rtems_rfs_inode_handle* handle, uint16_t flags)
{
rtems_rfs_write_u16 (&handle->node->flags, flags);
2043218: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
* @prarm mode The mode.
*/
static inline void
rtems_rfs_inode_set_mode (rtems_rfs_inode_handle* handle, uint16_t mode)
{
rtems_rfs_write_u16 (&handle->node->mode, mode);
204321c: 85 32 a0 08 srl %o2, 8, %g2 <== NOT EXECUTED
* @prarm flags The flags.
*/
static inline void
rtems_rfs_inode_set_flags (rtems_rfs_inode_handle* handle, uint16_t flags)
{
rtems_rfs_write_u16 (&handle->node->flags, flags);
2043220: c0 28 e0 08 clrb [ %g3 + 8 ] <== NOT EXECUTED
2043224: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
rtems_rfs_inode_initialise (rtems_rfs_inode_handle* handle,
uint16_t links,
uint16_t mode,
uid_t uid,
gid_t gid)
{
2043228: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
204322c: c0 28 e0 09 clrb [ %g3 + 9 ] <== NOT EXECUTED
* @prarm mode The mode.
*/
static inline void
rtems_rfs_inode_set_mode (rtems_rfs_inode_handle* handle, uint16_t mode)
{
rtems_rfs_write_u16 (&handle->node->mode, mode);
2043230: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
2043234: c4 28 e0 02 stb %g2, [ %g3 + 2 ] <== NOT EXECUTED
2043238: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_uid_gid (rtems_rfs_inode_handle* handle,
uint16_t uid, uint16_t gid)
{
rtems_rfs_write_u32 (&handle->node->owner, (((uint32_t) gid) << 16) | uid);
204323c: 85 2a e0 10 sll %o3, 0x10, %g2 <== NOT EXECUTED
* @prarm mode The mode.
*/
static inline void
rtems_rfs_inode_set_mode (rtems_rfs_inode_handle* handle, uint16_t mode)
{
rtems_rfs_write_u16 (&handle->node->mode, mode);
2043240: d4 28 e0 03 stb %o2, [ %g3 + 3 ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_uid_gid (rtems_rfs_inode_handle* handle,
uint16_t uid, uint16_t gid)
{
rtems_rfs_write_u32 (&handle->node->owner, (((uint32_t) gid) << 16) | uid);
2043244: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
2043248: 85 30 a0 10 srl %g2, 0x10, %g2 <== NOT EXECUTED
204324c: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
2043250: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
2043254: c8 28 e0 04 stb %g4, [ %g3 + 4 ] <== NOT EXECUTED
2043258: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
204325c: 89 30 a0 10 srl %g2, 0x10, %g4 <== NOT EXECUTED
2043260: c8 28 e0 05 stb %g4, [ %g3 + 5 ] <== NOT EXECUTED
2043264: c6 02 20 0c ld [ %o0 + 0xc ], %g3 <== NOT EXECUTED
2043268: 85 30 a0 08 srl %g2, 8, %g2 <== NOT EXECUTED
204326c: c4 28 e0 06 stb %g2, [ %g3 + 6 ] <== NOT EXECUTED
2043270: c4 02 20 0c ld [ %o0 + 0xc ], %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_count (rtems_rfs_inode_handle* handle, uint32_t block_count)
{
rtems_rfs_write_u32 (&handle->node->block_count, block_count);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043274: 86 10 20 00 clr %g3 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_uid_gid (rtems_rfs_inode_handle* handle,
uint16_t uid, uint16_t gid)
{
rtems_rfs_write_u32 (&handle->node->owner, (((uint32_t) gid) << 16) | uid);
2043278: d6 28 a0 07 stb %o3, [ %g2 + 7 ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
204327c: c4 02 20 0c ld [ %o0 + 0xc ], %g2 <== NOT EXECUTED
2043280: c0 28 a0 0a clrb [ %g2 + 0xa ] <== NOT EXECUTED
2043284: c8 02 20 0c ld [ %o0 + 0xc ], %g4 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block (rtems_rfs_inode_handle* handle, int block, uint32_t bno)
{
rtems_rfs_write_u32 (&handle->node->data.blocks[block], bno);
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043288: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
204328c: c0 29 20 0b clrb [ %g4 + 0xb ] <== NOT EXECUTED
* @param block_count The block count.
*/
static inline void
rtems_rfs_inode_set_block_count (rtems_rfs_inode_handle* handle, uint32_t block_count)
{
rtems_rfs_write_u32 (&handle->node->block_count, block_count);
2043290: c8 02 20 0c ld [ %o0 + 0xc ], %g4 <== NOT EXECUTED
2043294: c0 29 20 0c clrb [ %g4 + 0xc ] <== NOT EXECUTED
2043298: c8 02 20 0c ld [ %o0 + 0xc ], %g4 <== NOT EXECUTED
204329c: c0 29 20 0d clrb [ %g4 + 0xd ] <== NOT EXECUTED
20432a0: c8 02 20 0c ld [ %o0 + 0xc ], %g4 <== NOT EXECUTED
20432a4: c0 29 20 0e clrb [ %g4 + 0xe ] <== NOT EXECUTED
20432a8: c8 02 20 0c ld [ %o0 + 0xc ], %g4 <== NOT EXECUTED
20432ac: c0 29 20 0f clrb [ %g4 + 0xf ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20432b0: 88 10 20 01 mov 1, %g4 <== NOT EXECUTED
20432b4: c8 2a 20 10 stb %g4, [ %o0 + 0x10 ] <== NOT EXECUTED
* @param bno The block number.
*/
static inline void
rtems_rfs_inode_set_block (rtems_rfs_inode_handle* handle, int block, uint32_t bno)
{
rtems_rfs_write_u32 (&handle->node->data.blocks[block], bno);
20432b8: c8 00 60 0c ld [ %g1 + 0xc ], %g4 <== NOT EXECUTED
20432bc: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20432c0: c0 29 20 1c clrb [ %g4 + 0x1c ] <== NOT EXECUTED
20432c4: c8 00 60 0c ld [ %g1 + 0xc ], %g4 <== NOT EXECUTED
20432c8: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20432cc: c0 29 20 1d clrb [ %g4 + 0x1d ] <== NOT EXECUTED
20432d0: c8 00 60 0c ld [ %g1 + 0xc ], %g4 <== NOT EXECUTED
20432d4: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20432d8: c0 29 20 1e clrb [ %g4 + 0x1e ] <== NOT EXECUTED
20432dc: c8 00 60 0c ld [ %g1 + 0xc ], %g4 <== NOT EXECUTED
20432e0: 88 01 00 03 add %g4, %g3, %g4 <== NOT EXECUTED
20432e4: c0 29 20 1f clrb [ %g4 + 0x1f ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20432e8: 86 00 e0 04 add %g3, 4, %g3 <== NOT EXECUTED
rtems_rfs_inode_set_flags (handle, 0);
rtems_rfs_inode_set_mode (handle, mode);
rtems_rfs_inode_set_uid_gid (handle, uid, gid);
rtems_rfs_inode_set_block_offset (handle, 0);
rtems_rfs_inode_set_block_count (handle, 0);
for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)
20432ec: 80 a0 e0 14 cmp %g3, 0x14 <== NOT EXECUTED
20432f0: 12 bf ff f2 bne 20432b8 <rtems_rfs_inode_initialise+0xb8> <== NOT EXECUTED
20432f4: c4 28 60 10 stb %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
* @param block_count The last map block number.
*/
static inline void
rtems_rfs_inode_set_last_map_block (rtems_rfs_inode_handle* handle, uint32_t last_map_block)
{
rtems_rfs_write_u32 (&handle->node->last_map_block, last_map_block);
20432f8: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
rtems_rfs_inode_set_block (handle, b, 0);
rtems_rfs_inode_set_last_map_block (handle, 0);
rtems_rfs_inode_set_last_data_block (handle, 0);
return rtems_rfs_inode_time_stamp_now (handle, true, true);
20432fc: 90 10 00 01 mov %g1, %o0 <== NOT EXECUTED
2043300: c0 28 e0 30 clrb [ %g3 + 0x30 ] <== NOT EXECUTED
2043304: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043308: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
204330c: c0 28 e0 31 clrb [ %g3 + 0x31 ] <== NOT EXECUTED
2043310: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043314: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2043318: c0 28 e0 32 clrb [ %g3 + 0x32 ] <== NOT EXECUTED
204331c: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043320: c0 28 e0 33 clrb [ %g3 + 0x33 ] <== NOT EXECUTED
* @param block_count The last data block number.
*/
static inline void
rtems_rfs_inode_set_last_data_block (rtems_rfs_inode_handle* handle, uint32_t last_data_block)
{
rtems_rfs_write_u32 (&handle->node->last_data_block, last_data_block);
2043324: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043328: c0 28 e0 34 clrb [ %g3 + 0x34 ] <== NOT EXECUTED
204332c: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043330: c0 28 e0 35 clrb [ %g3 + 0x35 ] <== NOT EXECUTED
2043334: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043338: c0 28 e0 36 clrb [ %g3 + 0x36 ] <== NOT EXECUTED
204333c: c6 00 60 0c ld [ %g1 + 0xc ], %g3 <== NOT EXECUTED
2043340: c0 28 e0 37 clrb [ %g3 + 0x37 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043344: c4 28 60 10 stb %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2043348: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
204334c: 7f ff ff 84 call 204315c <rtems_rfs_inode_time_stamp_now> <== NOT EXECUTED
2043350: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02043448 <rtems_rfs_inode_load>:
int
rtems_rfs_inode_load (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle)
{
2043448: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
/*
* An inode does not move so once loaded no need to do again.
*/
if (!rtems_rfs_inode_is_loaded (handle))
204344c: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
2043450: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043454: 22 80 00 08 be,a 2043474 <rtems_rfs_inode_load+0x2c> <== NOT EXECUTED
2043458: d4 06 60 1c ld [ %i1 + 0x1c ], %o2 <== NOT EXECUTED
handle->node = rtems_rfs_buffer_data (&handle->buffer);
handle->node += handle->offset;
}
handle->loads++;
204345c: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
2043460: b0 10 20 00 clr %i0 <== NOT EXECUTED
2043464: 82 00 60 01 inc %g1 <== NOT EXECUTED
2043468: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
return 0;
}
204346c: 81 c7 e0 08 ret <== NOT EXECUTED
2043470: 81 e8 00 00 restore <== NOT EXECUTED
if (!rtems_rfs_inode_is_loaded (handle))
{
int rc;
rc = rtems_rfs_buffer_handle_request (fs,&handle->buffer,
2043474: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2043478: 92 06 60 10 add %i1, 0x10, %o1 <== NOT EXECUTED
204347c: 7f ff f1 28 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2043480: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
handle->block, true);
if (rc > 0)
2043484: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043488: 14 bf ff f9 bg 204346c <rtems_rfs_inode_load+0x24> <== NOT EXECUTED
204348c: 01 00 00 00 nop <== NOT EXECUTED
return rc;
handle->node = rtems_rfs_buffer_data (&handle->buffer);
2043490: c4 06 60 18 ld [ %i1 + 0x18 ], %g2 <== NOT EXECUTED
handle->node += handle->offset;
2043494: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs,&handle->buffer,
handle->block, true);
if (rc > 0)
return rc;
handle->node = rtems_rfs_buffer_data (&handle->buffer);
2043498: c4 00 a0 24 ld [ %g2 + 0x24 ], %g2 <== NOT EXECUTED
handle->node += handle->offset;
204349c: 87 28 60 06 sll %g1, 6, %g3 <== NOT EXECUTED
20434a0: 83 28 60 03 sll %g1, 3, %g1 <== NOT EXECUTED
20434a4: 82 20 c0 01 sub %g3, %g1, %g1 <== NOT EXECUTED
20434a8: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
20434ac: 10 bf ff ec b 204345c <rtems_rfs_inode_load+0x14> <== NOT EXECUTED
20434b0: c2 26 60 0c st %g1, [ %i1 + 0xc ] <== NOT EXECUTED
020434b4 <rtems_rfs_inode_open>:
int
rtems_rfs_inode_open (rtems_rfs_file_system* fs,
rtems_rfs_ino ino,
rtems_rfs_inode_handle* handle,
bool load)
{
20434b4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_OPEN))
printf ("rtems-rfs: inode-open: ino: %" PRIu32 "\n", ino);
if (ino == RTEMS_RFS_EMPTY_INO)
20434b8: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
20434bc: 02 80 00 28 be 204355c <rtems_rfs_inode_open+0xa8> <== NOT EXECUTED
20434c0: a2 06 7f ff add %i1, -1, %l1 <== NOT EXECUTED
return EINVAL;
if ((ino - RTEMS_RFS_ROOT_INO) > rtems_rfs_fs_inodes (fs))
20434c4: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
20434c8: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
20434cc: 38 80 00 25 bgu,a 2043560 <rtems_rfs_inode_open+0xac> <== NOT EXECUTED
20434d0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
return EINVAL;
handle->ino = ino;
handle->node = NULL;
handle->loads = 0;
20434d4: c0 26 a0 24 clr [ %i2 + 0x24 ] <== NOT EXECUTED
gino = ino - RTEMS_RFS_ROOT_INO;
group = gino / fs->group_inodes;
20434d8: e6 06 20 28 ld [ %i0 + 0x28 ], %l3 <== NOT EXECUTED
return EINVAL;
if ((ino - RTEMS_RFS_ROOT_INO) > rtems_rfs_fs_inodes (fs))
return EINVAL;
handle->ino = ino;
20434dc: f2 26 a0 08 st %i1, [ %i2 + 8 ] <== NOT EXECUTED
handle->node = NULL;
handle->loads = 0;
gino = ino - RTEMS_RFS_ROOT_INO;
group = gino / fs->group_inodes;
gino = gino % fs->group_inodes;
20434e0: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
if ((ino - RTEMS_RFS_ROOT_INO) > rtems_rfs_fs_inodes (fs))
return EINVAL;
handle->ino = ino;
handle->node = NULL;
20434e4: c0 26 a0 0c clr [ %i2 + 0xc ] <== NOT EXECUTED
handle->loads = 0;
gino = ino - RTEMS_RFS_ROOT_INO;
group = gino / fs->group_inodes;
gino = gino % fs->group_inodes;
20434e8: 40 00 7d d3 call 2062c34 <.urem> <== NOT EXECUTED
20434ec: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
20434f0: e4 06 20 2c ld [ %i0 + 0x2c ], %l2 <== NOT EXECUTED
handle->node = NULL;
handle->loads = 0;
gino = ino - RTEMS_RFS_ROOT_INO;
group = gino / fs->group_inodes;
gino = gino % fs->group_inodes;
20434f4: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
handle->offset = gino % fs->inodes_per_block;
20434f8: 40 00 7d cf call 2062c34 <.urem> <== NOT EXECUTED
20434fc: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
handle->block = rtems_rfs_group_block (&fs->groups[group], index);
2043500: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
gino = ino - RTEMS_RFS_ROOT_INO;
group = gino / fs->group_inodes;
gino = gino % fs->group_inodes;
index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
handle->offset = gino % fs->inodes_per_block;
2043504: d0 26 a0 20 st %o0, [ %i2 + 0x20 ] <== NOT EXECUTED
handle->block = rtems_rfs_group_block (&fs->groups[group], index);
2043508: 40 00 7d 1f call 2062984 <.udiv> <== NOT EXECUTED
204350c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2043510: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 <== NOT EXECUTED
2043514: 85 2a 20 06 sll %o0, 6, %g2 <== NOT EXECUTED
2043518: 91 2a 20 04 sll %o0, 4, %o0 <== NOT EXECUTED
204351c: 90 02 00 02 add %o0, %g2, %o0 <== NOT EXECUTED
2043520: e0 00 40 08 ld [ %g1 + %o0 ], %l0 <== NOT EXECUTED
2043524: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043528: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
204352c: 40 00 7d 16 call 2062984 <.udiv> <== NOT EXECUTED
2043530: a0 04 20 02 add %l0, 2, %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2043534: c0 2e a0 10 clrb [ %i2 + 0x10 ] <== NOT EXECUTED
2043538: 90 04 00 08 add %l0, %o0, %o0 <== NOT EXECUTED
handle->bnum = 0;
204353c: c0 26 a0 14 clr [ %i2 + 0x14 ] <== NOT EXECUTED
2043540: d0 26 a0 1c st %o0, [ %i2 + 0x1c ] <== NOT EXECUTED
handle->buffer = NULL;
2043544: c0 26 a0 18 clr [ %i2 + 0x18 ] <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_open (fs, &handle->buffer);
if ((rc == 0) && load)
2043548: 80 8e e0 ff btst 0xff, %i3 <== NOT EXECUTED
204354c: 02 80 00 05 be 2043560 <rtems_rfs_inode_open+0xac> <== NOT EXECUTED
2043550: 82 10 20 00 clr %g1 <== NOT EXECUTED
rc = rtems_rfs_inode_load (fs, handle);
2043554: 7f ff ff bd call 2043448 <rtems_rfs_inode_load> <== NOT EXECUTED
2043558: 93 e8 00 1a restore %g0, %i2, %o1 <== NOT EXECUTED
204355c: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
return rc;
}
2043560: 81 c7 e0 08 ret <== NOT EXECUTED
2043564: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
02041c64 <rtems_rfs_inode_overhead>:
/**
* Return the inode overhead given a number of inodes.
*/
static int
rtems_rfs_inode_overhead (rtems_rfs_file_system* fs)
{
2041c64: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int blocks;
int bits_per_block;
blocks = rtems_rfs_rup_quotient(fs->group_inodes * RTEMS_RFS_INODE_SIZE,
2041c68: c2 06 20 28 ld [ %i0 + 0x28 ], %g1 <== NOT EXECUTED
rtems_rfs_fs_block_size (fs));
2041c6c: e0 06 20 08 ld [ %i0 + 8 ], %l0 <== NOT EXECUTED
static int
rtems_rfs_inode_overhead (rtems_rfs_file_system* fs)
{
int blocks;
int bits_per_block;
blocks = rtems_rfs_rup_quotient(fs->group_inodes * RTEMS_RFS_INODE_SIZE,
2041c70: 91 28 60 06 sll %g1, 6, %o0 <== NOT EXECUTED
2041c74: 83 28 60 03 sll %g1, 3, %g1 <== NOT EXECUTED
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
if (dividend == 0)
2041c78: 82 a2 00 01 subcc %o0, %g1, %g1 <== NOT EXECUTED
2041c7c: 02 80 00 0b be 2041ca8 <rtems_rfs_inode_overhead+0x44> <== NOT EXECUTED
2041c80: 90 10 27 d0 mov 0x7d0, %o0 <== NOT EXECUTED
2041c84: 90 00 7f ff add %g1, -1, %o0 <== NOT EXECUTED
2041c88: 40 00 83 3f call 2062984 <.udiv> <== NOT EXECUTED
2041c8c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2041c90: 90 02 20 02 add %o0, 2, %o0 <== NOT EXECUTED
2041c94: 83 2a 20 02 sll %o0, 2, %g1 <== NOT EXECUTED
2041c98: 85 2a 20 07 sll %o0, 7, %g2 <== NOT EXECUTED
2041c9c: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
2041ca0: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
2041ca4: 91 2a 20 03 sll %o0, 3, %o0 <== NOT EXECUTED
rtems_rfs_fs_block_size (fs));
bits_per_block = rtems_rfs_bits_per_block (fs);
/*
* There could be more bits than blocks, eg 512K disk with 512 blocks.
*/
if (bits_per_block > (rtems_rfs_fs_blocks (fs) - RTEMS_RFS_SUPERBLOCK_SIZE))
2041ca8: d2 06 20 04 ld [ %i0 + 4 ], %o1 <== NOT EXECUTED
* Return the number of bits that fit in the block size.
*/
static int
rtems_rfs_bits_per_block (rtems_rfs_file_system* fs)
{
return rtems_rfs_bitmap_numof_bits (rtems_rfs_fs_block_size (fs));
2041cac: a1 2c 20 03 sll %l0, 3, %l0 <== NOT EXECUTED
rtems_rfs_fs_block_size (fs));
bits_per_block = rtems_rfs_bits_per_block (fs);
/*
* There could be more bits than blocks, eg 512K disk with 512 blocks.
*/
if (bits_per_block > (rtems_rfs_fs_blocks (fs) - RTEMS_RFS_SUPERBLOCK_SIZE))
2041cb0: 92 02 7f ff add %o1, -1, %o1 <== NOT EXECUTED
2041cb4: 80 a2 40 10 cmp %o1, %l0 <== NOT EXECUTED
2041cb8: 3a 80 00 02 bcc,a 2041cc0 <rtems_rfs_inode_overhead+0x5c><== NOT EXECUTED
2041cbc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
bits_per_block = rtems_rfs_fs_blocks (fs) - RTEMS_RFS_SUPERBLOCK_SIZE;
2041cc0: 40 00 83 33 call 206298c <.div> <== NOT EXECUTED
2041cc4: 01 00 00 00 nop <== NOT EXECUTED
return ((blocks + 1) * 100 * 10) / bits_per_block;
}
2041cc8: 81 c7 e0 08 ret <== NOT EXECUTED
2041ccc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
0204315c <rtems_rfs_inode_time_stamp_now>:
int
rtems_rfs_inode_time_stamp_now (rtems_rfs_inode_handle* handle,
bool atime,
bool mtime)
{
204315c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
time_t now;
if (!rtems_rfs_inode_is_loaded (handle))
2043160: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
int
rtems_rfs_inode_time_stamp_now (rtems_rfs_inode_handle* handle,
bool atime,
bool mtime)
{
2043164: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
time_t now;
if (!rtems_rfs_inode_is_loaded (handle))
2043168: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
204316c: 02 80 00 23 be 20431f8 <rtems_rfs_inode_time_stamp_now+0x9c><== NOT EXECUTED
2043170: b0 10 20 06 mov 6, %i0 <== NOT EXECUTED
return ENXIO;
now = time (NULL);
2043174: 40 00 4d 79 call 2056758 <time> <== NOT EXECUTED
2043178: 90 10 20 00 clr %o0 <== NOT EXECUTED
if (atime)
204317c: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
2043180: 02 80 00 0f be 20431bc <rtems_rfs_inode_time_stamp_now+0x60><== NOT EXECUTED
2043184: 80 8e a0 ff btst 0xff, %i2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_atime (rtems_rfs_inode_handle* handle,
rtems_rfs_time atime)
{
rtems_rfs_write_u32 (&handle->node->atime, atime);
2043188: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
204318c: 85 32 20 18 srl %o0, 0x18, %g2 <== NOT EXECUTED
2043190: c4 28 60 10 stb %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2043194: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
2043198: 85 32 20 10 srl %o0, 0x10, %g2 <== NOT EXECUTED
204319c: c4 28 60 11 stb %g2, [ %g1 + 0x11 ] <== NOT EXECUTED
20431a0: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431a4: 85 32 20 08 srl %o0, 8, %g2 <== NOT EXECUTED
20431a8: c4 28 60 12 stb %g2, [ %g1 + 0x12 ] <== NOT EXECUTED
20431ac: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431b0: d0 28 60 13 stb %o0, [ %g1 + 0x13 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20431b4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20431b8: c2 2c 20 10 stb %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
rtems_rfs_inode_set_atime (handle, now);
if (mtime)
20431bc: 02 80 00 0f be 20431f8 <rtems_rfs_inode_time_stamp_now+0x9c><== NOT EXECUTED
20431c0: b0 10 20 00 clr %i0 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_mtime (rtems_rfs_inode_handle* handle,
rtems_rfs_time mtime)
{
rtems_rfs_write_u32 (&handle->node->mtime, mtime);
20431c4: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431c8: 85 32 20 18 srl %o0, 0x18, %g2 <== NOT EXECUTED
20431cc: c4 28 60 14 stb %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
20431d0: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431d4: 85 32 20 10 srl %o0, 0x10, %g2 <== NOT EXECUTED
20431d8: c4 28 60 15 stb %g2, [ %g1 + 0x15 ] <== NOT EXECUTED
20431dc: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431e0: 85 32 20 08 srl %o0, 8, %g2 <== NOT EXECUTED
20431e4: c4 28 60 16 stb %g2, [ %g1 + 0x16 ] <== NOT EXECUTED
20431e8: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
20431ec: d0 28 60 17 stb %o0, [ %g1 + 0x17 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20431f0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20431f4: c2 2c 20 10 stb %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
rtems_rfs_inode_set_mtime (handle, now);
return 0;
}
20431f8: 81 c7 e0 08 ret <== NOT EXECUTED
20431fc: 81 e8 00 00 restore <== NOT EXECUTED
02043358 <rtems_rfs_inode_unload>:
int
rtems_rfs_inode_unload (rtems_rfs_file_system* fs,
rtems_rfs_inode_handle* handle,
bool update_ctime)
{
2043358: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_UNLOAD))
printf ("rtems-rfs: inode-unload: ino=%" PRIu32 " loads=%i loaded=%s\n",
handle->ino, handle->loads,
rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");
if (rtems_rfs_inode_is_loaded (handle))
204335c: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
2043360: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043364: 02 80 00 17 be 20433c0 <rtems_rfs_inode_unload+0x68> <== NOT EXECUTED
2043368: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{
if (handle->loads == 0)
204336c: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 <== NOT EXECUTED
2043370: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043374: 02 80 00 14 be 20433c4 <rtems_rfs_inode_unload+0x6c> <== NOT EXECUTED
2043378: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
return EIO;
handle->loads--;
204337c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (handle->loads == 0)
2043380: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043384: 12 80 00 0f bne 20433c0 <rtems_rfs_inode_unload+0x68> <== NOT EXECUTED
2043388: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
{
/*
* If the buffer is dirty it will be release. Also set the ctime.
*/
if (rtems_rfs_buffer_dirty (&handle->buffer) && update_ctime)
204338c: c2 0e 60 10 ldub [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
2043390: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2043394: 02 80 00 06 be 20433ac <rtems_rfs_inode_unload+0x54> <== NOT EXECUTED
2043398: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204339c: 80 8e a0 ff btst 0xff, %i2 <== NOT EXECUTED
20433a0: 12 80 00 0b bne 20433cc <rtems_rfs_inode_unload+0x74> <== NOT EXECUTED
20433a4: 01 00 00 00 nop <== NOT EXECUTED
rtems_rfs_inode_set_ctime (handle, time (NULL));
rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);
20433a8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20433ac: 7f ff f1 13 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
20433b0: 92 06 60 10 add %i1, 0x10, %o1 <== NOT EXECUTED
handle->node = NULL;
20433b4: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
/*
* If the buffer is dirty it will be release. Also set the ctime.
*/
if (rtems_rfs_buffer_dirty (&handle->buffer) && update_ctime)
rtems_rfs_inode_set_ctime (handle, time (NULL));
rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);
20433b8: 81 c7 e0 08 ret <== NOT EXECUTED
20433bc: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
handle->node = NULL;
20433c0: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
}
return rc;
}
20433c4: 81 c7 e0 08 ret <== NOT EXECUTED
20433c8: 81 e8 00 00 restore <== NOT EXECUTED
{
/*
* If the buffer is dirty it will be release. Also set the ctime.
*/
if (rtems_rfs_buffer_dirty (&handle->buffer) && update_ctime)
rtems_rfs_inode_set_ctime (handle, time (NULL));
20433cc: 40 00 4c e3 call 2056758 <time> <== NOT EXECUTED
20433d0: 90 10 20 00 clr %o0 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_ctime (rtems_rfs_inode_handle* handle,
rtems_rfs_time ctime)
{
rtems_rfs_write_u32 (&handle->node->ctime, ctime);
20433d4: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
20433d8: 85 32 20 18 srl %o0, 0x18, %g2 <== NOT EXECUTED
20433dc: c4 28 60 18 stb %g2, [ %g1 + 0x18 ] <== NOT EXECUTED
20433e0: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
20433e4: 85 32 20 10 srl %o0, 0x10, %g2 <== NOT EXECUTED
20433e8: c4 28 60 19 stb %g2, [ %g1 + 0x19 ] <== NOT EXECUTED
20433ec: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
20433f0: 85 32 20 08 srl %o0, 8, %g2 <== NOT EXECUTED
20433f4: c4 28 60 1a stb %g2, [ %g1 + 0x1a ] <== NOT EXECUTED
20433f8: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
20433fc: d0 28 60 1b stb %o0, [ %g1 + 0x1b ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043400: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2043404: 10 bf ff e9 b 20433a8 <rtems_rfs_inode_unload+0x50> <== NOT EXECUTED
2043408: c2 2e 60 10 stb %g1, [ %i1 + 0x10 ] <== NOT EXECUTED
02043edc <rtems_rfs_link>:
const char* name,
int length,
rtems_rfs_ino parent,
rtems_rfs_ino target,
bool link_dir)
{
2043edc: 9d e3 bf 50 save %sp, -176, %sp <== NOT EXECUTED
for (c = 0; c < length; c++)
printf ("%c", name[c]);
printf ("(%" PRIu32 ")\n", target);
}
rc = rtems_rfs_inode_open (fs, target, &target_inode, true);
2043ee0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2043ee4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
const char* name,
int length,
rtems_rfs_ino parent,
rtems_rfs_ino target,
bool link_dir)
{
2043ee8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
for (c = 0; c < length; c++)
printf ("%c", name[c]);
printf ("(%" PRIu32 ")\n", target);
}
rc = rtems_rfs_inode_open (fs, target, &target_inode, true);
2043eec: a2 07 bf b0 add %fp, -80, %l1 <== NOT EXECUTED
2043ef0: 92 10 00 1c mov %i4, %o1 <== NOT EXECUTED
2043ef4: 7f ff fd 70 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043ef8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc)
2043efc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043f00: 12 80 00 41 bne 2044004 <rtems_rfs_link+0x128> <== NOT EXECUTED
2043f04: 80 8f 60 ff btst 0xff, %i5 <== NOT EXECUTED
/*
* If the target inode is a directory and we cannot link directories
* return a not supported error code.
*/
if (!link_dir && S_ISDIR (rtems_rfs_inode_get_mode (&target_inode)))
2043f08: 12 80 00 0a bne 2043f30 <rtems_rfs_link+0x54> <== NOT EXECUTED
2043f0c: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
2043f10: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
2043f14: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2043f18: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2043f1c: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
2043f20: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
2043f24: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2043f28: 02 80 00 45 be 204403c <rtems_rfs_link+0x160> <== NOT EXECUTED
2043f2c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &target_inode);
return ENOTSUP;
}
rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);
2043f30: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2043f34: a4 07 bf d8 add %fp, -40, %l2 <== NOT EXECUTED
2043f38: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043f3c: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2043f40: 7f ff fd 5d call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043f44: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
2043f48: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043f4c: 12 80 00 2b bne 2043ff8 <rtems_rfs_link+0x11c> <== NOT EXECUTED
2043f50: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
rc = rtems_rfs_dir_add_entry (fs, &parent_inode, name, length, target);
2043f54: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
2043f58: 98 10 00 1c mov %i4, %o4 <== NOT EXECUTED
2043f5c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043f60: 7f ff f0 8b call 204018c <rtems_rfs_dir_add_entry> <== NOT EXECUTED
2043f64: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
if (rc > 0)
2043f68: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043f6c: 14 80 00 2c bg 204401c <rtems_rfs_link+0x140> <== NOT EXECUTED
2043f70: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2043f74: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
2043f78: c8 08 40 00 ldub [ %g1 ], %g4 <== NOT EXECUTED
2043f7c: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
2043f80: 88 11 00 02 or %g4, %g2, %g4 <== NOT EXECUTED
if (links == 0xffff)
2043f84: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED
2043f88: 87 29 20 10 sll %g4, 0x10, %g3 <== NOT EXECUTED
2043f8c: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
2043f90: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
2043f94: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
2043f98: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
2043f9c: 02 80 00 06 be 2043fb4 <rtems_rfs_link+0xd8> <== NOT EXECUTED
2043fa0: 86 10 20 00 clr %g3 <== NOT EXECUTED
2043fa4: 88 01 20 01 inc %g4 <== NOT EXECUTED
2043fa8: 84 10 00 04 mov %g4, %g2 <== NOT EXECUTED
2043fac: 89 29 20 10 sll %g4, 0x10, %g4 <== NOT EXECUTED
2043fb0: 87 31 20 18 srl %g4, 0x18, %g3 <== NOT EXECUTED
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
2043fb4: c6 28 40 00 stb %g3, [ %g1 ] <== NOT EXECUTED
2043fb8: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
}
links = rtems_rfs_inode_get_links (&target_inode) + 1;
rtems_rfs_inode_set_links (&target_inode, links);
rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);
2043fbc: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2043fc0: c4 28 60 01 stb %g2, [ %g1 + 1 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043fc4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2043fc8: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2043fcc: c2 2f bf c0 stb %g1, [ %fp + -64 ] <== NOT EXECUTED
2043fd0: 7f ff fc 63 call 204315c <rtems_rfs_inode_time_stamp_now> <== NOT EXECUTED
2043fd4: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
if (rc > 0)
2043fd8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043fdc: 14 80 00 11 bg 2044020 <rtems_rfs_link+0x144> <== NOT EXECUTED
2043fe0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &parent_inode);
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
rc = rtems_rfs_inode_close (fs, &parent_inode);
2043fe4: 7f ff fd 0a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043fe8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2043fec: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043ff0: 04 80 00 07 ble 204400c <rtems_rfs_link+0x130> <== NOT EXECUTED
2043ff4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &target_inode);
2043ff8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043ffc: 7f ff fd 04 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044000: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2044004: 81 c7 e0 08 ret <== NOT EXECUTED
2044008: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_close (fs, &target_inode);
204400c: 7f ff fd 00 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044010: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
2044014: 81 c7 e0 08 ret <== NOT EXECUTED
2044018: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_rfs_inode_set_links (&target_inode, links);
rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);
if (rc > 0)
{
rtems_rfs_inode_close (fs, &parent_inode);
204401c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044020: 7f ff fc fb call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044024: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &target_inode);
2044028: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204402c: 7f ff fc f8 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044030: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2044034: 81 c7 e0 08 ret <== NOT EXECUTED
2044038: 81 e8 00 00 restore <== NOT EXECUTED
* If the target inode is a directory and we cannot link directories
* return a not supported error code.
*/
if (!link_dir && S_ISDIR (rtems_rfs_inode_get_mode (&target_inode)))
{
rtems_rfs_inode_close (fs, &target_inode);
204403c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2044040: 7f ff fc f3 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044044: b0 10 20 86 mov 0x86, %i0 <== NOT EXECUTED
return ENOTSUP;
2044048: 81 c7 e0 08 ret <== NOT EXECUTED
204404c: 81 e8 00 00 restore <== NOT EXECUTED
02044070 <rtems_rfs_mutex_create>:
RTEMS_NO_INHERIT_PRIORITY | RTEMS_NO_PRIORITY_CEILING | RTEMS_LOCAL)
#endif
int
rtems_rfs_mutex_create (rtems_rfs_mutex* mutex)
{
2044070: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
#if __rtems__
rtems_status_code sc;
sc = rtems_semaphore_create (rtems_build_name ('R', 'F', 'S', 'm'),
2044074: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2044078: 98 10 00 18 mov %i0, %o4 <== NOT EXECUTED
204407c: 94 10 20 24 mov 0x24, %o2 <== NOT EXECUTED
2044080: 96 10 20 00 clr %o3 <== NOT EXECUTED
2044084: 11 14 91 94 sethi %hi(0x52465000), %o0 <== NOT EXECUTED
2044088: 7f ff 24 b2 call 200d350 <rtems_semaphore_create> <== NOT EXECUTED
204408c: 90 12 23 6d or %o0, 0x36d, %o0 ! 5246536d <RAM_END+0x5006536d><== NOT EXECUTED
1, RTEMS_RFS_MUTEX_ATTRIBS, 0,
mutex);
if (sc != RTEMS_SUCCESSFUL)
2044090: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2044094: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
rtems_status_text (sc));
return EIO;
}
#endif
return 0;
}
2044098: b0 0e 20 05 and %i0, 5, %i0 <== NOT EXECUTED
204409c: 81 c7 e0 08 ret <== NOT EXECUTED
20440a0: 81 e8 00 00 restore <== NOT EXECUTED
02044050 <rtems_rfs_mutex_destroy>:
return 0;
}
int
rtems_rfs_mutex_destroy (rtems_rfs_mutex* mutex)
{
2044050: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
#if __rtems__
rtems_status_code sc;
sc = rtems_semaphore_delete (*mutex);
2044054: 7f ff 25 33 call 200d520 <rtems_semaphore_delete> <== NOT EXECUTED
2044058: d0 06 00 00 ld [ %i0 ], %o0 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
204405c: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2044060: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
rtems_status_text (sc));
return EIO;
}
#endif
return 0;
}
2044064: b0 0e 20 05 and %i0, 5, %i0 <== NOT EXECUTED
2044068: 81 c7 e0 08 ret <== NOT EXECUTED
204406c: 81 e8 00 00 restore <== NOT EXECUTED
0203f628 <rtems_rfs_release_chain>:
static int
rtems_rfs_release_chain (rtems_chain_control* chain,
uint32_t* count,
bool modified)
{
203f628: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
203f62c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
203f630: a2 06 20 04 add %i0, 4, %l1 <== NOT EXECUTED
buffer = (rtems_rfs_buffer*) rtems_chain_get (chain);
(*count)--;
buffer->user = (void*) 0;
rc = rtems_rfs_buffer_io_release (buffer, modified);
203f634: b4 0e a0 ff and %i2, 0xff, %i2 <== NOT EXECUTED
203f638: b0 10 20 00 clr %i0 <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: release-chain: count=%" PRIu32 "\n", *count);
while (!rtems_chain_is_empty (chain))
203f63c: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
203f640: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
203f644: 02 80 00 14 be 203f694 <rtems_rfs_release_chain+0x6c> <== NOT EXECUTED
203f648: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(
rtems_chain_control *the_chain
)
{
return _Chain_Get( the_chain );
203f64c: 7f ff 3b 66 call 200e3e4 <_Chain_Get> <== NOT EXECUTED
203f650: 01 00 00 00 nop <== NOT EXECUTED
{
buffer = (rtems_rfs_buffer*) rtems_chain_get (chain);
(*count)--;
203f654: c2 06 40 00 ld [ %i1 ], %g1 <== NOT EXECUTED
buffer->user = (void*) 0;
203f658: c0 22 20 3c clr [ %o0 + 0x3c ] <== NOT EXECUTED
printf ("rtems-rfs: release-chain: count=%" PRIu32 "\n", *count);
while (!rtems_chain_is_empty (chain))
{
buffer = (rtems_rfs_buffer*) rtems_chain_get (chain);
(*count)--;
203f65c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
buffer->user = (void*) 0;
rc = rtems_rfs_buffer_io_release (buffer, modified);
203f660: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
203f664: 40 00 29 64 call 2049bf4 <rtems_rfs_buffer_bdbuf_release> <== NOT EXECUTED
203f668: c2 26 40 00 st %g1, [ %i1 ] <== NOT EXECUTED
if ((rc > 0) && (rrc == 0))
203f66c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
203f670: 04 bf ff f4 ble 203f640 <rtems_rfs_release_chain+0x18> <== NOT EXECUTED
203f674: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
203f678: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
203f67c: 12 bf ff f1 bne 203f640 <rtems_rfs_release_chain+0x18> <== NOT EXECUTED
203f680: 01 00 00 00 nop <== NOT EXECUTED
203f684: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))
printf ("rtems-rfs: release-chain: count=%" PRIu32 "\n", *count);
while (!rtems_chain_is_empty (chain))
203f688: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
203f68c: 12 bf ff f0 bne 203f64c <rtems_rfs_release_chain+0x24> <== NOT EXECUTED
203f690: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_io_release (buffer, modified);
if ((rc > 0) && (rrc == 0))
rrc = rc;
}
return rrc;
}
203f694: 81 c7 e0 08 ret <== NOT EXECUTED
203f698: 81 e8 00 00 restore <== NOT EXECUTED
020257a8 <rtems_rfs_rtems_chown>:
static int
rtems_rfs_rtems_chown (rtems_filesystem_location_info_t *pathloc,
uid_t owner,
gid_t group)
{
20257a8: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20257ac: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
20257b0: e4 06 00 00 ld [ %i0 ], %l2 <== NOT EXECUTED
static int
rtems_rfs_rtems_chown (rtems_filesystem_location_info_t *pathloc,
uid_t owner,
gid_t group)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20257b4: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20257b8: 92 10 20 00 clr %o1 <== NOT EXECUTED
20257bc: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
20257c0: 94 10 20 00 clr %o2 <== NOT EXECUTED
20257c4: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20257c8: 7f ff 9f 9c call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20257cc: a2 07 bf d8 add %fp, -40, %l1 <== NOT EXECUTED
printf ("rtems-rfs-rtems: chown: in: ino:%" PRId32 " uid:%d gid:%d\n",
ino, owner, group);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
20257d0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20257d4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20257d8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20257dc: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
20257e0: 40 00 77 35 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20257e4: a6 10 00 19 mov %i1, %l3 <== NOT EXECUTED
if (rc > 0)
20257e8: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20257ec: 04 80 00 0d ble 2025820 <rtems_rfs_rtems_chown+0x78> <== NOT EXECUTED
20257f0: 01 00 00 00 nop <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20257f4: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20257f8: 40 00 67 a9 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20257fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2025800: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2025804: 7f ff 9f d4 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025808: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("chown: opening inode", rc);
202580c: 40 00 93 1d call 204a480 <__errno> <== NOT EXECUTED
2025810: 01 00 00 00 nop <== NOT EXECUTED
2025814: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2025818: 81 c7 e0 08 ret <== NOT EXECUTED
202581c: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Verify I am the owner of the node or the super user.
*/
#if defined (RTEMS_POSIX_API)
uid = geteuid();
2025820: 40 00 1d 29 call 202ccc4 <geteuid> <== NOT EXECUTED
2025824: 01 00 00 00 nop <== NOT EXECUTED
* @return uint16_t The user id (uid).
*/
static inline uint16_t
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;
2025828: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
if ((uid != rtems_rfs_inode_get_uid (&inode)) && (uid != 0))
202582c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
2025830: 84 00 60 04 add %g1, 4, %g2 <== NOT EXECUTED
2025834: c6 08 a0 03 ldub [ %g2 + 3 ], %g3 <== NOT EXECUTED
2025838: c4 08 a0 02 ldub [ %g2 + 2 ], %g2 <== NOT EXECUTED
202583c: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2025840: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
2025844: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2025848: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
202584c: 02 80 00 05 be 2025860 <rtems_rfs_rtems_chown+0xb8> <== NOT EXECUTED
2025850: 89 32 20 10 srl %o0, 0x10, %g4 <== NOT EXECUTED
2025854: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
2025858: 12 80 00 2a bne 2025900 <rtems_rfs_rtems_chown+0x158> <== NOT EXECUTED
202585c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_uid_gid (rtems_rfs_inode_handle* handle,
uint16_t uid, uint16_t gid)
{
rtems_rfs_write_u32 (&handle->node->owner, (((uint32_t) gid) << 16) | uid);
2025860: b5 2e a0 10 sll %i2, 0x10, %i2 <== NOT EXECUTED
2025864: b3 2e 60 10 sll %i1, 0x10, %i1 <== NOT EXECUTED
2025868: b3 36 60 10 srl %i1, 0x10, %i1 <== NOT EXECUTED
202586c: b4 16 80 19 or %i2, %i1, %i2 <== NOT EXECUTED
2025870: 85 36 a0 18 srl %i2, 0x18, %g2 <== NOT EXECUTED
2025874: c4 28 60 04 stb %g2, [ %g1 + 4 ] <== NOT EXECUTED
2025878: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
202587c: 85 36 a0 10 srl %i2, 0x10, %g2 <== NOT EXECUTED
2025880: c4 28 60 05 stb %g2, [ %g1 + 5 ] <== NOT EXECUTED
2025884: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2025888: b5 36 a0 08 srl %i2, 8, %i2 <== NOT EXECUTED
202588c: f4 28 60 06 stb %i2, [ %g1 + 6 ] <== NOT EXECUTED
2025890: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
}
#endif
rtems_rfs_inode_set_uid_gid (&inode, owner, group);
rc = rtems_rfs_inode_close (fs, &inode);
2025894: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025898: e6 28 60 07 stb %l3, [ %g1 + 7 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
202589c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20258a0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20258a4: 40 00 76 da call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20258a8: c2 2f bf e8 stb %g1, [ %fp + -24 ] <== NOT EXECUTED
if (rc)
20258ac: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20258b0: 22 80 00 0d be,a 20258e4 <rtems_rfs_rtems_chown+0x13c> <== NOT EXECUTED
20258b4: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20258b8: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20258bc: 40 00 67 78 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20258c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20258c4: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
20258c8: 7f ff 9f a3 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20258cc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("chown: closing inode", rc);
20258d0: 40 00 92 ec call 204a480 <__errno> <== NOT EXECUTED
20258d4: 01 00 00 00 nop <== NOT EXECUTED
20258d8: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20258dc: 81 c7 e0 08 ret <== NOT EXECUTED
20258e0: 81 e8 00 00 restore <== NOT EXECUTED
20258e4: 40 00 67 6e call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20258e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20258ec: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20258f0: 7f ff 9f 99 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20258f4: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
20258f8: 81 c7 e0 08 ret <== NOT EXECUTED
20258fc: 81 e8 00 00 restore <== NOT EXECUTED
#if defined (RTEMS_POSIX_API)
uid = geteuid();
if ((uid != rtems_rfs_inode_get_uid (&inode)) && (uid != 0))
{
rtems_rfs_inode_close (fs, &inode);
2025900: 40 00 76 c3 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025904: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2025908: 7f ff f9 b8 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
202590c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("chown: not able", EPERM);
2025910: 40 00 92 dc call 204a480 <__errno> <== NOT EXECUTED
2025914: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025918: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
202591c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2025920: 81 c7 e0 08 ret <== NOT EXECUTED
2025924: 81 e8 00 00 restore <== NOT EXECUTED
020441b4 <rtems_rfs_rtems_device_close>:
* @return int
*/
static int
rtems_rfs_rtems_device_close (rtems_libio_t* iop)
{
20441b4: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_libio_open_close_args_t args;
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
20441b8: d0 06 20 34 ld [ %i0 + 0x34 ], %o0 <== NOT EXECUTED
minor = (intptr_t) iop->data1;
20441bc: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 <== NOT EXECUTED
args.iop = iop;
20441c0: f0 27 bf f4 st %i0, [ %fp + -12 ] <== NOT EXECUTED
args.flags = 0;
20441c4: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
args.mode = 0;
20441c8: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
status = rtems_io_close (major, minor, (void *) &args);
20441cc: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED
20441d0: 40 00 0b d7 call 204712c <rtems_io_close> <== NOT EXECUTED
20441d4: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (status)
20441d8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20441dc: 12 80 00 04 bne 20441ec <rtems_rfs_rtems_device_close+0x38><== NOT EXECUTED
20441e0: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno (status);
return 0;
}
20441e4: 81 c7 e0 08 ret <== NOT EXECUTED
20441e8: 81 e8 00 00 restore <== NOT EXECUTED
args.flags = 0;
args.mode = 0;
status = rtems_io_close (major, minor, (void *) &args);
if (status)
return rtems_deviceio_errno (status);
20441ec: 40 00 02 ca call 2044d14 <rtems_deviceio_errno> <== NOT EXECUTED
20441f0: 01 00 00 00 nop <== NOT EXECUTED
return 0;
}
20441f4: 81 c7 e0 08 ret <== NOT EXECUTED
20441f8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020440b0 <rtems_rfs_rtems_device_ftruncate>:
static int
rtems_rfs_rtems_device_ftruncate (rtems_libio_t* iop, rtems_off64_t length)
{
return 0;
}
20440b0: 81 c3 e0 08 retl <== NOT EXECUTED
20440b4: 90 10 20 00 clr %o0 <== NOT EXECUTED
020440b8 <rtems_rfs_rtems_device_ioctl>:
static int
rtems_rfs_rtems_device_ioctl (rtems_libio_t* iop,
uint32_t command,
void* buffer)
{
20440b8: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
20440bc: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 <== NOT EXECUTED
rtems_libio_ioctl_args_t args;
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
20440c0: d0 06 20 34 ld [ %i0 + 0x34 ], %o0 <== NOT EXECUTED
minor = (intptr_t) iop->data1;
args.iop = iop;
args.command = command;
args.buffer = buffer;
20440c4: f4 27 bf f8 st %i2, [ %fp + -8 ] <== NOT EXECUTED
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
args.iop = iop;
args.command = command;
20440c8: f0 3f bf f0 std %i0, [ %fp + -16 ] <== NOT EXECUTED
args.buffer = buffer;
status = rtems_io_control (major, minor, (void *) &args);
20440cc: 40 00 0c 30 call 204718c <rtems_io_control> <== NOT EXECUTED
20440d0: 94 07 bf f0 add %fp, -16, %o2 <== NOT EXECUTED
if (status)
20440d4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20440d8: 12 80 00 05 bne 20440ec <rtems_rfs_rtems_device_ioctl+0x34><== NOT EXECUTED
20440dc: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno (status);
return args.ioctl_return;
20440e0: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
20440e4: 81 c7 e0 08 ret <== NOT EXECUTED
20440e8: 81 e8 00 00 restore <== NOT EXECUTED
args.command = command;
args.buffer = buffer;
status = rtems_io_control (major, minor, (void *) &args);
if (status)
return rtems_deviceio_errno (status);
20440ec: 40 00 03 0a call 2044d14 <rtems_deviceio_errno> <== NOT EXECUTED
20440f0: 01 00 00 00 nop <== NOT EXECUTED
20440f4: 81 c7 e0 08 ret <== NOT EXECUTED
20440f8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020440a4 <rtems_rfs_rtems_device_lseek>:
rtems_rfs_rtems_device_lseek (rtems_libio_t* iop,
rtems_off64_t offset,
int whence)
{
return offset;
}
20440a4: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED
20440a8: 81 c3 e0 08 retl <== NOT EXECUTED
20440ac: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED
020441fc <rtems_rfs_rtems_device_open>:
static int
rtems_rfs_rtems_device_open ( rtems_libio_t *iop,
const char *pathname,
uint32_t flag,
uint32_t mode)
{
20441fc: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
rtems_libio_open_close_args_t args;
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
2044200: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_iop_ino (iop);
2044204: e4 06 20 3c ld [ %i0 + 0x3c ], %l2 <== NOT EXECUTED
const char *pathname,
uint32_t flag,
uint32_t mode)
{
rtems_libio_open_close_args_t args;
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
2044208: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
204420c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044210: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2044214: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044218: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
204421c: 7f ff 25 07 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2044220: a2 07 bf cc add %fp, -52, %l1 <== NOT EXECUTED
rtems_status_code status;
int rc;
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2044224: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044228: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204422c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2044230: 7f ff fc a1 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2044234: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2044238: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
204423c: 04 80 00 0d ble 2044270 <rtems_rfs_rtems_device_open+0x74><== NOT EXECUTED
2044240: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044244: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044248: 7f ff ed 15 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
204424c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044250: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2044254: 7f ff 25 40 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044258: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("device_open: opening inode", rc);
204425c: 40 00 18 89 call 204a480 <__errno> <== NOT EXECUTED
2044260: 01 00 00 00 nop <== NOT EXECUTED
2044264: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2044268: 81 c7 e0 08 ret <== NOT EXECUTED
204426c: 81 e8 00 00 restore <== NOT EXECUTED
}
major = rtems_rfs_inode_get_block (&inode, 0);
minor = rtems_rfs_inode_get_block (&inode, 1);
rc = rtems_rfs_inode_close (fs, &inode);
2044270: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
* @return uint32_t The block number.
*/
static inline uint32_t
rtems_rfs_inode_get_block (rtems_rfs_inode_handle* handle, int block)
{
return rtems_rfs_read_u32 (&handle->node->data.blocks[block]);
2044274: ee 08 60 1c ldub [ %g1 + 0x1c ], %l7 <== NOT EXECUTED
2044278: 82 00 60 1c add %g1, 0x1c, %g1 <== NOT EXECUTED
204427c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044280: e4 08 60 07 ldub [ %g1 + 7 ], %l2 <== NOT EXECUTED
2044284: ec 08 60 01 ldub [ %g1 + 1 ], %l6 <== NOT EXECUTED
2044288: ea 08 60 02 ldub [ %g1 + 2 ], %l5 <== NOT EXECUTED
204428c: fa 08 60 03 ldub [ %g1 + 3 ], %i5 <== NOT EXECUTED
2044290: e8 08 60 04 ldub [ %g1 + 4 ], %l4 <== NOT EXECUTED
2044294: e6 08 60 05 ldub [ %g1 + 5 ], %l3 <== NOT EXECUTED
2044298: 7f ff fc 5d call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
204429c: e2 08 60 06 ldub [ %g1 + 6 ], %l1 <== NOT EXECUTED
if (rc > 0)
20442a0: b8 92 20 00 orcc %o0, 0, %i4 <== NOT EXECUTED
20442a4: 24 80 00 0d ble,a 20442d8 <rtems_rfs_rtems_device_open+0xdc><== NOT EXECUTED
20442a8: f8 04 20 7c ld [ %l0 + 0x7c ], %i4 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20442ac: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20442b0: 7f ff ec fb call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20442b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20442b8: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20442bc: 7f ff 25 26 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20442c0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("device_open: closing inode", rc);
20442c4: 40 00 18 6f call 204a480 <__errno> <== NOT EXECUTED
20442c8: 01 00 00 00 nop <== NOT EXECUTED
20442cc: f8 22 00 00 st %i4, [ %o0 ] <== NOT EXECUTED
20442d0: 81 c7 e0 08 ret <== NOT EXECUTED
20442d4: 81 e8 00 00 restore <== NOT EXECUTED
20442d8: 7f ff ec f1 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20442dc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20442e0: d0 07 00 00 ld [ %i4 ], %o0 <== NOT EXECUTED
20442e4: 7f ff 25 1c call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20442e8: ba 0f 60 ff and %i5, 0xff, %i5 <== NOT EXECUTED
iop->data0 = major;
iop->data1 = (void*)((intptr_t) minor);
args.iop = iop;
args.flags = iop->flags;
20442ec: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
args.mode = mode;
20442f0: f6 27 bf fc st %i3, [ %fp + -4 ] <== NOT EXECUTED
iop->data0 = major;
iop->data1 = (void*)((intptr_t) minor);
args.iop = iop;
args.flags = iop->flags;
20442f4: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
iop->data0 = major;
iop->data1 = (void*)((intptr_t) minor);
args.iop = iop;
20442f8: f0 27 bf f4 st %i0, [ %fp + -12 ] <== NOT EXECUTED
20442fc: af 2d e0 18 sll %l7, 0x18, %l7 <== NOT EXECUTED
2044300: ac 0d a0 ff and %l6, 0xff, %l6 <== NOT EXECUTED
2044304: ae 17 40 17 or %i5, %l7, %l7 <== NOT EXECUTED
2044308: aa 0d 60 ff and %l5, 0xff, %l5 <== NOT EXECUTED
204430c: ad 2d a0 10 sll %l6, 0x10, %l6 <== NOT EXECUTED
2044310: ab 2d 60 08 sll %l5, 8, %l5 <== NOT EXECUTED
2044314: ac 15 c0 16 or %l7, %l6, %l6 <== NOT EXECUTED
2044318: a9 2d 20 18 sll %l4, 0x18, %l4 <== NOT EXECUTED
204431c: aa 15 80 15 or %l6, %l5, %l5 <== NOT EXECUTED
2044320: a6 0c e0 ff and %l3, 0xff, %l3 <== NOT EXECUTED
return rtems_rfs_rtems_error ("device_open: closing inode", rc);
}
rtems_rfs_rtems_unlock (fs);
iop->data0 = major;
2044324: ea 26 20 34 st %l5, [ %i0 + 0x34 ] <== NOT EXECUTED
2044328: a4 0c a0 ff and %l2, 0xff, %l2 <== NOT EXECUTED
204432c: a7 2c e0 10 sll %l3, 0x10, %l3 <== NOT EXECUTED
2044330: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
2044334: a8 15 00 13 or %l4, %l3, %l4 <== NOT EXECUTED
2044338: a3 2c 60 08 sll %l1, 8, %l1 <== NOT EXECUTED
204433c: a4 15 00 12 or %l4, %l2, %l2 <== NOT EXECUTED
args.iop = iop;
args.flags = iop->flags;
args.mode = mode;
status = rtems_io_open (major, minor, (void *) &args);
2044340: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2044344: a2 14 80 11 or %l2, %l1, %l1 <== NOT EXECUTED
2044348: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
iop->data0 = major;
iop->data1 = (void*)((intptr_t) minor);
204434c: e2 26 20 38 st %l1, [ %i0 + 0x38 ] <== NOT EXECUTED
args.iop = iop;
args.flags = iop->flags;
args.mode = mode;
status = rtems_io_open (major, minor, (void *) &args);
2044350: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2044354: 40 00 0b a6 call 20471ec <rtems_io_open> <== NOT EXECUTED
2044358: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (status)
204435c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2044360: 12 80 00 04 bne 2044370 <rtems_rfs_rtems_device_open+0x174><== NOT EXECUTED
2044364: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno(status);
return 0;
}
2044368: 81 c7 e0 08 ret <== NOT EXECUTED
204436c: 81 e8 00 00 restore <== NOT EXECUTED
args.flags = iop->flags;
args.mode = mode;
status = rtems_io_open (major, minor, (void *) &args);
if (status)
return rtems_deviceio_errno(status);
2044370: 40 00 02 69 call 2044d14 <rtems_deviceio_errno> <== NOT EXECUTED
2044374: 01 00 00 00 nop <== NOT EXECUTED
return 0;
}
2044378: 81 c7 e0 08 ret <== NOT EXECUTED
204437c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02044158 <rtems_rfs_rtems_device_read>:
* @return ssize_t
*/
static ssize_t
rtems_rfs_rtems_device_read (rtems_libio_t* iop, void* buffer, size_t count)
{
2044158: 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;
204415c: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
rtems_libio_rw_args_t args;
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
2044160: d0 06 20 34 ld [ %i0 + 0x34 ], %o0 <== NOT EXECUTED
minor = (intptr_t) iop->data1;
args.iop = iop;
args.offset = iop->offset;
2044164: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
2044168: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 <== NOT EXECUTED
args.iop = iop;
args.offset = iop->offset;
args.buffer = buffer;
204416c: f2 27 bf f0 st %i1, [ %fp + -16 ] <== NOT EXECUTED
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
args.iop = iop;
args.offset = iop->offset;
2044170: c4 3f bf e8 std %g2, [ %fp + -24 ] <== NOT EXECUTED
args.buffer = buffer;
args.count = count;
2044174: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED
args.flags = iop->flags;
2044178: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
int minor;
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
args.iop = iop;
204417c: 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;
2044180: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
status = rtems_io_read (major, minor, (void *) &args);
2044184: 40 00 0c 32 call 204724c <rtems_io_read> <== NOT EXECUTED
2044188: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED
if (status)
204418c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2044190: 12 80 00 05 bne 20441a4 <rtems_rfs_rtems_device_read+0x4c><== NOT EXECUTED
2044194: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno (status);
return (ssize_t) args.bytes_moved;
2044198: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
204419c: 81 c7 e0 08 ret <== NOT EXECUTED
20441a0: 81 e8 00 00 restore <== NOT EXECUTED
args.flags = iop->flags;
args.bytes_moved = 0;
status = rtems_io_read (major, minor, (void *) &args);
if (status)
return rtems_deviceio_errno (status);
20441a4: 40 00 02 dc call 2044d14 <rtems_deviceio_errno> <== NOT EXECUTED
20441a8: 01 00 00 00 nop <== NOT EXECUTED
20441ac: 81 c7 e0 08 ret <== NOT EXECUTED
20441b0: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020440fc <rtems_rfs_rtems_device_write>:
static ssize_t
rtems_rfs_rtems_device_write (rtems_libio_t* iop,
const void* buffer,
size_t count)
{
20440fc: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
args.iop = iop;
args.offset = iop->offset;
args.buffer = (void *) buffer;
args.count = count;
args.flags = iop->flags;
2044100: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
rtems_libio_rw_args_t args;
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
2044104: d0 06 20 34 ld [ %i0 + 0x34 ], %o0 <== NOT EXECUTED
minor = (intptr_t) iop->data1;
args.iop = iop;
args.offset = iop->offset;
2044108: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
rtems_status_code status;
int major;
int minor;
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
204410c: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 <== NOT EXECUTED
args.iop = iop;
args.offset = iop->offset;
args.buffer = (void *) buffer;
2044110: f2 27 bf f0 st %i1, [ %fp + -16 ] <== NOT EXECUTED
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
args.iop = iop;
args.offset = iop->offset;
2044114: c4 3f bf e8 std %g2, [ %fp + -24 ] <== NOT EXECUTED
args.buffer = (void *) buffer;
args.count = count;
2044118: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED
args.flags = iop->flags;
204411c: c2 27 bf f8 st %g1, [ %fp + -8 ] <== NOT EXECUTED
int minor;
major = (int) iop->data0;
minor = (intptr_t) iop->data1;
args.iop = iop;
2044120: f0 27 bf e0 st %i0, [ %fp + -32 ] <== NOT EXECUTED
args.offset = iop->offset;
args.buffer = (void *) buffer;
args.count = count;
args.flags = iop->flags;
args.bytes_moved = 0;
2044124: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
status = rtems_io_write (major, minor, (void *) &args);
2044128: 40 00 0c 61 call 20472ac <rtems_io_write> <== NOT EXECUTED
204412c: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED
if (status)
2044130: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2044134: 12 80 00 05 bne 2044148 <rtems_rfs_rtems_device_write+0x4c><== NOT EXECUTED
2044138: 01 00 00 00 nop <== NOT EXECUTED
return rtems_deviceio_errno (status);
return (ssize_t) args.bytes_moved;
204413c: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
2044140: 81 c7 e0 08 ret <== NOT EXECUTED
2044144: 81 e8 00 00 restore <== NOT EXECUTED
args.flags = iop->flags;
args.bytes_moved = 0;
status = rtems_io_write (major, minor, (void *) &args);
if (status)
return rtems_deviceio_errno (status);
2044148: 40 00 02 f3 call 2044d14 <rtems_deviceio_errno> <== NOT EXECUTED
204414c: 01 00 00 00 nop <== NOT EXECUTED
2044150: 81 c7 e0 08 ret <== NOT EXECUTED
2044154: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
02044380 <rtems_rfs_rtems_dir_close>:
{
/*
* The RFS does not hold any resources. Nothing to do.
*/
return 0;
}
2044380: 81 c3 e0 08 retl <== NOT EXECUTED
2044384: 90 10 20 00 clr %o0 <== NOT EXECUTED
02044388 <rtems_rfs_rtems_dir_lseek>:
*/
static rtems_off64_t
rtems_rfs_rtems_dir_lseek (rtems_libio_t* iop,
rtems_off64_t offset,
int whence)
{
2044388: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
switch (whence)
204438c: 84 10 20 00 clr %g2 <== NOT EXECUTED
2044390: 80 a6 e0 01 cmp %i3, 1 <== NOT EXECUTED
2044394: 08 80 00 09 bleu 20443b8 <rtems_rfs_rtems_dir_lseek+0x30> <== NOT EXECUTED
2044398: 86 10 20 00 clr %g3 <== NOT EXECUTED
break;
case SEEK_END: /* Movement past the end of the directory via lseek */
/* is not a permitted operation */
default:
return rtems_rfs_rtems_error ("dir_lseek: bad whence", EINVAL);
204439c: 40 00 18 39 call 204a480 <__errno> <== NOT EXECUTED
20443a0: 01 00 00 00 nop <== NOT EXECUTED
20443a4: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
20443a8: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
20443ac: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20443b0: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
20443b4: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
break;
}
return 0;
}
20443b8: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
20443bc: 81 c7 e0 08 ret <== NOT EXECUTED
20443c0: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
020445c8 <rtems_rfs_rtems_dir_open>:
static int
rtems_rfs_rtems_dir_open (rtems_libio_t* iop,
const char* pathname,
uint32_t flag,
uint32_t mode)
{
20445c8: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
20445cc: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_iop_ino (iop);
20445d0: e4 06 20 3c ld [ %i0 + 0x3c ], %l2 <== NOT EXECUTED
rtems_rfs_rtems_dir_open (rtems_libio_t* iop,
const char* pathname,
uint32_t flag,
uint32_t mode)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
20445d4: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20445d8: 92 10 20 00 clr %o1 <== NOT EXECUTED
20445dc: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
20445e0: 94 10 20 00 clr %o2 <== NOT EXECUTED
20445e4: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20445e8: 7f ff 24 14 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20445ec: a2 07 bf d8 add %fp, -40, %l1 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
int rc;
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
20445f0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20445f4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20445f8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20445fc: 7f ff fb ae call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2044600: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
2044604: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2044608: 12 80 00 16 bne 2044660 <rtems_rfs_rtems_dir_open+0x98> <== NOT EXECUTED
204460c: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_open: opening inode", rc);
}
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
2044610: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
2044614: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2044618: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
204461c: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
2044620: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
2044624: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2044628: 12 80 00 19 bne 204468c <rtems_rfs_rtems_dir_open+0xc4> <== NOT EXECUTED
204462c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_open: not dir", ENOTDIR);
}
iop->offset = 0;
2044630: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
2044634: c0 26 20 14 clr [ %i0 + 0x14 ] <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
2044638: 7f ff fb 75 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
204463c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044640: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044644: 7f ff ec 16 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044648: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
204464c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2044650: 7f ff 24 41 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044654: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return 0;
}
2044658: 81 c7 e0 08 ret <== NOT EXECUTED
204465c: 81 e8 00 00 restore <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044660: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044664: 7f ff ec 0e call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044668: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204466c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2044670: 7f ff 24 39 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044674: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc)
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_open: opening inode", rc);
2044678: 40 00 17 82 call 204a480 <__errno> <== NOT EXECUTED
204467c: 01 00 00 00 nop <== NOT EXECUTED
2044680: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2044684: 81 c7 e0 08 ret <== NOT EXECUTED
2044688: 81 e8 00 00 restore <== NOT EXECUTED
}
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
{
rtems_rfs_inode_close (fs, &inode);
204468c: 7f ff fb 60 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044690: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044694: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044698: 7f ff ec 01 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
204469c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20446a0: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20446a4: 7f ff 24 2c call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20446a8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_open: not dir", ENOTDIR);
20446ac: 40 00 17 75 call 204a480 <__errno> <== NOT EXECUTED
20446b0: 01 00 00 00 nop <== NOT EXECUTED
20446b4: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> <== NOT EXECUTED
20446b8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20446bc: 81 c7 e0 08 ret <== NOT EXECUTED
20446c0: 81 e8 00 00 restore <== NOT EXECUTED
0204447c <rtems_rfs_rtems_dir_read>:
*/
static ssize_t
rtems_rfs_rtems_dir_read (rtems_libio_t* iop,
void* buffer,
size_t count)
{
204447c: 9d e3 bf 70 save %sp, -144, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
2044480: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_iop_ino (iop);
2044484: e6 06 20 3c ld [ %i0 + 0x3c ], %l3 <== NOT EXECUTED
static ssize_t
rtems_rfs_rtems_dir_read (rtems_libio_t* iop,
void* buffer,
size_t count)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
2044488: e2 00 60 34 ld [ %g1 + 0x34 ], %l1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
204448c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044490: c2 04 60 7c ld [ %l1 + 0x7c ], %g1 <== NOT EXECUTED
2044494: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044498: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
204449c: 7f ff 24 67 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20444a0: a4 07 bf d4 add %fp, -44, %l2 <== NOT EXECUTED
count = count / sizeof (struct dirent);
dirent = buffer;
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
20444a4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
20444a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20444ac: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
20444b0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
20444b4: 7f ff fc 00 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20444b8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (rc)
20444bc: a6 92 20 00 orcc %o0, 0, %l3 <== NOT EXECUTED
20444c0: 12 80 00 2a bne 2044568 <rtems_rfs_rtems_dir_read+0xec> <== NOT EXECUTED
20444c4: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
struct dirent* dirent;
ssize_t bytes_transferred;
int d;
int rc;
count = count / sizeof (struct dirent);
20444c8: 92 10 21 18 mov 0x118, %o1 <== NOT EXECUTED
20444cc: 40 00 79 2e call 2062984 <.udiv> <== NOT EXECUTED
20444d0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("dir_read: read inode", rc);
}
bytes_transferred = 0;
for (d = 0; d < count; d++, dirent++)
20444d4: a8 92 20 00 orcc %o0, 0, %l4 <== NOT EXECUTED
20444d8: 02 80 00 1b be 2044544 <rtems_rfs_rtems_dir_read+0xc8> <== NOT EXECUTED
20444dc: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc)
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_read: read inode", rc);
20444e0: d4 1c 20 10 ldd [ %l0 + 0x10 ], %o2 <== NOT EXECUTED
20444e4: a6 10 20 00 clr %l3 <== NOT EXECUTED
20444e8: b0 10 20 00 clr %i0 <== NOT EXECUTED
20444ec: 10 80 00 0d b 2044520 <rtems_rfs_rtems_dir_read+0xa4> <== NOT EXECUTED
20444f0: aa 07 bf fc add %fp, -4, %l5 <== NOT EXECUTED
if (rc == ENOENT)
{
rc = 0;
break;
}
if (rc > 0)
20444f4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20444f8: 14 80 00 27 bg 2044594 <rtems_rfs_rtems_dir_read+0x118> <== NOT EXECUTED
20444fc: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
{
bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
break;
}
iop->offset += size;
2044500: c4 1c 20 10 ldd [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
return rtems_rfs_rtems_error ("dir_read: read inode", rc);
}
bytes_transferred = 0;
for (d = 0; d < count; d++, dirent++)
2044504: a6 04 e0 01 inc %l3 <== NOT EXECUTED
if (rc > 0)
{
bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
break;
}
iop->offset += size;
2044508: 96 80 c0 0a addcc %g3, %o2, %o3 <== NOT EXECUTED
204450c: 94 40 a0 00 addx %g2, 0, %o2 <== NOT EXECUTED
2044510: d4 3c 20 10 std %o2, [ %l0 + 0x10 ] <== NOT EXECUTED
return rtems_rfs_rtems_error ("dir_read: read inode", rc);
}
bytes_transferred = 0;
for (d = 0; d < count; d++, dirent++)
2044514: 80 a5 00 13 cmp %l4, %l3 <== NOT EXECUTED
2044518: 08 80 00 0a bleu 2044540 <rtems_rfs_rtems_dir_read+0xc4> <== NOT EXECUTED
204451c: b0 06 21 18 add %i0, 0x118, %i0 <== NOT EXECUTED
{
size_t size;
rc = rtems_rfs_dir_read (fs, &inode, iop->offset, dirent, &size);
2044520: 98 06 40 18 add %i1, %i0, %o4 <== NOT EXECUTED
2044524: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2044528: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
204452c: 7f ff ed 95 call 203fb80 <rtems_rfs_dir_read> <== NOT EXECUTED
2044530: 9a 10 00 15 mov %l5, %o5 <== NOT EXECUTED
if (rc == ENOENT)
2044534: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED
2044538: 12 bf ff ef bne 20444f4 <rtems_rfs_rtems_dir_read+0x78> <== NOT EXECUTED
204453c: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
}
iop->offset += size;
bytes_transferred += sizeof (struct dirent);
}
rtems_rfs_inode_close (fs, &inode);
2044540: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044544: 7f ff fb b2 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2044548: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
204454c: e0 04 60 7c ld [ %l1 + 0x7c ], %l0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044550: 7f ff ec 53 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044554: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044558: 7f ff 24 7f call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
204455c: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return bytes_transferred;
}
2044560: 81 c7 e0 08 ret <== NOT EXECUTED
2044564: 81 e8 00 00 restore <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044568: e0 04 60 7c ld [ %l1 + 0x7c ], %l0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
204456c: 7f ff ec 4c call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044570: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2044574: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
2044578: 7f ff 24 77 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
204457c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc)
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_read: read inode", rc);
2044580: 40 00 17 c0 call 204a480 <__errno> <== NOT EXECUTED
2044584: 01 00 00 00 nop <== NOT EXECUTED
2044588: e6 22 00 00 st %l3, [ %o0 ] <== NOT EXECUTED
204458c: 81 c7 e0 08 ret <== NOT EXECUTED
2044590: 81 e8 00 00 restore <== NOT EXECUTED
rc = 0;
break;
}
if (rc > 0)
{
bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
2044594: 40 00 17 bb call 204a480 <__errno> <== NOT EXECUTED
2044598: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
iop->offset += size;
bytes_transferred += sizeof (struct dirent);
}
rtems_rfs_inode_close (fs, &inode);
204459c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
rc = 0;
break;
}
if (rc > 0)
{
bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
20445a0: ec 22 00 00 st %l6, [ %o0 ] <== NOT EXECUTED
}
iop->offset += size;
bytes_transferred += sizeof (struct dirent);
}
rtems_rfs_inode_close (fs, &inode);
20445a4: 7f ff fb 9a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20445a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20445ac: e0 04 60 7c ld [ %l1 + 0x7c ], %l0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20445b0: 7f ff ec 3b call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20445b4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20445b8: 7f ff 24 67 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20445bc: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return bytes_transferred;
}
20445c0: 81 c7 e0 08 ret <== NOT EXECUTED
20445c4: 81 e8 00 00 restore <== NOT EXECUTED
020443c4 <rtems_rfs_rtems_dir_rmnod>:
static int
rtems_rfs_rtems_dir_rmnod (rtems_filesystem_location_info_t* parent_pathloc,
rtems_filesystem_location_info_t* pathloc)
{
20443c4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20443c8: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_pathloc);
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
20443cc: e2 06 40 00 ld [ %i1 ], %l1 <== NOT EXECUTED
static int
rtems_rfs_rtems_dir_rmnod (rtems_filesystem_location_info_t* parent_pathloc,
rtems_filesystem_location_info_t* pathloc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20443d0: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_pathloc);
20443d4: e6 06 00 00 ld [ %i0 ], %l3 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_DIR_RMNOD))
printf ("rtems-rfs: dir-rmnod: parent:%" PRId32 " doff:%" PRIu32 ", ino:%" PRId32 "\n",
parent, doff, ino);
if (ino == RTEMS_RFS_ROOT_INO)
20443d8: 80 a4 60 01 cmp %l1, 1 <== NOT EXECUTED
20443dc: 02 80 00 22 be 2044464 <rtems_rfs_rtems_dir_rmnod+0xa0> <== NOT EXECUTED
20443e0: e4 06 60 04 ld [ %i1 + 4 ], %l2 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20443e4: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
20443e8: 92 10 20 00 clr %o1 <== NOT EXECUTED
20443ec: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20443f0: 7f ff 24 92 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20443f4: 94 10 20 00 clr %o2 <== NOT EXECUTED
return rtems_rfs_rtems_error ("dir_rmnod: root inode", EBUSY);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_unlink (fs, parent, ino, doff, rtems_rfs_unlink_dir_if_empty);
20443f8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20443fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044400: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2044404: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
2044408: 7f ff fe 2e call 2043cc0 <rtems_rfs_unlink> <== NOT EXECUTED
204440c: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
if (rc)
2044410: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2044414: 22 80 00 0d be,a 2044448 <rtems_rfs_rtems_dir_rmnod+0x84><== NOT EXECUTED
2044418: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
204441c: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044420: 7f ff ec 9f call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044424: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044428: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
204442c: 7f ff 24 ca call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044430: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("dir_rmnod: unlinking", rc);
2044434: 40 00 18 13 call 204a480 <__errno> <== NOT EXECUTED
2044438: 01 00 00 00 nop <== NOT EXECUTED
204443c: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2044440: 81 c7 e0 08 ret <== NOT EXECUTED
2044444: 81 e8 00 00 restore <== NOT EXECUTED
2044448: 7f ff ec 95 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
204444c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044450: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2044454: 7f ff 24 c0 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044458: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
204445c: 81 c7 e0 08 ret <== NOT EXECUTED
2044460: 81 e8 00 00 restore <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_DIR_RMNOD))
printf ("rtems-rfs: dir-rmnod: parent:%" PRId32 " doff:%" PRIu32 ", ino:%" PRId32 "\n",
parent, doff, ino);
if (ino == RTEMS_RFS_ROOT_INO)
return rtems_rfs_rtems_error ("dir_rmnod: root inode", EBUSY);
2044464: 40 00 18 07 call 204a480 <__errno> <== NOT EXECUTED
2044468: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
204446c: 82 10 20 10 mov 0x10, %g1 <== NOT EXECUTED
2044470: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2044474: 81 c7 e0 08 ret <== NOT EXECUTED
2044478: 81 e8 00 00 restore <== NOT EXECUTED
02024f54 <rtems_rfs_rtems_eval_for_make>:
*/
int
rtems_rfs_rtems_eval_for_make (const char* path,
rtems_filesystem_location_info_t* pathloc,
const char** name)
{
2024f54: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024f58: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2024f5c: c4 06 40 00 ld [ %i1 ], %g2 <== NOT EXECUTED
int
rtems_rfs_rtems_eval_for_make (const char* path,
rtems_filesystem_location_info_t* pathloc,
const char** name)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024f60: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2024f64: c4 27 bf fc st %g2, [ %fp + -4 ] <== NOT EXECUTED
rtems_rfs_ino node_ino;
uint32_t doff = 0;
2024f68: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
int rc;
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE))
printf ("rtems-rfs-rtems: eval-for-make: path:%s ino:%" PRId32 "\n", path, ino);
*name = path + strlen (path);
2024f6c: 40 00 b1 01 call 2051370 <strlen> <== NOT EXECUTED
2024f70: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2024f74: 90 06 00 08 add %i0, %o0, %o0 <== NOT EXECUTED
2024f78: d0 26 80 00 st %o0, [ %i2 ] <== NOT EXECUTED
while (*name != path)
2024f7c: 80 a6 00 08 cmp %i0, %o0 <== NOT EXECUTED
2024f80: 02 80 00 0b be 2024fac <rtems_rfs_rtems_eval_for_make+0x58><== NOT EXECUTED
2024f84: 82 02 3f ff add %o0, -1, %g1 <== NOT EXECUTED
{
(*name)--;
2024f88: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
if (rtems_filesystem_is_separator (**name))
2024f8c: 7f ff 95 7a call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
2024f90: d0 4a 3f ff ldsb [ %o0 + -1 ], %o0 <== NOT EXECUTED
2024f94: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024f98: 22 bf ff f9 be,a 2024f7c <rtems_rfs_rtems_eval_for_make+0x28><== NOT EXECUTED
2024f9c: d0 06 80 00 ld [ %i2 ], %o0 <== NOT EXECUTED
{
(*name)++;
2024fa0: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
2024fa4: 82 00 60 01 inc %g1 <== NOT EXECUTED
2024fa8: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
}
/*
* Eat any separators at start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, strlen(path));
2024fac: 40 00 b0 f1 call 2051370 <strlen> <== NOT EXECUTED
2024fb0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2024fb4: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2024fb8: 7f ff 8d bb call 20086a4 <rtems_filesystem_prefix_separators><== NOT EXECUTED
2024fbc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024fc0: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
path += stripped;
2024fc4: ba 06 00 08 add %i0, %o0, %i5 <== NOT EXECUTED
2024fc8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2024fcc: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024fd0: 94 10 20 00 clr %o2 <== NOT EXECUTED
2024fd4: 7f ff a1 99 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024fd8: 2f 00 81 a6 sethi %hi(0x2069800), %l7 <== NOT EXECUTED
2024fdc: a2 07 bf cc add %fp, -52, %l1 <== NOT EXECUTED
}
/*
* We need to find the parent of this node.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, "..", 2, &ino, &doff);
2024fe0: ae 15 e2 18 or %l7, 0x218, %l7 <== NOT EXECUTED
}
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
2024fe4: 29 00 00 3c sethi %hi(0xf000), %l4 <== NOT EXECUTED
2024fe8: 27 00 00 10 sethi %hi(0x4000), %l3 <== NOT EXECUTED
else
{
/*
* Read the inode so we know it exists and what type it is.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode,
2024fec: ac 07 bf fc add %fp, -4, %l6 <== NOT EXECUTED
2024ff0: aa 07 bf f4 add %fp, -12, %l5 <== NOT EXECUTED
while (true)
{
/*
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2024ff4: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2024ff8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024ffc: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2025000: 40 00 79 2d call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2025004: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2025008: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
202500c: 14 80 00 cb bg 2025338 <rtems_rfs_rtems_eval_for_make+0x3e4><== NOT EXECUTED
2025010: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
}
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
2025014: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2025018: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
202501c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2025020: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2025024: 82 08 40 14 and %g1, %l4, %g1 <== NOT EXECUTED
2025028: 80 a0 40 13 cmp %g1, %l3 <== NOT EXECUTED
202502c: 02 80 00 6c be 20251dc <rtems_rfs_rtems_eval_for_make+0x288><== NOT EXECUTED
2025030: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
}
/*
* Is this the end of the pathname we where given ?
*/
if (path == *name)
2025034: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
2025038: 80 a0 40 1d cmp %g1, %i5 <== NOT EXECUTED
202503c: 02 80 00 3f be 2025138 <rtems_rfs_rtems_eval_for_make+0x1e4><== NOT EXECUTED
2025040: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
2025044: a4 10 00 1d mov %i5, %l2 <== NOT EXECUTED
2025048: 10 80 00 0c b 2025078 <rtems_rfs_rtems_eval_for_make+0x124><== NOT EXECUTED
202504c: b8 10 20 00 clr %i4 <== NOT EXECUTED
/*
* Extract the node name we will look for this time around.
*/
node = path;
node_len = 0;
while (!rtems_filesystem_is_separator(*path) &&
2025050: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2025054: 02 80 00 0e be 202508c <rtems_rfs_rtems_eval_for_make+0x138><== NOT EXECUTED
2025058: 01 00 00 00 nop <== NOT EXECUTED
(*path != '\0') &&
(node_len < (rtems_rfs_fs_max_name (fs) - 1)))
202505c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
2025060: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2025064: 80 a7 00 01 cmp %i4, %g1 <== NOT EXECUTED
2025068: 1a 80 00 09 bcc 202508c <rtems_rfs_rtems_eval_for_make+0x138><== NOT EXECUTED
202506c: 01 00 00 00 nop <== NOT EXECUTED
{
node_len++;
2025070: b8 07 20 01 inc %i4 <== NOT EXECUTED
path++;
2025074: a4 04 a0 01 inc %l2 <== NOT EXECUTED
/*
* Extract the node name we will look for this time around.
*/
node = path;
node_len = 0;
while (!rtems_filesystem_is_separator(*path) &&
2025078: 7f ff 95 3f call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
202507c: d0 4c 80 00 ldsb [ %l2 ], %o0 <== NOT EXECUTED
2025080: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2025084: 22 bf ff f3 be,a 2025050 <rtems_rfs_rtems_eval_for_make+0xfc><== NOT EXECUTED
2025088: c2 4c 80 00 ldsb [ %l2 ], %g1 <== NOT EXECUTED
}
/*
* Eat any separators at start of the new path.
*/
stripped = rtems_filesystem_prefix_separators (path, strlen (path));
202508c: 40 00 b0 b9 call 2051370 <strlen> <== NOT EXECUTED
2025090: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2025094: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2025098: 7f ff 8d 83 call 20086a4 <rtems_filesystem_prefix_separators><== NOT EXECUTED
202509c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
20250a0: c2 4f 40 00 ldsb [ %i5 ], %g1 <== NOT EXECUTED
20250a4: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
20250a8: 02 80 00 1b be 2025114 <rtems_rfs_rtems_eval_for_make+0x1c0><== NOT EXECUTED
20250ac: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
/*
* If the node is a parent we must move up one directory. If the location
* is on another file system we have a crossmount so we call that file
* system to handle the remainder of the path.
*/
if (rtems_rfs_parent_dir (path))
20250b0: c2 4c 80 00 ldsb [ %l2 ], %g1 <== NOT EXECUTED
20250b4: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
20250b8: 12 80 00 07 bne 20250d4 <rtems_rfs_rtems_eval_for_make+0x180><== NOT EXECUTED
20250bc: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
20250c0: c2 4c a0 01 ldsb [ %l2 + 1 ], %g1 <== NOT EXECUTED
20250c4: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
20250c8: 22 80 00 55 be,a 202521c <rtems_rfs_rtems_eval_for_make+0x2c8><== NOT EXECUTED
20250cc: d0 4c a0 02 ldsb [ %l2 + 2 ], %o0 <== NOT EXECUTED
else
{
/*
* Read the inode so we know it exists and what type it is.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode,
20250d0: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
20250d4: 96 10 00 1c mov %i4, %o3 <== NOT EXECUTED
20250d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20250dc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20250e0: 98 10 00 16 mov %l6, %o4 <== NOT EXECUTED
20250e4: 40 00 6c f2 call 20404ac <rtems_rfs_dir_lookup_ino> <== NOT EXECUTED
20250e8: 9a 10 00 15 mov %l5, %o5 <== NOT EXECUTED
node, node_len - stripped, &ino, &doff);
if (rc > 0)
20250ec: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
20250f0: 14 80 00 81 bg 20252f4 <rtems_rfs_rtems_eval_for_make+0x3a0><== NOT EXECUTED
20250f4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE))
printf("rtems-rfs-rtems: eval-for-make: down: path:%s ino:%" PRId32 "\n",
node, ino);
}
rc = rtems_rfs_inode_close (fs, &inode);
20250f8: 40 00 78 c5 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20250fc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc > 0)
2025100: ba 92 20 00 orcc %o0, 0, %i5 <== NOT EXECUTED
2025104: 14 80 00 7f bg 2025300 <rtems_rfs_rtems_eval_for_make+0x3ac><== NOT EXECUTED
2025108: 01 00 00 00 nop <== NOT EXECUTED
202510c: 10 bf ff ba b 2024ff4 <rtems_rfs_rtems_eval_for_make+0xa0><== NOT EXECUTED
2025110: ba 10 00 12 mov %l2, %i5 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
2025114: d0 4f 60 01 ldsb [ %i5 + 1 ], %o0 <== NOT EXECUTED
2025118: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202511c: 12 80 00 53 bne 2025268 <rtems_rfs_rtems_eval_for_make+0x314><== NOT EXECUTED
2025120: 01 00 00 00 nop <== NOT EXECUTED
{
if (*path)
2025124: c2 4c 80 00 ldsb [ %l2 ], %g1 <== NOT EXECUTED
2025128: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202512c: 12 80 00 58 bne 202528c <rtems_rfs_rtems_eval_for_make+0x338><== NOT EXECUTED
2025130: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
2025134: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_for_make: closing node", rc);
}
}
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
2025138: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
202513c: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2025140: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2025144: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
2025148: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
202514c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2025150: 12 80 00 81 bne 2025354 <rtems_rfs_rtems_eval_for_make+0x400><== NOT EXECUTED
2025154: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_for_make: not dir", ENOTDIR);
}
if (!rtems_rfs_rtems_eval_perms (&inode, RTEMS_LIBIO_PERMS_WX))
2025158: 40 00 02 76 call 2025b30 <rtems_rfs_rtems_eval_perms> <== NOT EXECUTED
202515c: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
2025160: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
2025164: 02 80 00 24 be 20251f4 <rtems_rfs_rtems_eval_for_make+0x2a0><== NOT EXECUTED
2025168: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
}
/*
* Make sure the name does not already exists in the directory.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, *name, strlen (*name),
202516c: e4 06 80 00 ld [ %i2 ], %l2 <== NOT EXECUTED
2025170: 40 00 b0 80 call 2051370 <strlen> <== NOT EXECUTED
2025174: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2025178: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
202517c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2025180: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025184: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025188: 98 07 bf f8 add %fp, -8, %o4 <== NOT EXECUTED
202518c: 40 00 6c c8 call 20404ac <rtems_rfs_dir_lookup_ino> <== NOT EXECUTED
2025190: 9a 07 bf f4 add %fp, -12, %o5 <== NOT EXECUTED
&node_ino, &doff);
if (rc == 0)
2025194: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2025198: 02 80 00 8c be 20253c8 <rtems_rfs_rtems_eval_for_make+0x474><== NOT EXECUTED
202519c: 80 a4 a0 02 cmp %l2, 2 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_for_make: found name", EEXIST);
}
if (rc != ENOENT)
20251a0: 02 80 00 40 be 20252a0 <rtems_rfs_rtems_eval_for_make+0x34c><== NOT EXECUTED
20251a4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
20251a8: 40 00 78 99 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20251ac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20251b0: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20251b4: 40 00 69 3a call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20251b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20251bc: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20251c0: 7f ff a1 65 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20251c4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_for_make: look up", rc);
20251c8: 40 00 94 ae call 204a480 <__errno> <== NOT EXECUTED
20251cc: 01 00 00 00 nop <== NOT EXECUTED
20251d0: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
20251d4: 81 c7 e0 08 ret <== NOT EXECUTED
20251d8: 81 e8 00 00 restore <== NOT EXECUTED
}
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
20251dc: 40 00 02 55 call 2025b30 <rtems_rfs_rtems_eval_perms> <== NOT EXECUTED
20251e0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
20251e4: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
20251e8: 32 bf ff 94 bne,a 2025038 <rtems_rfs_rtems_eval_for_make+0xe4><== NOT EXECUTED
20251ec: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: not dir", ENOTDIR);
}
if (!rtems_rfs_rtems_eval_perms (&inode, RTEMS_LIBIO_PERMS_WX))
{
rtems_rfs_inode_close (fs, &inode);
20251f0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20251f4: 40 00 78 86 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20251f8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
20251fc: 7f ff fb 7b call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025200: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: cannot write", EACCES);
2025204: 40 00 94 9f call 204a480 <__errno> <== NOT EXECUTED
2025208: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202520c: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED
2025210: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2025214: 81 c7 e0 08 ret <== NOT EXECUTED
2025218: 81 e8 00 00 restore <== NOT EXECUTED
/*
* If the node is a parent we must move up one directory. If the location
* is on another file system we have a crossmount so we call that file
* system to handle the remainder of the path.
*/
if (rtems_rfs_parent_dir (path))
202521c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2025220: 12 80 00 3f bne 202531c <rtems_rfs_rtems_eval_for_make+0x3c8><== NOT EXECUTED
2025224: b0 04 a0 02 add %l2, 2, %i0 <== NOT EXECUTED
{
/*
* If we are at the root inode of the file system we have a crossmount
* path.
*/
if (ino == RTEMS_RFS_ROOT_INO)
2025228: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
202522c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2025230: 02 80 00 54 be 2025380 <rtems_rfs_rtems_eval_for_make+0x42c><== NOT EXECUTED
2025234: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
/*
* If not a directory give and up return. We cannot change dir from a
* regular file or device node.
*/
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
2025238: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
202523c: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
2025240: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2025244: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2025248: 82 08 40 14 and %g1, %l4, %g1 <== NOT EXECUTED
202524c: 80 a0 40 13 cmp %g1, %l3 <== NOT EXECUTED
2025250: 12 80 00 69 bne 20253f4 <rtems_rfs_rtems_eval_for_make+0x4a0><== NOT EXECUTED
2025254: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
/*
* We need to find the parent of this node.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, "..", 2, &ino, &doff);
2025258: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202525c: 94 10 00 17 mov %l7, %o2 <== NOT EXECUTED
2025260: 10 bf ff a0 b 20250e0 <rtems_rfs_rtems_eval_for_make+0x18c><== NOT EXECUTED
2025264: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
2025268: 7f ff 94 c3 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
202526c: 01 00 00 00 nop <== NOT EXECUTED
2025270: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2025274: 02 bf ff 90 be 20250b4 <rtems_rfs_rtems_eval_for_make+0x160><== NOT EXECUTED
2025278: c2 4c 80 00 ldsb [ %l2 ], %g1 <== NOT EXECUTED
{
if (*path)
202527c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2025280: 02 bf ff ae be 2025138 <rtems_rfs_rtems_eval_for_make+0x1e4><== NOT EXECUTED
2025284: c2 07 bf d8 ld [ %fp + -40 ], %g1 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
2025288: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202528c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025290: 40 00 78 5f call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025294: ba 10 00 12 mov %l2, %i5 <== NOT EXECUTED
while (true)
{
/*
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2025298: 10 bf ff 58 b 2024ff8 <rtems_rfs_rtems_eval_for_make+0xa4><== NOT EXECUTED
202529c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
/*
* Set the parent ino in the path location.
*/
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
20252a0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
20252a4: c2 26 40 00 st %g1, [ %i1 ] <== NOT EXECUTED
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
20252a8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20252ac: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
20252b0: 40 00 01 ec call 2025a60 <rtems_rfs_rtems_set_handlers> <== NOT EXECUTED
20252b4: c2 26 60 04 st %g1, [ %i1 + 4 ] <== NOT EXECUTED
20252b8: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED
20252bc: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE))
printf("rtems-rfs-rtems: eval-for-make: parent ino:%" PRId32 " name:%s\n",
ino, *name);
rtems_rfs_inode_close (fs, &inode);
20252c0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
*/
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20252c4: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE))
printf("rtems-rfs-rtems: eval-for-make: parent ino:%" PRId32 " name:%s\n",
ino, *name);
rtems_rfs_inode_close (fs, &inode);
20252c8: 40 00 78 51 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20252cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20252d0: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20252d4: 40 00 68 f2 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20252d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20252dc: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
*/
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20252e0: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
20252e4: 7f ff a1 1c call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20252e8: b0 06 20 05 add %i0, 5, %i0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
rtems_rfs_rtems_unlock (fs);
return rc;
}
20252ec: 81 c7 e0 08 ret <== NOT EXECUTED
20252f0: 81 e8 00 00 restore <== NOT EXECUTED
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode,
node, node_len - stripped, &ino, &doff);
if (rc > 0)
{
rtems_rfs_inode_close (fs, &inode);
20252f4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20252f8: 40 00 78 45 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20252fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
rc = rtems_rfs_inode_close (fs, &inode);
if (rc > 0)
{
rtems_rfs_rtems_unlock (fs);
2025300: 7f ff fb 3a call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025304: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: closing node", rc);
2025308: 40 00 94 5e call 204a480 <__errno> <== NOT EXECUTED
202530c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025310: fa 22 00 00 st %i5, [ %o0 ] <== NOT EXECUTED
2025314: 81 c7 e0 08 ret <== NOT EXECUTED
2025318: 81 e8 00 00 restore <== NOT EXECUTED
/*
* If the node is a parent we must move up one directory. If the location
* is on another file system we have a crossmount so we call that file
* system to handle the remainder of the path.
*/
if (rtems_rfs_parent_dir (path))
202531c: 7f ff 94 96 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
2025320: 01 00 00 00 nop <== NOT EXECUTED
2025324: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2025328: 02 bf ff 6b be 20250d4 <rtems_rfs_rtems_eval_for_make+0x180><== NOT EXECUTED
202532c: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
{
/*
* If we are at the root inode of the file system we have a crossmount
* path.
*/
if (ino == RTEMS_RFS_ROOT_INO)
2025330: 10 bf ff bf b 202522c <rtems_rfs_rtems_eval_for_make+0x2d8><== NOT EXECUTED
2025334: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc > 0)
{
rtems_rfs_rtems_unlock (fs);
2025338: 7f ff fb 2c call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
202533c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: read ino", rc);
2025340: 40 00 94 50 call 204a480 <__errno> <== NOT EXECUTED
2025344: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025348: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
202534c: 81 c7 e0 08 ret <== NOT EXECUTED
2025350: 81 e8 00 00 restore <== NOT EXECUTED
}
}
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
{
rtems_rfs_inode_close (fs, &inode);
2025354: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025358: 40 00 78 2d call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
202535c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2025360: 7f ff fb 22 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025364: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: not dir", ENOTDIR);
2025368: 40 00 94 46 call 204a480 <__errno> <== NOT EXECUTED
202536c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025370: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED
2025374: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2025378: 81 c7 e0 08 ret <== NOT EXECUTED
202537c: 81 e8 00 00 restore <== NOT EXECUTED
{
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_FOR_MAKE))
printf("rtems-rfs-rtems: eval-for-make: crossmount: path:%s\n",
path - node_len);
rtems_rfs_inode_close (fs, &inode);
2025380: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025384: 40 00 78 22 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025388: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
202538c: 7f ff fb 17 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025390: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*pathloc = pathloc->mt_entry->mt_point_node;
2025394: d2 06 60 10 ld [ %i1 + 0x10 ], %o1 <== NOT EXECUTED
2025398: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED
202539c: 92 02 60 08 add %o1, 8, %o1 <== NOT EXECUTED
20253a0: 40 00 a1 84 call 204d9b0 <memcpy> <== NOT EXECUTED
20253a4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
return (*pathloc->ops->evalformake_h)(path + 2, pathloc, name);
20253a8: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
20253ac: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20253b0: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
20253b4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20253b8: 9f c0 40 00 call %g1 <== NOT EXECUTED
20253bc: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
20253c0: 81 c7 e0 08 ret <== NOT EXECUTED
20253c4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, *name, strlen (*name),
&node_ino, &doff);
if (rc == 0)
{
rtems_rfs_inode_close (fs, &inode);
20253c8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20253cc: 40 00 78 10 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20253d0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
20253d4: 7f ff fb 05 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
20253d8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: found name", EEXIST);
20253dc: 40 00 94 29 call 204a480 <__errno> <== NOT EXECUTED
20253e0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20253e4: 82 10 20 11 mov 0x11, %g1 <== NOT EXECUTED
20253e8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20253ec: 81 c7 e0 08 ret <== NOT EXECUTED
20253f0: 81 e8 00 00 restore <== NOT EXECUTED
* If not a directory give and up return. We cannot change dir from a
* regular file or device node.
*/
if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))
{
rtems_rfs_inode_close (fs, &inode);
20253f4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20253f8: 40 00 78 05 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20253fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2025400: 7f ff fa fa call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025404: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_for_make: not dir", ENOTSUP);
2025408: 40 00 94 1e call 204a480 <__errno> <== NOT EXECUTED
202540c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025410: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2025414: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2025418: 81 c7 e0 08 ret <== NOT EXECUTED
202541c: 81 e8 00 00 restore <== NOT EXECUTED
02024310 <rtems_rfs_rtems_eval_path>:
int
rtems_rfs_rtems_eval_path (const char* path,
size_t pathlen,
int flags,
rtems_filesystem_location_info_t* pathloc)
{
2024310: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024314: c4 06 e0 10 ld [ %i3 + 0x10 ], %g2 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2024318: c2 06 c0 00 ld [ %i3 ], %g1 <== NOT EXECUTED
rtems_rfs_rtems_eval_path (const char* path,
size_t pathlen,
int flags,
rtems_filesystem_location_info_t* pathloc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
202431c: e0 00 a0 34 ld [ %g2 + 0x34 ], %l0 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2024320: c2 27 bf fc st %g1, [ %fp + -4 ] <== NOT EXECUTED
path, pathlen, ino);
/*
* Eat any separators at the start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, pathlen);
2024324: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
rtems_filesystem_location_info_t* pathloc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
rtems_rfs_inode_handle inode;
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
uint32_t doff = 0;
2024328: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
path, pathlen, ino);
/*
* Eat any separators at the start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, pathlen);
202432c: 7f ff 90 de call 20086a4 <rtems_filesystem_prefix_separators><== NOT EXECUTED
2024330: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024334: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2024338: b8 10 00 08 mov %o0, %i4 <== NOT EXECUTED
path += stripped;
pathlen -= stripped;
202433c: a2 26 40 08 sub %i1, %o0, %l1 <== NOT EXECUTED
2024340: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2024344: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024348: 94 10 20 00 clr %o2 <== NOT EXECUTED
}
/*
* We need to find the parent of this node.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, "..", 2, &ino, &doff);
202434c: 3b 00 81 a6 sethi %hi(0x2069800), %i5 <== NOT EXECUTED
2024350: 7f ff a4 ba call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024354: b8 06 00 1c add %i0, %i4, %i4 <== NOT EXECUTED
2024358: a4 07 bf d0 add %fp, -48, %l2 <== NOT EXECUTED
202435c: ba 17 62 18 or %i5, 0x218, %i5 <== NOT EXECUTED
break;
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
2024360: 2b 00 00 3c sethi %hi(0xf000), %l5 <== NOT EXECUTED
2024364: 29 00 00 10 sethi %hi(0x4000), %l4 <== NOT EXECUTED
/*
* Look up the node name in this directory. If found drop through, close
* the current inode and let the loop open the inode so the mode can be
* read and handlers set.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode,
2024368: ae 07 bf fc add %fp, -4, %l7 <== NOT EXECUTED
202436c: ac 07 bf f8 add %fp, -8, %l6 <== NOT EXECUTED
while (true)
{
/*
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2024370: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
2024374: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024378: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
202437c: 40 00 7c 4e call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2024380: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2024384: a6 92 20 00 orcc %o0, 0, %l3 <== NOT EXECUTED
2024388: 14 80 00 97 bg 20245e4 <rtems_rfs_rtems_eval_path+0x2d4> <== NOT EXECUTED
202438c: 01 00 00 00 nop <== NOT EXECUTED
}
/*
* Is this the end of the pathname we where given ?
*/
if ((*path == '\0') || (pathlen == 0))
2024390: d0 0f 00 00 ldub [ %i4 ], %o0 <== NOT EXECUTED
2024394: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
2024398: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202439c: 02 80 00 4e be 20244d4 <rtems_rfs_rtems_eval_path+0x1c4> <== NOT EXECUTED
20243a0: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
20243a4: 02 80 00 4c be 20244d4 <rtems_rfs_rtems_eval_path+0x1c4> <== NOT EXECUTED
20243a8: c2 07 bf dc ld [ %fp + -36 ], %g1 <== NOT EXECUTED
break;
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
20243ac: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
20243b0: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
20243b4: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20243b8: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
20243bc: 82 08 40 15 and %g1, %l5, %g1 <== NOT EXECUTED
20243c0: 80 a0 40 14 cmp %g1, %l4 <== NOT EXECUTED
20243c4: 22 80 00 34 be,a 2024494 <rtems_rfs_rtems_eval_path+0x184><== NOT EXECUTED
20243c8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
20243cc: a6 10 00 1c mov %i4, %l3 <== NOT EXECUTED
20243d0: 10 80 00 11 b 2024414 <rtems_rfs_rtems_eval_path+0x104> <== NOT EXECUTED
20243d4: b0 10 20 00 clr %i0 <== NOT EXECUTED
/*
* Extract the node name we will look for this time around.
*/
node = path;
node_len = 0;
while (!rtems_filesystem_is_separator (*path) &&
20243d8: 02 80 00 15 be 202442c <rtems_rfs_rtems_eval_path+0x11c> <== NOT EXECUTED
20243dc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20243e0: c4 4c c0 00 ldsb [ %l3 ], %g2 <== NOT EXECUTED
20243e4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20243e8: 02 80 00 11 be 202442c <rtems_rfs_rtems_eval_path+0x11c> <== NOT EXECUTED
20243ec: 82 06 20 01 add %i0, 1, %g1 <== NOT EXECUTED
(*path != '\0') && pathlen &&
((node_len + 1) < rtems_rfs_fs_max_name (fs)))
20243f0: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 <== NOT EXECUTED
20243f4: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20243f8: 1a 80 00 0d bcc 202442c <rtems_rfs_rtems_eval_path+0x11c> <== NOT EXECUTED
20243fc: 01 00 00 00 nop <== NOT EXECUTED
{
path++;
2024400: a6 04 e0 01 inc %l3 <== NOT EXECUTED
pathlen--;
2024404: d0 0c c0 00 ldub [ %l3 ], %o0 <== NOT EXECUTED
2024408: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
202440c: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
2024410: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
/*
* Extract the node name we will look for this time around.
*/
node = path;
node_len = 0;
while (!rtems_filesystem_is_separator (*path) &&
2024414: 7f ff 98 58 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
2024418: 91 3a 20 18 sra %o0, 0x18, %o0 <== NOT EXECUTED
202441c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024420: 02 bf ff ee be 20243d8 <rtems_rfs_rtems_eval_path+0xc8> <== NOT EXECUTED
2024424: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
}
/*
* Eat any separators at start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, pathlen);
2024428: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202442c: 7f ff 90 9e call 20086a4 <rtems_filesystem_prefix_separators><== NOT EXECUTED
2024430: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
2024434: c2 4f 00 00 ldsb [ %i4 ], %g1 <== NOT EXECUTED
}
/*
* Eat any separators at start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, pathlen);
2024438: b2 10 00 08 mov %o0, %i1 <== NOT EXECUTED
path += stripped;
202443c: a6 04 c0 08 add %l3, %o0, %l3 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
2024440: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
/*
* Eat any separators at start of the path.
*/
stripped = rtems_filesystem_prefix_separators (path, pathlen);
path += stripped;
pathlen -= stripped;
2024444: a2 24 40 08 sub %l1, %o0, %l1 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
2024448: 02 80 00 1b be 20244b4 <rtems_rfs_rtems_eval_path+0x1a4> <== NOT EXECUTED
202444c: b0 02 00 18 add %o0, %i0, %i0 <== NOT EXECUTED
/*
* Look up the node name in this directory. If found drop through, close
* the current inode and let the loop open the inode so the mode can be
* read and handlers set.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode,
2024450: 96 26 00 19 sub %i0, %i1, %o3 <== NOT EXECUTED
2024454: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2024458: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202445c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024460: 98 10 00 17 mov %l7, %o4 <== NOT EXECUTED
2024464: 40 00 70 12 call 20404ac <rtems_rfs_dir_lookup_ino> <== NOT EXECUTED
2024468: 9a 10 00 16 mov %l6, %o5 <== NOT EXECUTED
node, node_len - stripped, &ino, &doff);
if (rc > 0)
202446c: b8 92 20 00 orcc %o0, 0, %i4 <== NOT EXECUTED
2024470: 14 80 00 4c bg 20245a0 <rtems_rfs_rtems_eval_path+0x290> <== NOT EXECUTED
2024474: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_PATH))
printf("rtems-rfs-rtems: eval-path: down: path:%s ino:%" PRId32 "\n", node, ino);
}
rc = rtems_rfs_inode_close (fs, &inode);
2024478: 40 00 7b e5 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
202447c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
if (rc > 0)
2024480: b8 92 20 00 orcc %o0, 0, %i4 <== NOT EXECUTED
2024484: 14 80 00 48 bg 20245a4 <rtems_rfs_rtems_eval_path+0x294> <== NOT EXECUTED
2024488: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
202448c: 10 bf ff b9 b 2024370 <rtems_rfs_rtems_eval_path+0x60> <== NOT EXECUTED
2024490: b8 10 00 13 mov %l3, %i4 <== NOT EXECUTED
break;
/*
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
2024494: 40 00 05 a7 call 2025b30 <rtems_rfs_rtems_eval_perms> <== NOT EXECUTED
2024498: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
202449c: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED
20244a0: 02 80 00 6b be 202464c <rtems_rfs_rtems_eval_path+0x33c> <== NOT EXECUTED
20244a4: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20244a8: d0 0f 00 00 ldub [ %i4 ], %o0 <== NOT EXECUTED
20244ac: 10 bf ff c8 b 20243cc <rtems_rfs_rtems_eval_path+0xbc> <== NOT EXECUTED
20244b0: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
20244b4: d0 4f 20 01 ldsb [ %i4 + 1 ], %o0 <== NOT EXECUTED
20244b8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20244bc: 12 80 00 1c bne 202452c <rtems_rfs_rtems_eval_path+0x21c> <== NOT EXECUTED
20244c0: 82 07 20 01 add %i4, 1, %g1 <== NOT EXECUTED
{
if (*path)
20244c4: c2 4c c0 00 ldsb [ %l3 ], %g1 <== NOT EXECUTED
20244c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20244cc: 32 80 00 30 bne,a 202458c <rtems_rfs_rtems_eval_path+0x27c><== NOT EXECUTED
20244d0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_path: closing node", rc);
}
}
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
20244d4: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20244d8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("eval_path: closing node", rc);
}
}
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
20244dc: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
20244e0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20244e4: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
20244e8: 40 00 05 5e call 2025a60 <rtems_rfs_rtems_set_handlers> <== NOT EXECUTED
20244ec: c2 26 e0 04 st %g1, [ %i3 + 4 ] <== NOT EXECUTED
20244f0: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED
20244f4: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
20244f8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
}
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
20244fc: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
2024500: 40 00 7b c3 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024504: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024508: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
202450c: 40 00 6c 64 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024510: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2024514: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
}
rtems_rfs_rtems_set_pathloc_ino (pathloc, ino);
rtems_rfs_rtems_set_pathloc_doff (pathloc, doff);
rc = rtems_rfs_rtems_set_handlers (pathloc, &inode) ? 0 : EIO;
2024518: b0 0e 3f fb and %i0, -5, %i0 <== NOT EXECUTED
202451c: 7f ff a4 8e call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024520: b0 06 20 05 add %i0, 5, %i0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_PATH))
printf("rtems-rfs-rtems: eval-path: ino:%" PRId32 "\n", ino);
return rc;
}
2024524: 81 c7 e0 08 ret <== NOT EXECUTED
2024528: 81 e8 00 00 restore <== NOT EXECUTED
/*
* If the node is the current directory and there is more path to come move
* on it else we are at the inode we want.
*/
if (rtems_rfs_current_dir (node))
202452c: 7f ff 98 12 call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
2024530: c2 27 bf cc st %g1, [ %fp + -52 ] <== NOT EXECUTED
2024534: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024538: 12 bf ff e3 bne 20244c4 <rtems_rfs_rtems_eval_path+0x1b4> <== NOT EXECUTED
202453c: c2 07 bf cc ld [ %fp + -52 ], %g1 <== NOT EXECUTED
/*
* If the node is a parent we must move up one directory. If the location
* is on another file system we have a crossmount so we call that file
* system to handle the remainder of the path.
*/
if (rtems_rfs_parent_dir (node))
2024540: c4 4f 00 00 ldsb [ %i4 ], %g2 <== NOT EXECUTED
2024544: 80 a0 a0 2e cmp %g2, 0x2e <== NOT EXECUTED
2024548: 12 bf ff c3 bne 2024454 <rtems_rfs_rtems_eval_path+0x144> <== NOT EXECUTED
202454c: 96 26 00 19 sub %i0, %i1, %o3 <== NOT EXECUTED
2024550: c2 48 40 00 ldsb [ %g1 ], %g1 <== NOT EXECUTED
2024554: 80 a0 60 2e cmp %g1, 0x2e <== NOT EXECUTED
2024558: 12 bf ff c0 bne 2024458 <rtems_rfs_rtems_eval_path+0x148> <== NOT EXECUTED
202455c: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2024560: d0 4f 20 02 ldsb [ %i4 + 2 ], %o0 <== NOT EXECUTED
2024564: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024568: 12 80 00 18 bne 20245c8 <rtems_rfs_rtems_eval_path+0x2b8> <== NOT EXECUTED
202456c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
{
/*
* If we are at root inode of the file system we have a crossmount path.
*/
if (ino == RTEMS_RFS_ROOT_INO)
2024570: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED
2024574: 02 80 00 23 be 2024600 <rtems_rfs_rtems_eval_path+0x2f0> <== NOT EXECUTED
2024578: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}
/*
* We need to find the parent of this node.
*/
rc = rtems_rfs_dir_lookup_ino (fs, &inode, "..", 2, &ino, &doff);
202457c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024580: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
2024584: 10 bf ff b7 b 2024460 <rtems_rfs_rtems_eval_path+0x150> <== NOT EXECUTED
2024588: 96 10 20 02 mov 2, %o3 <== NOT EXECUTED
*/
if (rtems_rfs_current_dir (node))
{
if (*path)
{
rtems_rfs_inode_close (fs, &inode);
202458c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024590: 40 00 7b 9f call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024594: b8 10 00 13 mov %l3, %i4 <== NOT EXECUTED
while (true)
{
/*
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2024598: 10 bf ff 77 b 2024374 <rtems_rfs_rtems_eval_path+0x64> <== NOT EXECUTED
202459c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
}
rc = rtems_rfs_inode_close (fs, &inode);
if (rc > 0)
{
rtems_rfs_inode_close (fs, &inode);
20245a0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20245a4: 40 00 7b 9a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20245a8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
20245ac: 7f ff fe 8f call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
20245b0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_path: closing node", rc);
20245b4: 40 00 97 b3 call 204a480 <__errno> <== NOT EXECUTED
20245b8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20245bc: f8 22 00 00 st %i4, [ %o0 ] <== NOT EXECUTED
20245c0: 81 c7 e0 08 ret <== NOT EXECUTED
20245c4: 81 e8 00 00 restore <== NOT EXECUTED
/*
* If the node is a parent we must move up one directory. If the location
* is on another file system we have a crossmount so we call that file
* system to handle the remainder of the path.
*/
if (rtems_rfs_parent_dir (node))
20245c8: 7f ff 97 eb call 200a574 <rtems_filesystem_is_separator> <== NOT EXECUTED
20245cc: 01 00 00 00 nop <== NOT EXECUTED
20245d0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20245d4: 02 bf ff a0 be 2024454 <rtems_rfs_rtems_eval_path+0x144> <== NOT EXECUTED
20245d8: 96 26 00 19 sub %i0, %i1, %o3 <== NOT EXECUTED
{
/*
* If we are at root inode of the file system we have a crossmount path.
*/
if (ino == RTEMS_RFS_ROOT_INO)
20245dc: 10 bf ff e5 b 2024570 <rtems_rfs_rtems_eval_path+0x260> <== NOT EXECUTED
20245e0: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
* Open and load the inode.
*/
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc > 0)
{
rtems_rfs_rtems_unlock (fs);
20245e4: 7f ff fe 81 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
20245e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_path: opening inode", rc);
20245ec: 40 00 97 a5 call 204a480 <__errno> <== NOT EXECUTED
20245f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20245f4: e6 22 00 00 st %l3, [ %o0 ] <== NOT EXECUTED
20245f8: 81 c7 e0 08 ret <== NOT EXECUTED
20245fc: 81 e8 00 00 restore <== NOT EXECUTED
if (ino == RTEMS_RFS_ROOT_INO)
{
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_PATH))
printf("rtems-rfs-rtems: eval-path: crossmount: path:%s (%zd)\n",
path - node_len, pathlen + node_len);
rtems_rfs_inode_close (fs, &inode);
2024600: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024604: 40 00 7b 82 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024608: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
202460c: 7f ff fe 77 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2024610: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*pathloc = pathloc->mt_entry->mt_point_node;
2024614: d2 06 e0 10 ld [ %i3 + 0x10 ], %o1 <== NOT EXECUTED
2024618: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED
202461c: 92 02 60 08 add %o1, 8, %o1 <== NOT EXECUTED
2024620: 40 00 a4 e4 call 204d9b0 <memcpy> <== NOT EXECUTED
2024624: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
return (*pathloc->ops->evalpath_h)(path - node_len, pathlen + node_len,
2024628: c2 06 e0 0c ld [ %i3 + 0xc ], %g1 <== NOT EXECUTED
202462c: 92 06 00 11 add %i0, %l1, %o1 <== NOT EXECUTED
2024630: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
2024634: 90 24 c0 18 sub %l3, %i0, %o0 <== NOT EXECUTED
2024638: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
202463c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2024640: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2024644: 81 c7 e0 08 ret <== NOT EXECUTED
2024648: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
* If a directory the execute bit must be set for us to enter.
*/
if (RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)) &&
!rtems_rfs_rtems_eval_perms (&inode, RTEMS_LIBIO_PERMS_SEARCH))
{
rtems_rfs_inode_close (fs, &inode);
202464c: 40 00 7b 70 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024650: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2024654: 7f ff fe 65 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2024658: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("eval_path: eval perms", EACCES);
202465c: 40 00 97 89 call 204a480 <__errno> <== NOT EXECUTED
2024660: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2024664: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED
2024668: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202466c: 81 c7 e0 08 ret <== NOT EXECUTED
2024670: 81 e8 00 00 restore <== NOT EXECUTED
02025b30 <rtems_rfs_rtems_eval_perms>:
#include "rtems-rfs-rtems.h"
bool
rtems_rfs_rtems_eval_perms (rtems_rfs_inode_handle* inode, int flags)
{
2025b30: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
* @return uint16_t The user id (uid).
*/
static inline uint16_t
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;
2025b34: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2025b38: 84 00 60 04 add %g1, 4, %g2 <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
2025b3c: e0 08 60 03 ldub [ %g1 + 3 ], %l0 <== NOT EXECUTED
* @return uint16_t The user id (uid).
*/
static inline uint16_t
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;
2025b40: ea 08 a0 02 ldub [ %g2 + 2 ], %l5 <== NOT EXECUTED
2025b44: e8 08 a0 03 ldub [ %g2 + 3 ], %l4 <== NOT EXECUTED
* @return uint16_t The group id (gid).
*/
static inline uint16_t
rtems_rfs_inode_get_gid (rtems_rfs_inode_handle* handle)
{
return (rtems_rfs_read_u32 (&handle->node->owner) >> 16) & 0xffff;
2025b48: e4 08 a0 01 ldub [ %g2 + 1 ], %l2 <== NOT EXECUTED
2025b4c: e6 08 60 04 ldub [ %g1 + 4 ], %l3 <== NOT EXECUTED
uid = rtems_rfs_inode_get_uid (inode);
gid = rtems_rfs_inode_get_gid (inode);
mode = rtems_rfs_inode_get_mode (inode);
#if defined (RTEMS_POSIX_API)
st_uid = geteuid ();
2025b50: 40 00 1c 5d call 202ccc4 <geteuid> <== NOT EXECUTED
2025b54: e2 08 60 02 ldub [ %g1 + 2 ], %l1 <== NOT EXECUTED
st_gid = getegid ();
2025b58: 40 00 1c 57 call 202ccb4 <getegid> <== NOT EXECUTED
2025b5c: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
/*
* Check if I am owner or a group member or someone else.
*/
flags_to_test = flags;
if ((st_uid == 0) || (st_uid == uid))
2025b60: ad 2d a0 10 sll %l6, 0x10, %l6 <== NOT EXECUTED
2025b64: ad 35 a0 10 srl %l6, 0x10, %l6 <== NOT EXECUTED
2025b68: 80 a0 00 16 cmp %g0, %l6 <== NOT EXECUTED
2025b6c: ab 2d 60 08 sll %l5, 8, %l5 <== NOT EXECUTED
2025b70: 84 60 3f ff subx %g0, -1, %g2 <== NOT EXECUTED
2025b74: a8 15 40 14 or %l5, %l4, %l4 <== NOT EXECUTED
2025b78: a9 2d 20 10 sll %l4, 0x10, %l4 <== NOT EXECUTED
2025b7c: a9 35 20 10 srl %l4, 0x10, %l4 <== NOT EXECUTED
2025b80: 80 a5 80 14 cmp %l6, %l4 <== NOT EXECUTED
2025b84: 22 80 00 26 be,a 2025c1c <rtems_rfs_rtems_eval_perms+0xec><== NOT EXECUTED
2025b88: 83 2e 60 06 sll %i1, 6, %g1 <== NOT EXECUTED
2025b8c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2025b90: 12 80 00 22 bne 2025c18 <rtems_rfs_rtems_eval_perms+0xe8> <== NOT EXECUTED
2025b94: 82 10 00 19 mov %i1, %g1 <== NOT EXECUTED
flags_to_test |= flags << 6;
if ((st_uid == 0) || (st_gid == gid))
2025b98: a7 2c e0 18 sll %l3, 0x18, %l3 <== NOT EXECUTED
2025b9c: a4 0c a0 ff and %l2, 0xff, %l2 <== NOT EXECUTED
2025ba0: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
2025ba4: a5 2c a0 10 sll %l2, 0x10, %l2 <== NOT EXECUTED
2025ba8: a6 14 c0 12 or %l3, %l2, %l3 <== NOT EXECUTED
2025bac: 80 a4 c0 08 cmp %l3, %o0 <== NOT EXECUTED
2025bb0: 22 80 00 0f be,a 2025bec <rtems_rfs_rtems_eval_perms+0xbc><== NOT EXECUTED
2025bb4: b3 2e 60 03 sll %i1, 3, %i1 <== NOT EXECUTED
2025bb8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2025bbc: 32 80 00 0c bne,a 2025bec <rtems_rfs_rtems_eval_perms+0xbc><== NOT EXECUTED
2025bc0: b3 2e 60 03 sll %i1, 3, %i1 <== NOT EXECUTED
flags_to_test |= flags << 3;
2025bc4: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
2025bc8: a0 0c 20 ff and %l0, 0xff, %l0 <== NOT EXECUTED
2025bcc: a3 2c 60 08 sll %l1, 8, %l1 <== NOT EXECUTED
2025bd0: a0 14 00 11 or %l0, %l1, %l0 <== NOT EXECUTED
2025bd4: a0 0c 21 ff and %l0, 0x1ff, %l0 <== NOT EXECUTED
2025bd8: 82 0c 00 01 and %l0, %g1, %g1 <== NOT EXECUTED
2025bdc: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2025be0: b0 40 20 00 addx %g0, 0, %i0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_PERMS))
printf("rtems-rfs: eval-perms: perms failed\n");
return false;
}
2025be4: 81 c7 e0 08 ret <== NOT EXECUTED
2025be8: 81 e8 00 00 restore <== NOT EXECUTED
flags_to_test = flags;
if ((st_uid == 0) || (st_uid == uid))
flags_to_test |= flags << 6;
if ((st_uid == 0) || (st_gid == gid))
flags_to_test |= flags << 3;
2025bec: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
2025bf0: 82 10 40 19 or %g1, %i1, %g1 <== NOT EXECUTED
2025bf4: a3 2c 60 08 sll %l1, 8, %l1 <== NOT EXECUTED
2025bf8: a0 0c 20 ff and %l0, 0xff, %l0 <== NOT EXECUTED
2025bfc: a0 14 00 11 or %l0, %l1, %l0 <== NOT EXECUTED
2025c00: a0 0c 21 ff and %l0, 0x1ff, %l0 <== NOT EXECUTED
2025c04: 82 0c 00 01 and %l0, %g1, %g1 <== NOT EXECUTED
2025c08: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2025c0c: b0 40 20 00 addx %g0, 0, %i0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_EVAL_PERMS))
printf("rtems-rfs: eval-perms: perms failed\n");
return false;
}
2025c10: 81 c7 e0 08 ret <== NOT EXECUTED
2025c14: 81 e8 00 00 restore <== NOT EXECUTED
* Check if I am owner or a group member or someone else.
*/
flags_to_test = flags;
if ((st_uid == 0) || (st_uid == uid))
flags_to_test |= flags << 6;
2025c18: 83 2e 60 06 sll %i1, 6, %g1 <== NOT EXECUTED
2025c1c: 10 bf ff df b 2025b98 <rtems_rfs_rtems_eval_perms+0x68> <== NOT EXECUTED
2025c20: 82 10 40 19 or %g1, %i1, %g1 <== NOT EXECUTED
02025634 <rtems_rfs_rtems_fchmod>:
* @return int
*/
int
rtems_rfs_rtems_fchmod (rtems_filesystem_location_info_t* pathloc,
mode_t mode)
{
2025634: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2025638: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
202563c: e4 06 00 00 ld [ %i0 ], %l2 <== NOT EXECUTED
*/
int
rtems_rfs_rtems_fchmod (rtems_filesystem_location_info_t* pathloc,
mode_t mode)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2025640: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2025644: 92 10 20 00 clr %o1 <== NOT EXECUTED
2025648: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
202564c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2025650: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2025654: 7f ff 9f f9 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2025658: a2 07 bf d8 add %fp, -40, %l1 <== NOT EXECUTED
printf ("rtems-rfs-rtems: fchmod: in: ino:%" PRId32 " mode:%06" PRIomode_t "\n",
ino, mode);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
202565c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2025660: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025664: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2025668: 40 00 77 93 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
202566c: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
2025670: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2025674: 02 80 00 0d be 20256a8 <rtems_rfs_rtems_fchmod+0x74> <== NOT EXECUTED
2025678: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
202567c: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2025680: 40 00 68 07 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025684: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2025688: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
202568c: 7f ff a0 32 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025690: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("fchmod: opening inode", rc);
2025694: 40 00 93 7b call 204a480 <__errno> <== NOT EXECUTED
2025698: 01 00 00 00 nop <== NOT EXECUTED
202569c: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
20256a0: 81 c7 e0 08 ret <== NOT EXECUTED
20256a4: 81 e8 00 00 restore <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
20256a8: e4 08 60 03 ldub [ %g1 + 3 ], %l2 <== NOT EXECUTED
/*
* Verify I am the owner of the node or the super user.
*/
#if defined (RTEMS_POSIX_API)
uid = geteuid();
20256ac: 40 00 1d 86 call 202ccc4 <geteuid> <== NOT EXECUTED
20256b0: e6 08 60 02 ldub [ %g1 + 2 ], %l3 <== NOT EXECUTED
* @return uint16_t The user id (uid).
*/
static inline uint16_t
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;
20256b4: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
if ((uid != rtems_rfs_inode_get_uid (&inode)) && (uid != 0))
20256b8: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
20256bc: 84 00 60 04 add %g1, 4, %g2 <== NOT EXECUTED
20256c0: c6 08 a0 03 ldub [ %g2 + 3 ], %g3 <== NOT EXECUTED
20256c4: c4 08 a0 02 ldub [ %g2 + 2 ], %g2 <== NOT EXECUTED
20256c8: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
20256cc: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
20256d0: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20256d4: 80 a0 80 08 cmp %g2, %o0 <== NOT EXECUTED
20256d8: 02 80 00 05 be 20256ec <rtems_rfs_rtems_fchmod+0xb8> <== NOT EXECUTED
20256dc: 89 32 20 10 srl %o0, 0x10, %g4 <== NOT EXECUTED
20256e0: 80 a1 20 00 cmp %g4, 0 <== NOT EXECUTED
20256e4: 12 80 00 27 bne 2025780 <rtems_rfs_rtems_fchmod+0x14c> <== NOT EXECUTED
20256e8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
20256ec: a6 0c e0 ff and %l3, 0xff, %l3 <== NOT EXECUTED
20256f0: a4 0c a0 ff and %l2, 0xff, %l2 <== NOT EXECUTED
20256f4: a7 2c e0 08 sll %l3, 8, %l3 <== NOT EXECUTED
return rtems_rfs_rtems_error ("fchmod: not owner", EPERM);
}
#endif
imode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
imode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
20256f8: b2 0e 6f ff and %i1, 0xfff, %i1 <== NOT EXECUTED
20256fc: a4 14 c0 12 or %l3, %l2, %l2 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("fchmod: not owner", EPERM);
}
#endif
imode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
2025700: a4 0c b0 00 and %l2, -4096, %l2 <== NOT EXECUTED
imode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
2025704: b2 14 80 19 or %l2, %i1, %i1 <== NOT EXECUTED
* @prarm mode The mode.
*/
static inline void
rtems_rfs_inode_set_mode (rtems_rfs_inode_handle* handle, uint16_t mode)
{
rtems_rfs_write_u16 (&handle->node->mode, mode);
2025708: 85 36 60 08 srl %i1, 8, %g2 <== NOT EXECUTED
202570c: c4 28 60 02 stb %g2, [ %g1 + 2 ] <== NOT EXECUTED
2025710: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
rtems_rfs_inode_set_mode (&inode, imode);
rc = rtems_rfs_inode_close (fs, &inode);
2025714: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2025718: f2 28 60 03 stb %i1, [ %g1 + 3 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
202571c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2025720: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025724: 40 00 77 3a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025728: c2 2f bf e8 stb %g1, [ %fp + -24 ] <== NOT EXECUTED
if (rc > 0)
202572c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2025730: 24 80 00 0d ble,a 2025764 <rtems_rfs_rtems_fchmod+0x130> <== NOT EXECUTED
2025734: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2025738: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
202573c: 40 00 67 d8 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025740: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025744: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2025748: 7f ff a0 03 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202574c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("fchmod: closing inode", rc);
2025750: 40 00 93 4c call 204a480 <__errno> <== NOT EXECUTED
2025754: 01 00 00 00 nop <== NOT EXECUTED
2025758: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
202575c: 81 c7 e0 08 ret <== NOT EXECUTED
2025760: 81 e8 00 00 restore <== NOT EXECUTED
2025764: 40 00 67 ce call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025768: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202576c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2025770: 7f ff 9f f9 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025774: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2025778: 81 c7 e0 08 ret <== NOT EXECUTED
202577c: 81 e8 00 00 restore <== NOT EXECUTED
#if defined (RTEMS_POSIX_API)
uid = geteuid();
if ((uid != rtems_rfs_inode_get_uid (&inode)) && (uid != 0))
{
rtems_rfs_inode_close (fs, &inode);
2025780: 40 00 77 23 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025784: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2025788: 7f ff fa 18 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
202578c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("fchmod: not owner", EPERM);
2025790: 40 00 93 3c call 204a480 <__errno> <== NOT EXECUTED
2025794: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025798: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
202579c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20257a0: 81 c7 e0 08 ret <== NOT EXECUTED
20257a4: 81 e8 00 00 restore <== NOT EXECUTED
02023fe0 <rtems_rfs_rtems_fcntl>:
int
rtems_rfs_rtems_fcntl (int cmd,
rtems_libio_t* iop)
{
return 0;
}
2023fe0: 81 c3 e0 08 retl <== NOT EXECUTED
2023fe4: 90 10 20 00 clr %o0 <== NOT EXECUTED
020242d4 <rtems_rfs_rtems_fdatasync>:
* @param iop
* @return int
*/
int
rtems_rfs_rtems_fdatasync (rtems_libio_t* iop)
{
20242d4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc;
rc = rtems_rfs_buffer_sync (rtems_rfs_rtems_pathloc_dev (&iop->pathinfo));
20242d8: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
if (rc)
20242dc: b0 10 20 00 clr %i0 <== NOT EXECUTED
int
rtems_rfs_rtems_fdatasync (rtems_libio_t* iop)
{
int rc;
rc = rtems_rfs_buffer_sync (rtems_rfs_rtems_pathloc_dev (&iop->pathinfo));
20242e0: 40 00 6d 02 call 203f6e8 <rtems_rfs_buffer_sync> <== NOT EXECUTED
20242e4: d0 00 60 34 ld [ %g1 + 0x34 ], %o0 <== NOT EXECUTED
if (rc)
20242e8: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
20242ec: 12 80 00 04 bne 20242fc <rtems_rfs_rtems_fdatasync+0x28> <== NOT EXECUTED
20242f0: 01 00 00 00 nop <== NOT EXECUTED
return rtems_rfs_rtems_error ("fdatasync: sync", rc);
return 0;
}
20242f4: 81 c7 e0 08 ret <== NOT EXECUTED
20242f8: 81 e8 00 00 restore <== NOT EXECUTED
{
int rc;
rc = rtems_rfs_buffer_sync (rtems_rfs_rtems_pathloc_dev (&iop->pathinfo));
if (rc)
return rtems_rfs_rtems_error ("fdatasync: sync", rc);
20242fc: 40 00 98 61 call 204a480 <__errno> <== NOT EXECUTED
2024300: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2024304: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
return 0;
}
2024308: 81 c7 e0 08 ret <== NOT EXECUTED
202430c: 81 e8 00 00 restore <== NOT EXECUTED
0204481c <rtems_rfs_rtems_file_close>:
* @param iop
* @return int
*/
static int
rtems_rfs_rtems_file_close (rtems_libio_t* iop)
{
204481c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_handle* file = iop->file_info;
2044820: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2044824: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_file_fs (file);
2044828: c2 04 60 1c ld [ %l1 + 0x1c ], %g1 <== NOT EXECUTED
204482c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044830: e0 00 60 98 ld [ %g1 + 0x98 ], %l0 <== NOT EXECUTED
2044834: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2044838: 7f ff 23 80 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
204483c: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_CLOSE))
printf("rtems-rfs: file-close: handle:%p\n", file);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_file_close (fs, file);
2044840: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044844: 7f ff f2 47 call 2041160 <rtems_rfs_file_close> <== NOT EXECUTED
2044848: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc > 0)
204484c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2044850: 24 80 00 07 ble,a 204486c <rtems_rfs_rtems_file_close+0x50><== NOT EXECUTED
2044854: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rc = rtems_rfs_rtems_error ("file-close: file close", rc);
2044858: 40 00 17 0a call 204a480 <__errno> <== NOT EXECUTED
204485c: 01 00 00 00 nop <== NOT EXECUTED
2044860: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED
2044864: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044868: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
204486c: 7f ff eb 8c call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044870: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044874: 7f ff 23 b8 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044878: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return rc;
}
204487c: 81 c7 e0 08 ret <== NOT EXECUTED
2044880: 81 e8 00 00 restore <== NOT EXECUTED
02044884 <rtems_rfs_rtems_file_ftruncate>:
* @return int
*/
int
rtems_rfs_rtems_file_ftruncate (rtems_libio_t* iop,
rtems_off64_t length)
{
2044884: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_handle* file = iop->file_info;
2044888: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
204488c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044890: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2044894: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044898: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
* @return int
*/
int
rtems_rfs_rtems_file_ftruncate (rtems_libio_t* iop,
rtems_off64_t length)
{
204489c: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
20448a0: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 <== NOT EXECUTED
20448a4: 7f ff 23 65 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20448a8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_FTRUNC))
printf("rtems-rfs: file-ftrunc: handle:%p length:%Ld\n", file, length);
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
rc = rtems_rfs_file_set_size (file, length);
20448ac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20448b0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
20448b4: 7f ff f0 a4 call 2040b44 <rtems_rfs_file_set_size> <== NOT EXECUTED
20448b8: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (rc)
20448bc: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20448c0: 22 80 00 07 be,a 20448dc <rtems_rfs_rtems_file_ftruncate+0x58><== NOT EXECUTED
20448c4: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
rc = rtems_rfs_rtems_error ("file_ftruncate: set size", rc);
20448c8: 40 00 16 ee call 204a480 <__errno> <== NOT EXECUTED
20448cc: 01 00 00 00 nop <== NOT EXECUTED
20448d0: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED
20448d4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
iop->size = rtems_rfs_file_size (file);
20448d8: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
20448dc: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
20448e0: 7f ff e7 8a call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
20448e4: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
20448e8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
rc = rtems_rfs_file_set_size (file, length);
if (rc)
rc = rtems_rfs_rtems_error ("file_ftruncate: set size", rc);
iop->size = rtems_rfs_file_size (file);
20448ec: d0 3c 60 08 std %o0, [ %l1 + 8 ] <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
20448f0: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
20448f4: 7f ff eb 6a call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20448f8: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20448fc: 7f ff 23 96 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044900: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return rc;
}
2044904: 81 c7 e0 08 ret <== NOT EXECUTED
2044908: 81 e8 00 00 restore <== NOT EXECUTED
020446c4 <rtems_rfs_rtems_file_ioctl>:
int
rtems_rfs_rtems_file_ioctl (rtems_libio_t* iop, uint32_t command, void* buffer)
{
return 0;
}
20446c4: 81 c3 e0 08 retl <== NOT EXECUTED
20446c8: 90 10 20 00 clr %o0 <== NOT EXECUTED
02044b04 <rtems_rfs_rtems_file_lseek>:
*/
rtems_off64_t
rtems_rfs_rtems_file_lseek (rtems_libio_t* iop,
rtems_off64_t offset,
int whence)
{
2044b04: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_handle* file = iop->file_info;
2044b08: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2044b0c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044b10: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2044b14: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044b18: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
2044b1c: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 <== NOT EXECUTED
2044b20: 7f ff 22 c6 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2044b24: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_LSEEK))
printf("rtems-rfs: file-lseek: handle:%p offset:%Ld\n", file, offset);
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
2044b28: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
rc = rtems_rfs_file_seek (file, pos, &pos);
2044b2c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_LSEEK))
printf("rtems-rfs: file-lseek: handle:%p offset:%Ld\n", file, offset);
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
2044b30: c4 3f bf f8 std %g2, [ %fp + -8 ] <== NOT EXECUTED
rc = rtems_rfs_file_seek (file, pos, &pos);
2044b34: 92 10 00 02 mov %g2, %o1 <== NOT EXECUTED
2044b38: 94 10 00 03 mov %g3, %o2 <== NOT EXECUTED
2044b3c: 7f ff f0 cb call 2040e68 <rtems_rfs_file_seek> <== NOT EXECUTED
2044b40: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
if (rc)
2044b44: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2044b48: 02 80 00 10 be 2044b88 <rtems_rfs_rtems_file_lseek+0x84> <== NOT EXECUTED
2044b4c: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044b50: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2044b54: 7f ff ea d2 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044b58: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044b5c: 7f ff 22 fe call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044b60: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("file_lseek: lseek", rc);
2044b64: 40 00 16 47 call 204a480 <__errno> <== NOT EXECUTED
2044b68: 01 00 00 00 nop <== NOT EXECUTED
2044b6c: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED
2044b70: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2044b74: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED
2044b78: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
return iop->offset;
}
2044b7c: b0 10 00 02 mov %g2, %i0 <== NOT EXECUTED
2044b80: 81 c7 e0 08 ret <== NOT EXECUTED
2044b84: 93 e8 00 03 restore %g0, %g3, %o1 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
return rtems_rfs_rtems_error ("file_lseek: lseek", rc);
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044b88: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2044b8c: 7f ff ea c4 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044b90: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
2044b94: 7f ff 22 f0 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044b98: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return iop->offset;
2044b9c: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
}
2044ba0: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED
2044ba4: 81 c7 e0 08 ret <== NOT EXECUTED
2044ba8: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
02044bac <rtems_rfs_rtems_file_open>:
static int
rtems_rfs_rtems_file_open (rtems_libio_t* iop,
const char* pathname,
uint32_t flag,
uint32_t mode)
{
2044bac: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
2044bb0: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2044bb4: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044bb8: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
2044bbc: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044bc0: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2044bc4: 7f ff 22 9d call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2044bc8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_lock (fs);
ino = rtems_rfs_rtems_get_iop_ino (iop);
rc = rtems_rfs_file_open (fs, ino, flags, &file);
2044bcc: d2 06 20 3c ld [ %i0 + 0x3c ], %o1 <== NOT EXECUTED
2044bd0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044bd4: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044bd8: 7f ff f1 d6 call 2041330 <rtems_rfs_file_open> <== NOT EXECUTED
2044bdc: 96 07 bf fc add %fp, -4, %o3 <== NOT EXECUTED
if (rc > 0)
2044be0: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2044be4: 04 80 00 0d ble 2044c18 <rtems_rfs_rtems_file_open+0x6c> <== NOT EXECUTED
2044be8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044bec: f0 04 20 7c ld [ %l0 + 0x7c ], %i0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044bf0: 7f ff ea ab call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044bf4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044bf8: d0 06 00 00 ld [ %i0 ], %o0 <== NOT EXECUTED
2044bfc: 7f ff 22 d6 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044c00: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("file-open: open", rc);
2044c04: 40 00 16 1f call 204a480 <__errno> <== NOT EXECUTED
2044c08: 01 00 00 00 nop <== NOT EXECUTED
2044c0c: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2044c10: 81 c7 e0 08 ret <== NOT EXECUTED
2044c14: 81 e8 00 00 restore <== NOT EXECUTED
}
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_OPEN))
printf("rtems-rfs: file-open: handle:%p\n", file);
iop->size = rtems_rfs_file_size (file);
2044c18: d2 00 60 1c ld [ %g1 + 0x1c ], %o1 <== NOT EXECUTED
2044c1c: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2044c20: 7f ff e6 ba call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2044c24: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
iop->file_info = file;
2044c28: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
}
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_OPEN))
printf("rtems-rfs: file-open: handle:%p\n", file);
iop->size = rtems_rfs_file_size (file);
2044c2c: d0 3e 20 08 std %o0, [ %i0 + 8 ] <== NOT EXECUTED
iop->file_info = file;
2044c30: c2 26 20 3c st %g1, [ %i0 + 0x3c ] <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2044c34: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2044c38: 7f ff ea 99 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044c3c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044c40: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2044c44: 7f ff 22 c4 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044c48: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
return 0;
}
2044c4c: 81 c7 e0 08 ret <== NOT EXECUTED
2044c50: 81 e8 00 00 restore <== NOT EXECUTED
020446cc <rtems_rfs_rtems_file_read>:
*/
ssize_t
rtems_rfs_rtems_file_read (rtems_libio_t* iop,
void* buffer,
size_t count)
{
20446cc: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_handle* file = iop->file_info;
20446d0: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20446d4: 92 10 20 00 clr %o1 <== NOT EXECUTED
20446d8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
20446dc: 94 10 20 00 clr %o2 <== NOT EXECUTED
20446e0: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
20446e4: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 <== NOT EXECUTED
20446e8: 7f ff 23 d4 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20446ec: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
if (pos < rtems_rfs_file_size (file))
20446f0: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_READ))
printf("rtems-rfs: file-read: handle:%p count:%zd\n", file, count);
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
20446f4: e2 06 20 10 ld [ %i0 + 0x10 ], %l1 <== NOT EXECUTED
20446f8: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
20446fc: e4 06 20 14 ld [ %i0 + 0x14 ], %l2 <== NOT EXECUTED
2044700: 7f ff e8 02 call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2044704: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
if (pos < rtems_rfs_file_size (file))
2044708: 80 a2 00 11 cmp %o0, %l1 <== NOT EXECUTED
204470c: 08 80 00 33 bleu 20447d8 <rtems_rfs_rtems_file_read+0x10c><== NOT EXECUTED
2044710: b0 10 20 00 clr %i0 <== NOT EXECUTED
{
while (count)
2044714: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2044718: 12 80 00 07 bne 2044734 <rtems_rfs_rtems_file_read+0x68> <== NOT EXECUTED
204471c: a4 07 bf fc add %fp, -4, %l2 <== NOT EXECUTED
break;
}
}
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044720: 10 80 00 34 b 20447f0 <rtems_rfs_rtems_file_read+0x124> <== NOT EXECUTED
2044724: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
pos = iop->offset;
if (pos < rtems_rfs_file_size (file))
{
while (count)
2044728: b4 a6 80 11 subcc %i2, %l1, %i2 <== NOT EXECUTED
204472c: 02 80 00 23 be 20447b8 <rtems_rfs_rtems_file_read+0xec> <== NOT EXECUTED
2044730: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
{
size_t size;
rc = rtems_rfs_file_io_start (file, &size, true);
2044734: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044738: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
204473c: 7f ff f0 9c call 20409ac <rtems_rfs_file_io_start> <== NOT EXECUTED
2044740: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2044744: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
if (rc > 0)
2044748: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
204474c: 14 80 00 30 bg 204480c <rtems_rfs_rtems_file_read+0x140> <== NOT EXECUTED
2044750: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
{
read = rtems_rfs_rtems_error ("file-read: read: io-start", rc);
break;
}
if (size == 0)
2044754: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
2044758: 80 a2 a0 00 cmp %o2, 0 <== NOT EXECUTED
204475c: 02 80 00 17 be 20447b8 <rtems_rfs_rtems_file_read+0xec> <== NOT EXECUTED
2044760: 80 a2 80 1a cmp %o2, %i2 <== NOT EXECUTED
break;
if (size > count)
2044764: 28 80 00 05 bleu,a 2044778 <rtems_rfs_rtems_file_read+0xac><== NOT EXECUTED
2044768: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
size = count;
204476c: f4 27 bf fc st %i2, [ %fp + -4 ] <== NOT EXECUTED
2044770: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
memcpy (data, rtems_rfs_file_data (file), size);
2044774: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
2044778: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
204477c: d2 00 a0 24 ld [ %g2 + 0x24 ], %o1 <== NOT EXECUTED
2044780: 40 00 24 8c call 204d9b0 <memcpy> <== NOT EXECUTED
2044784: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED
data += size;
2044788: e2 07 bf fc ld [ %fp + -4 ], %l1 <== NOT EXECUTED
count -= size;
read += size;
rc = rtems_rfs_file_io_end (file, size, true);
204478c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044790: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2044794: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2044798: 7f ff f1 ea call 2040f40 <rtems_rfs_file_io_end> <== NOT EXECUTED
204479c: b2 06 40 11 add %i1, %l1, %i1 <== NOT EXECUTED
if (rc > 0)
20447a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20447a4: 04 bf ff e1 ble 2044728 <rtems_rfs_rtems_file_read+0x5c> <== NOT EXECUTED
20447a8: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
{
read = rtems_rfs_rtems_error ("file-read: read: io-end", rc);
20447ac: 40 00 17 35 call 204a480 <__errno> <== NOT EXECUTED
20447b0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20447b4: e6 22 00 00 st %l3, [ %o0 ] <== NOT EXECUTED
break;
}
}
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
20447b8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
20447bc: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
20447c0: 7f ff eb b7 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20447c4: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20447c8: 7f ff 23 e3 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20447cc: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return read;
}
20447d0: 81 c7 e0 08 ret <== NOT EXECUTED
20447d4: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
if (pos < rtems_rfs_file_size (file))
20447d8: 12 80 00 04 bne 20447e8 <rtems_rfs_rtems_file_read+0x11c> <== NOT EXECUTED
20447dc: 80 a2 40 12 cmp %o1, %l2 <== NOT EXECUTED
20447e0: 38 bf ff cd bgu,a 2044714 <rtems_rfs_rtems_file_read+0x48><== NOT EXECUTED
20447e4: b0 10 20 00 clr %i0 <== NOT EXECUTED
break;
}
}
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
20447e8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
if (size > count)
size = count;
memcpy (data, rtems_rfs_file_data (file), size);
data += size;
20447ec: b0 10 20 00 clr %i0 <== NOT EXECUTED
break;
}
}
}
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
20447f0: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
20447f4: 7f ff eb aa call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20447f8: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
20447fc: 7f ff 23 d6 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044800: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return read;
}
2044804: 81 c7 e0 08 ret <== NOT EXECUTED
2044808: 81 e8 00 00 restore <== NOT EXECUTED
size_t size;
rc = rtems_rfs_file_io_start (file, &size, true);
if (rc > 0)
{
read = rtems_rfs_rtems_error ("file-read: read: io-start", rc);
204480c: 40 00 17 1d call 204a480 <__errno> <== NOT EXECUTED
2044810: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2044814: 10 bf ff e9 b 20447b8 <rtems_rfs_rtems_file_read+0xec> <== NOT EXECUTED
2044818: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
0204490c <rtems_rfs_rtems_file_write>:
*/
ssize_t
rtems_rfs_rtems_file_write (rtems_libio_t* iop,
const void* buffer,
size_t count)
{
204490c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_handle* file = iop->file_info;
2044910: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2044914: 92 10 20 00 clr %o1 <== NOT EXECUTED
2044918: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
204491c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044920: c2 00 60 98 ld [ %g1 + 0x98 ], %g1 <== NOT EXECUTED
*/
ssize_t
rtems_rfs_rtems_file_write (rtems_libio_t* iop,
const void* buffer,
size_t count)
{
2044924: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
2044928: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 <== NOT EXECUTED
204492c: 7f ff 23 43 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2044930: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
* size of file we are still past the end of the file as positions number
* from 0. For a specific position we need a file that has a length of one
* more.
*/
if (pos >= rtems_rfs_file_size (file))
2044934: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_WRITE))
printf("rtems-rfs: file-write: handle:%p count:%zd\n", file, count);
rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));
pos = iop->offset;
2044938: e4 1e 20 10 ldd [ %i0 + 0x10 ], %l2 <== NOT EXECUTED
204493c: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2044940: 7f ff e7 72 call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2044944: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
* size of file we are still past the end of the file as positions number
* from 0. For a specific position we need a file that has a length of one
* more.
*/
if (pos >= rtems_rfs_file_size (file))
2044948: 80 a2 00 12 cmp %o0, %l2 <== NOT EXECUTED
204494c: 38 80 00 0e bgu,a 2044984 <rtems_rfs_rtems_file_write+0x78><== NOT EXECUTED
2044950: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
2044954: 80 a2 00 12 cmp %o0, %l2 <== NOT EXECUTED
2044958: 02 80 00 45 be 2044a6c <rtems_rfs_rtems_file_write+0x160> <== NOT EXECUTED
204495c: 80 a2 40 13 cmp %o1, %l3 <== NOT EXECUTED
{
rc = rtems_rfs_file_set_size (file, pos + 1);
2044960: 86 84 e0 01 addcc %l3, 1, %g3 <== NOT EXECUTED
2044964: 84 44 a0 00 addx %l2, 0, %g2 <== NOT EXECUTED
2044968: 94 10 00 03 mov %g3, %o2 <== NOT EXECUTED
204496c: 92 10 00 02 mov %g2, %o1 <== NOT EXECUTED
2044970: 7f ff f0 75 call 2040b44 <rtems_rfs_file_set_size> <== NOT EXECUTED
2044974: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc)
2044978: a8 92 20 00 orcc %o0, 0, %l4 <== NOT EXECUTED
204497c: 12 80 00 47 bne 2044a98 <rtems_rfs_rtems_file_write+0x18c><== NOT EXECUTED
2044980: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
return rtems_rfs_rtems_error ("file-write: write extend", rc);
}
}
rtems_rfs_file_set_bpos (file, pos);
2044984: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044988: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
204498c: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
2044990: 7f ff e7 2f call 203e64c <rtems_rfs_block_get_bpos> <== NOT EXECUTED
2044994: 96 04 20 10 add %l0, 0x10, %o3 <== NOT EXECUTED
while (count)
2044998: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
204499c: 02 80 00 27 be 2044a38 <rtems_rfs_rtems_file_write+0x12c> <== NOT EXECUTED
20449a0: b0 10 20 00 clr %i0 <== NOT EXECUTED
20449a4: 10 80 00 05 b 20449b8 <rtems_rfs_rtems_file_write+0xac> <== NOT EXECUTED
20449a8: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED
20449ac: b4 a6 80 12 subcc %i2, %l2, %i2 <== NOT EXECUTED
20449b0: 02 80 00 22 be 2044a38 <rtems_rfs_rtems_file_write+0x12c> <== NOT EXECUTED
20449b4: b0 06 00 12 add %i0, %l2, %i0 <== NOT EXECUTED
{
size_t size = count;
rc = rtems_rfs_file_io_start (file, &size, false);
20449b8: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
rtems_rfs_file_set_bpos (file, pos);
while (count)
{
size_t size = count;
20449bc: f4 27 bf fc st %i2, [ %fp + -4 ] <== NOT EXECUTED
rc = rtems_rfs_file_io_start (file, &size, false);
20449c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20449c4: 7f ff ef fa call 20409ac <rtems_rfs_file_io_start> <== NOT EXECUTED
20449c8: 94 10 20 00 clr %o2 <== NOT EXECUTED
}
if (size > count)
size = count;
memcpy (rtems_rfs_file_data (file), data, size);
20449cc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
while (count)
{
size_t size = count;
rc = rtems_rfs_file_io_start (file, &size, false);
if (rc)
20449d0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20449d4: 12 80 00 3c bne 2044ac4 <rtems_rfs_rtems_file_write+0x1b8><== NOT EXECUTED
20449d8: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
{
write = rtems_rfs_rtems_error ("file-write: write open", rc);
break;
}
if (size > count)
20449dc: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
20449e0: 80 a2 80 1a cmp %o2, %i2 <== NOT EXECUTED
20449e4: 28 80 00 05 bleu,a 20449f8 <rtems_rfs_rtems_file_write+0xec><== NOT EXECUTED
20449e8: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
size = count;
20449ec: f4 27 bf fc st %i2, [ %fp + -4 ] <== NOT EXECUTED
20449f0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
memcpy (rtems_rfs_file_data (file), data, size);
20449f4: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
20449f8: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
20449fc: d0 00 a0 24 ld [ %g2 + 0x24 ], %o0 <== NOT EXECUTED
2044a00: 40 00 23 ec call 204d9b0 <memcpy> <== NOT EXECUTED
2044a04: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
data += size;
2044a08: e4 07 bf fc ld [ %fp + -4 ], %l2 <== NOT EXECUTED
count -= size;
write += size;
rc = rtems_rfs_file_io_end (file, size, false);
2044a0c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2044a10: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2044a14: 94 10 20 00 clr %o2 <== NOT EXECUTED
2044a18: 7f ff f1 4a call 2040f40 <rtems_rfs_file_io_end> <== NOT EXECUTED
2044a1c: b2 06 40 12 add %i1, %l2, %i1 <== NOT EXECUTED
if (rc)
2044a20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2044a24: 02 bf ff e2 be 20449ac <rtems_rfs_rtems_file_write+0xa0> <== NOT EXECUTED
2044a28: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
{
write = rtems_rfs_rtems_error ("file-write: write close", rc);
2044a2c: 40 00 16 95 call 204a480 <__errno> <== NOT EXECUTED
2044a30: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2044a34: e8 22 00 00 st %l4, [ %o0 ] <== NOT EXECUTED
break;
}
}
iop->size = rtems_rfs_file_size (file);
2044a38: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
2044a3c: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2044a40: 7f ff e7 32 call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2044a44: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044a48: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
write = rtems_rfs_rtems_error ("file-write: write close", rc);
break;
}
}
iop->size = rtems_rfs_file_size (file);
2044a4c: d0 3c 60 08 std %o0, [ %l1 + 8 ] <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044a50: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2044a54: 7f ff eb 12 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044a58: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2044a5c: 7f ff 23 3e call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044a60: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return write;
}
2044a64: 81 c7 e0 08 ret <== NOT EXECUTED
2044a68: 81 e8 00 00 restore <== NOT EXECUTED
* size of file we are still past the end of the file as positions number
* from 0. For a specific position we need a file that has a length of one
* more.
*/
if (pos >= rtems_rfs_file_size (file))
2044a6c: 38 bf ff c6 bgu,a 2044984 <rtems_rfs_rtems_file_write+0x78><== NOT EXECUTED
2044a70: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
{
rc = rtems_rfs_file_set_size (file, pos + 1);
2044a74: 86 84 e0 01 addcc %l3, 1, %g3 <== NOT EXECUTED
2044a78: 84 44 a0 00 addx %l2, 0, %g2 <== NOT EXECUTED
2044a7c: 94 10 00 03 mov %g3, %o2 <== NOT EXECUTED
2044a80: 92 10 00 02 mov %g2, %o1 <== NOT EXECUTED
2044a84: 7f ff f0 30 call 2040b44 <rtems_rfs_file_set_size> <== NOT EXECUTED
2044a88: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc)
2044a8c: a8 92 20 00 orcc %o0, 0, %l4 <== NOT EXECUTED
2044a90: 02 bf ff bd be 2044984 <rtems_rfs_rtems_file_write+0x78> <== NOT EXECUTED
2044a94: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
return rtems_rfs_rtems_error ("file-write: write extend", rc);
2044a98: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
if (pos >= rtems_rfs_file_size (file))
{
rc = rtems_rfs_file_set_size (file, pos + 1);
if (rc)
{
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044a9c: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2044aa0: 7f ff ea ff call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044aa4: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
2044aa8: 7f ff 23 2b call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044aac: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("file-write: write extend", rc);
2044ab0: 40 00 16 74 call 204a480 <__errno> <== NOT EXECUTED
2044ab4: 01 00 00 00 nop <== NOT EXECUTED
2044ab8: e8 22 00 00 st %l4, [ %o0 ] <== NOT EXECUTED
2044abc: 81 c7 e0 08 ret <== NOT EXECUTED
2044ac0: 81 e8 00 00 restore <== NOT EXECUTED
size_t size = count;
rc = rtems_rfs_file_io_start (file, &size, false);
if (rc)
{
write = rtems_rfs_rtems_error ("file-write: write open", rc);
2044ac4: 40 00 16 6f call 204a480 <__errno> <== NOT EXECUTED
2044ac8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
write = rtems_rfs_rtems_error ("file-write: write close", rc);
break;
}
}
iop->size = rtems_rfs_file_size (file);
2044acc: d2 04 20 1c ld [ %l0 + 0x1c ], %o1 <== NOT EXECUTED
size_t size = count;
rc = rtems_rfs_file_io_start (file, &size, false);
if (rc)
{
write = rtems_rfs_rtems_error ("file-write: write open", rc);
2044ad0: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2044ad4: d0 02 60 98 ld [ %o1 + 0x98 ], %o0 <== NOT EXECUTED
2044ad8: 7f ff e7 0c call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2044adc: 92 02 60 84 add %o1, 0x84, %o1 <== NOT EXECUTED
}
}
iop->size = rtems_rfs_file_size (file);
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044ae0: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED
write = rtems_rfs_rtems_error ("file-write: write close", rc);
break;
}
}
iop->size = rtems_rfs_file_size (file);
2044ae4: d0 3c 60 08 std %o0, [ %l1 + 8 ] <== NOT EXECUTED
rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));
2044ae8: d0 00 60 98 ld [ %g1 + 0x98 ], %o0 <== NOT EXECUTED
2044aec: 7f ff ea ec call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2044af0: e0 02 20 7c ld [ %o0 + 0x7c ], %l0 <== NOT EXECUTED
2044af4: 7f ff 23 18 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2044af8: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
return write;
}
2044afc: 81 c7 e0 08 ret <== NOT EXECUTED
2044b00: 81 e8 00 00 restore <== NOT EXECUTED
02023fd8 <rtems_rfs_rtems_freenodinfo>:
int
rtems_rfs_rtems_freenodinfo (rtems_filesystem_location_info_t* pathloc)
{
return 0;
}
2023fd8: 81 c3 e0 08 retl <== NOT EXECUTED
2023fdc: 90 10 20 00 clr %o0 <== NOT EXECUTED
02025a50 <rtems_rfs_rtems_imode>:
{
/*
* Mapping matches RTEMS so no need to change.
*/
return mode;
}
2025a50: 81 c3 e0 08 retl <== NOT EXECUTED
02024048 <rtems_rfs_rtems_initialise>:
*/
int
rtems_rfs_rtems_initialise (rtems_filesystem_mount_table_entry_t* mt_entry,
const void* data)
{
2024048: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int rc;
/*
* Parse the options the user specifiies.
*/
while (options)
202404c: a8 10 20 05 mov 5, %l4 <== NOT EXECUTED
2024050: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2024054: 02 80 00 1f be 20240d0 <rtems_rfs_rtems_initialise+0x88> <== NOT EXECUTED
2024058: a2 10 20 00 clr %l1 <== NOT EXECUTED
202405c: 25 00 81 a6 sethi %hi(0x2069800), %l2 <== NOT EXECUTED
2024060: 21 00 81 a6 sethi %hi(0x2069800), %l0 <== NOT EXECUTED
{
printf ("options=%s\n", options);
if (strncmp (options, "hold-bitmaps",
sizeof ("hold-bitmaps") - 1) == 0)
flags |= RTEMS_RFS_FS_BITMAPS_HOLD;
else if (strncmp (options, "no-local-cache",
2024064: 27 00 81 a6 sethi %hi(0x2069800), %l3 <== NOT EXECUTED
sizeof ("no-local-cache") - 1) == 0)
flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;
else if (strncmp (options, "max-held-bufs",
2024068: 2b 00 81 a6 sethi %hi(0x2069800), %l5 <== NOT EXECUTED
/*
* Parse the options the user specifiies.
*/
while (options)
{
printf ("options=%s\n", options);
202406c: a4 14 a1 d8 or %l2, 0x1d8, %l2 <== NOT EXECUTED
if (strncmp (options, "hold-bitmaps",
2024070: a0 14 21 e8 or %l0, 0x1e8, %l0 <== NOT EXECUTED
sizeof ("hold-bitmaps") - 1) == 0)
flags |= RTEMS_RFS_FS_BITMAPS_HOLD;
else if (strncmp (options, "no-local-cache",
2024074: a6 14 e1 f8 or %l3, 0x1f8, %l3 <== NOT EXECUTED
sizeof ("no-local-cache") - 1) == 0)
flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;
else if (strncmp (options, "max-held-bufs",
2024078: aa 15 62 08 or %l5, 0x208, %l5 <== NOT EXECUTED
/*
* Parse the options the user specifiies.
*/
while (options)
{
printf ("options=%s\n", options);
202407c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2024080: 40 00 aa fb call 204ec6c <printf> <== NOT EXECUTED
2024084: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if (strncmp (options, "hold-bitmaps",
2024088: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
202408c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2024090: 40 00 b5 20 call 2051510 <strncmp> <== NOT EXECUTED
2024094: 94 10 20 0c mov 0xc, %o2 <== NOT EXECUTED
2024098: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202409c: 12 80 00 1e bne 2024114 <rtems_rfs_rtems_initialise+0xcc> <== NOT EXECUTED
20240a0: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
sizeof ("hold-bitmaps") - 1) == 0)
flags |= RTEMS_RFS_FS_BITMAPS_HOLD;
20240a4: a2 14 60 01 or %l1, 1, %l1 <== NOT EXECUTED
max_held_buffers = strtoul (options + sizeof ("max-held-bufs"), 0, 0);
}
else
return rtems_rfs_rtems_error ("initialise: invalid option", EINVAL);
options = strchr (options, ',');
20240a8: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
20240ac: 40 00 b2 3d call 20509a0 <strchr> <== NOT EXECUTED
20240b0: 92 10 20 2c mov 0x2c, %o1 <== NOT EXECUTED
if (options)
20240b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20240b8: 02 80 00 06 be 20240d0 <rtems_rfs_rtems_initialise+0x88> <== NOT EXECUTED
20240bc: 01 00 00 00 nop <== NOT EXECUTED
{
++options;
if (*options == '\0')
20240c0: c2 4a 20 01 ldsb [ %o0 + 1 ], %g1 <== NOT EXECUTED
20240c4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20240c8: 12 bf ff ed bne 202407c <rtems_rfs_rtems_initialise+0x34> <== NOT EXECUTED
20240cc: b2 02 20 01 add %o0, 1, %i1 <== NOT EXECUTED
options = NULL;
}
}
rtems = malloc (sizeof (rtems_rfs_rtems_private));
20240d0: 7f ff 93 e4 call 2009060 <malloc> <== NOT EXECUTED
20240d4: 90 10 20 04 mov 4, %o0 <== NOT EXECUTED
if (!rtems)
20240d8: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED
20240dc: 02 80 00 53 be 2024228 <rtems_rfs_rtems_initialise+0x1e0> <== NOT EXECUTED
20240e0: 01 00 00 00 nop <== NOT EXECUTED
return rtems_rfs_rtems_error ("initialise: local data", ENOMEM);
memset (rtems, 0, sizeof (rtems_rfs_rtems_private));
rc = rtems_rfs_mutex_create (&rtems->access);
20240e4: 40 00 7f e3 call 2044070 <rtems_rfs_mutex_create> <== NOT EXECUTED
20240e8: c0 24 00 00 clr [ %l0 ] <== NOT EXECUTED
if (rc > 0)
20240ec: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20240f0: 24 80 00 1c ble,a 2024160 <rtems_rfs_rtems_initialise+0x118><== NOT EXECUTED
20240f4: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED
{
free (rtems);
20240f8: 7f ff 91 f9 call 20088dc <free> <== NOT EXECUTED
20240fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("initialise: cannot create mutex", rc);
2024100: 40 00 98 e0 call 204a480 <__errno> <== NOT EXECUTED
2024104: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2024108: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
202410c: 81 c7 e0 08 ret <== NOT EXECUTED
2024110: 81 e8 00 00 restore <== NOT EXECUTED
{
printf ("options=%s\n", options);
if (strncmp (options, "hold-bitmaps",
sizeof ("hold-bitmaps") - 1) == 0)
flags |= RTEMS_RFS_FS_BITMAPS_HOLD;
else if (strncmp (options, "no-local-cache",
2024114: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2024118: 40 00 b4 fe call 2051510 <strncmp> <== NOT EXECUTED
202411c: 94 10 20 0e mov 0xe, %o2 <== NOT EXECUTED
2024120: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024124: 12 80 00 04 bne 2024134 <rtems_rfs_rtems_initialise+0xec> <== NOT EXECUTED
2024128: 92 10 00 15 mov %l5, %o1 <== NOT EXECUTED
sizeof ("no-local-cache") - 1) == 0)
flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;
202412c: 10 bf ff df b 20240a8 <rtems_rfs_rtems_initialise+0x60> <== NOT EXECUTED
2024130: a2 14 60 02 or %l1, 2, %l1 <== NOT EXECUTED
else if (strncmp (options, "max-held-bufs",
2024134: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2024138: 40 00 b4 f6 call 2051510 <strncmp> <== NOT EXECUTED
202413c: 94 10 20 0d mov 0xd, %o2 <== NOT EXECUTED
2024140: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024144: 12 80 00 26 bne 20241dc <rtems_rfs_rtems_initialise+0x194><== NOT EXECUTED
2024148: 90 06 60 0e add %i1, 0xe, %o0 <== NOT EXECUTED
sizeof ("max-held-bufs") - 1) == 0)
{
max_held_buffers = strtoul (options + sizeof ("max-held-bufs"), 0, 0);
202414c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024150: 40 00 ba 3d call 2052a44 <strtoul> <== NOT EXECUTED
2024154: 94 10 20 00 clr %o2 <== NOT EXECUTED
2024158: 10 bf ff d4 b 20240a8 <rtems_rfs_rtems_initialise+0x60> <== NOT EXECUTED
202415c: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024160: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024164: 7f ff a5 35 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024168: 94 10 20 00 clr %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
202416c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024170: 12 80 00 11 bne 20241b4 <rtems_rfs_rtems_initialise+0x16c><== NOT EXECUTED
2024174: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
rtems_rfs_mutex_destroy (&rtems->access);
free (rtems);
return rtems_rfs_rtems_error ("initialise: cannot lock access mutex", rc);
}
rc = rtems_rfs_fs_open (mt_entry->dev, rtems, flags, max_held_buffers, &fs);
2024178: d0 06 20 70 ld [ %i0 + 0x70 ], %o0 <== NOT EXECUTED
202417c: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
2024180: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2024184: 40 00 75 37 call 2041660 <rtems_rfs_fs_open> <== NOT EXECUTED
2024188: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
if (rc)
202418c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024190: 02 80 00 19 be 20241f4 <rtems_rfs_rtems_initialise+0x1ac> <== NOT EXECUTED
2024194: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
{
free (rtems);
2024198: 7f ff 91 d1 call 20088dc <free> <== NOT EXECUTED
202419c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("initialise: open", rc);
20241a0: 40 00 98 b8 call 204a480 <__errno> <== NOT EXECUTED
20241a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20241a8: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20241ac: 81 c7 e0 08 ret <== NOT EXECUTED
20241b0: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_mutex_lock (&rtems->access);
if (rc > 0)
{
rtems_rfs_mutex_destroy (&rtems->access);
20241b4: 40 00 7f a7 call 2044050 <rtems_rfs_mutex_destroy> <== NOT EXECUTED
20241b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
free (rtems);
20241bc: 7f ff 91 c8 call 20088dc <free> <== NOT EXECUTED
20241c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("initialise: cannot lock access mutex", rc);
20241c4: 40 00 98 af call 204a480 <__errno> <== NOT EXECUTED
20241c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20241cc: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
20241d0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20241d4: 81 c7 e0 08 ret <== NOT EXECUTED
20241d8: 81 e8 00 00 restore <== NOT EXECUTED
sizeof ("max-held-bufs") - 1) == 0)
{
max_held_buffers = strtoul (options + sizeof ("max-held-bufs"), 0, 0);
}
else
return rtems_rfs_rtems_error ("initialise: invalid option", EINVAL);
20241dc: 40 00 98 a9 call 204a480 <__errno> <== NOT EXECUTED
20241e0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20241e4: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
20241e8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20241ec: 81 c7 e0 08 ret <== NOT EXECUTED
20241f0: 81 e8 00 00 restore <== NOT EXECUTED
{
free (rtems);
return rtems_rfs_rtems_error ("initialise: open", rc);
}
mt_entry->fs_info = fs;
20241f4: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
mt_entry->mt_fs_root.node_access = (void*) RTEMS_RFS_ROOT_INO;
20241f8: c2 26 20 1c st %g1, [ %i0 + 0x1c ] <== NOT EXECUTED
mt_entry->mt_fs_root.handlers = &rtems_rfs_rtems_dir_handlers;
20241fc: 03 00 81 bb sethi %hi(0x206ec00), %g1 <== NOT EXECUTED
2024200: 82 10 61 48 or %g1, 0x148, %g1 ! 206ed48 <rtems_rfs_rtems_dir_handlers><== NOT EXECUTED
2024204: c2 26 20 24 st %g1, [ %i0 + 0x24 ] <== NOT EXECUTED
mt_entry->mt_fs_root.ops = &rtems_rfs_ops;
2024208: 03 00 81 a6 sethi %hi(0x2069800), %g1 <== NOT EXECUTED
202420c: 82 10 62 58 or %g1, 0x258, %g1 ! 2069a58 <rtems_rfs_ops> <== NOT EXECUTED
{
free (rtems);
return rtems_rfs_rtems_error ("initialise: open", rc);
}
mt_entry->fs_info = fs;
2024210: d0 26 20 34 st %o0, [ %i0 + 0x34 ] <== NOT EXECUTED
mt_entry->mt_fs_root.node_access = (void*) RTEMS_RFS_ROOT_INO;
mt_entry->mt_fs_root.handlers = &rtems_rfs_rtems_dir_handlers;
mt_entry->mt_fs_root.ops = &rtems_rfs_ops;
2024214: c2 26 20 28 st %g1, [ %i0 + 0x28 ] <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2024218: 7f ff ff 74 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
202421c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
2024220: 81 c7 e0 08 ret <== NOT EXECUTED
2024224: 81 e8 00 00 restore <== NOT EXECUTED
}
}
rtems = malloc (sizeof (rtems_rfs_rtems_private));
if (!rtems)
return rtems_rfs_rtems_error ("initialise: local data", ENOMEM);
2024228: 40 00 98 96 call 204a480 <__errno> <== NOT EXECUTED
202422c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2024230: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED
2024234: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2024238: 81 c7 e0 08 ret <== NOT EXECUTED
202423c: 81 e8 00 00 restore <== NOT EXECUTED
02024900 <rtems_rfs_rtems_link>:
*/
int
rtems_rfs_rtems_link (rtems_filesystem_location_info_t* to_loc,
rtems_filesystem_location_info_t* parent_loc,
const char* name)
{
2024900: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (to_loc);
2024904: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino target = rtems_rfs_rtems_get_pathloc_ino (to_loc);
2024908: e2 06 00 00 ld [ %i0 ], %l1 <== NOT EXECUTED
int
rtems_rfs_rtems_link (rtems_filesystem_location_info_t* to_loc,
rtems_filesystem_location_info_t* parent_loc,
const char* name)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (to_loc);
202490c: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024910: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024914: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2024918: 94 10 20 00 clr %o2 <== NOT EXECUTED
202491c: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2024920: 7f ff a3 46 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024924: e4 06 40 00 ld [ %i1 ], %l2 <== NOT EXECUTED
printf ("rtems-rfs-rtems: link: in: parent:%" PRId32 " target:%" PRId32 "\n",
parent, target);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_link (fs, name, strlen (name), parent, target, false);
2024928: 40 00 b2 92 call 2051370 <strlen> <== NOT EXECUTED
202492c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2024930: 98 10 00 11 mov %l1, %o4 <== NOT EXECUTED
2024934: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2024938: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
202493c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024940: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
2024944: 40 00 7d 66 call 2043edc <rtems_rfs_link> <== NOT EXECUTED
2024948: 9a 10 20 00 clr %o5 <== NOT EXECUTED
if (rc)
202494c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024950: 22 80 00 0d be,a 2024984 <rtems_rfs_rtems_link+0x84> <== NOT EXECUTED
2024954: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024958: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
202495c: 40 00 6b 50 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024960: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2024964: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024968: 7f ff a3 7b call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202496c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("link: linking", rc);
2024970: 40 00 96 c4 call 204a480 <__errno> <== NOT EXECUTED
2024974: 01 00 00 00 nop <== NOT EXECUTED
2024978: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
202497c: 81 c7 e0 08 ret <== NOT EXECUTED
2024980: 81 e8 00 00 restore <== NOT EXECUTED
2024984: 40 00 6b 46 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024988: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202498c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024990: 7f ff a3 71 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024994: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2024998: 81 c7 e0 08 ret <== NOT EXECUTED
202499c: 81 e8 00 00 restore <== NOT EXECUTED
02025420 <rtems_rfs_rtems_mknod>:
int
rtems_rfs_rtems_mknod (const char *name,
mode_t mode,
dev_t dev,
rtems_filesystem_location_info_t *pathloc)
{
2025420: 9d e3 bf 60 save %sp, -160, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2025424: c2 07 20 10 ld [ %i4 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2025428: e6 07 00 00 ld [ %i4 ], %l3 <== NOT EXECUTED
uid_t uid;
gid_t gid;
int rc;
#if defined(RTEMS_POSIX_API)
uid = geteuid ();
202542c: 40 00 1e 26 call 202ccc4 <geteuid> <== NOT EXECUTED
2025430: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
gid = getegid ();
2025434: 40 00 1e 20 call 202ccb4 <getegid> <== NOT EXECUTED
2025438: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
202543c: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2025440: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2025444: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2025448: 92 10 20 00 clr %o1 <== NOT EXECUTED
202544c: 7f ff a0 7b call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2025450: 94 10 20 00 clr %o2 <== NOT EXECUTED
gid = 0;
#endif
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_create (fs, parent, name, strlen (name),
2025454: 40 00 af c7 call 2051370 <strlen> <== NOT EXECUTED
2025458: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202545c: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
rtems_rfs_rtems_imode (mode),
2025460: 40 00 01 7c call 2025a50 <rtems_rfs_rtems_imode> <== NOT EXECUTED
2025464: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
gid = 0;
#endif
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_create (fs, parent, name, strlen (name),
2025468: 82 07 bf fc add %fp, -4, %g1 <== NOT EXECUTED
202546c: a3 2c 60 10 sll %l1, 0x10, %l1 <== NOT EXECUTED
2025470: a3 34 60 10 srl %l1, 0x10, %l1 <== NOT EXECUTED
2025474: 99 2a 20 10 sll %o0, 0x10, %o4 <== NOT EXECUTED
2025478: e2 23 a0 60 st %l1, [ %sp + 0x60 ] <== NOT EXECUTED
202547c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2025480: a5 2c a0 10 sll %l2, 0x10, %l2 <== NOT EXECUTED
2025484: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
2025488: a5 34 a0 10 srl %l2, 0x10, %l2 <== NOT EXECUTED
202548c: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
2025490: e4 23 a0 5c st %l2, [ %sp + 0x5c ] <== NOT EXECUTED
2025494: 99 33 20 10 srl %o4, 0x10, %o4 <== NOT EXECUTED
2025498: c2 23 a0 64 st %g1, [ %sp + 0x64 ] <== NOT EXECUTED
202549c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20254a0: 40 00 78 69 call 2043644 <rtems_rfs_inode_create> <== NOT EXECUTED
20254a4: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
rtems_rfs_rtems_imode (mode),
1, uid, gid, &ino);
if (rc > 0)
20254a8: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20254ac: 04 80 00 0d ble 20254e0 <rtems_rfs_rtems_mknod+0xc0> <== NOT EXECUTED
20254b0: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20254b4: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20254b8: 40 00 68 79 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20254bc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20254c0: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
20254c4: 7f ff a0 a4 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20254c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("mknod: inode create", rc);
20254cc: 40 00 93 ed call 204a480 <__errno> <== NOT EXECUTED
20254d0: 01 00 00 00 nop <== NOT EXECUTED
20254d4: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20254d8: 81 c7 e0 08 ret <== NOT EXECUTED
20254dc: 81 e8 00 00 restore <== NOT EXECUTED
}
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
20254e0: a2 07 bf d4 add %fp, -44, %l1 <== NOT EXECUTED
20254e4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20254e8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20254ec: 40 00 77 f2 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20254f0: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
20254f4: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20254f8: 04 80 00 0d ble 202552c <rtems_rfs_rtems_mknod+0x10c> <== NOT EXECUTED
20254fc: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2025500: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2025504: 40 00 68 66 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025508: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202550c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2025510: 7f ff a0 91 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025514: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("mknod: inode open", rc);
2025518: 40 00 93 da call 204a480 <__errno> <== NOT EXECUTED
202551c: 01 00 00 00 nop <== NOT EXECUTED
2025520: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2025524: 81 c7 e0 08 ret <== NOT EXECUTED
2025528: 81 e8 00 00 restore <== NOT EXECUTED
}
if (S_ISDIR(mode) || S_ISREG(mode))
202552c: b2 0e 40 01 and %i1, %g1, %i1 <== NOT EXECUTED
2025530: 03 00 00 20 sethi %hi(0x8000), %g1 <== NOT EXECUTED
2025534: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2025538: 02 80 00 20 be 20255b8 <rtems_rfs_rtems_mknod+0x198> <== NOT EXECUTED
202553c: 03 00 00 10 sethi %hi(0x4000), %g1 <== NOT EXECUTED
2025540: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2025544: 02 80 00 1d be 20255b8 <rtems_rfs_rtems_mknod+0x198> <== NOT EXECUTED
2025548: 03 00 00 18 sethi %hi(0x6000), %g1 <== NOT EXECUTED
{
}
else if (S_ISCHR (mode) || S_ISBLK (mode))
202554c: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2025550: 12 80 00 2b bne 20255fc <rtems_rfs_rtems_mknod+0x1dc> <== NOT EXECUTED
2025554: 03 00 00 08 sethi %hi(0x2000), %g1 <== NOT EXECUTED
* @param bno The block number.
*/
static inline void
rtems_rfs_inode_set_block (rtems_rfs_inode_handle* handle, int block, uint32_t bno)
{
rtems_rfs_write_u32 (&handle->node->data.blocks[block], bno);
2025558: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
202555c: 85 36 a0 18 srl %i2, 0x18, %g2 <== NOT EXECUTED
2025560: c4 28 60 1c stb %g2, [ %g1 + 0x1c ] <== NOT EXECUTED
2025564: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
2025568: 85 36 a0 10 srl %i2, 0x10, %g2 <== NOT EXECUTED
202556c: c4 28 60 1d stb %g2, [ %g1 + 0x1d ] <== NOT EXECUTED
2025570: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
2025574: 85 36 a0 08 srl %i2, 8, %g2 <== NOT EXECUTED
2025578: c4 28 60 1e stb %g2, [ %g1 + 0x1e ] <== NOT EXECUTED
202557c: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
2025580: 85 36 e0 18 srl %i3, 0x18, %g2 <== NOT EXECUTED
2025584: f4 28 60 1f stb %i2, [ %g1 + 0x1f ] <== NOT EXECUTED
2025588: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
202558c: 87 36 e0 10 srl %i3, 0x10, %g3 <== NOT EXECUTED
2025590: c4 28 60 20 stb %g2, [ %g1 + 0x20 ] <== NOT EXECUTED
2025594: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
2025598: 85 36 e0 08 srl %i3, 8, %g2 <== NOT EXECUTED
202559c: c6 28 60 21 stb %g3, [ %g1 + 0x21 ] <== NOT EXECUTED
20255a0: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20255a4: c4 28 60 22 stb %g2, [ %g1 + 0x22 ] <== NOT EXECUTED
20255a8: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20255ac: f6 28 60 23 stb %i3, [ %g1 + 0x23 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
20255b0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20255b4: c2 2f bf e4 stb %g1, [ %fp + -28 ] <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("mknod: bad mode", EINVAL);
}
rc = rtems_rfs_inode_close (fs, &inode);
20255b8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20255bc: 40 00 77 94 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20255c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
20255c4: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20255c8: 04 80 00 09 ble 20255ec <rtems_rfs_rtems_mknod+0x1cc> <== NOT EXECUTED
20255cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
20255d0: 7f ff fa 86 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
20255d4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("mknod: closing inode", rc);
20255d8: 40 00 93 aa call 204a480 <__errno> <== NOT EXECUTED
20255dc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
20255e0: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20255e4: 81 c7 e0 08 ret <== NOT EXECUTED
20255e8: 81 e8 00 00 restore <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
20255ec: 7f ff fa 7f call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
20255f0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
20255f4: 81 c7 e0 08 ret <== NOT EXECUTED
20255f8: 81 e8 00 00 restore <== NOT EXECUTED
}
if (S_ISDIR(mode) || S_ISREG(mode))
{
}
else if (S_ISCHR (mode) || S_ISBLK (mode))
20255fc: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED
2025600: 02 bf ff d7 be 202555c <rtems_rfs_rtems_mknod+0x13c> <== NOT EXECUTED
2025604: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
rtems_rfs_inode_set_block (&inode, 0, major);
rtems_rfs_inode_set_block (&inode, 1, minor);
}
else
{
rtems_rfs_inode_close (fs, &inode);
2025608: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202560c: 40 00 77 80 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2025610: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_rtems_unlock (fs);
2025614: 7f ff fa 75 call 2023fe8 <rtems_rfs_rtems_unlock> <== NOT EXECUTED
2025618: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("mknod: bad mode", EINVAL);
202561c: 40 00 93 99 call 204a480 <__errno> <== NOT EXECUTED
2025620: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2025624: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
2025628: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202562c: 81 c7 e0 08 ret <== NOT EXECUTED
2025630: 81 e8 00 00 restore <== NOT EXECUTED
02025a58 <rtems_rfs_rtems_mode>:
{
/*
* Mapping matches RTEMS so no need to change.
*/
return imode;
}
2025a58: 81 c3 e0 08 retl <== NOT EXECUTED
02025928 <rtems_rfs_rtems_node_type>:
* @return rtems_filesystem_node_types_t
*/
rtems_filesystem_node_types_t
rtems_rfs_rtems_node_type (rtems_filesystem_location_info_t* pathloc)
{
2025928: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
202592c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2025930: e4 06 00 00 ld [ %i0 ], %l2 <== NOT EXECUTED
*/
rtems_filesystem_node_types_t
rtems_rfs_rtems_node_type (rtems_filesystem_location_info_t* pathloc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2025934: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2025938: 92 10 20 00 clr %o1 <== NOT EXECUTED
202593c: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2025940: 94 10 20 00 clr %o2 <== NOT EXECUTED
2025944: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2025948: 7f ff 9f 3c call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
202594c: a2 07 bf d8 add %fp, -40, %l1 <== NOT EXECUTED
uint16_t mode;
int rc;
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2025950: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2025954: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025958: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
202595c: 40 00 76 d6 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2025960: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2025964: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2025968: 04 80 00 0d ble 202599c <rtems_rfs_rtems_node_type+0x74> <== NOT EXECUTED
202596c: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2025970: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2025974: 40 00 67 4a call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025978: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
202597c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2025980: 7f ff 9f 75 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025984: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("node_type: opening inode", rc);
2025988: 40 00 92 be call 204a480 <__errno> <== NOT EXECUTED
202598c: 01 00 00 00 nop <== NOT EXECUTED
2025990: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2025994: 81 c7 e0 08 ret <== NOT EXECUTED
2025998: 81 e8 00 00 restore <== NOT EXECUTED
* link is actually the normal path to a regular file, directory, device
* etc's inode. Links to inodes can be considered "the real" one, yet they
* are all links.
*/
mode = rtems_rfs_inode_get_mode (&inode);
if (RTEMS_RFS_S_ISDIR (mode))
202599c: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
20259a0: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
20259a4: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20259a8: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
20259ac: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
20259b0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20259b4: 02 80 00 0b be 20259e0 <rtems_rfs_rtems_node_type+0xb8> <== NOT EXECUTED
20259b8: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
type = RTEMS_FILESYSTEM_DIRECTORY;
else if (RTEMS_RFS_S_ISLNK (mode))
20259bc: 05 00 00 28 sethi %hi(0xa000), %g2 <== NOT EXECUTED
20259c0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20259c4: 02 80 00 07 be 20259e0 <rtems_rfs_rtems_node_type+0xb8> <== NOT EXECUTED
20259c8: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED
type = RTEMS_FILESYSTEM_SYM_LINK;
else if (RTEMS_RFS_S_ISBLK (mode) || RTEMS_RFS_S_ISCHR (mode))
20259cc: 05 00 00 08 sethi %hi(0x2000), %g2 <== NOT EXECUTED
20259d0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20259d4: 12 80 00 14 bne 2025a24 <rtems_rfs_rtems_node_type+0xfc> <== NOT EXECUTED
20259d8: 05 00 00 18 sethi %hi(0x6000), %g2 <== NOT EXECUTED
20259dc: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
type = RTEMS_FILESYSTEM_DEVICE;
else
type = RTEMS_FILESYSTEM_MEMORY_FILE;
rc = rtems_rfs_inode_close (fs, &inode);
20259e0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20259e4: 40 00 76 8a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20259e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
20259ec: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20259f0: 24 80 00 12 ble,a 2025a38 <rtems_rfs_rtems_node_type+0x110><== NOT EXECUTED
20259f4: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20259f8: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20259fc: 40 00 67 28 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025a00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025a04: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2025a08: 7f ff 9f 53 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025a0c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("node_type: closing inode", rc);
2025a10: 40 00 92 9c call 204a480 <__errno> <== NOT EXECUTED
2025a14: 01 00 00 00 nop <== NOT EXECUTED
2025a18: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2025a1c: 81 c7 e0 08 ret <== NOT EXECUTED
2025a20: 81 e8 00 00 restore <== NOT EXECUTED
mode = rtems_rfs_inode_get_mode (&inode);
if (RTEMS_RFS_S_ISDIR (mode))
type = RTEMS_FILESYSTEM_DIRECTORY;
else if (RTEMS_RFS_S_ISLNK (mode))
type = RTEMS_FILESYSTEM_SYM_LINK;
else if (RTEMS_RFS_S_ISBLK (mode) || RTEMS_RFS_S_ISCHR (mode))
2025a24: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025a28: 12 bf ff ee bne 20259e0 <rtems_rfs_rtems_node_type+0xb8> <== NOT EXECUTED
2025a2c: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED
2025a30: 10 bf ff ec b 20259e0 <rtems_rfs_rtems_node_type+0xb8> <== NOT EXECUTED
2025a34: b0 10 20 02 mov 2, %i0 <== NOT EXECUTED
2025a38: 40 00 67 19 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025a3c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2025a40: 7f ff 9f 45 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025a44: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return type;
}
2025a48: 81 c7 e0 08 ret <== NOT EXECUTED
2025a4c: 81 e8 00 00 restore <== NOT EXECUTED
02024674 <rtems_rfs_rtems_readlink>:
int
rtems_rfs_rtems_readlink (rtems_filesystem_location_info_t* pathloc,
char* buf,
size_t bufsize)
{
2024674: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024678: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
202467c: e2 06 00 00 ld [ %i0 ], %l1 <== NOT EXECUTED
int
rtems_rfs_rtems_readlink (rtems_filesystem_location_info_t* pathloc,
char* buf,
size_t bufsize)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024680: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024684: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024688: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
202468c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2024690: 7f ff a3 ea call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024694: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_READLINK))
printf ("rtems-rfs-rtems: readlink: in: ino:%" PRId32 "\n", ino);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_symlink_read (fs, ino, buf, bufsize, &length);
2024698: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
202469c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20246a0: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
20246a4: 96 10 00 1a mov %i2, %o3 <== NOT EXECUTED
20246a8: 40 00 7c 96 call 2043900 <rtems_rfs_symlink_read> <== NOT EXECUTED
20246ac: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
if (rc)
20246b0: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20246b4: 22 80 00 0d be,a 20246e8 <rtems_rfs_rtems_readlink+0x74> <== NOT EXECUTED
20246b8: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20246bc: f4 04 20 7c ld [ %l0 + 0x7c ], %i2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20246c0: 40 00 6b f7 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20246c4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20246c8: d0 06 80 00 ld [ %i2 ], %o0 <== NOT EXECUTED
20246cc: 7f ff a4 22 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20246d0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("readlink: reading link", rc);
20246d4: 40 00 97 6b call 204a480 <__errno> <== NOT EXECUTED
20246d8: 01 00 00 00 nop <== NOT EXECUTED
20246dc: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20246e0: 81 c7 e0 08 ret <== NOT EXECUTED
20246e4: 81 e8 00 00 restore <== NOT EXECUTED
20246e8: 40 00 6b ed call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20246ec: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20246f0: 7f ff a4 19 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20246f4: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return (int) length;
20246f8: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
}
20246fc: 81 c7 e0 08 ret <== NOT EXECUTED
2024700: 81 e8 00 00 restore <== NOT EXECUTED
02024ad0 <rtems_rfs_rtems_rename>:
int
rtems_rfs_rtems_rename(rtems_filesystem_location_info_t* old_parent_loc,
rtems_filesystem_location_info_t* old_loc,
rtems_filesystem_location_info_t* new_parent_loc,
const char* new_name)
{
2024ad0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (old_loc);
2024ad4: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino;
uint32_t doff;
int rc;
old_parent = rtems_rfs_rtems_get_pathloc_ino (old_parent_loc);
new_parent = rtems_rfs_rtems_get_pathloc_ino (new_parent_loc);
2024ad8: e8 06 80 00 ld [ %i2 ], %l4 <== NOT EXECUTED
rtems_rfs_rtems_rename(rtems_filesystem_location_info_t* old_parent_loc,
rtems_filesystem_location_info_t* old_loc,
rtems_filesystem_location_info_t* new_parent_loc,
const char* new_name)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (old_loc);
2024adc: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024ae0: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024ae4: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2024ae8: 94 10 20 00 clr %o2 <== NOT EXECUTED
2024aec: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
int rc;
old_parent = rtems_rfs_rtems_get_pathloc_ino (old_parent_loc);
new_parent = rtems_rfs_rtems_get_pathloc_ino (new_parent_loc);
ino = rtems_rfs_rtems_get_pathloc_ino (old_loc);
2024af0: e2 06 40 00 ld [ %i1 ], %l1 <== NOT EXECUTED
rtems_rfs_ino new_parent;
rtems_rfs_ino ino;
uint32_t doff;
int rc;
old_parent = rtems_rfs_rtems_get_pathloc_ino (old_parent_loc);
2024af4: e6 06 00 00 ld [ %i0 ], %l3 <== NOT EXECUTED
2024af8: 7f ff a2 d0 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024afc: e4 06 60 04 ld [ %i1 + 4 ], %l2 <== NOT EXECUTED
/*
* Link to the inode before unlinking so the inode is not erased when
* unlinked.
*/
rc = rtems_rfs_link (fs, new_name, strlen (new_name), new_parent, ino, true);
2024b00: 40 00 b2 1c call 2051370 <strlen> <== NOT EXECUTED
2024b04: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
2024b08: 96 10 00 14 mov %l4, %o3 <== NOT EXECUTED
2024b0c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2024b10: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2024b14: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024b18: 98 10 00 11 mov %l1, %o4 <== NOT EXECUTED
2024b1c: 40 00 7c f0 call 2043edc <rtems_rfs_link> <== NOT EXECUTED
2024b20: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
if (rc)
2024b24: a8 92 20 00 orcc %o0, 0, %l4 <== NOT EXECUTED
2024b28: 02 80 00 0d be 2024b5c <rtems_rfs_rtems_rename+0x8c> <== NOT EXECUTED
2024b2c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024b30: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024b34: 40 00 6a da call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024b38: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2024b3c: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024b40: 7f ff a3 05 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024b44: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("rename: linking", rc);
2024b48: 40 00 96 4e call 204a480 <__errno> <== NOT EXECUTED
2024b4c: 01 00 00 00 nop <== NOT EXECUTED
2024b50: e8 22 00 00 st %l4, [ %o0 ] <== NOT EXECUTED
2024b54: 81 c7 e0 08 ret <== NOT EXECUTED
2024b58: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Unlink all inodes even directories with the dir option as false because a
* directory may not be empty.
*/
rc = rtems_rfs_unlink (fs, old_parent, ino, doff,
2024b5c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2024b60: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
2024b64: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024b68: 40 00 7c 56 call 2043cc0 <rtems_rfs_unlink> <== NOT EXECUTED
2024b6c: 98 10 20 02 mov 2, %o4 <== NOT EXECUTED
rtems_rfs_unlink_dir_allowed);
if (rc)
2024b70: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024b74: 22 80 00 0d be,a 2024ba8 <rtems_rfs_rtems_rename+0xd8> <== NOT EXECUTED
2024b78: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024b7c: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024b80: 40 00 6a c7 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024b84: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024b88: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024b8c: 7f ff a2 f2 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024b90: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("rename: unlinking", rc);
2024b94: 40 00 96 3b call 204a480 <__errno> <== NOT EXECUTED
2024b98: 01 00 00 00 nop <== NOT EXECUTED
2024b9c: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2024ba0: 81 c7 e0 08 ret <== NOT EXECUTED
2024ba4: 81 e8 00 00 restore <== NOT EXECUTED
2024ba8: 40 00 6a bd call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024bac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024bb0: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024bb4: 7f ff a2 e8 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024bb8: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2024bbc: 81 c7 e0 08 ret <== NOT EXECUTED
2024bc0: 81 e8 00 00 restore <== NOT EXECUTED
020247d0 <rtems_rfs_rtems_rmnod>:
* @return int
*/
int
rtems_rfs_rtems_rmnod (rtems_filesystem_location_info_t* parent_pathloc,
rtems_filesystem_location_info_t* pathloc)
{
20247d0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20247d4: c2 06 60 10 ld [ %i1 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_pathloc);
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
uint32_t doff = rtems_rfs_rtems_get_pathloc_doff (pathloc);
20247d8: e2 06 60 04 ld [ %i1 + 4 ], %l1 <== NOT EXECUTED
*/
int
rtems_rfs_rtems_rmnod (rtems_filesystem_location_info_t* parent_pathloc,
rtems_filesystem_location_info_t* pathloc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20247dc: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_pathloc);
20247e0: e6 06 00 00 ld [ %i0 ], %l3 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20247e4: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
20247e8: e4 06 40 00 ld [ %i1 ], %l2 <== NOT EXECUTED
20247ec: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20247f0: 92 10 20 00 clr %o1 <== NOT EXECUTED
20247f4: 7f ff a3 91 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20247f8: 94 10 20 00 clr %o2 <== NOT EXECUTED
printf ("rtems-rfs: rmnod: parent:%" PRId32 " doff:%" PRIu32 ", ino:%" PRId32 "\n",
parent, doff, ino);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_unlink (fs, parent, ino, doff, rtems_rfs_unlink_dir_denied);
20247fc: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
2024800: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024804: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2024808: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
202480c: 40 00 7d 2d call 2043cc0 <rtems_rfs_unlink> <== NOT EXECUTED
2024810: 98 10 20 00 clr %o4 <== NOT EXECUTED
if (rc)
2024814: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024818: 22 80 00 0d be,a 202484c <rtems_rfs_rtems_rmnod+0x7c> <== NOT EXECUTED
202481c: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024820: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024824: 40 00 6b 9e call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024828: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
202482c: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024830: 7f ff a3 c9 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024834: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("rmnod: unlinking", rc);
2024838: 40 00 97 12 call 204a480 <__errno> <== NOT EXECUTED
202483c: 01 00 00 00 nop <== NOT EXECUTED
2024840: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2024844: 81 c7 e0 08 ret <== NOT EXECUTED
2024848: 81 e8 00 00 restore <== NOT EXECUTED
202484c: 40 00 6b 94 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024850: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024854: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024858: 7f ff a3 bf call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202485c: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2024860: 81 c7 e0 08 ret <== NOT EXECUTED
2024864: 81 e8 00 00 restore <== NOT EXECUTED
02025a60 <rtems_rfs_rtems_set_handlers>:
*/
bool
rtems_rfs_rtems_set_handlers (rtems_filesystem_location_info_t* loc,
rtems_rfs_inode_handle* inode)
{
2025a60: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
2025a64: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
2025a68: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2025a6c: d2 08 60 02 ldub [ %g1 + 2 ], %o1 <== NOT EXECUTED
2025a70: 93 2a 60 08 sll %o1, 8, %o1 <== NOT EXECUTED
uint16_t mode = rtems_rfs_inode_get_mode (inode);
loc->handlers = NULL;
if (RTEMS_RFS_S_ISDIR (mode))
2025a74: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2025a78: 92 12 40 02 or %o1, %g2, %o1 <== NOT EXECUTED
2025a7c: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
2025a80: 93 2a 60 10 sll %o1, 0x10, %o1 <== NOT EXECUTED
2025a84: 93 32 60 10 srl %o1, 0x10, %o1 <== NOT EXECUTED
2025a88: 82 0a 40 01 and %o1, %g1, %g1 <== NOT EXECUTED
2025a8c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025a90: 02 80 00 19 be 2025af4 <rtems_rfs_rtems_set_handlers+0x94><== NOT EXECUTED
2025a94: c0 26 20 08 clr [ %i0 + 8 ] <== NOT EXECUTED
loc->handlers = rtems_rfs_rtems_handlers (dir);
else if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK(mode))
2025a98: 05 00 00 18 sethi %hi(0x6000), %g2 <== NOT EXECUTED
2025a9c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025aa0: 02 80 00 10 be 2025ae0 <rtems_rfs_rtems_set_handlers+0x80><== NOT EXECUTED
2025aa4: 05 00 00 08 sethi %hi(0x2000), %g2 <== NOT EXECUTED
2025aa8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025aac: 02 80 00 0d be 2025ae0 <rtems_rfs_rtems_set_handlers+0x80><== NOT EXECUTED
2025ab0: 05 00 00 28 sethi %hi(0xa000), %g2 <== NOT EXECUTED
loc->handlers = rtems_rfs_rtems_handlers (device);
else if (RTEMS_RFS_S_ISLNK (mode))
2025ab4: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025ab8: 02 80 00 19 be 2025b1c <rtems_rfs_rtems_set_handlers+0xbc><== NOT EXECUTED
2025abc: 05 00 00 20 sethi %hi(0x8000), %g2 <== NOT EXECUTED
loc->handlers = rtems_rfs_rtems_handlers (link);
else if (RTEMS_RFS_S_ISREG (mode))
2025ac0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2025ac4: 02 80 00 11 be 2025b08 <rtems_rfs_rtems_set_handlers+0xa8><== NOT EXECUTED
2025ac8: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
loc->handlers = rtems_rfs_rtems_handlers (file);
else
{
printf ("rtems-rfs: mode type unknown: %04x\n", mode);
2025acc: b0 10 20 00 clr %i0 <== NOT EXECUTED
2025ad0: 40 00 a4 67 call 204ec6c <printf> <== NOT EXECUTED
2025ad4: 90 12 22 a0 or %o0, 0x2a0, %o0 <== NOT EXECUTED
return false;
}
return true;
}
2025ad8: 81 c7 e0 08 ret <== NOT EXECUTED
2025adc: 81 e8 00 00 restore <== NOT EXECUTED
uint16_t mode = rtems_rfs_inode_get_mode (inode);
loc->handlers = NULL;
if (RTEMS_RFS_S_ISDIR (mode))
loc->handlers = rtems_rfs_rtems_handlers (dir);
else if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK(mode))
loc->handlers = rtems_rfs_rtems_handlers (device);
2025ae0: 03 00 81 bb sethi %hi(0x206ec00), %g1 <== NOT EXECUTED
2025ae4: 82 10 61 10 or %g1, 0x110, %g1 ! 206ed10 <rtems_rfs_rtems_device_handlers><== NOT EXECUTED
2025ae8: c2 26 20 08 st %g1, [ %i0 + 8 ] <== NOT EXECUTED
2025aec: 81 c7 e0 08 ret <== NOT EXECUTED
2025af0: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
rtems_rfs_inode_handle* inode)
{
uint16_t mode = rtems_rfs_inode_get_mode (inode);
loc->handlers = NULL;
if (RTEMS_RFS_S_ISDIR (mode))
loc->handlers = rtems_rfs_rtems_handlers (dir);
2025af4: 03 00 81 bb sethi %hi(0x206ec00), %g1 <== NOT EXECUTED
2025af8: 82 10 61 48 or %g1, 0x148, %g1 ! 206ed48 <rtems_rfs_rtems_dir_handlers><== NOT EXECUTED
2025afc: c2 26 20 08 st %g1, [ %i0 + 8 ] <== NOT EXECUTED
2025b00: 81 c7 e0 08 ret <== NOT EXECUTED
2025b04: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
else if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK(mode))
loc->handlers = rtems_rfs_rtems_handlers (device);
else if (RTEMS_RFS_S_ISLNK (mode))
loc->handlers = rtems_rfs_rtems_handlers (link);
else if (RTEMS_RFS_S_ISREG (mode))
loc->handlers = rtems_rfs_rtems_handlers (file);
2025b08: 03 00 81 bb sethi %hi(0x206ec00), %g1 <== NOT EXECUTED
2025b0c: 82 10 61 80 or %g1, 0x180, %g1 ! 206ed80 <rtems_rfs_rtems_file_handlers><== NOT EXECUTED
2025b10: c2 26 20 08 st %g1, [ %i0 + 8 ] <== NOT EXECUTED
2025b14: 81 c7 e0 08 ret <== NOT EXECUTED
2025b18: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
if (RTEMS_RFS_S_ISDIR (mode))
loc->handlers = rtems_rfs_rtems_handlers (dir);
else if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK(mode))
loc->handlers = rtems_rfs_rtems_handlers (device);
else if (RTEMS_RFS_S_ISLNK (mode))
loc->handlers = rtems_rfs_rtems_handlers (link);
2025b1c: 03 00 81 a6 sethi %hi(0x2069800), %g1 <== NOT EXECUTED
2025b20: 82 10 62 20 or %g1, 0x220, %g1 ! 2069a20 <rtems_rfs_rtems_link_handlers><== NOT EXECUTED
2025b24: c2 26 20 08 st %g1, [ %i0 + 8 ] <== NOT EXECUTED
2025b28: 81 c7 e0 08 ret <== NOT EXECUTED
2025b2c: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
02024008 <rtems_rfs_rtems_shutdown>:
/**
* Shutdown the file system.
*/
int
rtems_rfs_rtems_shutdown (rtems_filesystem_mount_table_entry_t* mt_entry)
{
2024008: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = mt_entry->fs_info;
202400c: d0 06 20 34 ld [ %i0 + 0x34 ], %o0 <== NOT EXECUTED
rtems_rfs_rtems_private* rtems;
int rc;
rtems = rtems_rfs_fs_user (fs);
rc = rtems_rfs_fs_close(fs);
2024010: 40 00 75 73 call 20415dc <rtems_rfs_fs_close> <== NOT EXECUTED
2024014: e2 02 20 7c ld [ %o0 + 0x7c ], %l1 <== NOT EXECUTED
2024018: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
rtems_rfs_mutex_destroy (&rtems->access);
202401c: 40 00 80 0d call 2044050 <rtems_rfs_mutex_destroy> <== NOT EXECUTED
2024020: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
free (rtems);
2024024: 7f ff 92 2e call 20088dc <free> <== NOT EXECUTED
2024028: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("shutdown: close", rc);
202402c: 40 00 99 15 call 204a480 <__errno> <== NOT EXECUTED
2024030: 01 00 00 00 nop <== NOT EXECUTED
}
2024034: 80 a0 00 10 cmp %g0, %l0 <== NOT EXECUTED
rc = rtems_rfs_fs_close(fs);
rtems_rfs_mutex_destroy (&rtems->access);
free (rtems);
return rtems_rfs_rtems_error ("shutdown: close", rc);
2024038: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
}
202403c: b0 60 20 00 subx %g0, 0, %i0 <== NOT EXECUTED
2024040: 81 c7 e0 08 ret <== NOT EXECUTED
2024044: 81 e8 00 00 restore <== NOT EXECUTED
02024bc4 <rtems_rfs_rtems_stat>:
*/
int
rtems_rfs_rtems_stat (rtems_filesystem_location_info_t* pathloc,
struct stat* buf)
{
2024bc4: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024bc8: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
2024bcc: e2 06 00 00 ld [ %i0 ], %l1 <== NOT EXECUTED
int
rtems_rfs_rtems_stat (rtems_filesystem_location_info_t* pathloc,
struct stat* buf)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024bd0: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024bd4: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024bd8: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2024bdc: 94 10 20 00 clr %o2 <== NOT EXECUTED
2024be0: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2024be4: 7f ff a2 95 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024be8: a4 07 bf d8 add %fp, -40, %l2 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_STAT))
printf ("rtems-rfs-rtems: stat: in: ino:%" PRId32 "\n", ino);
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2024bec: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024bf0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2024bf4: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2024bf8: 40 00 7a 2f call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2024bfc: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
2024c00: a6 92 20 00 orcc %o0, 0, %l3 <== NOT EXECUTED
2024c04: 12 80 00 86 bne 2024e1c <rtems_rfs_rtems_stat+0x258> <== NOT EXECUTED
2024c08: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
return rtems_rfs_rtems_error ("stat: opening inode", rc);
}
mode = rtems_rfs_inode_get_mode (&inode);
if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK (mode))
2024c0c: 07 00 00 18 sethi %hi(0x6000), %g3 <== NOT EXECUTED
2024c10: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2024c14: d0 08 60 02 ldub [ %g1 + 2 ], %o0 <== NOT EXECUTED
2024c18: 91 2a 20 08 sll %o0, 8, %o0 <== NOT EXECUTED
2024c1c: 90 12 00 02 or %o0, %g2, %o0 <== NOT EXECUTED
2024c20: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
2024c24: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
2024c28: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED
2024c2c: 84 0a 00 02 and %o0, %g2, %g2 <== NOT EXECUTED
2024c30: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2024c34: 12 80 00 62 bne 2024dbc <rtems_rfs_rtems_stat+0x1f8> <== NOT EXECUTED
2024c38: 07 00 00 08 sethi %hi(0x2000), %g3 <== NOT EXECUTED
rtems_device_minor_number _minor
)
{
union __rtems_dev_t temp;
temp.__overlay.major = _major;
2024c3c: da 08 60 1c ldub [ %g1 + 0x1c ], %o5 <== NOT EXECUTED
* @return uint32_t The block number.
*/
static inline uint32_t
rtems_rfs_inode_get_block (rtems_rfs_inode_handle* handle, int block)
{
return rtems_rfs_read_u32 (&handle->node->data.blocks[block]);
2024c40: 82 00 60 1c add %g1, 0x1c, %g1 <== NOT EXECUTED
2024c44: d4 08 60 04 ldub [ %g1 + 4 ], %o2 <== NOT EXECUTED
2024c48: d6 08 60 07 ldub [ %g1 + 7 ], %o3 <== NOT EXECUTED
2024c4c: d8 08 60 06 ldub [ %g1 + 6 ], %o4 <== NOT EXECUTED
2024c50: d2 08 60 05 ldub [ %g1 + 5 ], %o1 <== NOT EXECUTED
2024c54: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
2024c58: c8 08 60 03 ldub [ %g1 + 3 ], %g4 <== NOT EXECUTED
2024c5c: c6 08 60 01 ldub [ %g1 + 1 ], %g3 <== NOT EXECUTED
2024c60: 95 2a a0 18 sll %o2, 0x18, %o2 <== NOT EXECUTED
2024c64: 83 2a 60 10 sll %o1, 0x10, %g1 <== NOT EXECUTED
2024c68: 99 2b 20 08 sll %o4, 8, %o4 <== NOT EXECUTED
2024c6c: 82 12 80 01 or %o2, %g1, %g1 <== NOT EXECUTED
2024c70: 82 10 40 0b or %g1, %o3, %g1 <== NOT EXECUTED
2024c74: 82 10 40 0c or %g1, %o4, %g1 <== NOT EXECUTED
2024c78: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
{
buf->st_rdev =
2024c7c: c2 26 60 1c st %g1, [ %i1 + 0x1c ] <== NOT EXECUTED
2024c80: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2024c84: 83 2b 60 18 sll %o5, 0x18, %g1 <== NOT EXECUTED
2024c88: 82 11 00 01 or %g4, %g1, %g1 <== NOT EXECUTED
2024c8c: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
2024c90: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2024c94: c2 26 60 18 st %g1, [ %i1 + 0x18 ] <== NOT EXECUTED
rtems_filesystem_make_dev_t (rtems_rfs_inode_get_block (&inode, 0),
rtems_rfs_inode_get_block (&inode, 1));
}
buf->st_dev = rtems_rfs_fs_device (fs);
2024c98: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
buf->st_ino = ino;
2024c9c: e2 26 60 08 st %l1, [ %i1 + 8 ] <== NOT EXECUTED
buf->st_rdev =
rtems_filesystem_make_dev_t (rtems_rfs_inode_get_block (&inode, 0),
rtems_rfs_inode_get_block (&inode, 1));
}
buf->st_dev = rtems_rfs_fs_device (fs);
2024ca0: c4 18 40 00 ldd [ %g1 ], %g2 <== NOT EXECUTED
buf->st_ino = ino;
buf->st_mode = rtems_rfs_rtems_mode (mode);
2024ca4: 40 00 03 6d call 2025a58 <rtems_rfs_rtems_mode> <== NOT EXECUTED
2024ca8: c4 3e 40 00 std %g2, [ %i1 ] <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2024cac: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024cb0: d0 26 60 0c st %o0, [ %i1 + 0xc ] <== NOT EXECUTED
2024cb4: c6 08 60 01 ldub [ %g1 + 1 ], %g3 <== NOT EXECUTED
2024cb8: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
if (links == 0xffff)
2024cbc: 09 3f ff c0 sethi %hi(0xffff0000), %g4 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2024cc0: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2024cc4: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
if (links == 0xffff)
2024cc8: 87 28 a0 10 sll %g2, 0x10, %g3 <== NOT EXECUTED
2024ccc: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
2024cd0: 86 39 00 03 xnor %g4, %g3, %g3 <== NOT EXECUTED
2024cd4: 80 a0 00 03 cmp %g0, %g3 <== NOT EXECUTED
2024cd8: 86 60 20 00 subx %g0, 0, %g3 <== NOT EXECUTED
2024cdc: 84 08 80 03 and %g2, %g3, %g2 <== NOT EXECUTED
buf->st_nlink = rtems_rfs_inode_get_links (&inode);
2024ce0: c4 36 60 10 sth %g2, [ %i1 + 0x10 ] <== NOT EXECUTED
buf->st_uid = rtems_rfs_inode_get_uid (&inode);
2024ce4: c4 08 60 06 ldub [ %g1 + 6 ], %g2 <== NOT EXECUTED
2024ce8: c6 08 60 07 ldub [ %g1 + 7 ], %g3 <== NOT EXECUTED
2024cec: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2024cf0: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
2024cf4: c4 36 60 12 sth %g2, [ %i1 + 0x12 ] <== NOT EXECUTED
buf->st_gid = rtems_rfs_inode_get_gid (&inode);
2024cf8: c4 08 60 05 ldub [ %g1 + 5 ], %g2 <== NOT EXECUTED
2024cfc: c2 08 60 04 ldub [ %g1 + 4 ], %g1 <== NOT EXECUTED
2024d00: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2024d04: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
2024d08: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
2024d0c: 83 30 60 10 srl %g1, 0x10, %g1 <== NOT EXECUTED
/*
* Need to check is the ino is an open file. If so we take the values from
* the open file rather than the inode.
*/
shared = rtems_rfs_file_get_shared (fs, ino);
2024d10: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
buf->st_dev = rtems_rfs_fs_device (fs);
buf->st_ino = ino;
buf->st_mode = rtems_rfs_rtems_mode (mode);
buf->st_nlink = rtems_rfs_inode_get_links (&inode);
buf->st_uid = rtems_rfs_inode_get_uid (&inode);
buf->st_gid = rtems_rfs_inode_get_gid (&inode);
2024d14: c2 36 60 14 sth %g1, [ %i1 + 0x14 ] <== NOT EXECUTED
/*
* Need to check is the ino is an open file. If so we take the values from
* the open file rather than the inode.
*/
shared = rtems_rfs_file_get_shared (fs, ino);
2024d18: 40 00 6f 10 call 2040958 <rtems_rfs_file_get_shared> <== NOT EXECUTED
2024d1c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (shared)
2024d20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2024d24: 02 80 00 49 be 2024e48 <rtems_rfs_rtems_stat+0x284> <== NOT EXECUTED
2024d28: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
{
buf->st_atime = rtems_rfs_file_shared_get_atime (shared);
2024d2c: c2 02 20 8c ld [ %o0 + 0x8c ], %g1 <== NOT EXECUTED
buf->st_mtime = rtems_rfs_file_shared_get_mtime (shared);
buf->st_ctime = rtems_rfs_file_shared_get_ctime (shared);
buf->st_blocks = rtems_rfs_file_shared_get_block_count (shared);
if (S_ISLNK (buf->st_mode))
2024d30: c6 06 60 0c ld [ %i1 + 0xc ], %g3 <== NOT EXECUTED
*/
shared = rtems_rfs_file_get_shared (fs, ino);
if (shared)
{
buf->st_atime = rtems_rfs_file_shared_get_atime (shared);
2024d34: c2 26 60 28 st %g1, [ %i1 + 0x28 ] <== NOT EXECUTED
buf->st_mtime = rtems_rfs_file_shared_get_mtime (shared);
2024d38: c2 02 20 90 ld [ %o0 + 0x90 ], %g1 <== NOT EXECUTED
2024d3c: c2 26 60 30 st %g1, [ %i1 + 0x30 ] <== NOT EXECUTED
buf->st_ctime = rtems_rfs_file_shared_get_ctime (shared);
2024d40: c2 02 20 94 ld [ %o0 + 0x94 ], %g1 <== NOT EXECUTED
buf->st_blocks = rtems_rfs_file_shared_get_block_count (shared);
if (S_ISLNK (buf->st_mode))
2024d44: 84 08 c0 02 and %g3, %g2, %g2 <== NOT EXECUTED
if (shared)
{
buf->st_atime = rtems_rfs_file_shared_get_atime (shared);
buf->st_mtime = rtems_rfs_file_shared_get_mtime (shared);
buf->st_ctime = rtems_rfs_file_shared_get_ctime (shared);
2024d48: c2 26 60 38 st %g1, [ %i1 + 0x38 ] <== NOT EXECUTED
buf->st_blocks = rtems_rfs_file_shared_get_block_count (shared);
2024d4c: c2 02 20 84 ld [ %o0 + 0x84 ], %g1 <== NOT EXECUTED
2024d50: c2 26 60 44 st %g1, [ %i1 + 0x44 ] <== NOT EXECUTED
if (S_ISLNK (buf->st_mode))
2024d54: 03 00 00 28 sethi %hi(0xa000), %g1 <== NOT EXECUTED
2024d58: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2024d5c: 12 80 00 1d bne 2024dd0 <rtems_rfs_rtems_stat+0x20c> <== NOT EXECUTED
2024d60: 92 02 20 84 add %o0, 0x84, %o1 <== NOT EXECUTED
buf->st_size = rtems_rfs_file_shared_get_block_offset (shared);
2024d64: c2 12 20 8a lduh [ %o0 + 0x8a ], %g1 <== NOT EXECUTED
2024d68: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
2024d6c: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
buf->st_size = rtems_rfs_inode_get_block_offset (&inode);
else
buf->st_size = rtems_rfs_inode_get_size (fs, &inode);
}
buf->st_blksize = rtems_rfs_fs_block_size (fs);
2024d70: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_inode_close (fs, &inode);
2024d74: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
buf->st_size = rtems_rfs_inode_get_block_offset (&inode);
else
buf->st_size = rtems_rfs_inode_get_size (fs, &inode);
}
buf->st_blksize = rtems_rfs_fs_block_size (fs);
2024d78: c2 26 60 40 st %g1, [ %i1 + 0x40 ] <== NOT EXECUTED
rc = rtems_rfs_inode_close (fs, &inode);
2024d7c: 40 00 79 a4 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024d80: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2024d84: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024d88: 24 80 00 1e ble,a 2024e00 <rtems_rfs_rtems_stat+0x23c> <== NOT EXECUTED
2024d8c: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024d90: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024d94: 40 00 6a 42 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024d98: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2024d9c: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024da0: 7f ff a2 6d call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024da4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("stat: closing inode", rc);
2024da8: 40 00 95 b6 call 204a480 <__errno> <== NOT EXECUTED
2024dac: 01 00 00 00 nop <== NOT EXECUTED
2024db0: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2024db4: 81 c7 e0 08 ret <== NOT EXECUTED
2024db8: 81 e8 00 00 restore <== NOT EXECUTED
return rtems_rfs_rtems_error ("stat: opening inode", rc);
}
mode = rtems_rfs_inode_get_mode (&inode);
if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK (mode))
2024dbc: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED
2024dc0: 32 bf ff b7 bne,a 2024c9c <rtems_rfs_rtems_stat+0xd8> <== NOT EXECUTED
2024dc4: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
2024dc8: 10 bf ff 9e b 2024c40 <rtems_rfs_rtems_stat+0x7c> <== NOT EXECUTED
2024dcc: da 08 60 1c ldub [ %g1 + 0x1c ], %o5 <== NOT EXECUTED
*/
static inline rtems_rfs_pos
rtems_rfs_file_shared_get_size (rtems_rfs_file_system* fs,
rtems_rfs_file_shared* shared)
{
return rtems_rfs_block_get_size (fs, &shared->size);
2024dd0: 40 00 66 4e call 203e708 <rtems_rfs_block_get_size> <== NOT EXECUTED
2024dd4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
buf->st_size = rtems_rfs_inode_get_block_offset (&inode);
else
buf->st_size = rtems_rfs_inode_get_size (fs, &inode);
}
buf->st_blksize = rtems_rfs_fs_block_size (fs);
2024dd8: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
buf->st_blocks = rtems_rfs_file_shared_get_block_count (shared);
if (S_ISLNK (buf->st_mode))
buf->st_size = rtems_rfs_file_shared_get_block_offset (shared);
else
buf->st_size = rtems_rfs_file_shared_get_size (fs, shared);
2024ddc: d0 3e 60 20 std %o0, [ %i1 + 0x20 ] <== NOT EXECUTED
buf->st_size = rtems_rfs_inode_get_block_offset (&inode);
else
buf->st_size = rtems_rfs_inode_get_size (fs, &inode);
}
buf->st_blksize = rtems_rfs_fs_block_size (fs);
2024de0: c2 26 60 40 st %g1, [ %i1 + 0x40 ] <== NOT EXECUTED
rc = rtems_rfs_inode_close (fs, &inode);
2024de4: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024de8: 40 00 79 89 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024dec: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2024df0: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024df4: 34 bf ff e8 bg,a 2024d94 <rtems_rfs_rtems_stat+0x1d0> <== NOT EXECUTED
2024df8: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024dfc: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024e00: 40 00 6a 27 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024e04: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024e08: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024e0c: 7f ff a2 52 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024e10: b0 10 20 00 clr %i0 <== NOT EXECUTED
return rtems_rfs_rtems_error ("stat: closing inode", rc);
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2024e14: 81 c7 e0 08 ret <== NOT EXECUTED
2024e18: 81 e8 00 00 restore <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024e1c: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024e20: 40 00 6a 1f call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024e24: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024e28: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024e2c: 7f ff a2 4a call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024e30: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc)
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("stat: opening inode", rc);
2024e34: 40 00 95 93 call 204a480 <__errno> <== NOT EXECUTED
2024e38: 01 00 00 00 nop <== NOT EXECUTED
2024e3c: e6 22 00 00 st %l3, [ %o0 ] <== NOT EXECUTED
2024e40: 81 c7 e0 08 ret <== NOT EXECUTED
2024e44: 81 e8 00 00 restore <== NOT EXECUTED
* @return rtems_rfs_time The atime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_atime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->atime);
2024e48: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
buf->st_atime = rtems_rfs_inode_get_atime (&inode);
buf->st_mtime = rtems_rfs_inode_get_mtime (&inode);
buf->st_ctime = rtems_rfs_inode_get_ctime (&inode);
buf->st_blocks = rtems_rfs_inode_get_block_count (&inode);
if (S_ISLNK (buf->st_mode))
2024e4c: c6 06 60 0c ld [ %i1 + 0xc ], %g3 <== NOT EXECUTED
else
buf->st_size = rtems_rfs_file_shared_get_size (fs, shared);
}
else
{
buf->st_atime = rtems_rfs_inode_get_atime (&inode);
2024e50: d6 08 60 10 ldub [ %g1 + 0x10 ], %o3 <== NOT EXECUTED
2024e54: 84 00 60 10 add %g1, 0x10, %g2 <== NOT EXECUTED
2024e58: d8 08 a0 03 ldub [ %g2 + 3 ], %o4 <== NOT EXECUTED
2024e5c: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
2024e60: da 08 a0 01 ldub [ %g2 + 1 ], %o5 <== NOT EXECUTED
2024e64: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
2024e68: 85 2a e0 18 sll %o3, 0x18, %g2 <== NOT EXECUTED
2024e6c: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
2024e70: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
2024e74: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
2024e78: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
2024e7c: c4 26 60 28 st %g2, [ %i1 + 0x28 ] <== NOT EXECUTED
* @return rtems_rfs_time The mtime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_mtime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->mtime);
2024e80: 84 00 60 14 add %g1, 0x14, %g2 <== NOT EXECUTED
buf->st_mtime = rtems_rfs_inode_get_mtime (&inode);
2024e84: d6 08 60 14 ldub [ %g1 + 0x14 ], %o3 <== NOT EXECUTED
2024e88: d8 08 a0 03 ldub [ %g2 + 3 ], %o4 <== NOT EXECUTED
2024e8c: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
2024e90: da 08 a0 01 ldub [ %g2 + 1 ], %o5 <== NOT EXECUTED
2024e94: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
2024e98: 85 2a e0 18 sll %o3, 0x18, %g2 <== NOT EXECUTED
2024e9c: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
2024ea0: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
2024ea4: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
2024ea8: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
2024eac: c4 26 60 30 st %g2, [ %i1 + 0x30 ] <== NOT EXECUTED
* @return rtems_rfs_time The ctime.
*/
static inline rtems_rfs_time
rtems_rfs_inode_get_ctime (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->ctime);
2024eb0: 84 00 60 18 add %g1, 0x18, %g2 <== NOT EXECUTED
buf->st_ctime = rtems_rfs_inode_get_ctime (&inode);
2024eb4: d6 08 60 18 ldub [ %g1 + 0x18 ], %o3 <== NOT EXECUTED
2024eb8: d8 08 a0 03 ldub [ %g2 + 3 ], %o4 <== NOT EXECUTED
2024ebc: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
2024ec0: da 08 a0 01 ldub [ %g2 + 1 ], %o5 <== NOT EXECUTED
2024ec4: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
2024ec8: 85 2a e0 18 sll %o3, 0x18, %g2 <== NOT EXECUTED
2024ecc: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
2024ed0: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
2024ed4: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
2024ed8: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
2024edc: c4 26 60 38 st %g2, [ %i1 + 0x38 ] <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
2024ee0: 84 00 60 0c add %g1, 0xc, %g2 <== NOT EXECUTED
buf->st_blocks = rtems_rfs_inode_get_block_count (&inode);
2024ee4: d6 08 60 0c ldub [ %g1 + 0xc ], %o3 <== NOT EXECUTED
2024ee8: c8 08 a0 02 ldub [ %g2 + 2 ], %g4 <== NOT EXECUTED
2024eec: d8 08 a0 03 ldub [ %g2 + 3 ], %o4 <== NOT EXECUTED
2024ef0: da 08 a0 01 ldub [ %g2 + 1 ], %o5 <== NOT EXECUTED
2024ef4: 89 29 20 08 sll %g4, 8, %g4 <== NOT EXECUTED
2024ef8: 85 2a e0 18 sll %o3, 0x18, %g2 <== NOT EXECUTED
2024efc: 9b 2b 60 10 sll %o5, 0x10, %o5 <== NOT EXECUTED
2024f00: 84 13 00 02 or %o4, %g2, %g2 <== NOT EXECUTED
2024f04: 84 10 80 0d or %g2, %o5, %g2 <== NOT EXECUTED
2024f08: 84 10 80 04 or %g2, %g4, %g2 <== NOT EXECUTED
2024f0c: c4 26 60 44 st %g2, [ %i1 + 0x44 ] <== NOT EXECUTED
if (S_ISLNK (buf->st_mode))
2024f10: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
2024f14: 86 08 c0 02 and %g3, %g2, %g3 <== NOT EXECUTED
2024f18: 05 00 00 28 sethi %hi(0xa000), %g2 <== NOT EXECUTED
2024f1c: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED
2024f20: 12 80 00 09 bne 2024f44 <rtems_rfs_rtems_stat+0x380> <== NOT EXECUTED
2024f24: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
buf->st_size = rtems_rfs_inode_get_block_offset (&inode);
2024f28: c4 08 60 0b ldub [ %g1 + 0xb ], %g2 <== NOT EXECUTED
2024f2c: c2 08 60 0a ldub [ %g1 + 0xa ], %g1 <== NOT EXECUTED
2024f30: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
2024f34: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2024f38: 82 10 80 01 or %g2, %g1, %g1 <== NOT EXECUTED
2024f3c: 10 bf ff 8d b 2024d70 <rtems_rfs_rtems_stat+0x1ac> <== NOT EXECUTED
2024f40: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
else
buf->st_size = rtems_rfs_inode_get_size (fs, &inode);
2024f44: 40 00 78 6d call 20430f8 <rtems_rfs_inode_get_size> <== NOT EXECUTED
2024f48: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2024f4c: 10 bf ff 89 b 2024d70 <rtems_rfs_rtems_stat+0x1ac> <== NOT EXECUTED
2024f50: d0 3e 60 20 std %o0, [ %i1 + 0x20 ] <== NOT EXECUTED
02024240 <rtems_rfs_rtems_statvfs>:
* @return int
*/
int
rtems_rfs_rtems_statvfs (rtems_filesystem_location_info_t* pathloc,
struct statvfs* sb)
{
2024240: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
2024244: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
size_t blocks;
size_t inodes;
rtems_rfs_group_usage (fs, &blocks, &inodes);
2024248: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
*/
int
rtems_rfs_rtems_statvfs (rtems_filesystem_location_info_t* pathloc,
struct statvfs* sb)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
202424c: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
size_t blocks;
size_t inodes;
rtems_rfs_group_usage (fs, &blocks, &inodes);
2024250: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
2024254: 40 00 7a 2f call 2042b10 <rtems_rfs_group_usage> <== NOT EXECUTED
2024258: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
202425c: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
size_t blocks;
size_t inodes;
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
2024260: c4 04 20 08 ld [ %l0 + 8 ], %g2 <== NOT EXECUTED
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
2024264: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
size_t blocks;
size_t inodes;
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
2024268: c4 26 40 00 st %g2, [ %i1 ] <== NOT EXECUTED
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
202426c: c4 00 60 24 ld [ %g1 + 0x24 ], %g2 <== NOT EXECUTED
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
2024270: c0 26 60 10 clr [ %i1 + 0x10 ] <== NOT EXECUTED
size_t inodes;
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
2024274: c4 26 60 04 st %g2, [ %i1 + 4 ] <== NOT EXECUTED
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
sb->f_bavail = sb->f_bfree;
sb->f_files = rtems_rfs_fs_inodes (fs);
2024278: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
202427c: c6 00 60 1c ld [ %g1 + 0x1c ], %g3 <== NOT EXECUTED
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
sb->f_bavail = sb->f_bfree;
sb->f_files = rtems_rfs_fs_inodes (fs);
sb->f_ffree = rtems_rfs_fs_inodes (fs) - inodes;
2024280: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
sb->f_bavail = sb->f_bfree;
sb->f_files = rtems_rfs_fs_inodes (fs);
2024284: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED
sb->f_ffree = rtems_rfs_fs_inodes (fs) - inodes;
2024288: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
sb->f_favail = sb->f_ffree;
202428c: c2 26 60 28 st %g1, [ %i1 + 0x28 ] <== NOT EXECUTED
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
sb->f_bavail = sb->f_bfree;
sb->f_files = rtems_rfs_fs_inodes (fs);
sb->f_ffree = rtems_rfs_fs_inodes (fs) - inodes;
2024290: c2 26 60 24 st %g1, [ %i1 + 0x24 ] <== NOT EXECUTED
sb->f_favail = sb->f_ffree;
sb->f_fsid = RTEMS_RFS_SB_MAGIC;
2024294: 03 0a 02 48 sethi %hi(0x28092000), %g1 <== NOT EXECUTED
2024298: 82 10 60 01 or %g1, 1, %g1 ! 28092001 <RAM_END+0x25c92001><== NOT EXECUTED
202429c: c2 26 60 2c st %g1, [ %i1 + 0x2c ] <== NOT EXECUTED
sb->f_flag = rtems_rfs_fs_flags (fs);
20242a0: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
20242a4: c4 04 20 04 ld [ %l0 + 4 ], %g2 <== NOT EXECUTED
sb->f_bavail = sb->f_bfree;
sb->f_files = rtems_rfs_fs_inodes (fs);
sb->f_ffree = rtems_rfs_fs_inodes (fs) - inodes;
sb->f_favail = sb->f_ffree;
sb->f_fsid = RTEMS_RFS_SB_MAGIC;
sb->f_flag = rtems_rfs_fs_flags (fs);
20242a8: c2 26 60 30 st %g1, [ %i1 + 0x30 ] <== NOT EXECUTED
sb->f_namemax = rtems_rfs_fs_max_name (fs);
20242ac: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
20242b0: c6 26 60 0c st %g3, [ %i1 + 0xc ] <== NOT EXECUTED
sb->f_files = rtems_rfs_fs_inodes (fs);
sb->f_ffree = rtems_rfs_fs_inodes (fs) - inodes;
sb->f_favail = sb->f_ffree;
sb->f_fsid = RTEMS_RFS_SB_MAGIC;
sb->f_flag = rtems_rfs_fs_flags (fs);
sb->f_namemax = rtems_rfs_fs_max_name (fs);
20242b4: c2 26 60 34 st %g1, [ %i1 + 0x34 ] <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
20242b8: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
sb->f_bavail = sb->f_bfree;
20242bc: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
20242c0: 82 20 80 01 sub %g2, %g1, %g1 <== NOT EXECUTED
sb->f_bavail = sb->f_bfree;
20242c4: c2 26 60 1c st %g1, [ %i1 + 0x1c ] <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
sb->f_bsize = rtems_rfs_fs_block_size (fs);
sb->f_frsize = rtems_rfs_fs_media_block_size (fs);
sb->f_blocks = rtems_rfs_fs_media_blocks (fs);
sb->f_bfree = rtems_rfs_fs_blocks (fs) - blocks;
20242c8: c2 26 60 14 st %g1, [ %i1 + 0x14 ] <== NOT EXECUTED
sb->f_fsid = RTEMS_RFS_SB_MAGIC;
sb->f_flag = rtems_rfs_fs_flags (fs);
sb->f_namemax = rtems_rfs_fs_max_name (fs);
return 0;
}
20242cc: 81 c7 e0 08 ret <== NOT EXECUTED
20242d0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
02024704 <rtems_rfs_rtems_symlink>:
int
rtems_rfs_rtems_symlink (rtems_filesystem_location_info_t* parent_loc,
const char* link_name,
const char* node_name)
{
2024704: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
2024708: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
202470c: e6 06 00 00 ld [ %i0 ], %l3 <== NOT EXECUTED
uid_t uid;
gid_t gid;
int rc;
#if defined(RTEMS_POSIX_API)
uid = geteuid ();
2024710: 40 00 21 6d call 202ccc4 <geteuid> <== NOT EXECUTED
2024714: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
gid = getegid ();
2024718: 40 00 21 67 call 202ccb4 <getegid> <== NOT EXECUTED
202471c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
2024720: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
2024724: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2024728: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
202472c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2024730: 7f ff a3 c2 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024734: 94 10 20 00 clr %o2 <== NOT EXECUTED
gid = 0;
#endif
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_symlink (fs, node_name, strlen (node_name),
2024738: 40 00 b3 0e call 2051370 <strlen> <== NOT EXECUTED
202473c: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
2024740: a3 2c 60 10 sll %l1, 0x10, %l1 <== NOT EXECUTED
2024744: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
2024748: a3 34 60 10 srl %l1, 0x10, %l1 <== NOT EXECUTED
link_name, strlen (link_name),
202474c: 40 00 b3 09 call 2051370 <strlen> <== NOT EXECUTED
2024750: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
gid = 0;
#endif
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_symlink (fs, node_name, strlen (node_name),
2024754: 9b 2c a0 10 sll %l2, 0x10, %o5 <== NOT EXECUTED
link_name, strlen (link_name),
2024758: 98 10 00 08 mov %o0, %o4 <== NOT EXECUTED
gid = 0;
#endif
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_symlink (fs, node_name, strlen (node_name),
202475c: e2 23 a0 5c st %l1, [ %sp + 0x5c ] <== NOT EXECUTED
2024760: e6 23 a0 60 st %l3, [ %sp + 0x60 ] <== NOT EXECUTED
2024764: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2024768: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
202476c: 96 10 00 19 mov %i1, %o3 <== NOT EXECUTED
2024770: 9b 33 60 10 srl %o5, 0x10, %o5 <== NOT EXECUTED
2024774: 40 00 7c d3 call 2043ac0 <rtems_rfs_symlink> <== NOT EXECUTED
2024778: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
link_name, strlen (link_name),
uid, gid, parent);
if (rc)
202477c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024780: 22 80 00 0d be,a 20247b4 <rtems_rfs_rtems_symlink+0xb0> <== NOT EXECUTED
2024784: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024788: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
202478c: 40 00 6b c4 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024790: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2024794: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024798: 7f ff a3 ef call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
202479c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("symlink: linking", rc);
20247a0: 40 00 97 38 call 204a480 <__errno> <== NOT EXECUTED
20247a4: 01 00 00 00 nop <== NOT EXECUTED
20247a8: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20247ac: 81 c7 e0 08 ret <== NOT EXECUTED
20247b0: 81 e8 00 00 restore <== NOT EXECUTED
20247b4: 40 00 6b ba call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20247b8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20247bc: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20247c0: 7f ff a3 e5 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20247c4: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
20247c8: 81 c7 e0 08 ret <== NOT EXECUTED
20247cc: 81 e8 00 00 restore <== NOT EXECUTED
02024868 <rtems_rfs_rtems_unlink>:
*/
int
rtems_rfs_rtems_unlink (rtems_filesystem_location_info_t* parent_loc,
rtems_filesystem_location_info_t* loc)
{
2024868: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
202486c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (loc);
uint32_t doff = rtems_rfs_rtems_get_pathloc_doff (loc);
2024870: e2 06 60 04 ld [ %i1 + 4 ], %l1 <== NOT EXECUTED
int
rtems_rfs_rtems_unlink (rtems_filesystem_location_info_t* parent_loc,
rtems_filesystem_location_info_t* loc)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
2024874: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
rtems_rfs_ino parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
2024878: e6 06 00 00 ld [ %i0 ], %l3 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
202487c: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (loc);
2024880: e4 06 40 00 ld [ %i1 ], %l2 <== NOT EXECUTED
2024884: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2024888: 92 10 20 00 clr %o1 <== NOT EXECUTED
202488c: 7f ff a3 6b call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2024890: 94 10 20 00 clr %o2 <== NOT EXECUTED
if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_UNLINK))
printf("rtems-rfs-rtems: unlink: parent:%" PRId32 " doff:%" PRIu32 " ino:%" PRId32 "\n",
parent, doff, ino);
rc = rtems_rfs_unlink (fs, parent, ino, doff, rtems_rfs_unlink_dir_denied);
2024894: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
2024898: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
202489c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
20248a0: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
20248a4: 40 00 7d 07 call 2043cc0 <rtems_rfs_unlink> <== NOT EXECUTED
20248a8: 98 10 20 00 clr %o4 <== NOT EXECUTED
if (rc)
20248ac: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20248b0: 22 80 00 0d be,a 20248e4 <rtems_rfs_rtems_unlink+0x7c> <== NOT EXECUTED
20248b4: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20248b8: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20248bc: 40 00 6b 78 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20248c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20248c4: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
20248c8: 7f ff a3 a3 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20248cc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("unlink: unlink inode", rc);
20248d0: 40 00 96 ec call 204a480 <__errno> <== NOT EXECUTED
20248d4: 01 00 00 00 nop <== NOT EXECUTED
20248d8: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
20248dc: 81 c7 e0 08 ret <== NOT EXECUTED
20248e0: 81 e8 00 00 restore <== NOT EXECUTED
20248e4: 40 00 6b 6e call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20248e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20248ec: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20248f0: 7f ff a3 99 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20248f4: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
20248f8: 81 c7 e0 08 ret <== NOT EXECUTED
20248fc: 81 e8 00 00 restore <== NOT EXECUTED
02023fe8 <rtems_rfs_rtems_unlock>:
/**
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
2023fe8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2023fec: e0 06 20 7c ld [ %i0 + 0x7c ], %l0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2023ff0: 40 00 6d ab call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2023ff4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
2023ff8: f0 04 00 00 ld [ %l0 ], %i0 <== NOT EXECUTED
2023ffc: 7f ff a5 d6 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024000: 81 e8 00 00 restore <== NOT EXECUTED
020249a0 <rtems_rfs_rtems_utime>:
int
rtems_rfs_rtems_utime(rtems_filesystem_location_info_t* pathloc,
time_t atime,
time_t mtime)
{
20249a0: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20249a4: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
20249a8: e4 06 00 00 ld [ %i0 ], %l2 <== NOT EXECUTED
int
rtems_rfs_rtems_utime(rtems_filesystem_location_info_t* pathloc,
time_t atime,
time_t mtime)
{
rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);
20249ac: e0 00 60 34 ld [ %g1 + 0x34 ], %l0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20249b0: 92 10 20 00 clr %o1 <== NOT EXECUTED
20249b4: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 <== NOT EXECUTED
20249b8: 94 10 20 00 clr %o2 <== NOT EXECUTED
20249bc: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20249c0: 7f ff a3 1e call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20249c4: a2 07 bf d8 add %fp, -40, %l1 <== NOT EXECUTED
rtems_rfs_inode_handle inode;
int rc;
rtems_rfs_rtems_lock (fs);
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
20249c8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20249cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20249d0: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20249d4: 40 00 7a b8 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
20249d8: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
20249dc: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
20249e0: 02 80 00 0d be 2024a14 <rtems_rfs_rtems_utime+0x74> <== NOT EXECUTED
20249e4: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
20249e8: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
20249ec: 40 00 6b 2c call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
20249f0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_release (*mutex);
20249f4: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
20249f8: 7f ff a3 57 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
20249fc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("utime: read inode", rc);
2024a00: 40 00 96 a0 call 204a480 <__errno> <== NOT EXECUTED
2024a04: 01 00 00 00 nop <== NOT EXECUTED
2024a08: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED
2024a0c: 81 c7 e0 08 ret <== NOT EXECUTED
2024a10: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_atime (rtems_rfs_inode_handle* handle,
rtems_rfs_time atime)
{
rtems_rfs_write_u32 (&handle->node->atime, atime);
2024a14: 85 36 60 18 srl %i1, 0x18, %g2 <== NOT EXECUTED
2024a18: c4 28 60 10 stb %g2, [ %g1 + 0x10 ] <== NOT EXECUTED
2024a1c: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024a20: 85 36 60 10 srl %i1, 0x10, %g2 <== NOT EXECUTED
2024a24: c4 28 60 11 stb %g2, [ %g1 + 0x11 ] <== NOT EXECUTED
2024a28: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024a2c: 85 36 60 08 srl %i1, 8, %g2 <== NOT EXECUTED
2024a30: c4 28 60 12 stb %g2, [ %g1 + 0x12 ] <== NOT EXECUTED
2024a34: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_mtime (rtems_rfs_inode_handle* handle,
rtems_rfs_time mtime)
{
rtems_rfs_write_u32 (&handle->node->mtime, mtime);
2024a38: 85 36 a0 18 srl %i2, 0x18, %g2 <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_atime (rtems_rfs_inode_handle* handle,
rtems_rfs_time atime)
{
rtems_rfs_write_u32 (&handle->node->atime, atime);
2024a3c: f2 28 60 13 stb %i1, [ %g1 + 0x13 ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_mtime (rtems_rfs_inode_handle* handle,
rtems_rfs_time mtime)
{
rtems_rfs_write_u32 (&handle->node->mtime, mtime);
2024a40: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024a44: 87 36 a0 10 srl %i2, 0x10, %g3 <== NOT EXECUTED
2024a48: c4 28 60 14 stb %g2, [ %g1 + 0x14 ] <== NOT EXECUTED
2024a4c: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024a50: 85 36 a0 08 srl %i2, 8, %g2 <== NOT EXECUTED
2024a54: c6 28 60 15 stb %g3, [ %g1 + 0x15 ] <== NOT EXECUTED
2024a58: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
}
rtems_rfs_inode_set_atime (&inode, atime);
rtems_rfs_inode_set_mtime (&inode, mtime);
rc = rtems_rfs_inode_close (fs, &inode);
2024a5c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2024a60: c4 28 60 16 stb %g2, [ %g1 + 0x16 ] <== NOT EXECUTED
2024a64: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2024a68: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024a6c: f4 28 60 17 stb %i2, [ %g1 + 0x17 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2024a70: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2024a74: 40 00 7a 66 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2024a78: c2 2f bf e8 stb %g1, [ %fp + -24 ] <== NOT EXECUTED
if (rc)
2024a7c: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2024a80: 22 80 00 0d be,a 2024ab4 <rtems_rfs_rtems_utime+0x114> <== NOT EXECUTED
2024a84: e2 04 20 7c ld [ %l0 + 0x7c ], %l1 <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2024a88: e4 04 20 7c ld [ %l0 + 0x7c ], %l2 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2024a8c: 40 00 6b 04 call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024a90: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024a94: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED
2024a98: 7f ff a3 2f call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024a9c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
{
rtems_rfs_rtems_unlock (fs);
return rtems_rfs_rtems_error ("utime: closing inode", rc);
2024aa0: 40 00 96 78 call 204a480 <__errno> <== NOT EXECUTED
2024aa4: 01 00 00 00 nop <== NOT EXECUTED
2024aa8: e2 22 00 00 st %l1, [ %o0 ] <== NOT EXECUTED
2024aac: 81 c7 e0 08 ret <== NOT EXECUTED
2024ab0: 81 e8 00 00 restore <== NOT EXECUTED
2024ab4: 40 00 6a fa call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2024ab8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2024abc: d0 04 40 00 ld [ %l1 ], %o0 <== NOT EXECUTED
2024ac0: 7f ff a3 25 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2024ac4: b0 10 20 00 clr %i0 <== NOT EXECUTED
}
rtems_rfs_rtems_unlock (fs);
return 0;
}
2024ac8: 81 c7 e0 08 ret <== NOT EXECUTED
2024acc: 81 e8 00 00 restore <== NOT EXECUTED
02041c3c <rtems_rfs_rup_quotient>:
* Return a rounded up integer quotient given a dividend and divisor. That is:
* "quotient = dividend / divisor"
*/
int
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)
{
2041c3c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (dividend == 0)
2041c40: 82 96 20 00 orcc %i0, 0, %g1 <== NOT EXECUTED
2041c44: 02 80 00 06 be 2041c5c <rtems_rfs_rup_quotient+0x20> <== NOT EXECUTED
2041c48: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
return 1;
return ((dividend - 1) / divisor) + 1;
2041c4c: 90 00 7f ff add %g1, -1, %o0 <== NOT EXECUTED
2041c50: 40 00 83 4d call 2062984 <.udiv> <== NOT EXECUTED
2041c54: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2041c58: b0 02 20 01 add %o0, 1, %i0 <== NOT EXECUTED
}
2041c5c: 81 c7 e0 08 ret <== NOT EXECUTED
2041c60: 81 e8 00 00 restore <== NOT EXECUTED
02026a00 <rtems_rfs_shell_block>:
return 0;
}
static int
rtems_rfs_shell_block (rtems_rfs_file_system* fs, int argc, char *argv[])
{
2026a00: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
uint8_t* data;
bool state;
int b;
int rc;
if (argc <= 1)
2026a04: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
2026a08: 04 80 00 81 ble 2026c0c <rtems_rfs_shell_block+0x20c> <== NOT EXECUTED
2026a0c: 92 10 20 00 clr %o1 <== NOT EXECUTED
{
printf ("error: no block number provided\n");
return 1;
}
block = strtoul (argv[1], 0, 0);
2026a10: d0 06 a0 04 ld [ %i2 + 4 ], %o0 <== NOT EXECUTED
2026a14: 40 00 b0 0c call 2052a44 <strtoul> <== NOT EXECUTED
2026a18: 94 10 20 00 clr %o2 <== NOT EXECUTED
2026a1c: c2 06 20 7c ld [ %i0 + 0x7c ], %g1 <== NOT EXECUTED
2026a20: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
2026a24: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2026a28: 92 10 20 00 clr %o1 <== NOT EXECUTED
2026a2c: 7f ff 9b 03 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2026a30: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
rc = rtems_rfs_group_bitmap_test (fs, false, block, &state);
2026a34: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026a38: 92 10 20 00 clr %o1 <== NOT EXECUTED
2026a3c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2026a40: 40 00 70 5b call 2042bac <rtems_rfs_group_bitmap_test> <== NOT EXECUTED
2026a44: 96 07 bf ff add %fp, -1, %o3 <== NOT EXECUTED
if (rc > 0)
2026a48: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2026a4c: 14 80 00 4c bg 2026b7c <rtems_rfs_shell_block+0x17c> <== NOT EXECUTED
2026a50: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
printf ("error: testing block state: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
printf (" %5" PRIu32 ": block %s\n", block, state ? "allocated" : "free");
2026a54: 15 00 81 a7 sethi %hi(0x2069c00), %o2 <== NOT EXECUTED
2026a58: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2026a5c: 12 80 00 04 bne 2026a6c <rtems_rfs_shell_block+0x6c> <== NOT EXECUTED
2026a60: 94 12 a3 80 or %o2, 0x380, %o2 <== NOT EXECUTED
2026a64: 15 00 81 a7 sethi %hi(0x2069c00), %o2 <== NOT EXECUTED
2026a68: 94 12 a3 78 or %o2, 0x378, %o2 ! 2069f78 <rtems_rfs_ops+0x520><== NOT EXECUTED
2026a6c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026a70: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026a74: 40 00 a0 7e call 204ec6c <printf> <== NOT EXECUTED
2026a78: 90 12 23 90 or %o0, 0x390, %o0 ! 2069f90 <rtems_rfs_ops+0x538><== NOT EXECUTED
printf ("error: opening buffer handle: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
2026a7c: a2 07 bf f0 add %fp, -16, %l1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2026a80: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2026a84: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2026a88: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2026a8c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026a90: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2026a94: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2026a98: 40 00 63 a1 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2026a9c: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2026aa0: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED
2026aa4: 14 80 00 47 bg 2026bc0 <rtems_rfs_shell_block+0x1c0> <== NOT EXECUTED
2026aa8: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026aac: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
2026ab0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2026ab4: 02 80 00 25 be 2026b48 <rtems_rfs_shell_block+0x148> <== NOT EXECUTED
2026ab8: e4 00 a0 24 ld [ %g2 + 0x24 ], %l2 <== NOT EXECUTED
2026abc: 27 00 81 a8 sethi %hi(0x206a000), %l3 <== NOT EXECUTED
int mod = b % 16;
if (mod == 0)
{
if (b)
printf ("\n");
printf ("%04x ", b);
2026ac0: 29 00 81 a8 sethi %hi(0x206a000), %l4 <== NOT EXECUTED
}
if (mod == 8)
printf (" ");
printf ("%02x ", *data);
2026ac4: a6 14 e0 78 or %l3, 0x78, %l3 <== NOT EXECUTED
int mod = b % 16;
if (mod == 0)
{
if (b)
printf ("\n");
printf ("%04x ", b);
2026ac8: a8 15 20 70 or %l4, 0x70, %l4 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026acc: 10 80 00 0f b 2026b08 <rtems_rfs_shell_block+0x108> <== NOT EXECUTED
2026ad0: a0 10 20 00 clr %l0 <== NOT EXECUTED
b++, data++)
{
int mod = b % 16;
if (mod == 0)
{
if (b)
2026ad4: 12 80 00 37 bne 2026bb0 <rtems_rfs_shell_block+0x1b0> <== NOT EXECUTED
2026ad8: 01 00 00 00 nop <== NOT EXECUTED
printf ("\n");
printf ("%04x ", b);
2026adc: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
2026ae0: 40 00 a0 63 call 204ec6c <printf> <== NOT EXECUTED
2026ae4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
}
if (mod == 8)
printf (" ");
printf ("%02x ", *data);
2026ae8: d2 0c 80 10 ldub [ %l2 + %l0 ], %o1 <== NOT EXECUTED
2026aec: 40 00 a0 60 call 204ec6c <printf> <== NOT EXECUTED
2026af0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026af4: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
b++, data++)
2026af8: a0 04 20 01 inc %l0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026afc: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2026b00: 08 80 00 12 bleu 2026b48 <rtems_rfs_shell_block+0x148> <== NOT EXECUTED
2026b04: 01 00 00 00 nop <== NOT EXECUTED
b++, data++)
{
int mod = b % 16;
if (mod == 0)
2026b08: 82 8c 20 0f andcc %l0, 0xf, %g1 <== NOT EXECUTED
2026b0c: 02 bf ff f2 be 2026ad4 <rtems_rfs_shell_block+0xd4> <== NOT EXECUTED
2026b10: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED
{
if (b)
printf ("\n");
printf ("%04x ", b);
}
if (mod == 8)
2026b14: 80 a0 60 08 cmp %g1, 8 <== NOT EXECUTED
2026b18: 32 bf ff f5 bne,a 2026aec <rtems_rfs_shell_block+0xec> <== NOT EXECUTED
2026b1c: d2 0c 80 10 ldub [ %l2 + %l0 ], %o1 <== NOT EXECUTED
printf (" ");
2026b20: 40 00 a0 cb call 204ee4c <putchar> <== NOT EXECUTED
2026b24: 90 10 20 20 mov 0x20, %o0 <== NOT EXECUTED
printf ("%02x ", *data);
2026b28: d2 0c 80 10 ldub [ %l2 + %l0 ], %o1 <== NOT EXECUTED
2026b2c: 40 00 a0 50 call 204ec6c <printf> <== NOT EXECUTED
2026b30: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026b34: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
b++, data++)
2026b38: a0 04 20 01 inc %l0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
}
for (b = 0, data = rtems_rfs_buffer_data (&buffer);
b < rtems_rfs_fs_block_size (fs);
2026b3c: 80 a0 40 10 cmp %g1, %l0 <== NOT EXECUTED
2026b40: 18 bf ff f3 bgu 2026b0c <rtems_rfs_shell_block+0x10c> <== NOT EXECUTED
2026b44: 82 8c 20 0f andcc %l0, 0xf, %g1 <== NOT EXECUTED
if (mod == 8)
printf (" ");
printf ("%02x ", *data);
}
printf ("\n");
2026b48: 40 00 a0 c1 call 204ee4c <putchar> <== NOT EXECUTED
2026b4c: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2026b50: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2026b54: 40 00 63 29 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2026b58: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: closing buffer handle: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
rtems_rfs_shell_unlock_rfs (fs);
2026b5c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
handle->dirty = false;
2026b60: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2026b64: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2026b68: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2026b6c: 7f ff fd 10 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026b70: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
2026b74: 81 c7 e0 08 ret <== NOT EXECUTED
2026b78: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
rc = rtems_rfs_group_bitmap_test (fs, false, block, &state);
if (rc > 0)
{
rtems_rfs_shell_unlock_rfs (fs);
2026b7c: 7f ff fd 0c call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026b80: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: testing block state: block=%" PRIu32 ": (%d) %s\n",
2026b84: 40 00 a8 ef call 2050f40 <strerror> <== NOT EXECUTED
2026b88: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2026b8c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026b90: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026b94: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2026b98: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026b9c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026ba0: 40 00 a0 33 call 204ec6c <printf> <== NOT EXECUTED
2026ba4: 90 12 23 48 or %o0, 0x348, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
2026ba8: 81 c7 e0 08 ret <== NOT EXECUTED
2026bac: 81 e8 00 00 restore <== NOT EXECUTED
{
int mod = b % 16;
if (mod == 0)
{
if (b)
printf ("\n");
2026bb0: 40 00 a0 a7 call 204ee4c <putchar> <== NOT EXECUTED
2026bb4: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED
printf ("%04x ", b);
2026bb8: 10 bf ff ca b 2026ae0 <rtems_rfs_shell_block+0xe0> <== NOT EXECUTED
2026bbc: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2026bc0: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2026bc4: 40 00 63 0d call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2026bc8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_shell_unlock_rfs (fs);
2026bcc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
handle->dirty = false;
2026bd0: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2026bd4: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2026bd8: 7f ff fc f5 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026bdc: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
printf ("error: requesting buffer handle: block=%" PRIu32 ": (%d) %s\n",
2026be0: 40 00 a8 d8 call 2050f40 <strerror> <== NOT EXECUTED
2026be4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026be8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026bec: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026bf0: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2026bf4: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026bf8: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026bfc: 40 00 a0 1c call 204ec6c <printf> <== NOT EXECUTED
2026c00: 90 12 23 a8 or %o0, 0x3a8, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
2026c04: 81 c7 e0 08 ret <== NOT EXECUTED
2026c08: 81 e8 00 00 restore <== NOT EXECUTED
int b;
int rc;
if (argc <= 1)
{
printf ("error: no block number provided\n");
2026c0c: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026c10: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026c14: 40 00 a0 c2 call 204ef1c <puts> <== NOT EXECUTED
2026c18: 90 12 23 28 or %o0, 0x328, %o0 <== NOT EXECUTED
return 1;
2026c1c: 81 c7 e0 08 ret <== NOT EXECUTED
2026c20: 81 e8 00 00 restore <== NOT EXECUTED
02026c24 <rtems_rfs_shell_data>:
return rc;
}
static int
rtems_rfs_shell_data (rtems_rfs_file_system* fs, int argc, char *argv[])
{
2026c24: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
size_t blocks;
size_t inodes;
int bpcent;
int ipcent;
printf ("RFS Filesystem Data\n");
2026c28: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c2c: 40 00 a0 bc call 204ef1c <puts> <== NOT EXECUTED
2026c30: 90 12 20 80 or %o0, 0x80, %o0 ! 206a080 <rtems_rfs_ops+0x628><== NOT EXECUTED
printf (" flags: %08" PRIx32 "\n", fs->flags);
2026c34: d2 06 00 00 ld [ %i0 ], %o1 <== NOT EXECUTED
2026c38: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c3c: 40 00 a0 0c call 204ec6c <printf> <== NOT EXECUTED
2026c40: 90 12 20 98 or %o0, 0x98, %o0 ! 206a098 <rtems_rfs_ops+0x640><== NOT EXECUTED
#if 0
printf (" device: %08lx\n", rtems_rfs_fs_device (fs));
#endif
printf (" blocks: %zu\n", rtems_rfs_fs_blocks (fs));
2026c44: d2 06 20 04 ld [ %i0 + 4 ], %o1 <== NOT EXECUTED
2026c48: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c4c: 40 00 a0 08 call 204ec6c <printf> <== NOT EXECUTED
2026c50: 90 12 20 b8 or %o0, 0xb8, %o0 ! 206a0b8 <rtems_rfs_ops+0x660><== NOT EXECUTED
printf (" block size: %zu\n", rtems_rfs_fs_block_size (fs));
2026c54: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED
2026c58: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c5c: 40 00 a0 04 call 204ec6c <printf> <== NOT EXECUTED
2026c60: 90 12 20 d8 or %o0, 0xd8, %o0 ! 206a0d8 <rtems_rfs_ops+0x680><== NOT EXECUTED
printf (" size: %" PRIu64 "\n", rtems_rfs_fs_size (fs));
2026c64: 40 00 6a 4b call 2041590 <rtems_rfs_fs_size> <== NOT EXECUTED
2026c68: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026c6c: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
2026c70: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2026c74: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c78: 40 00 9f fd call 204ec6c <printf> <== NOT EXECUTED
2026c7c: 90 12 20 f8 or %o0, 0xf8, %o0 ! 206a0f8 <rtems_rfs_ops+0x6a0><== NOT EXECUTED
printf (" media block size: %" PRIu32 "\n", rtems_rfs_fs_media_block_size (fs));
2026c80: c2 06 20 0c ld [ %i0 + 0xc ], %g1 <== NOT EXECUTED
2026c84: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026c88: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2026c8c: 40 00 9f f8 call 204ec6c <printf> <== NOT EXECUTED
2026c90: 90 12 21 18 or %o0, 0x118, %o0 <== NOT EXECUTED
printf (" media size: %" PRIu64 "\n", rtems_rfs_fs_media_size (fs));
2026c94: 40 00 6a 48 call 20415b4 <rtems_rfs_fs_media_size> <== NOT EXECUTED
2026c98: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026c9c: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED
2026ca0: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2026ca4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026ca8: 40 00 9f f1 call 204ec6c <printf> <== NOT EXECUTED
2026cac: 90 12 21 38 or %o0, 0x138, %o0 ! 206a138 <rtems_rfs_ops+0x6e0><== NOT EXECUTED
printf (" inodes: %" PRIu32 "\n", rtems_rfs_fs_inodes (fs));
2026cb0: d2 06 20 10 ld [ %i0 + 0x10 ], %o1 <== NOT EXECUTED
2026cb4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026cb8: 40 00 9f ed call 204ec6c <printf> <== NOT EXECUTED
2026cbc: 90 12 21 58 or %o0, 0x158, %o0 ! 206a158 <rtems_rfs_ops+0x700><== NOT EXECUTED
printf (" bad blocks: %" PRIu32 "\n", fs->bad_blocks);
2026cc0: d2 06 20 14 ld [ %i0 + 0x14 ], %o1 <== NOT EXECUTED
2026cc4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026cc8: 40 00 9f e9 call 204ec6c <printf> <== NOT EXECUTED
2026ccc: 90 12 21 78 or %o0, 0x178, %o0 ! 206a178 <rtems_rfs_ops+0x720><== NOT EXECUTED
printf (" max. name length: %" PRIu32 "\n", rtems_rfs_fs_max_name (fs));
2026cd0: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 <== NOT EXECUTED
2026cd4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026cd8: 40 00 9f e5 call 204ec6c <printf> <== NOT EXECUTED
2026cdc: 90 12 21 98 or %o0, 0x198, %o0 ! 206a198 <rtems_rfs_ops+0x740><== NOT EXECUTED
printf (" groups: %d\n", fs->group_count);
2026ce0: d2 06 20 20 ld [ %i0 + 0x20 ], %o1 <== NOT EXECUTED
2026ce4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026ce8: 40 00 9f e1 call 204ec6c <printf> <== NOT EXECUTED
2026cec: 90 12 21 b8 or %o0, 0x1b8, %o0 ! 206a1b8 <rtems_rfs_ops+0x760><== NOT EXECUTED
printf (" group blocks: %zd\n", fs->group_blocks);
2026cf0: d2 06 20 24 ld [ %i0 + 0x24 ], %o1 <== NOT EXECUTED
2026cf4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026cf8: 40 00 9f dd call 204ec6c <printf> <== NOT EXECUTED
2026cfc: 90 12 21 d0 or %o0, 0x1d0, %o0 ! 206a1d0 <rtems_rfs_ops+0x778><== NOT EXECUTED
printf (" group inodes: %zd\n", fs->group_inodes);
2026d00: d2 06 20 28 ld [ %i0 + 0x28 ], %o1 <== NOT EXECUTED
2026d04: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d08: 40 00 9f d9 call 204ec6c <printf> <== NOT EXECUTED
2026d0c: 90 12 21 f0 or %o0, 0x1f0, %o0 ! 206a1f0 <rtems_rfs_ops+0x798><== NOT EXECUTED
printf (" inodes per block: %zd\n", fs->inodes_per_block);
2026d10: d2 06 20 2c ld [ %i0 + 0x2c ], %o1 <== NOT EXECUTED
2026d14: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d18: 40 00 9f d5 call 204ec6c <printf> <== NOT EXECUTED
2026d1c: 90 12 22 10 or %o0, 0x210, %o0 ! 206a210 <rtems_rfs_ops+0x7b8><== NOT EXECUTED
printf (" blocks per block: %zd\n", fs->blocks_per_block);
2026d20: d2 06 20 30 ld [ %i0 + 0x30 ], %o1 <== NOT EXECUTED
2026d24: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d28: 40 00 9f d1 call 204ec6c <printf> <== NOT EXECUTED
2026d2c: 90 12 22 30 or %o0, 0x230, %o0 ! 206a230 <rtems_rfs_ops+0x7d8><== NOT EXECUTED
printf (" singly blocks: %zd\n", fs->block_map_singly_blocks);
2026d30: d2 06 20 34 ld [ %i0 + 0x34 ], %o1 <== NOT EXECUTED
2026d34: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d38: 40 00 9f cd call 204ec6c <printf> <== NOT EXECUTED
2026d3c: 90 12 22 50 or %o0, 0x250, %o0 ! 206a250 <rtems_rfs_ops+0x7f8><== NOT EXECUTED
printf (" doublly blocks: %zd\n", fs->block_map_doubly_blocks);
2026d40: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 <== NOT EXECUTED
2026d44: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d48: 40 00 9f c9 call 204ec6c <printf> <== NOT EXECUTED
2026d4c: 90 12 22 70 or %o0, 0x270, %o0 ! 206a270 <rtems_rfs_ops+0x818><== NOT EXECUTED
printf (" max. held buffers: %" PRId32 "\n", fs->max_held_buffers);
2026d50: d2 06 20 3c ld [ %i0 + 0x3c ], %o1 <== NOT EXECUTED
2026d54: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026d58: 40 00 9f c5 call 204ec6c <printf> <== NOT EXECUTED
2026d5c: 90 12 22 90 or %o0, 0x290, %o0 ! 206a290 <rtems_rfs_ops+0x838><== NOT EXECUTED
2026d60: c2 06 20 7c ld [ %i0 + 0x7c ], %g1 <== NOT EXECUTED
2026d64: 92 10 20 00 clr %o1 <== NOT EXECUTED
2026d68: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
2026d6c: 7f ff 9a 33 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
2026d70: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
rtems_rfs_group_usage (fs, &blocks, &inodes);
2026d74: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED
2026d78: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
2026d7c: 40 00 6f 65 call 2042b10 <rtems_rfs_group_usage> <== NOT EXECUTED
2026d80: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_shell_unlock_rfs (fs);
2026d84: 7f ff fc 8a call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026d88: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
bpcent = (blocks * 1000) / rtems_rfs_fs_blocks (fs);
2026d8c: e0 07 bf fc ld [ %fp + -4 ], %l0 <== NOT EXECUTED
2026d90: d2 06 20 04 ld [ %i0 + 4 ], %o1 <== NOT EXECUTED
2026d94: 83 2c 20 02 sll %l0, 2, %g1 <== NOT EXECUTED
2026d98: 91 2c 20 07 sll %l0, 7, %o0 <== NOT EXECUTED
2026d9c: 90 22 00 01 sub %o0, %g1, %o0 <== NOT EXECUTED
2026da0: 90 02 00 10 add %o0, %l0, %o0 <== NOT EXECUTED
2026da4: 40 00 ee f8 call 2062984 <.udiv> <== NOT EXECUTED
2026da8: 91 2a 20 03 sll %o0, 3, %o0 <== NOT EXECUTED
ipcent = (inodes * 1000) / rtems_rfs_fs_inodes (fs);
2026dac: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
return rc;
}
static int
rtems_rfs_shell_data (rtems_rfs_file_system* fs, int argc, char *argv[])
{
2026db0: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
rtems_rfs_shell_unlock_rfs (fs);
bpcent = (blocks * 1000) / rtems_rfs_fs_blocks (fs);
ipcent = (inodes * 1000) / rtems_rfs_fs_inodes (fs);
2026db4: d2 04 60 10 ld [ %l1 + 0x10 ], %o1 <== NOT EXECUTED
2026db8: 87 28 60 07 sll %g1, 7, %g3 <== NOT EXECUTED
2026dbc: 85 28 60 02 sll %g1, 2, %g2 <== NOT EXECUTED
2026dc0: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED
2026dc4: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
rtems_rfs_shell_unlock_rfs (fs);
bpcent = (blocks * 1000) / rtems_rfs_fs_blocks (fs);
2026dc8: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
ipcent = (inodes * 1000) / rtems_rfs_fs_inodes (fs);
2026dcc: 40 00 ee ee call 2062984 <.udiv> <== NOT EXECUTED
2026dd0: 91 28 60 03 sll %g1, 3, %o0 <== NOT EXECUTED
printf (" blocks used: %zd (%d.%d%%)\n",
2026dd4: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
rtems_rfs_group_usage (fs, &blocks, &inodes);
rtems_rfs_shell_unlock_rfs (fs);
bpcent = (blocks * 1000) / rtems_rfs_fs_blocks (fs);
ipcent = (inodes * 1000) / rtems_rfs_fs_inodes (fs);
2026dd8: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
printf (" blocks used: %zd (%d.%d%%)\n",
2026ddc: 40 00 ee ec call 206298c <.div> <== NOT EXECUTED
2026de0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026de4: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2026de8: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
2026dec: 40 00 ef 94 call 2062c3c <.rem> <== NOT EXECUTED
2026df0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026df4: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
2026df8: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026dfc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026e00: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026e04: 40 00 9f 9a call 204ec6c <printf> <== NOT EXECUTED
2026e08: 90 12 22 b0 or %o0, 0x2b0, %o0 ! 206a2b0 <rtems_rfs_ops+0x858><== NOT EXECUTED
blocks, bpcent / 10, bpcent % 10);
printf (" inodes used: %zd (%d.%d%%)\n",
2026e0c: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2026e10: 40 00 ee df call 206298c <.div> <== NOT EXECUTED
2026e14: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2026e18: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2026e1c: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
2026e20: 40 00 ef 87 call 2062c3c <.rem> <== NOT EXECUTED
2026e24: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2026e28: d2 07 bf f8 ld [ %fp + -8 ], %o1 <== NOT EXECUTED
inodes, ipcent / 10, ipcent % 10);
return 0;
}
2026e2c: b0 10 20 00 clr %i0 <== NOT EXECUTED
bpcent = (blocks * 1000) / rtems_rfs_fs_blocks (fs);
ipcent = (inodes * 1000) / rtems_rfs_fs_inodes (fs);
printf (" blocks used: %zd (%d.%d%%)\n",
blocks, bpcent / 10, bpcent % 10);
printf (" inodes used: %zd (%d.%d%%)\n",
2026e30: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026e34: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2026e38: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026e3c: 40 00 9f 8c call 204ec6c <printf> <== NOT EXECUTED
2026e40: 90 12 22 d8 or %o0, 0x2d8, %o0 ! 206a2d8 <rtems_rfs_ops+0x880><== NOT EXECUTED
inodes, ipcent / 10, ipcent % 10);
return 0;
}
2026e44: 81 c7 e0 08 ret <== NOT EXECUTED
2026e48: 81 e8 00 00 restore <== NOT EXECUTED
020266a0 <rtems_rfs_shell_dir>:
return 0;
}
static int
rtems_rfs_shell_dir (rtems_rfs_file_system* fs, int argc, char *argv[])
{
20266a0: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED
bool state;
int entry;
int b;
int rc;
if (argc <= 1)
20266a4: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
20266a8: 04 80 00 ca ble 20269d0 <rtems_rfs_shell_dir+0x330> <== NOT EXECUTED
20266ac: 92 10 20 00 clr %o1 <== NOT EXECUTED
{
printf ("error: no block number provided\n");
return 1;
}
block = strtoul (argv[1], 0, 0);
20266b0: d0 06 a0 04 ld [ %i2 + 4 ], %o0 <== NOT EXECUTED
20266b4: 40 00 b0 e4 call 2052a44 <strtoul> <== NOT EXECUTED
20266b8: 94 10 20 00 clr %o2 <== NOT EXECUTED
20266bc: c2 06 20 7c ld [ %i0 + 0x7c ], %g1 <== NOT EXECUTED
20266c0: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
20266c4: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20266c8: 92 10 20 00 clr %o1 <== NOT EXECUTED
20266cc: 7f ff 9b db call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20266d0: 94 10 20 00 clr %o2 <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
rc = rtems_rfs_group_bitmap_test (fs, false, block, &state);
20266d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20266d8: 92 10 20 00 clr %o1 <== NOT EXECUTED
20266dc: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
20266e0: 40 00 71 33 call 2042bac <rtems_rfs_group_bitmap_test> <== NOT EXECUTED
20266e4: 96 07 bf ff add %fp, -1, %o3 <== NOT EXECUTED
if (rc > 0)
20266e8: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
20266ec: 14 80 00 80 bg 20268ec <rtems_rfs_shell_dir+0x24c> <== NOT EXECUTED
20266f0: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
printf ("error: testing block state: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
printf (" %5" PRIu32 ": block %s\n", block, state ? "allocated" : "free");
20266f4: 15 00 81 a7 sethi %hi(0x2069c00), %o2 <== NOT EXECUTED
20266f8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20266fc: 12 80 00 04 bne 202670c <rtems_rfs_shell_dir+0x6c> <== NOT EXECUTED
2026700: 94 12 a3 80 or %o2, 0x380, %o2 <== NOT EXECUTED
2026704: 15 00 81 a7 sethi %hi(0x2069c00), %o2 <== NOT EXECUTED
2026708: 94 12 a3 78 or %o2, 0x378, %o2 ! 2069f78 <rtems_rfs_ops+0x520><== NOT EXECUTED
202670c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026710: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026714: 40 00 a1 56 call 204ec6c <printf> <== NOT EXECUTED
2026718: 90 12 23 90 or %o0, 0x390, %o0 ! 2069f90 <rtems_rfs_ops+0x538><== NOT EXECUTED
printf ("error: opening buffer handle: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
202671c: ae 07 bf f0 add %fp, -16, %l7 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2026720: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2026724: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2026728: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
202672c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026730: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2026734: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
2026738: 40 00 64 79 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
202673c: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2026740: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED
2026744: 14 80 00 90 bg 2026984 <rtems_rfs_shell_dir+0x2e4> <== NOT EXECUTED
2026748: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== NOT EXECUTED
b = 0;
entry = 1;
data = rtems_rfs_buffer_data (&buffer);
while (b < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE - 1))
202674c: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
2026750: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
2026754: 02 80 00 81 be 2026958 <rtems_rfs_shell_dir+0x2b8> <== NOT EXECUTED
2026758: e0 00 a0 24 ld [ %g2 + 0x24 ], %l0 <== NOT EXECUTED
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
elength = rtems_rfs_dir_entry_length (data);
202675c: c2 0c 20 09 ldub [ %l0 + 9 ], %g1 <== NOT EXECUTED
2026760: e2 0c 20 08 ldub [ %l0 + 8 ], %l1 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2026764: 2d 00 00 3f sethi %hi(0xfc00), %l6 <== NOT EXECUTED
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
elength = rtems_rfs_dir_entry_length (data);
2026768: a3 2c 60 08 sll %l1, 8, %l1 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
202676c: ac 15 a3 ff or %l6, 0x3ff, %l6 <== NOT EXECUTED
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
elength = rtems_rfs_dir_entry_length (data);
2026770: a2 14 40 01 or %l1, %g1, %l1 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
2026774: c6 0c 00 00 ldub [ %l0 ], %g3 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (data);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2026778: 80 a4 40 16 cmp %l1, %l6 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
202677c: c4 0c 20 01 ldub [ %l0 + 1 ], %g2 <== NOT EXECUTED
2026780: c2 0c 20 02 ldub [ %l0 + 2 ], %g1 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (data);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
2026784: 02 80 00 75 be 2026958 <rtems_rfs_shell_dir+0x2b8> <== NOT EXECUTED
2026788: c8 0c 20 03 ldub [ %l0 + 3 ], %g4 <== NOT EXECUTED
break;
if ((elength < RTEMS_RFS_DIR_ENTRY_SIZE) ||
202678c: 80 a4 60 09 cmp %l1, 9 <== NOT EXECUTED
2026790: 04 80 00 6d ble 2026944 <rtems_rfs_shell_dir+0x2a4> <== NOT EXECUTED
2026794: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
2026798: 88 09 20 ff and %g4, 0xff, %g4 <== NOT EXECUTED
202679c: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
20267a0: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
20267a4: 96 11 00 03 or %g4, %g3, %o3 <== NOT EXECUTED
20267a8: 82 08 60 ff and %g1, 0xff, %g1 <== NOT EXECUTED
20267ac: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20267b0: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20267b4: 96 12 c0 02 or %o3, %g2, %o3 <== NOT EXECUTED
break;
}
length = elength - RTEMS_RFS_DIR_ENTRY_SIZE;
printf (" %5d: %04x inode=%-6" PRIu32 " hash=%08" PRIx32 " name[%03u]=",
20267b8: 2b 00 81 a8 sethi %hi(0x206a000), %l5 <== NOT EXECUTED
length = 50;
for (c = 0; c < length; c++)
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
if (length < elength - RTEMS_RFS_DIR_ENTRY_SIZE)
printf ("...");
20267bc: 3b 00 81 a8 sethi %hi(0x206a000), %i5 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
20267c0: 96 12 c0 01 or %o3, %g1, %o3 <== NOT EXECUTED
break;
}
length = elength - RTEMS_RFS_DIR_ENTRY_SIZE;
printf (" %5d: %04x inode=%-6" PRIu32 " hash=%08" PRIx32 " name[%03u]=",
20267c4: aa 15 60 38 or %l5, 0x38, %l5 <== NOT EXECUTED
length = 50;
for (c = 0; c < length; c++)
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
if (length < elength - RTEMS_RFS_DIR_ENTRY_SIZE)
printf ("...");
20267c8: ba 17 60 68 or %i5, 0x68, %i5 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
20267cc: a6 10 20 00 clr %l3 <== NOT EXECUTED
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
break;
if ((elength < RTEMS_RFS_DIR_ENTRY_SIZE) ||
(elength >= rtems_rfs_fs_max_name (fs)))
20267d0: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 <== NOT EXECUTED
20267d4: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
20267d8: 1a 80 00 5b bcc 2026944 <rtems_rfs_shell_dir+0x2a4> <== NOT EXECUTED
20267dc: 80 a2 e0 00 cmp %o3, 0 <== NOT EXECUTED
{
printf (" %5d: entry length appears corrupt: %d\n", entry, elength);
break;
}
if ((eino < RTEMS_RFS_ROOT_INO) || (eino >= rtems_rfs_fs_inodes (fs)))
20267e0: 02 80 00 82 be 20269e8 <rtems_rfs_shell_dir+0x348> <== NOT EXECUTED
20267e4: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
20267e8: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED
20267ec: 80 a0 40 0b cmp %g1, %o3 <== NOT EXECUTED
20267f0: 08 80 00 7e bleu 20269e8 <rtems_rfs_shell_dir+0x348> <== NOT EXECUTED
20267f4: a4 04 7f f6 add %l1, -10, %l2 <== NOT EXECUTED
break;
}
length = elength - RTEMS_RFS_DIR_ENTRY_SIZE;
printf (" %5d: %04x inode=%-6" PRIu32 " hash=%08" PRIx32 " name[%03u]=",
20267f8: c6 0c 20 05 ldub [ %l0 + 5 ], %g3 <== NOT EXECUTED
20267fc: c2 0c 20 06 ldub [ %l0 + 6 ], %g1 <== NOT EXECUTED
2026800: d8 0c 20 04 ldub [ %l0 + 4 ], %o4 <== NOT EXECUTED
2026804: c4 0c 20 07 ldub [ %l0 + 7 ], %g2 <== NOT EXECUTED
2026808: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
202680c: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2026810: 99 2b 20 18 sll %o4, 0x18, %o4 <== NOT EXECUTED
2026814: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
2026818: 98 13 00 03 or %o4, %g3, %o4 <== NOT EXECUTED
202681c: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
2026820: 98 13 00 02 or %o4, %g2, %o4 <== NOT EXECUTED
2026824: 94 10 00 13 mov %l3, %o2 <== NOT EXECUTED
2026828: 98 13 00 01 or %o4, %g1, %o4 <== NOT EXECUTED
202682c: 40 00 a1 10 call 204ec6c <printf> <== NOT EXECUTED
2026830: 9a 10 00 12 mov %l2, %o5 <== NOT EXECUTED
2026834: 80 a4 a0 32 cmp %l2, 0x32 <== NOT EXECUTED
2026838: 04 80 00 3a ble 2026920 <rtems_rfs_shell_dir+0x280> <== NOT EXECUTED
202683c: b6 10 00 12 mov %l2, %i3 <== NOT EXECUTED
2026840: b6 10 20 32 mov 0x32, %i3 <== NOT EXECUTED
length);
if (length > 50)
length = 50;
for (c = 0; c < length; c++)
2026844: b8 10 20 00 clr %i4 <== NOT EXECUTED
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
2026848: 82 04 00 1c add %l0, %i4, %g1 <== NOT EXECUTED
202684c: d0 08 60 0a ldub [ %g1 + 0xa ], %o0 <== NOT EXECUTED
2026850: 40 00 a1 7f call 204ee4c <putchar> <== NOT EXECUTED
2026854: b8 07 20 01 inc %i4 <== NOT EXECUTED
length);
if (length > 50)
length = 50;
for (c = 0; c < length; c++)
2026858: 80 a6 c0 1c cmp %i3, %i4 <== NOT EXECUTED
202685c: 14 bf ff fc bg 202684c <rtems_rfs_shell_dir+0x1ac> <== NOT EXECUTED
2026860: 82 04 00 1c add %l0, %i4, %g1 <== NOT EXECUTED
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
if (length < elength - RTEMS_RFS_DIR_ENTRY_SIZE)
2026864: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2026868: 14 80 00 34 bg 2026938 <rtems_rfs_shell_dir+0x298> <== NOT EXECUTED
202686c: 01 00 00 00 nop <== NOT EXECUTED
printf ("...");
printf ("\n");
2026870: 40 00 a1 77 call 204ee4c <putchar> <== NOT EXECUTED
2026874: 90 10 20 0a mov 0xa, %o0 ! a <PROM_START+0xa> <== NOT EXECUTED
b = 0;
entry = 1;
data = rtems_rfs_buffer_data (&buffer);
while (b < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE - 1))
2026878: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
if (length < elength - RTEMS_RFS_DIR_ENTRY_SIZE)
printf ("...");
printf ("\n");
b += elength;
202687c: a6 04 c0 11 add %l3, %l1, %l3 <== NOT EXECUTED
b = 0;
entry = 1;
data = rtems_rfs_buffer_data (&buffer);
while (b < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE - 1))
2026880: 82 00 7f f5 add %g1, -11, %g1 <== NOT EXECUTED
2026884: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED
2026888: 1a 80 00 34 bcc 2026958 <rtems_rfs_shell_dir+0x2b8> <== NOT EXECUTED
202688c: a0 04 00 11 add %l0, %l1, %l0 <== NOT EXECUTED
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
elength = rtems_rfs_dir_entry_length (data);
2026890: c2 0c 20 09 ldub [ %l0 + 9 ], %g1 <== NOT EXECUTED
2026894: e2 0c 20 08 ldub [ %l0 + 8 ], %l1 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
2026898: c6 0c 00 00 ldub [ %l0 ], %g3 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (data);
202689c: a3 2c 60 08 sll %l1, 8, %l1 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
20268a0: c4 0c 20 01 ldub [ %l0 + 1 ], %g2 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (data);
20268a4: a2 14 40 01 or %l1, %g1, %l1 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
20268a8: c8 0c 20 03 ldub [ %l0 + 3 ], %g4 <== NOT EXECUTED
elength = rtems_rfs_dir_entry_length (data);
if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)
20268ac: 80 a4 40 16 cmp %l1, %l6 <== NOT EXECUTED
20268b0: 02 80 00 2a be 2026958 <rtems_rfs_shell_dir+0x2b8> <== NOT EXECUTED
20268b4: c2 0c 20 02 ldub [ %l0 + 2 ], %g1 <== NOT EXECUTED
break;
if ((elength < RTEMS_RFS_DIR_ENTRY_SIZE) ||
20268b8: 80 a4 60 09 cmp %l1, 9 <== NOT EXECUTED
20268bc: 04 80 00 22 ble 2026944 <rtems_rfs_shell_dir+0x2a4> <== NOT EXECUTED
20268c0: a8 05 20 01 inc %l4 <== NOT EXECUTED
rtems_rfs_ino eino;
int elength;
int length;
int c;
eino = rtems_rfs_dir_entry_ino (data);
20268c4: 96 09 20 ff and %g4, 0xff, %o3 <== NOT EXECUTED
20268c8: 87 28 e0 18 sll %g3, 0x18, %g3 <== NOT EXECUTED
20268cc: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
20268d0: 96 12 c0 03 or %o3, %g3, %o3 <== NOT EXECUTED
20268d4: 82 08 60 ff and %g1, 0xff, %g1 <== NOT EXECUTED
20268d8: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
20268dc: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
20268e0: 96 12 c0 02 or %o3, %g2, %o3 <== NOT EXECUTED
20268e4: 10 bf ff bb b 20267d0 <rtems_rfs_shell_dir+0x130> <== NOT EXECUTED
20268e8: 96 12 c0 01 or %o3, %g1, %o3 <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
rc = rtems_rfs_group_bitmap_test (fs, false, block, &state);
if (rc > 0)
{
rtems_rfs_shell_unlock_rfs (fs);
20268ec: 7f ff fd b0 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
20268f0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: testing block state: block=%" PRIu32 ": (%d) %s\n",
20268f4: 40 00 a9 93 call 2050f40 <strerror> <== NOT EXECUTED
20268f8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20268fc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026900: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026904: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2026908: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
202690c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026910: 40 00 a0 d7 call 204ec6c <printf> <== NOT EXECUTED
2026914: 90 12 23 48 or %o0, 0x348, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
2026918: 81 c7 e0 08 ret <== NOT EXECUTED
202691c: 81 e8 00 00 restore <== NOT EXECUTED
length);
if (length > 50)
length = 50;
for (c = 0; c < length; c++)
2026920: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
2026924: 14 bf ff c9 bg 2026848 <rtems_rfs_shell_dir+0x1a8> <== NOT EXECUTED
2026928: b8 10 20 00 clr %i4 <== NOT EXECUTED
printf ("%c", data[RTEMS_RFS_DIR_ENTRY_SIZE + c]);
if (length < elength - RTEMS_RFS_DIR_ENTRY_SIZE)
202692c: 80 a4 80 1b cmp %l2, %i3 <== NOT EXECUTED
2026930: 04 bf ff d0 ble 2026870 <rtems_rfs_shell_dir+0x1d0> <== NOT EXECUTED
2026934: 01 00 00 00 nop <== NOT EXECUTED
printf ("...");
2026938: 40 00 a0 cd call 204ec6c <printf> <== NOT EXECUTED
202693c: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
2026940: 30 bf ff cc b,a 2026870 <rtems_rfs_shell_dir+0x1d0> <== NOT EXECUTED
break;
if ((elength < RTEMS_RFS_DIR_ENTRY_SIZE) ||
(elength >= rtems_rfs_fs_max_name (fs)))
{
printf (" %5d: entry length appears corrupt: %d\n", entry, elength);
2026944: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026948: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
202694c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2026950: 40 00 a0 c7 call 204ec6c <printf> <== NOT EXECUTED
2026954: 90 12 23 e0 or %o0, 0x3e0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2026958: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
202695c: 40 00 63 a7 call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2026960: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: closing buffer handle: block=%" PRIu32 ": (%d) %s\n",
block, rc, strerror (rc));
return 1;
}
rtems_rfs_shell_unlock_rfs (fs);
2026964: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
handle->dirty = false;
2026968: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
202696c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2026970: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2026974: 7f ff fd 8e call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026978: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
202697c: 81 c7 e0 08 ret <== NOT EXECUTED
2026980: 81 e8 00 00 restore <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2026984: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2026988: 40 00 63 9c call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
202698c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);
if (rc > 0)
{
rtems_rfs_buffer_handle_close (fs, &buffer);
rtems_rfs_shell_unlock_rfs (fs);
2026990: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
handle->dirty = false;
2026994: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2026998: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
202699c: 7f ff fd 84 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
20269a0: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
printf ("error: requesting buffer handle: block=%" PRIu32 ": (%d) %s\n",
20269a4: 40 00 a9 67 call 2050f40 <strerror> <== NOT EXECUTED
20269a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
20269ac: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20269b0: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20269b4: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
20269b8: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
20269bc: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
20269c0: 40 00 a0 ab call 204ec6c <printf> <== NOT EXECUTED
20269c4: 90 12 23 a8 or %o0, 0x3a8, %o0 <== NOT EXECUTED
block, rc, strerror (rc));
return 1;
20269c8: 81 c7 e0 08 ret <== NOT EXECUTED
20269cc: 81 e8 00 00 restore <== NOT EXECUTED
int b;
int rc;
if (argc <= 1)
{
printf ("error: no block number provided\n");
20269d0: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
20269d4: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
20269d8: 40 00 a1 51 call 204ef1c <puts> <== NOT EXECUTED
20269dc: 90 12 23 28 or %o0, 0x328, %o0 <== NOT EXECUTED
return 1;
20269e0: 81 c7 e0 08 ret <== NOT EXECUTED
20269e4: 81 e8 00 00 restore <== NOT EXECUTED
break;
}
if ((eino < RTEMS_RFS_ROOT_INO) || (eino >= rtems_rfs_fs_inodes (fs)))
{
printf (" %5d: entry ino appears corrupt: ino=%" PRId32 "\n", entry, eino);
20269e8: 94 10 00 0b mov %o3, %o2 <== NOT EXECUTED
20269ec: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
20269f0: 40 00 a0 9f call 204ec6c <printf> <== NOT EXECUTED
20269f4: 90 12 20 08 or %o0, 8, %o0 ! 206a008 <rtems_rfs_ops+0x5b0><== NOT EXECUTED
break;
20269f8: 10 bf ff d9 b 202695c <rtems_rfs_shell_dir+0x2bc> <== NOT EXECUTED
20269fc: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
020264e0 <rtems_rfs_shell_group>:
return 0;
}
static int
rtems_rfs_shell_group (rtems_rfs_file_system* fs, int argc, char *argv[])
{
20264e0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int g;
start = 0;
end = fs->group_count - 1;
switch (argc)
20264e4: 80 a6 60 02 cmp %i1, 2 <== NOT EXECUTED
20264e8: 02 80 00 2d be 202659c <rtems_rfs_shell_group+0xbc> <== NOT EXECUTED
20264ec: d2 06 20 20 ld [ %i0 + 0x20 ], %o1 <== NOT EXECUTED
20264f0: 80 a6 60 03 cmp %i1, 3 <== NOT EXECUTED
20264f4: 02 80 00 1c be 2026564 <rtems_rfs_shell_group+0x84> <== NOT EXECUTED
20264f8: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
20264fc: 02 80 00 07 be 2026518 <rtems_rfs_shell_group+0x38> <== NOT EXECUTED
2026500: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
case 3:
start = strtoul (argv[1], 0, 0);
end = strtoul (argv[2], 0, 0);
break;
default:
printf ("error: too many arguments.\n");
2026504: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026508: 40 00 a2 85 call 204ef1c <puts> <== NOT EXECUTED
202650c: 90 12 22 98 or %o0, 0x298, %o0 <== NOT EXECUTED
return 1;
2026510: 81 c7 e0 08 ret <== NOT EXECUTED
2026514: 81 e8 00 00 restore <== NOT EXECUTED
int start;
int end;
int g;
start = 0;
end = fs->group_count - 1;
2026518: a4 02 7f ff add %o1, -1, %l2 <== NOT EXECUTED
202651c: 84 10 20 00 clr %g2 <== NOT EXECUTED
2026520: 83 34 a0 1f srl %l2, 0x1f, %g1 <== NOT EXECUTED
2026524: a6 10 20 00 clr %l3 <== NOT EXECUTED
default:
printf ("error: too many arguments.\n");
return 1;
}
if ((start < 0) || (end < 0) ||
2026528: 80 88 60 ff btst 0xff, %g1 <== NOT EXECUTED
202652c: 12 80 00 08 bne 202654c <rtems_rfs_shell_group+0x6c> <== NOT EXECUTED
2026530: 80 88 a0 ff btst 0xff, %g2 <== NOT EXECUTED
2026534: 12 80 00 06 bne 202654c <rtems_rfs_shell_group+0x6c> <== NOT EXECUTED
2026538: 80 a4 c0 09 cmp %l3, %o1 <== NOT EXECUTED
202653c: 16 80 00 04 bge 202654c <rtems_rfs_shell_group+0x6c> <== NOT EXECUTED
2026540: 80 a4 80 09 cmp %l2, %o1 <== NOT EXECUTED
2026544: 26 80 00 20 bl,a 20265c4 <rtems_rfs_shell_group+0xe4> <== NOT EXECUTED
2026548: c2 06 20 7c ld [ %i0 + 0x7c ], %g1 <== NOT EXECUTED
(start >= fs->group_count) || (end >= fs->group_count))
{
printf ("error: group out of range (0->%d).\n", fs->group_count);
202654c: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026550: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026554: 40 00 a1 c6 call 204ec6c <printf> <== NOT EXECUTED
2026558: 90 12 22 b8 or %o0, 0x2b8, %o0 <== NOT EXECUTED
return 1;
202655c: 81 c7 e0 08 ret <== NOT EXECUTED
2026560: 81 e8 00 00 restore <== NOT EXECUTED
break;
case 2:
start = end = strtoul (argv[1], 0, 0);
break;
case 3:
start = strtoul (argv[1], 0, 0);
2026564: d0 06 a0 04 ld [ %i2 + 4 ], %o0 <== NOT EXECUTED
2026568: 92 10 20 00 clr %o1 <== NOT EXECUTED
202656c: 40 00 b1 36 call 2052a44 <strtoul> <== NOT EXECUTED
2026570: 94 10 20 00 clr %o2 <== NOT EXECUTED
2026574: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
end = strtoul (argv[2], 0, 0);
2026578: d0 06 a0 08 ld [ %i2 + 8 ], %o0 <== NOT EXECUTED
202657c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2026580: 40 00 b1 31 call 2052a44 <strtoul> <== NOT EXECUTED
2026584: 94 10 20 00 clr %o2 <== NOT EXECUTED
2026588: 85 34 e0 1f srl %l3, 0x1f, %g2 <== NOT EXECUTED
202658c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
2026590: 83 32 20 1f srl %o0, 0x1f, %g1 <== NOT EXECUTED
break;
2026594: 10 bf ff e5 b 2026528 <rtems_rfs_shell_group+0x48> <== NOT EXECUTED
2026598: d2 06 20 20 ld [ %i0 + 0x20 ], %o1 <== NOT EXECUTED
switch (argc)
{
case 1:
break;
case 2:
start = end = strtoul (argv[1], 0, 0);
202659c: d0 06 a0 04 ld [ %i2 + 4 ], %o0 <== NOT EXECUTED
20265a0: 92 10 20 00 clr %o1 <== NOT EXECUTED
20265a4: 40 00 b1 28 call 2052a44 <strtoul> <== NOT EXECUTED
20265a8: 94 10 20 00 clr %o2 <== NOT EXECUTED
20265ac: d2 06 20 20 ld [ %i0 + 0x20 ], %o1 <== NOT EXECUTED
20265b0: 85 32 20 1f srl %o0, 0x1f, %g2 <== NOT EXECUTED
20265b4: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
20265b8: 82 10 00 02 mov %g2, %g1 <== NOT EXECUTED
break;
20265bc: 10 bf ff db b 2026528 <rtems_rfs_shell_group+0x48> <== NOT EXECUTED
20265c0: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
20265c4: 92 10 20 00 clr %o1 <== NOT EXECUTED
20265c8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20265cc: 7f ff 9c 1b call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20265d0: 94 10 20 00 clr %o2 <== NOT EXECUTED
return 1;
}
rtems_rfs_shell_lock_rfs (fs);
for (g = start; g <= end; g++)
20265d4: 80 a4 c0 12 cmp %l3, %l2 <== NOT EXECUTED
20265d8: 34 80 00 2e bg,a 2026690 <rtems_rfs_shell_group+0x1b0> <== NOT EXECUTED
20265dc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
20265e0: a1 2c e0 04 sll %l3, 4, %l0 <== NOT EXECUTED
20265e4: a2 10 00 13 mov %l3, %l1 <== NOT EXECUTED
20265e8: a7 2c e0 06 sll %l3, 6, %l3 <== NOT EXECUTED
20265ec: a0 04 00 13 add %l0, %l3, %l0 <== NOT EXECUTED
20265f0: 27 00 81 a7 sethi %hi(0x2069c00), %l3 <== NOT EXECUTED
rtems_rfs_group* group = &fs->groups[g];
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
printf (" %4d: base=%-7" PRIu32 " size=%-6zu blocks=%-5zu (%3zu%%) inode=%-5zu (%3zu%%)\n",
20265f4: a6 14 e2 e0 or %l3, 0x2e0, %l3 ! 2069ee0 <rtems_rfs_ops+0x488><== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
for (g = start; g <= end; g++)
{
rtems_rfs_group* group = &fs->groups[g];
20265f8: c4 06 20 1c ld [ %i0 + 0x1c ], %g2 <== NOT EXECUTED
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
20265fc: ee 06 20 28 ld [ %i0 + 0x28 ], %l7 <== NOT EXECUTED
rtems_rfs_shell_lock_rfs (fs);
for (g = start; g <= end; g++)
{
rtems_rfs_group* group = &fs->groups[g];
2026600: 82 00 80 10 add %g2, %l0, %g1 <== NOT EXECUTED
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
2026604: ec 00 60 04 ld [ %g1 + 4 ], %l6 <== NOT EXECUTED
2026608: ea 00 60 18 ld [ %g1 + 0x18 ], %l5 <== NOT EXECUTED
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
printf (" %4d: base=%-7" PRIu32 " size=%-6zu blocks=%-5zu (%3zu%%) inode=%-5zu (%3zu%%)\n",
202660c: fa 00 80 10 ld [ %g2 + %l0 ], %i5 <== NOT EXECUTED
{
rtems_rfs_group* group = &fs->groups[g];
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
2026610: f4 00 60 3c ld [ %g1 + 0x3c ], %i2 <== NOT EXECUTED
for (g = start; g <= end; g++)
{
rtems_rfs_group* group = &fs->groups[g];
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
2026614: aa 25 80 15 sub %l6, %l5, %l5 <== NOT EXECUTED
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
printf (" %4d: base=%-7" PRIu32 " size=%-6zu blocks=%-5zu (%3zu%%) inode=%-5zu (%3zu%%)\n",
2026618: 85 2d 60 02 sll %l5, 2, %g2 <== NOT EXECUTED
202661c: 83 2d 60 04 sll %l5, 4, %g1 <== NOT EXECUTED
2026620: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2026624: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED
2026628: 91 28 60 02 sll %g1, 2, %o0 <== NOT EXECUTED
202662c: 40 00 f0 d6 call 2062984 <.udiv> <== NOT EXECUTED
2026630: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
{
rtems_rfs_group* group = &fs->groups[g];
size_t blocks;
size_t inodes;
blocks = group->size - rtems_rfs_bitmap_map_free (&group->block_bitmap);
inodes = fs->group_inodes - rtems_rfs_bitmap_map_free (&group->inode_bitmap);
2026634: b4 25 c0 1a sub %l7, %i2, %i2 <== NOT EXECUTED
printf (" %4d: base=%-7" PRIu32 " size=%-6zu blocks=%-5zu (%3zu%%) inode=%-5zu (%3zu%%)\n",
2026638: 83 2e a0 04 sll %i2, 4, %g1 <== NOT EXECUTED
202663c: a8 10 00 08 mov %o0, %l4 <== NOT EXECUTED
2026640: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2026644: f4 23 a0 5c st %i2, [ %sp + 0x5c ] <== NOT EXECUTED
2026648: b5 2e a0 02 sll %i2, 2, %i2 <== NOT EXECUTED
202664c: b4 06 80 01 add %i2, %g1, %i2 <== NOT EXECUTED
2026650: 91 2e a0 02 sll %i2, 2, %o0 <== NOT EXECUTED
2026654: 40 00 f0 cc call 2062984 <.udiv> <== NOT EXECUTED
2026658: 90 06 80 08 add %i2, %o0, %o0 <== NOT EXECUTED
202665c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2026660: d0 23 a0 60 st %o0, [ %sp + 0x60 ] <== NOT EXECUTED
2026664: 94 10 00 1d mov %i5, %o2 <== NOT EXECUTED
2026668: 96 10 00 16 mov %l6, %o3 <== NOT EXECUTED
202666c: 98 10 00 15 mov %l5, %o4 <== NOT EXECUTED
2026670: 9a 10 00 14 mov %l4, %o5 <== NOT EXECUTED
2026674: 40 00 a1 7e call 204ec6c <printf> <== NOT EXECUTED
2026678: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
return 1;
}
rtems_rfs_shell_lock_rfs (fs);
for (g = start; g <= end; g++)
202667c: a2 04 60 01 inc %l1 <== NOT EXECUTED
2026680: 80 a4 80 11 cmp %l2, %l1 <== NOT EXECUTED
2026684: 16 bf ff dd bge 20265f8 <rtems_rfs_shell_group+0x118> <== NOT EXECUTED
2026688: a0 04 20 50 add %l0, 0x50, %l0 <== NOT EXECUTED
g, group->base, group->size,
blocks, (blocks * 100) / group->size,
inodes, (inodes * 100) / fs->group_inodes);
}
rtems_rfs_shell_unlock_rfs (fs);
202668c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026690: 7f ff fe 47 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026694: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
2026698: 81 c7 e0 08 ret <== NOT EXECUTED
202669c: 81 e8 00 00 restore <== NOT EXECUTED
02025fcc <rtems_rfs_shell_inode>:
return 0;
}
static int
rtems_rfs_shell_inode (rtems_rfs_file_system* fs, int argc, char *argv[])
{
2025fcc: 9d e3 bf 68 save %sp, -152, %sp <== NOT EXECUTED
bool have_end;
int arg;
int b;
int rc;
total = fs->group_inodes * fs->group_count;
2025fd0: d0 06 20 20 ld [ %i0 + 0x20 ], %o0 <== NOT EXECUTED
2025fd4: d2 06 20 28 ld [ %i0 + 0x28 ], %o1 <== NOT EXECUTED
2025fd8: 7f ff 72 ed call 2002b8c <.umul> <== NOT EXECUTED
2025fdc: a4 10 00 19 mov %i1, %l2 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
2025fe0: 80 a6 60 01 cmp %i1, 1 <== NOT EXECUTED
bool have_end;
int arg;
int b;
int rc;
total = fs->group_inodes * fs->group_count;
2025fe4: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
2025fe8: 04 80 01 38 ble 20264c8 <rtems_rfs_shell_inode+0x4fc> <== NOT EXECUTED
2025fec: b6 02 3f ff add %o0, -1, %i3 <== NOT EXECUTED
}
}
else
{
if (have_end && have_start)
printf ("warning: option ignored: %s\n", argv[arg]);
2025ff0: 39 00 81 a7 sethi %hi(0x2069c00), %i4 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
2025ff4: a2 10 00 1b mov %i3, %l1 <== NOT EXECUTED
}
}
else
{
if (have_end && have_start)
printf ("warning: option ignored: %s\n", argv[arg]);
2025ff8: b8 17 21 20 or %i4, 0x120, %i4 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
2025ffc: aa 10 20 01 mov 1, %l5 <== NOT EXECUTED
2026000: ba 10 20 00 clr %i5 <== NOT EXECUTED
2026004: ae 10 20 00 clr %l7 <== NOT EXECUTED
2026008: b2 10 20 00 clr %i1 <== NOT EXECUTED
202600c: ac 10 20 00 clr %l6 <== NOT EXECUTED
2026010: a8 10 20 00 clr %l4 <== NOT EXECUTED
2026014: 10 80 00 0e b 202604c <rtems_rfs_shell_inode+0x80> <== NOT EXECUTED
2026018: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
break;
}
}
else
{
if (have_end && have_start)
202601c: 12 80 00 e5 bne 20263b0 <rtems_rfs_shell_inode+0x3e4> <== NOT EXECUTED
2026020: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
printf ("warning: option ignored: %s\n", argv[arg]);
else if (!have_start)
{
start = end = strtoul (argv[arg], 0, 0);
2026024: 92 10 20 00 clr %o1 <== NOT EXECUTED
2026028: 94 10 20 00 clr %o2 <== NOT EXECUTED
202602c: 40 00 b2 86 call 2052a44 <strtoul> <== NOT EXECUTED
2026030: ae 10 20 01 mov 1, %l7 <== NOT EXECUTED
2026034: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
2026038: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
202603c: aa 05 60 01 inc %l5 <== NOT EXECUTED
2026040: 80 a4 80 15 cmp %l2, %l5 <== NOT EXECUTED
2026044: 04 80 00 14 ble 2026094 <rtems_rfs_shell_inode+0xc8> <== NOT EXECUTED
2026048: 80 a4 40 13 cmp %l1, %l3 <== NOT EXECUTED
{
if (argv[arg][0] == '-')
202604c: 83 2d 60 02 sll %l5, 2, %g1 <== NOT EXECUTED
2026050: d0 06 80 01 ld [ %i2 + %g1 ], %o0 <== NOT EXECUTED
2026054: c2 4a 00 00 ldsb [ %o0 ], %g1 <== NOT EXECUTED
2026058: 80 a0 60 2d cmp %g1, 0x2d <== NOT EXECUTED
202605c: 02 80 00 cd be 2026390 <rtems_rfs_shell_inode+0x3c4> <== NOT EXECUTED
2026060: 80 8f 60 ff btst 0xff, %i5 <== NOT EXECUTED
break;
}
}
else
{
if (have_end && have_start)
2026064: 12 bf ff ee bne 202601c <rtems_rfs_shell_inode+0x50> <== NOT EXECUTED
2026068: 80 8d e0 ff btst 0xff, %l7 <== NOT EXECUTED
printf ("warning: option ignored: %s\n", argv[arg]);
else if (!have_start)
202606c: 02 bf ff ee be 2026024 <rtems_rfs_shell_inode+0x58> <== NOT EXECUTED
2026070: 92 10 20 00 clr %o1 <== NOT EXECUTED
start = end = strtoul (argv[arg], 0, 0);
have_start = true;
}
else
{
end = strtoul (argv[arg], 0, 0);
2026074: 40 00 b2 74 call 2052a44 <strtoul> <== NOT EXECUTED
2026078: 94 10 20 00 clr %o2 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
202607c: aa 05 60 01 inc %l5 <== NOT EXECUTED
start = end = strtoul (argv[arg], 0, 0);
have_start = true;
}
else
{
end = strtoul (argv[arg], 0, 0);
2026080: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
2026084: 80 a4 80 15 cmp %l2, %l5 <== NOT EXECUTED
2026088: 14 bf ff f1 bg 202604c <rtems_rfs_shell_inode+0x80> <== NOT EXECUTED
202608c: ba 10 20 01 mov 1, %i5 <== NOT EXECUTED
have_end = true;
}
}
}
if ((start >= total) || (end >= total))
2026090: 80 a4 40 13 cmp %l1, %l3 <== NOT EXECUTED
2026094: 1a 80 00 e7 bcc 2026430 <rtems_rfs_shell_inode+0x464> <== NOT EXECUTED
2026098: 80 a4 00 13 cmp %l0, %l3 <== NOT EXECUTED
202609c: 1a 80 00 e5 bcc 2026430 <rtems_rfs_shell_inode+0x464> <== NOT EXECUTED
20260a0: 92 10 20 00 clr %o1 <== NOT EXECUTED
*/
static inline int
rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
{
#if __rtems__
rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
20260a4: c2 06 20 7c ld [ %i0 + 0x7c ], %g1 <== NOT EXECUTED
20260a8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED
20260ac: 7f ff 9d 63 call 200d638 <rtems_semaphore_obtain> <== NOT EXECUTED
20260b0: 94 10 20 00 clr %o2 <== NOT EXECUTED
return 1;
}
rtems_rfs_shell_lock_rfs (fs);
for (ino = start; ino <= end; ino++)
20260b4: 80 a4 00 11 cmp %l0, %l1 <== NOT EXECUTED
20260b8: 18 80 00 b2 bgu 2026380 <rtems_rfs_shell_inode+0x3b4> <== NOT EXECUTED
20260bc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
}
}
if (!error_check_only || error)
{
printf (" %5" PRIu32 ": pos=%06" PRIu32 ":%04zx %c ",
20260c0: 2f 00 81 a7 sethi %hi(0x2069c00), %l7 <== NOT EXECUTED
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
if (links == 0xffff)
20260c4: 39 00 00 3f sethi %hi(0xfc00), %i4 <== NOT EXECUTED
type = "BLK";
else if (RTEMS_RFS_S_ISREG (mode))
type = "REG";
else if (RTEMS_RFS_S_ISLNK (mode))
type = "LNK";
printf ("links=%03i mode=%04x (%s/%03o) bo=%04u bc=%04" PRIu32 " b=[",
20260c8: 3b 00 81 a7 sethi %hi(0x2069c00), %i5 <== NOT EXECUTED
20260cc: 27 00 81 a7 sethi %hi(0x2069c00), %l3 <== NOT EXECUTED
printf (" --\n");
else
{
const char* type;
type = "UKN";
if (RTEMS_RFS_S_ISDIR (mode))
20260d0: 37 00 81 a7 sethi %hi(0x2069c00), %i3 <== NOT EXECUTED
}
}
if (!error_check_only || error)
{
printf (" %5" PRIu32 ": pos=%06" PRIu32 ":%04zx %c ",
20260d4: ae 15 e1 c8 or %l7, 0x1c8, %l7 <== NOT EXECUTED
20260d8: b8 17 23 ff or %i4, 0x3ff, %i4 <== NOT EXECUTED
type = "BLK";
else if (RTEMS_RFS_S_ISREG (mode))
type = "REG";
else if (RTEMS_RFS_S_ISLNK (mode))
type = "LNK";
printf ("links=%03i mode=%04x (%s/%03o) bo=%04u bc=%04" PRIu32 " b=[",
20260dc: ba 17 62 20 or %i5, 0x220, %i5 <== NOT EXECUTED
rtems_rfs_inode_get_links (&inode),
mode, type, mode & ((1 << 10) - 1),
rtems_rfs_inode_get_block_offset (&inode),
rtems_rfs_inode_get_block_count (&inode));
for (b = 0; b < (RTEMS_RFS_INODE_BLOCKS - 1); b++)
printf ("%" PRIu32 " ", rtems_rfs_inode_get_block (&inode, b));
20260e0: a6 14 e2 58 or %l3, 0x258, %l3 <== NOT EXECUTED
printf (" --\n");
else
{
const char* type;
type = "UKN";
if (RTEMS_RFS_S_ISDIR (mode))
20260e4: b6 16 e1 f0 or %i3, 0x1f0, %i3 <== NOT EXECUTED
20260e8: aa 07 bf ff add %fp, -1, %l5 <== NOT EXECUTED
for (ino = start; ino <= end; ino++)
{
rtems_rfs_inode_handle inode;
bool allocated;
rc = rtems_rfs_group_bitmap_test (fs, true, ino, &allocated);
20260ec: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
20260f0: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
20260f4: 40 00 72 ae call 2042bac <rtems_rfs_group_bitmap_test> <== NOT EXECUTED
20260f8: 96 10 00 15 mov %l5, %o3 <== NOT EXECUTED
if (rc > 0)
20260fc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2026100: 14 80 00 d6 bg 2026458 <rtems_rfs_shell_inode+0x48c> <== NOT EXECUTED
2026104: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
printf ("error: testing inode state: ino=%" PRIu32 ": (%d) %s\n",
ino, rc, strerror (rc));
return 1;
}
if (show_all || allocated)
2026108: 12 80 00 05 bne 202611c <rtems_rfs_shell_inode+0x150> <== NOT EXECUTED
202610c: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
2026110: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2026114: 22 80 00 98 be,a 2026374 <rtems_rfs_shell_inode+0x3a8> <== NOT EXECUTED
2026118: a0 04 20 01 inc %l0 <== NOT EXECUTED
{
uint16_t mode;
bool error;
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
202611c: a4 07 bf d4 add %fp, -44, %l2 <== NOT EXECUTED
2026120: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2026124: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026128: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
202612c: 40 00 74 e2 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2026130: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2026134: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2026138: 14 80 00 d6 bg 2026490 <rtems_rfs_shell_inode+0x4c4> <== NOT EXECUTED
202613c: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
error = false;
mode = rtems_rfs_inode_get_mode (&inode);
if (error_check_only)
2026140: 80 8d a0 ff btst 0xff, %l6 <== NOT EXECUTED
* @return uint16_t The mode.
*/
static inline uint16_t
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u16 (&handle->node->mode);
2026144: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2026148: f4 08 60 02 ldub [ %g1 + 2 ], %i2 <== NOT EXECUTED
202614c: b5 2e a0 08 sll %i2, 8, %i2 <== NOT EXECUTED
2026150: 02 80 00 15 be 20261a4 <rtems_rfs_shell_inode+0x1d8> <== NOT EXECUTED
2026154: b4 16 80 02 or %i2, %g2, %i2 <== NOT EXECUTED
{
if (!RTEMS_RFS_S_ISDIR (mode) &&
2026158: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
202615c: 05 00 00 08 sethi %hi(0x2000), %g2 <== NOT EXECUTED
2026160: 82 0e 80 01 and %i2, %g1, %g1 <== NOT EXECUTED
2026164: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026168: 02 80 00 7d be 202635c <rtems_rfs_shell_inode+0x390> <== NOT EXECUTED
202616c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2026170: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
2026174: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026178: 02 80 00 79 be 202635c <rtems_rfs_shell_inode+0x390> <== NOT EXECUTED
202617c: 05 00 00 18 sethi %hi(0x6000), %g2 <== NOT EXECUTED
2026180: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026184: 02 80 00 76 be 202635c <rtems_rfs_shell_inode+0x390> <== NOT EXECUTED
2026188: 05 00 00 20 sethi %hi(0x8000), %g2 <== NOT EXECUTED
202618c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026190: 02 80 00 73 be 202635c <rtems_rfs_shell_inode+0x390> <== NOT EXECUTED
2026194: 05 00 00 28 sethi %hi(0xa000), %g2 <== NOT EXECUTED
}
#endif
}
}
if (!error_check_only || error)
2026198: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
202619c: 02 80 00 70 be 202635c <rtems_rfs_shell_inode+0x390> <== NOT EXECUTED
20261a0: 01 00 00 00 nop <== NOT EXECUTED
{
printf (" %5" PRIu32 ": pos=%06" PRIu32 ":%04zx %c ",
20261a4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
20261a8: c4 0f bf ff ldub [ %fp + -1 ], %g2 <== NOT EXECUTED
20261ac: d4 07 bf e8 ld [ %fp + -24 ], %o2 <== NOT EXECUTED
20261b0: 80 a0 00 02 cmp %g0, %g2 <== NOT EXECUTED
20261b4: 97 28 60 06 sll %g1, 6, %o3 <== NOT EXECUTED
20261b8: 83 28 60 03 sll %g1, 3, %g1 <== NOT EXECUTED
20261bc: 98 60 20 00 subx %g0, 0, %o4 <== NOT EXECUTED
20261c0: 96 22 c0 01 sub %o3, %g1, %o3 <== NOT EXECUTED
20261c4: 98 0b 3f fb and %o4, -5, %o4 <== NOT EXECUTED
20261c8: 90 10 00 17 mov %l7, %o0 <== NOT EXECUTED
20261cc: 98 03 20 46 add %o4, 0x46, %o4 <== NOT EXECUTED
20261d0: 40 00 a2 a7 call 204ec6c <printf> <== NOT EXECUTED
20261d4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
ino, rtems_rfs_buffer_bnum (&inode.buffer),
inode.offset * RTEMS_RFS_INODE_SIZE,
allocated ? 'A' : 'F');
if (!allocated && !forced)
20261d8: c2 0f bf ff ldub [ %fp + -1 ], %g1 <== NOT EXECUTED
20261dc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20261e0: 12 80 00 05 bne 20261f4 <rtems_rfs_shell_inode+0x228> <== NOT EXECUTED
20261e4: b5 2e a0 10 sll %i2, 0x10, %i2 <== NOT EXECUTED
20261e8: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED
20261ec: 02 80 00 7b be 20263d8 <rtems_rfs_shell_inode+0x40c> <== NOT EXECUTED
20261f0: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
printf (" --\n");
else
{
const char* type;
type = "UKN";
if (RTEMS_RFS_S_ISDIR (mode))
20261f4: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
20261f8: 95 36 a0 10 srl %i2, 0x10, %o2 <== NOT EXECUTED
20261fc: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
2026200: 82 0a 80 01 and %o2, %g1, %g1 <== NOT EXECUTED
2026204: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026208: 02 80 00 16 be 2026260 <rtems_rfs_shell_inode+0x294> <== NOT EXECUTED
202620c: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
type = "DIR";
else if (RTEMS_RFS_S_ISCHR (mode))
2026210: 05 00 00 08 sethi %hi(0x2000), %g2 <== NOT EXECUTED
2026214: 17 00 81 a7 sethi %hi(0x2069c00), %o3 <== NOT EXECUTED
2026218: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
202621c: 02 80 00 11 be 2026260 <rtems_rfs_shell_inode+0x294> <== NOT EXECUTED
2026220: 96 12 e1 f8 or %o3, 0x1f8, %o3 <== NOT EXECUTED
type = "CHR";
else if (RTEMS_RFS_S_ISBLK (mode))
2026224: 05 00 00 18 sethi %hi(0x6000), %g2 <== NOT EXECUTED
2026228: 17 00 81 a7 sethi %hi(0x2069c00), %o3 <== NOT EXECUTED
202622c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026230: 02 80 00 0c be 2026260 <rtems_rfs_shell_inode+0x294> <== NOT EXECUTED
2026234: 96 12 e2 00 or %o3, 0x200, %o3 <== NOT EXECUTED
type = "BLK";
else if (RTEMS_RFS_S_ISREG (mode))
2026238: 05 00 00 20 sethi %hi(0x8000), %g2 <== NOT EXECUTED
202623c: 17 00 81 a7 sethi %hi(0x2069c00), %o3 <== NOT EXECUTED
2026240: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026244: 02 80 00 07 be 2026260 <rtems_rfs_shell_inode+0x294> <== NOT EXECUTED
2026248: 96 12 e2 08 or %o3, 0x208, %o3 <== NOT EXECUTED
type = "REG";
else if (RTEMS_RFS_S_ISLNK (mode))
202624c: 05 00 00 28 sethi %hi(0xa000), %g2 <== NOT EXECUTED
2026250: 17 00 81 a7 sethi %hi(0x2069c00), %o3 <== NOT EXECUTED
2026254: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2026258: 02 80 00 7d be 202644c <rtems_rfs_shell_inode+0x480> <== NOT EXECUTED
202625c: 96 12 e2 18 or %o3, 0x218, %o3 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2026260: c6 07 bf e0 ld [ %fp + -32 ], %g3 <== NOT EXECUTED
type = "LNK";
printf ("links=%03i mode=%04x (%s/%03o) bo=%04u bc=%04" PRIu32 " b=[",
2026264: b4 10 20 00 clr %i2 <== NOT EXECUTED
if (links == 0xffff)
2026268: d0 08 e0 01 ldub [ %g3 + 1 ], %o0 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
202626c: d8 08 c0 00 ldub [ %g3 ], %o4 <== NOT EXECUTED
2026270: c2 08 e0 0c ldub [ %g3 + 0xc ], %g1 <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
2026274: 9e 00 e0 0c add %g3, 0xc, %o7 <== NOT EXECUTED
2026278: d2 08 e0 0a ldub [ %g3 + 0xa ], %o1 <== NOT EXECUTED
202627c: da 08 e0 0b ldub [ %g3 + 0xb ], %o5 <== NOT EXECUTED
2026280: c4 0b e0 02 ldub [ %o7 + 2 ], %g2 <== NOT EXECUTED
2026284: c8 0b e0 03 ldub [ %o7 + 3 ], %g4 <== NOT EXECUTED
2026288: c6 0b e0 01 ldub [ %o7 + 1 ], %g3 <== NOT EXECUTED
202628c: 93 2a 60 08 sll %o1, 8, %o1 <== NOT EXECUTED
2026290: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2026294: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2026298: 99 2b 20 08 sll %o4, 8, %o4 <== NOT EXECUTED
202629c: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED
if (links == 0xffff)
20262a0: 98 12 00 0c or %o0, %o4, %o4 <== NOT EXECUTED
20262a4: 82 11 00 01 or %g4, %g1, %g1 <== NOT EXECUTED
20262a8: 90 1b 00 1c xor %o4, %i4, %o0 <== NOT EXECUTED
20262ac: 82 10 40 03 or %g1, %g3, %g1 <== NOT EXECUTED
20262b0: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
20262b4: 82 10 40 02 or %g1, %g2, %g1 <== NOT EXECUTED
20262b8: 9a 13 40 09 or %o5, %o1, %o5 <== NOT EXECUTED
20262bc: c2 23 a0 5c st %g1, [ %sp + 0x5c ] <== NOT EXECUTED
20262c0: 92 60 20 00 subx %g0, 0, %o1 <== NOT EXECUTED
20262c4: 90 10 00 1d mov %i5, %o0 <== NOT EXECUTED
20262c8: 92 0b 00 09 and %o4, %o1, %o1 <== NOT EXECUTED
20262cc: 40 00 a2 68 call 204ec6c <printf> <== NOT EXECUTED
20262d0: 98 0a a3 ff and %o2, 0x3ff, %o4 <== NOT EXECUTED
* @return uint32_t The block number.
*/
static inline uint32_t
rtems_rfs_inode_get_block (rtems_rfs_inode_handle* handle, int block)
{
return rtems_rfs_read_u32 (&handle->node->data.blocks[block]);
20262d4: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
rtems_rfs_inode_get_links (&inode),
mode, type, mode & ((1 << 10) - 1),
rtems_rfs_inode_get_block_offset (&inode),
rtems_rfs_inode_get_block_count (&inode));
for (b = 0; b < (RTEMS_RFS_INODE_BLOCKS - 1); b++)
printf ("%" PRIu32 " ", rtems_rfs_inode_get_block (&inode, b));
20262d8: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
20262dc: 82 00 60 1c add %g1, 0x1c, %g1 <== NOT EXECUTED
20262e0: d2 08 40 1a ldub [ %g1 + %i2 ], %o1 <== NOT EXECUTED
20262e4: 82 00 40 1a add %g1, %i2, %g1 <== NOT EXECUTED
20262e8: c4 08 60 02 ldub [ %g1 + 2 ], %g2 <== NOT EXECUTED
20262ec: c6 08 60 03 ldub [ %g1 + 3 ], %g3 <== NOT EXECUTED
20262f0: c2 08 60 01 ldub [ %g1 + 1 ], %g1 <== NOT EXECUTED
20262f4: 93 2a 60 18 sll %o1, 0x18, %o1 <== NOT EXECUTED
20262f8: 83 28 60 10 sll %g1, 0x10, %g1 <== NOT EXECUTED
20262fc: 92 10 c0 09 or %g3, %o1, %o1 <== NOT EXECUTED
2026300: 92 12 40 01 or %o1, %g1, %o1 <== NOT EXECUTED
2026304: 83 28 a0 08 sll %g2, 8, %g1 <== NOT EXECUTED
2026308: 40 00 a2 59 call 204ec6c <printf> <== NOT EXECUTED
202630c: 92 12 40 01 or %o1, %g1, %o1 <== NOT EXECUTED
2026310: b4 06 a0 04 add %i2, 4, %i2 <== NOT EXECUTED
printf ("links=%03i mode=%04x (%s/%03o) bo=%04u bc=%04" PRIu32 " b=[",
rtems_rfs_inode_get_links (&inode),
mode, type, mode & ((1 << 10) - 1),
rtems_rfs_inode_get_block_offset (&inode),
rtems_rfs_inode_get_block_count (&inode));
for (b = 0; b < (RTEMS_RFS_INODE_BLOCKS - 1); b++)
2026314: 80 a6 a0 10 cmp %i2, 0x10 <== NOT EXECUTED
2026318: 12 bf ff f0 bne 20262d8 <rtems_rfs_shell_inode+0x30c> <== NOT EXECUTED
202631c: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
printf ("%" PRIu32 " ", rtems_rfs_inode_get_block (&inode, b));
printf ("%" PRIu32 "]\n", rtems_rfs_inode_get_block (&inode, b));
2026320: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026324: 82 00 60 1c add %g1, 0x1c, %g1 <== NOT EXECUTED
2026328: c4 08 60 12 ldub [ %g1 + 0x12 ], %g2 <== NOT EXECUTED
202632c: d2 08 60 10 ldub [ %g1 + 0x10 ], %o1 <== NOT EXECUTED
2026330: c6 08 60 11 ldub [ %g1 + 0x11 ], %g3 <== NOT EXECUTED
2026334: c2 08 60 13 ldub [ %g1 + 0x13 ], %g1 <== NOT EXECUTED
2026338: 93 2a 60 18 sll %o1, 0x18, %o1 <== NOT EXECUTED
202633c: 87 28 e0 10 sll %g3, 0x10, %g3 <== NOT EXECUTED
2026340: 92 12 40 03 or %o1, %g3, %o1 <== NOT EXECUTED
2026344: 92 12 40 01 or %o1, %g1, %o1 <== NOT EXECUTED
2026348: 83 28 a0 08 sll %g2, 8, %g1 <== NOT EXECUTED
202634c: 90 12 22 60 or %o0, 0x260, %o0 <== NOT EXECUTED
2026350: 40 00 a2 47 call 204ec6c <printf> <== NOT EXECUTED
2026354: 92 12 40 01 or %o1, %g1, %o1 <== NOT EXECUTED
}
}
rc = rtems_rfs_inode_close (fs, &inode);
2026358: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
202635c: 40 00 74 2c call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2026360: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
2026364: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2026368: 14 80 00 25 bg 20263fc <rtems_rfs_shell_inode+0x430> <== NOT EXECUTED
202636c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
return 1;
}
rtems_rfs_shell_lock_rfs (fs);
for (ino = start; ino <= end; ino++)
2026370: a0 04 20 01 inc %l0 <== NOT EXECUTED
2026374: 80 a4 00 11 cmp %l0, %l1 <== NOT EXECUTED
2026378: 08 bf ff 5d bleu 20260ec <rtems_rfs_shell_inode+0x120> <== NOT EXECUTED
202637c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
return 1;
}
}
}
rtems_rfs_shell_unlock_rfs (fs);
2026380: 7f ff ff 0b call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026384: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
}
2026388: 81 c7 e0 08 ret <== NOT EXECUTED
202638c: 81 e8 00 00 restore <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
2026390: c2 4a 20 01 ldsb [ %o0 + 1 ], %g1 <== NOT EXECUTED
2026394: 80 a0 60 65 cmp %g1, 0x65 <== NOT EXECUTED
2026398: 02 80 00 0e be 20263d0 <rtems_rfs_shell_inode+0x404> <== NOT EXECUTED
202639c: 80 a0 60 66 cmp %g1, 0x66 <== NOT EXECUTED
20263a0: 02 80 00 0a be 20263c8 <rtems_rfs_shell_inode+0x3fc> <== NOT EXECUTED
20263a4: 80 a0 60 61 cmp %g1, 0x61 <== NOT EXECUTED
20263a8: 02 80 00 06 be 20263c0 <rtems_rfs_shell_inode+0x3f4> <== NOT EXECUTED
20263ac: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
}
}
else
{
if (have_end && have_start)
printf ("warning: option ignored: %s\n", argv[arg]);
20263b0: 40 00 a2 2f call 204ec6c <printf> <== NOT EXECUTED
20263b4: 90 10 00 1c mov %i4, %o0 <== NOT EXECUTED
break;
}
}
else
{
if (have_end && have_start)
20263b8: 10 bf ff 22 b 2026040 <rtems_rfs_shell_inode+0x74> <== NOT EXECUTED
20263bc: aa 05 60 01 inc %l5 <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
20263c0: 10 bf ff 1f b 202603c <rtems_rfs_shell_inode+0x70> <== NOT EXECUTED
20263c4: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
case 'e':
error_check_only = true;
break;
case 'f':
forced = true;
break;
20263c8: 10 bf ff 1d b 202603c <rtems_rfs_shell_inode+0x70> <== NOT EXECUTED
20263cc: b2 10 20 01 mov 1, %i1 <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
20263d0: 10 bf ff 1b b 202603c <rtems_rfs_shell_inode+0x70> <== NOT EXECUTED
20263d4: ac 10 20 01 mov 1, %l6 <== NOT EXECUTED
ino, rtems_rfs_buffer_bnum (&inode.buffer),
inode.offset * RTEMS_RFS_INODE_SIZE,
allocated ? 'A' : 'F');
if (!allocated && !forced)
printf (" --\n");
20263d8: 40 00 a2 d1 call 204ef1c <puts> <== NOT EXECUTED
20263dc: 90 12 21 e8 or %o0, 0x1e8, %o0 <== NOT EXECUTED
printf ("%" PRIu32 " ", rtems_rfs_inode_get_block (&inode, b));
printf ("%" PRIu32 "]\n", rtems_rfs_inode_get_block (&inode, b));
}
}
rc = rtems_rfs_inode_close (fs, &inode);
20263e0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
20263e4: 40 00 74 0a call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20263e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if (rc > 0)
20263ec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20263f0: 24 bf ff e1 ble,a 2026374 <rtems_rfs_shell_inode+0x3a8> <== NOT EXECUTED
20263f4: a0 04 20 01 inc %l0 <== NOT EXECUTED
20263f8: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
{
rtems_rfs_shell_unlock_rfs (fs);
20263fc: 7f ff fe ec call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026400: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: closing inode handle: ino=%" PRIu32 ": (%d) %s\n",
2026404: 40 00 aa cf call 2050f40 <strerror> <== NOT EXECUTED
2026408: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
202640c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026410: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026414: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2026418: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
202641c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026420: 40 00 a2 13 call 204ec6c <printf> <== NOT EXECUTED
2026424: 90 12 22 68 or %o0, 0x268, %o0 <== NOT EXECUTED
ino, rc, strerror (rc));
return 1;
2026428: 81 c7 e0 08 ret <== NOT EXECUTED
202642c: 81 e8 00 00 restore <== NOT EXECUTED
}
}
if ((start >= total) || (end >= total))
{
printf ("error: inode out of range (0->%" PRId32 ").\n", total - 1);
2026430: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2026434: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2026438: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
202643c: 40 00 a2 0c call 204ec6c <printf> <== NOT EXECUTED
2026440: 90 12 21 40 or %o0, 0x140, %o0 <== NOT EXECUTED
return 1;
2026444: 81 c7 e0 08 ret <== NOT EXECUTED
2026448: 81 e8 00 00 restore <== NOT EXECUTED
type = "CHR";
else if (RTEMS_RFS_S_ISBLK (mode))
type = "BLK";
else if (RTEMS_RFS_S_ISREG (mode))
type = "REG";
else if (RTEMS_RFS_S_ISLNK (mode))
202644c: 17 00 81 a7 sethi %hi(0x2069c00), %o3 <== NOT EXECUTED
2026450: 10 bf ff 84 b 2026260 <rtems_rfs_shell_inode+0x294> <== NOT EXECUTED
2026454: 96 12 e2 10 or %o3, 0x210, %o3 ! 2069e10 <rtems_rfs_ops+0x3b8><== NOT EXECUTED
2026458: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
bool allocated;
rc = rtems_rfs_group_bitmap_test (fs, true, ino, &allocated);
if (rc > 0)
{
rtems_rfs_shell_unlock_rfs (fs);
202645c: 7f ff fe d4 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026460: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: testing inode state: ino=%" PRIu32 ": (%d) %s\n",
2026464: 40 00 aa b7 call 2050f40 <strerror> <== NOT EXECUTED
2026468: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
202646c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2026470: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2026474: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2026478: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
202647c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026480: 40 00 a1 fb call 204ec6c <printf> <== NOT EXECUTED
2026484: 90 12 21 68 or %o0, 0x168, %o0 <== NOT EXECUTED
ino, rc, strerror (rc));
return 1;
2026488: 81 c7 e0 08 ret <== NOT EXECUTED
202648c: 81 e8 00 00 restore <== NOT EXECUTED
2026490: b4 10 00 08 mov %o0, %i2 <== NOT EXECUTED
bool error;
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
if (rc > 0)
{
rtems_rfs_shell_unlock_rfs (fs);
2026494: 7f ff fe c6 call 2025fac <rtems_rfs_shell_unlock_rfs> <== NOT EXECUTED
2026498: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
printf ("error: opening inode handle: ino=%" PRIu32 ": (%d) %s\n",
202649c: 40 00 aa a9 call 2050f40 <strerror> <== NOT EXECUTED
20264a0: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
20264a4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20264a8: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20264ac: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
20264b0: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
20264b4: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
20264b8: 40 00 a1 ed call 204ec6c <printf> <== NOT EXECUTED
20264bc: 90 12 21 98 or %o0, 0x198, %o0 <== NOT EXECUTED
ino, rc, strerror (rc));
return 1;
20264c0: 81 c7 e0 08 ret <== NOT EXECUTED
20264c4: 81 e8 00 00 restore <== NOT EXECUTED
show_all = false;
error_check_only = false;
forced = false;
have_start = have_end = false;
for (arg = 1; arg < argc; arg++)
20264c8: a2 10 00 1b mov %i3, %l1 <== NOT EXECUTED
20264cc: b2 10 20 00 clr %i1 <== NOT EXECUTED
20264d0: ac 10 20 00 clr %l6 <== NOT EXECUTED
20264d4: a8 10 20 00 clr %l4 <== NOT EXECUTED
20264d8: 10 bf fe ee b 2026090 <rtems_rfs_shell_inode+0xc4> <== NOT EXECUTED
20264dc: a0 10 20 01 mov 1, %l0 <== NOT EXECUTED
02025fac <rtems_rfs_shell_unlock_rfs>:
/**
* Unlock the file system.
*/
static void
rtems_rfs_shell_unlock_rfs (rtems_rfs_file_system* fs)
{
2025fac: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
* Unlock the RFS file system.
*/
static inline void
rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs)
{
rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);
2025fb0: e0 06 20 7c ld [ %i0 + 0x7c ], %l0 <== NOT EXECUTED
rtems_rfs_buffers_release (fs);
2025fb4: 40 00 65 ba call 203f69c <rtems_rfs_buffers_release> <== NOT EXECUTED
2025fb8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2025fbc: f0 04 00 00 ld [ %l0 ], %i0 <== NOT EXECUTED
2025fc0: 7f ff 9d e5 call 200d754 <rtems_semaphore_release> <== NOT EXECUTED
2025fc4: 81 e8 00 00 restore <== NOT EXECUTED
02025cdc <rtems_rfs_shell_usage>:
}
void
rtems_rfs_shell_usage (const char* arg)
{
2025cdc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
printf ("%s: RFS debugger\n", arg);
2025ce0: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025ce4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2025ce8: 40 00 a3 e1 call 204ec6c <printf> <== NOT EXECUTED
2025cec: 90 12 22 c8 or %o0, 0x2c8, %o0 <== NOT EXECUTED
printf (" %s [-hl] <path> <command>\n", arg);
2025cf0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2025cf4: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025cf8: 40 00 a3 dd call 204ec6c <printf> <== NOT EXECUTED
2025cfc: 90 12 22 e0 or %o0, 0x2e0, %o0 ! 2069ae0 <rtems_rfs_ops+0x88><== NOT EXECUTED
printf (" where:\n");
2025d00: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025d04: 40 00 a4 86 call 204ef1c <puts> <== NOT EXECUTED
2025d08: 90 12 23 00 or %o0, 0x300, %o0 ! 2069b00 <rtems_rfs_ops+0xa8><== NOT EXECUTED
printf (" path: Path to the mounted RFS file system\n");
2025d0c: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025d10: 40 00 a4 83 call 204ef1c <puts> <== NOT EXECUTED
2025d14: 90 12 23 10 or %o0, 0x310, %o0 ! 2069b10 <rtems_rfs_ops+0xb8><== NOT EXECUTED
printf (" command: A debugger command. See -l for a list plus help.\n");
2025d18: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025d1c: 40 00 a4 80 call 204ef1c <puts> <== NOT EXECUTED
2025d20: 90 12 23 48 or %o0, 0x348, %o0 ! 2069b48 <rtems_rfs_ops+0xf0><== NOT EXECUTED
printf (" -h: This help\n");
2025d24: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025d28: 40 00 a4 7d call 204ef1c <puts> <== NOT EXECUTED
2025d2c: 90 12 23 88 or %o0, 0x388, %o0 ! 2069b88 <rtems_rfs_ops+0x130><== NOT EXECUTED
printf (" -l: The debugger command list.\n");
2025d30: 31 00 81 a6 sethi %hi(0x2069800), %i0 <== NOT EXECUTED
2025d34: 40 00 a4 7a call 204ef1c <puts> <== NOT EXECUTED
2025d38: 91 ee 23 a0 restore %i0, 0x3a0, %o0 <== NOT EXECUTED
02043ac0 <rtems_rfs_symlink>:
const char* link,
int link_length,
uid_t uid,
gid_t gid,
rtems_rfs_ino parent)
{
2043ac0: 9d e3 bf 00 save %sp, -256, %sp <== NOT EXECUTED
printf (" link:");
for (c = 0; c < link_length; c++)
printf ("%c", link[c]);
}
if (link_length >= rtems_rfs_fs_block_size (fs))
2043ac4: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
const char* link,
int link_length,
uid_t uid,
gid_t gid,
rtems_rfs_ino parent)
{
2043ac8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
printf (" link:");
for (c = 0; c < link_length; c++)
printf ("%c", link[c]);
}
if (link_length >= rtems_rfs_fs_block_size (fs))
2043acc: 80 a7 00 01 cmp %i4, %g1 <== NOT EXECUTED
const char* link,
int link_length,
uid_t uid,
gid_t gid,
rtems_rfs_ino parent)
{
2043ad0: e2 07 a0 5c ld [ %fp + 0x5c ], %l1 <== NOT EXECUTED
printf (" link:");
for (c = 0; c < link_length; c++)
printf ("%c", link[c]);
}
if (link_length >= rtems_rfs_fs_block_size (fs))
2043ad4: 1a 80 00 4a bcc 2043bfc <rtems_rfs_symlink+0x13c> <== NOT EXECUTED
2043ad8: b0 10 20 5b mov 0x5b, %i0 <== NOT EXECUTED
return ENAMETOOLONG;
rc = rtems_rfs_inode_create (fs, parent, name, strlen (name),
2043adc: 40 00 36 25 call 2051370 <strlen> <== NOT EXECUTED
2043ae0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2043ae4: d2 07 a0 60 ld [ %fp + 0x60 ], %o1 <== NOT EXECUTED
2043ae8: 82 07 bf fc add %fp, -4, %g1 <== NOT EXECUTED
2043aec: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
2043af0: bb 2f 60 10 sll %i5, 0x10, %i5 <== NOT EXECUTED
2043af4: a3 2c 60 10 sll %l1, 0x10, %l1 <== NOT EXECUTED
2043af8: bb 37 60 10 srl %i5, 0x10, %i5 <== NOT EXECUTED
2043afc: a3 34 60 10 srl %l1, 0x10, %l1 <== NOT EXECUTED
2043b00: fa 23 a0 5c st %i5, [ %sp + 0x5c ] <== NOT EXECUTED
2043b04: e2 23 a0 60 st %l1, [ %sp + 0x60 ] <== NOT EXECUTED
2043b08: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
2043b0c: c2 23 a0 64 st %g1, [ %sp + 0x64 ] <== NOT EXECUTED
2043b10: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043b14: 19 00 00 28 sethi %hi(0xa000), %o4 <== NOT EXECUTED
2043b18: 9a 10 20 01 mov 1, %o5 <== NOT EXECUTED
2043b1c: 7f ff fe ca call 2043644 <rtems_rfs_inode_create> <== NOT EXECUTED
2043b20: 98 13 21 ff or %o4, 0x1ff, %o4 <== NOT EXECUTED
RTEMS_RFS_S_SYMLINK,
1, uid, gid, &ino);
if (rc > 0)
2043b24: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043b28: 14 80 00 35 bg 2043bfc <rtems_rfs_symlink+0x13c> <== NOT EXECUTED
2043b2c: d2 07 bf fc ld [ %fp + -4 ], %o1 <== NOT EXECUTED
return rc;
rc = rtems_rfs_inode_open (fs, ino, &inode, true);
2043b30: b2 07 bf c4 add %fp, -60, %i1 <== NOT EXECUTED
2043b34: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043b38: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
2043b3c: 7f ff fe 5e call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043b40: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc > 0)
2043b44: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043b48: 14 80 00 2d bg 2043bfc <rtems_rfs_symlink+0x13c> <== NOT EXECUTED
2043b4c: 80 a7 20 13 cmp %i4, 0x13 <== NOT EXECUTED
/*
* If the link length is less than the length of data union in the inode
* place the link into the data area else allocate a block and write the link
* to that.
*/
if (link_length < RTEMS_RFS_INODE_DATA_NAME_SIZE)
2043b50: 18 80 00 22 bgu 2043bd8 <rtems_rfs_symlink+0x118> <== NOT EXECUTED
2043b54: a2 07 bf 74 add %fp, -140, %l1 <== NOT EXECUTED
{
memset (inode.node->data.name, 0, RTEMS_RFS_INODE_DATA_NAME_SIZE);
2043b58: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
memcpy (inode.node->data.name, link, link_length);
2043b5c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
* place the link into the data area else allocate a block and write the link
* to that.
*/
if (link_length < RTEMS_RFS_INODE_DATA_NAME_SIZE)
{
memset (inode.node->data.name, 0, RTEMS_RFS_INODE_DATA_NAME_SIZE);
2043b60: c0 20 60 1c clr [ %g1 + 0x1c ] <== NOT EXECUTED
2043b64: 82 00 60 1c add %g1, 0x1c, %g1 <== NOT EXECUTED
2043b68: c0 20 60 10 clr [ %g1 + 0x10 ] <== NOT EXECUTED
2043b6c: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
2043b70: c0 20 60 08 clr [ %g1 + 8 ] <== NOT EXECUTED
2043b74: c0 20 60 0c clr [ %g1 + 0xc ] <== NOT EXECUTED
memcpy (inode.node->data.name, link, link_length);
2043b78: d0 07 bf d0 ld [ %fp + -48 ], %o0 <== NOT EXECUTED
2043b7c: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2043b80: 40 00 27 8c call 204d9b0 <memcpy> <== NOT EXECUTED
2043b84: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
* @param block_count The block count.
*/
static inline void
rtems_rfs_inode_set_block_count (rtems_rfs_inode_handle* handle, uint32_t block_count)
{
rtems_rfs_write_u32 (&handle->node->block_count, block_count);
2043b88: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
2043b8c: c0 28 60 0c clrb [ %g1 + 0xc ] <== NOT EXECUTED
2043b90: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
2043b94: c0 28 60 0d clrb [ %g1 + 0xd ] <== NOT EXECUTED
2043b98: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
2043b9c: c0 28 60 0e clrb [ %g1 + 0xe ] <== NOT EXECUTED
2043ba0: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
2043ba4: c0 28 60 0f clrb [ %g1 + 0xf ] <== NOT EXECUTED
*/
static inline void
rtems_rfs_inode_set_block_offset (rtems_rfs_inode_handle* handle,
uint16_t block_offset)
{
rtems_rfs_write_u16 (&handle->node->block_offset, block_offset);
2043ba8: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
2043bac: 85 37 20 08 srl %i4, 8, %g2 <== NOT EXECUTED
2043bb0: c4 28 60 0a stb %g2, [ %g1 + 0xa ] <== NOT EXECUTED
2043bb4: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
}
}
rtems_rfs_inode_set_block_offset (&inode, link_length);
rc = rtems_rfs_inode_close (fs, &inode);
2043bb8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043bbc: f8 28 60 0b stb %i4, [ %g1 + 0xb ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043bc0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2043bc4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2043bc8: 7f ff fe 11 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043bcc: c2 2f bf d4 stb %g1, [ %fp + -44 ] <== NOT EXECUTED
return rc;
}
2043bd0: 81 c7 e0 08 ret <== NOT EXECUTED
2043bd4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_rfs_block_map map;
rtems_rfs_block_no block;
rtems_rfs_buffer_handle buffer;
uint8_t* data;
rc = rtems_rfs_block_map_open (fs, &inode, &map);
2043bd8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043bdc: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2043be0: 7f ff ee 31 call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
2043be4: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc > 0)
2043be8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043bec: 04 80 00 06 ble 2043c04 <rtems_rfs_symlink+0x144> <== NOT EXECUTED
2043bf0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
2043bf4: 7f ff fe 06 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043bf8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
return rc;
2043bfc: 81 c7 e0 08 ret <== NOT EXECUTED
2043c00: 81 e8 00 00 restore <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_block_map_grow (fs, &map, 1, &block);
2043c04: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2043c08: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2043c0c: 7f ff ec c7 call 203ef28 <rtems_rfs_block_map_grow> <== NOT EXECUTED
2043c10: 96 07 bf f8 add %fp, -8, %o3 <== NOT EXECUTED
if (rc > 0)
2043c14: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043c18: 04 80 00 07 ble 2043c34 <rtems_rfs_symlink+0x174> <== NOT EXECUTED
2043c1c: d4 07 bf f8 ld [ %fp + -8 ], %o2 <== NOT EXECUTED
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
2043c20: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2043c24: 7f ff ed af call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2043c28: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
2043c2c: 10 bf ff f2 b 2043bf4 <rtems_rfs_symlink+0x134> <== NOT EXECUTED
2043c30: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2043c34: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2043c38: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
handle->buffer = NULL;
2043c3c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
2043c40: a4 07 bf ec add %fp, -20, %l2 <== NOT EXECUTED
2043c44: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043c48: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043c4c: 7f ff ef 34 call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2043c50: 96 10 20 00 clr %o3 <== NOT EXECUTED
if (rc > 0)
2043c54: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043c58: 14 bf ff f3 bg 2043c24 <rtems_rfs_symlink+0x164> <== NOT EXECUTED
2043c5c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
data = rtems_rfs_buffer_data (&buffer);
2043c60: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
memset (data, 0xff, rtems_rfs_fs_block_size (fs));
2043c64: d4 04 20 08 ld [ %l0 + 8 ], %o2 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
data = rtems_rfs_buffer_data (&buffer);
2043c68: e6 00 60 24 ld [ %g1 + 0x24 ], %l3 <== NOT EXECUTED
memset (data, 0xff, rtems_rfs_fs_block_size (fs));
2043c6c: 92 10 20 ff mov 0xff, %o1 <== NOT EXECUTED
2043c70: 40 00 27 e3 call 204dbfc <memset> <== NOT EXECUTED
2043c74: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
memcpy (data, link, link_length);
2043c78: 94 10 00 1c mov %i4, %o2 <== NOT EXECUTED
2043c7c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED
2043c80: 40 00 27 4c call 204d9b0 <memcpy> <== NOT EXECUTED
2043c84: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2043c88: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043c8c: 7f ff ee db call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2043c90: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_block_map_close (fs, &map);
2043c94: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
handle->dirty = false;
2043c98: c0 2f bf ec clrb [ %fp + -20 ] <== NOT EXECUTED
handle->bnum = 0;
2043c9c: c0 27 bf f0 clr [ %fp + -16 ] <== NOT EXECUTED
handle->buffer = NULL;
2043ca0: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
2043ca4: 7f ff ed 8f call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2043ca8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2043cac: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043cb0: 04 bf ff bf ble 2043bac <rtems_rfs_symlink+0xec> <== NOT EXECUTED
2043cb4: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
2043cb8: 10 bf ff cf b 2043bf4 <rtems_rfs_symlink+0x134> <== NOT EXECUTED
2043cbc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
02043900 <rtems_rfs_symlink_read>:
rtems_rfs_symlink_read (rtems_rfs_file_system* fs,
rtems_rfs_ino link,
char* path,
size_t size,
size_t* length)
{
2043900: 9d e3 bf 18 save %sp, -232, %sp <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK_READ))
printf ("rtems-rfs: symlink-read: link:%" PRIu32 "\n", link);
rc = rtems_rfs_inode_open (fs, link, &inode, true);
2043904: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2043908: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_symlink_read (rtems_rfs_file_system* fs,
rtems_rfs_ino link,
char* path,
size_t size,
size_t* length)
{
204390c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK_READ))
printf ("rtems-rfs: symlink-read: link:%" PRIu32 "\n", link);
rc = rtems_rfs_inode_open (fs, link, &inode, true);
2043910: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2043914: a2 07 bf c8 add %fp, -56, %l1 <== NOT EXECUTED
2043918: 7f ff fe e7 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
204391c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc)
2043920: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043924: 12 80 00 0e bne 204395c <rtems_rfs_symlink_read+0x5c> <== NOT EXECUTED
2043928: d2 07 bf d4 ld [ %fp + -44 ], %o1 <== NOT EXECUTED
return rc;
if (!RTEMS_RFS_S_ISLNK (rtems_rfs_inode_get_mode (&inode)))
204392c: 03 00 00 3c sethi %hi(0xf000), %g1 <== NOT EXECUTED
2043930: c4 0a 60 02 ldub [ %o1 + 2 ], %g2 <== NOT EXECUTED
2043934: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2043938: 84 08 80 01 and %g2, %g1, %g2 <== NOT EXECUTED
204393c: 03 00 00 28 sethi %hi(0xa000), %g1 <== NOT EXECUTED
2043940: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2043944: 22 80 00 08 be,a 2043964 <rtems_rfs_symlink_read+0x64> <== NOT EXECUTED
2043948: d4 0a 60 0a ldub [ %o1 + 0xa ], %o2 <== NOT EXECUTED
*length = rtems_rfs_inode_get_block_offset (&inode);
if (size < *length)
{
rtems_rfs_inode_close (fs, &inode);
204394c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043950: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2043954: 7f ff fe ae call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043958: b0 10 20 16 mov 0x16, %i0 <== NOT EXECUTED
return EINVAL;
204395c: 81 c7 e0 08 ret <== NOT EXECUTED
2043960: 81 e8 00 00 restore <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
return EINVAL;
}
*length = rtems_rfs_inode_get_block_offset (&inode);
2043964: c2 0a 60 0b ldub [ %o1 + 0xb ], %g1 <== NOT EXECUTED
2043968: 95 2a a0 08 sll %o2, 8, %o2 <== NOT EXECUTED
204396c: 94 10 40 0a or %g1, %o2, %o2 <== NOT EXECUTED
if (size < *length)
2043970: 80 a2 80 1b cmp %o2, %i3 <== NOT EXECUTED
2043974: 18 bf ff f6 bgu 204394c <rtems_rfs_symlink_read+0x4c> <== NOT EXECUTED
2043978: d4 27 00 00 st %o2, [ %i4 ] <== NOT EXECUTED
* @return uint32_t The block count.
*/
static inline uint32_t
rtems_rfs_inode_get_block_count (rtems_rfs_inode_handle* handle)
{
return rtems_rfs_read_u32 (&handle->node->block_count);
204397c: 82 02 60 0c add %o1, 0xc, %g1 <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
return EINVAL;
}
if (rtems_rfs_inode_get_block_count (&inode) == 0)
2043980: c4 08 60 03 ldub [ %g1 + 3 ], %g2 <== NOT EXECUTED
2043984: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2043988: 12 80 00 18 bne 20439e8 <rtems_rfs_symlink_read+0xe8> <== NOT EXECUTED
204398c: a4 07 bf 78 add %fp, -136, %l2 <== NOT EXECUTED
2043990: c4 0a 60 0c ldub [ %o1 + 0xc ], %g2 <== NOT EXECUTED
2043994: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
2043998: 12 80 00 15 bne 20439ec <rtems_rfs_symlink_read+0xec> <== NOT EXECUTED
204399c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20439a0: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
20439a4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20439a8: 32 80 00 12 bne,a 20439f0 <rtems_rfs_symlink_read+0xf0> <== NOT EXECUTED
20439ac: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20439b0: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
20439b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20439b8: 32 80 00 0e bne,a 20439f0 <rtems_rfs_symlink_read+0xf0> <== NOT EXECUTED
20439bc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
{
memcpy (path, inode.node->data.name, *length);
20439c0: 92 02 60 1c add %o1, 0x1c, %o1 <== NOT EXECUTED
20439c4: 40 00 27 fb call 204d9b0 <memcpy> <== NOT EXECUTED
20439c8: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
return rc;
}
}
path[*length] = '\0';
20439cc: c2 07 00 00 ld [ %i4 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_inode_close (fs, &inode);
20439d0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
return rc;
}
}
path[*length] = '\0';
20439d4: c0 2e 80 01 clrb [ %i2 + %g1 ] <== NOT EXECUTED
rc = rtems_rfs_inode_close (fs, &inode);
20439d8: 7f ff fe 8d call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
20439dc: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
}
20439e0: 81 c7 e0 08 ret <== NOT EXECUTED
20439e4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
rtems_rfs_block_map map;
rtems_rfs_block_no block;
rtems_rfs_buffer_handle buffer;
char* data;
rc = rtems_rfs_block_map_open (fs, &inode, &map);
20439e8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20439ec: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
20439f0: 7f ff ee ad call 203f4a4 <rtems_rfs_block_map_open> <== NOT EXECUTED
20439f4: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
if (rc > 0)
20439f8: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
20439fc: 04 80 00 06 ble 2043a14 <rtems_rfs_symlink_read+0x114> <== NOT EXECUTED
2043a00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
2043a04: 7f ff fe 82 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043a08: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2043a0c: 81 c7 e0 08 ret <== NOT EXECUTED
2043a10: 81 e8 00 00 restore <== NOT EXECUTED
{
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);
2043a14: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043a18: 94 10 20 00 clr %o2 <== NOT EXECUTED
2043a1c: 96 10 20 00 clr %o3 <== NOT EXECUTED
2043a20: 7f ff eb e1 call 203e9a4 <rtems_rfs_block_map_seek> <== NOT EXECUTED
2043a24: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED
if (rc > 0)
2043a28: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043a2c: 04 80 00 07 ble 2043a48 <rtems_rfs_symlink_read+0x148> <== NOT EXECUTED
2043a30: d4 07 bf fc ld [ %fp + -4 ], %o2 <== NOT EXECUTED
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
2043a34: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043a38: 7f ff ee 2a call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2043a3c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
2043a40: 10 bf ff f1 b 2043a04 <rtems_rfs_symlink_read+0x104> <== NOT EXECUTED
2043a44: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_open (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
handle->dirty = false;
2043a48: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2043a4c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2043a50: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
2043a54: a6 07 bf f0 add %fp, -16, %l3 <== NOT EXECUTED
2043a58: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043a5c: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043a60: 7f ff ef af call 203f91c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
2043a64: 96 10 20 00 clr %o3 <== NOT EXECUTED
if (rc > 0)
2043a68: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043a6c: 14 bf ff f3 bg 2043a38 <rtems_rfs_symlink_read+0x138> <== NOT EXECUTED
2043a70: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &inode);
return rc;
}
data = rtems_rfs_buffer_data (&buffer);
memcpy (path, data, *length);
2043a74: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2043a78: d4 07 00 00 ld [ %i4 ], %o2 <== NOT EXECUTED
2043a7c: d2 00 60 24 ld [ %g1 + 0x24 ], %o1 <== NOT EXECUTED
2043a80: 40 00 27 cc call 204d9b0 <memcpy> <== NOT EXECUTED
2043a84: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED
*/
static inline int
rtems_rfs_buffer_handle_close (rtems_rfs_file_system* fs,
rtems_rfs_buffer_handle* handle)
{
rtems_rfs_buffer_handle_release (fs, handle);
2043a88: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2043a8c: 7f ff ef 5b call 203f7f8 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
2043a90: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
return rc;
}
rc = rtems_rfs_block_map_close (fs, &map);
2043a94: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
handle->dirty = false;
2043a98: c0 2f bf f0 clrb [ %fp + -16 ] <== NOT EXECUTED
handle->bnum = 0;
2043a9c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED
handle->buffer = NULL;
2043aa0: c0 27 bf f8 clr [ %fp + -8 ] <== NOT EXECUTED
2043aa4: 7f ff ee 0f call 203f2e0 <rtems_rfs_block_map_close> <== NOT EXECUTED
2043aa8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2043aac: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043ab0: 24 bf ff c8 ble,a 20439d0 <rtems_rfs_symlink_read+0xd0> <== NOT EXECUTED
2043ab4: c2 07 00 00 ld [ %i4 ], %g1 <== NOT EXECUTED
rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, false);
if (rc > 0)
{
rtems_rfs_block_map_close (fs, &map);
rtems_rfs_inode_close (fs, &inode);
2043ab8: 10 bf ff d3 b 2043a04 <rtems_rfs_symlink_read+0x104> <== NOT EXECUTED
2043abc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
02043cc0 <rtems_rfs_unlink>:
rtems_rfs_unlink (rtems_rfs_file_system* fs,
rtems_rfs_ino parent,
rtems_rfs_ino target,
uint32_t doff,
rtems_rfs_unlink_dir dir_mode)
{
2043cc0: 9d e3 bf 50 save %sp, -176, %sp <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: unlink: parent(%" PRIu32 ") -X-> (%" PRIu32 ")\n", parent, target);
rc = rtems_rfs_inode_open (fs, target, &target_inode, true);
2043cc4: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
2043cc8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
rtems_rfs_unlink (rtems_rfs_file_system* fs,
rtems_rfs_ino parent,
rtems_rfs_ino target,
uint32_t doff,
rtems_rfs_unlink_dir dir_mode)
{
2043ccc: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int rc;
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: unlink: parent(%" PRIu32 ") -X-> (%" PRIu32 ")\n", parent, target);
rc = rtems_rfs_inode_open (fs, target, &target_inode, true);
2043cd0: a2 07 bf b0 add %fp, -80, %l1 <== NOT EXECUTED
2043cd4: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
2043cd8: 7f ff fd f7 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043cdc: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
if (rc)
2043ce0: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043ce4: 12 80 00 13 bne 2043d30 <rtems_rfs_unlink+0x70> <== NOT EXECUTED
2043ce8: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
/*
* If a directory process the unlink mode.
*/
dir = RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&target_inode));
2043cec: 05 00 00 3c sethi %hi(0xf000), %g2 <== NOT EXECUTED
2043cf0: c2 08 60 02 ldub [ %g1 + 2 ], %g1 <== NOT EXECUTED
2043cf4: 83 28 60 08 sll %g1, 8, %g1 <== NOT EXECUTED
2043cf8: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED
2043cfc: 05 00 00 10 sethi %hi(0x4000), %g2 <== NOT EXECUTED
2043d00: 82 18 40 02 xor %g1, %g2, %g1 <== NOT EXECUTED
if (dir)
2043d04: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2043d08: a6 60 3f ff subx %g0, -1, %l3 <== NOT EXECUTED
2043d0c: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2043d10: 02 80 00 15 be 2043d64 <rtems_rfs_unlink+0xa4> <== NOT EXECUTED
2043d14: 80 a7 20 00 cmp %i4, 0 <== NOT EXECUTED
{
switch (dir_mode)
2043d18: 12 80 00 11 bne 2043d5c <rtems_rfs_unlink+0x9c> <== NOT EXECUTED
2043d1c: 80 a7 20 01 cmp %i4, 1 <== NOT EXECUTED
{
case rtems_rfs_unlink_dir_denied:
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: link is a directory\n");
rtems_rfs_inode_close (fs, &target_inode);
2043d20: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043d24: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
2043d28: 7f ff fd b9 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043d2c: b0 10 20 15 mov 0x15, %i0 <== NOT EXECUTED
return EISDIR;
2043d30: 81 c7 e0 08 ret <== NOT EXECUTED
2043d34: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_inode_close (fs, &parent_inode);
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
rc = rtems_rfs_inode_close (fs, &parent_inode);
2043d38: 7f ff fd b5 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043d3c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (rc > 0)
2043d40: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043d44: 14 80 00 40 bg 2043e44 <rtems_rfs_unlink+0x184> <== NOT EXECUTED
2043d48: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rc, strerror (rc));
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
rc = rtems_rfs_inode_close (fs, &target_inode);
2043d4c: 7f ff fd b0 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043d50: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: link: target inode-close failed: %d: %s\n",
rc, strerror (rc));
return rc;
}
2043d54: 81 c7 e0 08 ret <== NOT EXECUTED
2043d58: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
*/
dir = RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&target_inode));
if (dir)
{
switch (dir_mode)
2043d5c: 02 80 00 34 be 2043e2c <rtems_rfs_unlink+0x16c> <== NOT EXECUTED
2043d60: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
default:
break;
}
}
rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);
2043d64: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2043d68: a4 07 bf d8 add %fp, -40, %l2 <== NOT EXECUTED
2043d6c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043d70: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2043d74: 7f ff fd d0 call 20434b4 <rtems_rfs_inode_open> <== NOT EXECUTED
2043d78: 96 10 20 01 mov 1, %o3 <== NOT EXECUTED
if (rc)
2043d7c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043d80: 12 80 00 30 bne 2043e40 <rtems_rfs_unlink+0x180> <== NOT EXECUTED
2043d84: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
rc, strerror (rc));
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
rc = rtems_rfs_dir_del_entry (fs, &parent_inode, target, doff);
2043d88: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED
2043d8c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043d90: 7f ff f0 38 call 203fe70 <rtems_rfs_dir_del_entry> <== NOT EXECUTED
2043d94: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
if (rc > 0)
2043d98: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043d9c: 14 80 00 1c bg 2043e0c <rtems_rfs_unlink+0x14c> <== NOT EXECUTED
2043da0: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
if (links == 0xffff)
2043da4: 09 00 00 3f sethi %hi(0xfc00), %g4 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2043da8: c6 08 60 01 ldub [ %g1 + 1 ], %g3 <== NOT EXECUTED
2043dac: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
if (links == 0xffff)
2043db0: 88 11 23 ff or %g4, 0x3ff, %g4 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2043db4: 85 28 a0 08 sll %g2, 8, %g2 <== NOT EXECUTED
2043db8: 84 10 80 03 or %g2, %g3, %g2 <== NOT EXECUTED
if (links == 0xffff)
2043dbc: 87 28 a0 10 sll %g2, 0x10, %g3 <== NOT EXECUTED
2043dc0: 87 30 e0 10 srl %g3, 0x10, %g3 <== NOT EXECUTED
2043dc4: 80 a0 c0 04 cmp %g3, %g4 <== NOT EXECUTED
2043dc8: 02 80 00 23 be 2043e54 <rtems_rfs_unlink+0x194> <== NOT EXECUTED
2043dcc: 80 a0 e0 01 cmp %g3, 1 <== NOT EXECUTED
links = rtems_rfs_inode_get_links (&target_inode);
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: unlink: target:%" PRIu32 " links:%u\n", target, links);
if (links > 1)
2043dd0: 08 80 00 21 bleu 2043e54 <rtems_rfs_unlink+0x194> <== NOT EXECUTED
2043dd4: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
2043dd8: 87 30 a0 08 srl %g2, 8, %g3 <== NOT EXECUTED
2043ddc: c6 28 40 00 stb %g3, [ %g1 ] <== NOT EXECUTED
2043de0: c2 07 bf bc ld [ %fp + -68 ], %g1 <== NOT EXECUTED
2043de4: c4 28 60 01 stb %g2, [ %g1 + 1 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043de8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2043dec: c2 2f bf c0 stb %g1, [ %fp + -64 ] <== NOT EXECUTED
links--;
rtems_rfs_inode_set_links (&parent_inode, links);
}
}
rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);
2043df0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2043df4: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
2043df8: 7f ff fc d9 call 204315c <rtems_rfs_inode_time_stamp_now> <== NOT EXECUTED
2043dfc: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
if (rc > 0)
2043e00: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043e04: 24 bf ff cd ble,a 2043d38 <rtems_rfs_unlink+0x78> <== NOT EXECUTED
2043e08: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: link: inode-time-stamp failed: %d: %s\n",
rc, strerror (rc));
rtems_rfs_inode_close (fs, &parent_inode);
2043e0c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2043e10: 7f ff fd 7f call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043e14: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &target_inode);
2043e18: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043e1c: 7f ff fd 7c call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043e20: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2043e24: 81 c7 e0 08 ret <== NOT EXECUTED
2043e28: 81 e8 00 00 restore <== NOT EXECUTED
printf ("rtems-rfs: link is a directory\n");
rtems_rfs_inode_close (fs, &target_inode);
return EISDIR;
case rtems_rfs_unlink_dir_if_empty:
rc = rtems_rfs_dir_empty (fs, &target_inode);
2043e2c: 7f ff f2 3f call 2040728 <rtems_rfs_dir_empty> <== NOT EXECUTED
2043e30: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc > 0)
2043e34: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043e38: 04 bf ff cc ble 2043d68 <rtems_rfs_unlink+0xa8> <== NOT EXECUTED
2043e3c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if (rc > 0)
{
if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))
printf ("rtems-rfs: link: parent inode-close failed: %d: %s\n",
rc, strerror (rc));
rtems_rfs_inode_close (fs, &target_inode);
2043e40: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043e44: 7f ff fd 72 call 204340c <rtems_rfs_inode_close> <== NOT EXECUTED
2043e48: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
return rc;
2043e4c: 81 c7 e0 08 ret <== NOT EXECUTED
2043e50: 81 e8 00 00 restore <== NOT EXECUTED
else
{
/*
* Erasing the inode releases all blocks attached to it.
*/
rc = rtems_rfs_inode_delete (fs, &target_inode);
2043e54: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2043e58: 7f ff fd ca call 2043580 <rtems_rfs_inode_delete> <== NOT EXECUTED
2043e5c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
if (rc > 0)
2043e60: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED
2043e64: 14 bf ff ea bg 2043e0c <rtems_rfs_unlink+0x14c> <== NOT EXECUTED
2043e68: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
rtems_rfs_inode_close (fs, &parent_inode);
rtems_rfs_inode_close (fs, &target_inode);
return rc;
}
if (dir)
2043e6c: 22 bf ff e2 be,a 2043df4 <rtems_rfs_unlink+0x134> <== NOT EXECUTED
2043e70: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2043e74: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
if (links == 0xffff)
2043e78: 88 10 20 00 clr %g4 <== NOT EXECUTED
*/
static inline uint16_t
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)
{
uint16_t links;
links = rtems_rfs_read_u16 (&handle->node->links);
2043e7c: c6 08 40 00 ldub [ %g1 ], %g3 <== NOT EXECUTED
2043e80: c4 08 60 01 ldub [ %g1 + 1 ], %g2 <== NOT EXECUTED
2043e84: 87 28 e0 08 sll %g3, 8, %g3 <== NOT EXECUTED
2043e88: 84 10 c0 02 or %g3, %g2, %g2 <== NOT EXECUTED
if (links == 0xffff)
2043e8c: 07 00 00 3f sethi %hi(0xfc00), %g3 <== NOT EXECUTED
2043e90: 86 10 e3 ff or %g3, 0x3ff, %g3 ! ffff <PROM_START+0xffff> <== NOT EXECUTED
2043e94: 9b 28 a0 10 sll %g2, 0x10, %o5 <== NOT EXECUTED
2043e98: 9b 33 60 10 srl %o5, 0x10, %o5 <== NOT EXECUTED
2043e9c: 80 a3 40 03 cmp %o5, %g3 <== NOT EXECUTED
2043ea0: 02 80 00 09 be 2043ec4 <rtems_rfs_unlink+0x204> <== NOT EXECUTED
2043ea4: 86 10 20 00 clr %g3 <== NOT EXECUTED
{
links = rtems_rfs_inode_get_links (&parent_inode);
if (links > 1)
2043ea8: 80 a3 60 01 cmp %o5, 1 <== NOT EXECUTED
2043eac: 08 80 00 06 bleu 2043ec4 <rtems_rfs_unlink+0x204> <== NOT EXECUTED
2043eb0: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
links--;
2043eb4: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
2043eb8: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
2043ebc: 85 28 a0 10 sll %g2, 0x10, %g2 <== NOT EXECUTED
2043ec0: 89 30 a0 18 srl %g2, 0x18, %g4 <== NOT EXECUTED
* @prarm links The links.
*/
static inline void
rtems_rfs_inode_set_links (rtems_rfs_inode_handle* handle, uint16_t links)
{
rtems_rfs_write_u16 (&handle->node->links, links);
2043ec4: c8 28 40 00 stb %g4, [ %g1 ] <== NOT EXECUTED
2043ec8: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
2043ecc: c6 28 60 01 stb %g3, [ %g1 + 1 ] <== NOT EXECUTED
rtems_rfs_buffer_mark_dirty (&handle->buffer);
2043ed0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2043ed4: 10 bf ff c7 b 2043df0 <rtems_rfs_unlink+0x130> <== NOT EXECUTED
2043ed8: c2 2f bf e8 stb %g1, [ %fp + -24 ] <== NOT EXECUTED
02026e4c <rtems_shell_debugrfs>:
printf (" -l: The debugger command list.\n");
}
int
rtems_shell_debugrfs (int argc, char *argv[])
{
2026e4c: 9d e3 bf 10 save %sp, -240, %sp <== NOT EXECUTED
"Display a block as a table for directory entrie, dir <bno>" },
{ "group", rtems_rfs_shell_group,
"Display the group data of a file system, group, group <group>, group <start> <end>" },
{ "inode", rtems_rfs_shell_inode,
"Display an inode, inode <ino>, inode> <ino>..<ino>" }
};
2026e50: 13 00 81 a9 sethi %hi(0x206a400), %o1 <== NOT EXECUTED
2026e54: a0 07 bf 74 add %fp, -140, %l0 <== NOT EXECUTED
2026e58: 92 12 61 60 or %o1, 0x160, %o1 <== NOT EXECUTED
2026e5c: 94 10 20 3c mov 0x3c, %o2 <== NOT EXECUTED
2026e60: 40 00 9a d4 call 204d9b0 <memcpy> <== NOT EXECUTED
2026e64: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
int arg;
int t;
for (arg = 1; arg < argc; arg++)
2026e68: 80 a6 20 01 cmp %i0, 1 <== NOT EXECUTED
2026e6c: 04 80 00 41 ble 2026f70 <rtems_shell_debugrfs+0x124> <== NOT EXECUTED
2026e70: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
{
if (argv[arg][0] != '-')
2026e74: e4 06 60 04 ld [ %i1 + 4 ], %l2 <== NOT EXECUTED
2026e78: c2 4c 80 00 ldsb [ %l2 ], %g1 <== NOT EXECUTED
2026e7c: 80 a0 60 2d cmp %g1, 0x2d <== NOT EXECUTED
2026e80: 02 80 00 43 be 2026f8c <rtems_shell_debugrfs+0x140> <== NOT EXECUTED
2026e84: 80 a6 20 02 cmp %i0, 2 <== NOT EXECUTED
printf ("error: unknown option: %s\n", argv[arg]);
return 1;
}
}
if ((argc - arg) < 2)
2026e88: 22 80 00 3b be,a 2026f74 <rtems_shell_debugrfs+0x128> <== NOT EXECUTED
2026e8c: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
rtems_rfs_get_fs (const char* path, rtems_rfs_file_system** fs)
{
struct statvfs sb;
int rc;
rc = statvfs (path, &sb);
2026e90: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026e94: 40 00 1e 24 call 202e724 <statvfs> <== NOT EXECUTED
2026e98: 92 07 bf b0 add %fp, -80, %o1 <== NOT EXECUTED
if (rc < 0)
2026e9c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2026ea0: 06 80 00 78 bl 2027080 <rtems_shell_debugrfs+0x234> <== NOT EXECUTED
2026ea4: c4 07 bf dc ld [ %fp + -36 ], %g2 <== NOT EXECUTED
printf ("error: cannot statvfs path: %s: (%d) %s\n",
path, errno, strerror (errno));
return -1;
}
if (sb.f_fsid != RTEMS_RFS_SB_MAGIC)
2026ea8: 03 0a 02 48 sethi %hi(0x28092000), %g1 <== NOT EXECUTED
2026eac: 82 10 60 01 or %g1, 1, %g1 ! 28092001 <RAM_END+0x25c92001><== NOT EXECUTED
2026eb0: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2026eb4: 12 80 00 6d bne 2027068 <rtems_shell_debugrfs+0x21c> <== NOT EXECUTED
2026eb8: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
* Now find the path location on the file system. This will give the file
* system data.
*/
{
rtems_filesystem_location_info_t pathloc;
rc = rtems_filesystem_evaluate_path (path, strlen (path), 0, &pathloc, true);
2026ebc: 40 00 a9 2d call 2051370 <strlen> <== NOT EXECUTED
2026ec0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026ec4: 94 10 20 00 clr %o2 <== NOT EXECUTED
2026ec8: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
2026ecc: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
2026ed0: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2026ed4: a4 07 bf ec add %fp, -20, %l2 <== NOT EXECUTED
2026ed8: 7f ff 86 62 call 2008860 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
2026edc: 96 10 00 12 mov %l2, %o3 <== NOT EXECUTED
*fs = rtems_rfs_rtems_pathloc_dev (&pathloc);
rtems_filesystem_freenode (&pathloc);
2026ee0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
* system data.
*/
{
rtems_filesystem_location_info_t pathloc;
rc = rtems_filesystem_evaluate_path (path, strlen (path), 0, &pathloc, true);
*fs = rtems_rfs_rtems_pathloc_dev (&pathloc);
2026ee4: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
* Now find the path location on the file system. This will give the file
* system data.
*/
{
rtems_filesystem_location_info_t pathloc;
rc = rtems_filesystem_evaluate_path (path, strlen (path), 0, &pathloc, true);
2026ee8: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
*fs = rtems_rfs_rtems_pathloc_dev (&pathloc);
rtems_filesystem_freenode (&pathloc);
2026eec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2026ef0: 02 80 00 08 be 2026f10 <rtems_shell_debugrfs+0xc4> <== NOT EXECUTED
2026ef4: e8 00 a0 34 ld [ %g2 + 0x34 ], %l4 <== NOT EXECUTED
2026ef8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2026efc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2026f00: 02 80 00 05 be 2026f14 <rtems_shell_debugrfs+0xc8> <== NOT EXECUTED
2026f04: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2026f08: 9f c0 40 00 call %g1 <== NOT EXECUTED
2026f0c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
if ((argc - arg) < 2)
printf ("error: you need at least a path and command, try %s -h\n", argv[0]);
else
{
rtems_rfs_file_system* fs;
if (rtems_rfs_get_fs (argv[arg], &fs) == 0)
2026f10: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2026f14: 12 80 00 15 bne 2026f68 <rtems_shell_debugrfs+0x11c> <== NOT EXECUTED
2026f18: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026f1c: e6 06 60 08 ld [ %i1 + 8 ], %l3 <== NOT EXECUTED
2026f20: a4 10 20 00 clr %l2 <== NOT EXECUTED
2026f24: b2 06 60 08 add %i1, 8, %i1 <== NOT EXECUTED
{
for (t = 0; t < (sizeof (table) / sizeof (const rtems_rfs_shell_cmd)); t++)
if (strcmp (argv[arg + 1], table[t].name) == 0)
2026f28: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
2026f2c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2026f30: 40 00 a7 0f call 2050b6c <strcmp> <== NOT EXECUTED
2026f34: a0 04 20 0c add %l0, 0xc, %l0 <== NOT EXECUTED
2026f38: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2026f3c: 02 80 00 41 be 2027040 <rtems_shell_debugrfs+0x1f4> <== NOT EXECUTED
2026f40: 83 2c a0 04 sll %l2, 4, %g1 <== NOT EXECUTED
else
{
rtems_rfs_file_system* fs;
if (rtems_rfs_get_fs (argv[arg], &fs) == 0)
{
for (t = 0; t < (sizeof (table) / sizeof (const rtems_rfs_shell_cmd)); t++)
2026f44: a4 04 a0 01 inc %l2 <== NOT EXECUTED
2026f48: 80 a4 a0 05 cmp %l2, 5 <== NOT EXECUTED
2026f4c: 32 bf ff f8 bne,a 2026f2c <rtems_shell_debugrfs+0xe0> <== NOT EXECUTED
2026f50: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
if (strcmp (argv[arg + 1], table[t].name) == 0)
return table[t].handler (fs, argc - 2, argv + 2);
printf ("error: command not found: %s\n", argv[arg + 1]);
2026f54: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
2026f58: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026f5c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026f60: 40 00 9f 43 call 204ec6c <printf> <== NOT EXECUTED
2026f64: 90 12 23 e0 or %o0, 0x3e0, %o0 <== NOT EXECUTED
}
}
return 1;
}
2026f68: 81 c7 e0 08 ret <== NOT EXECUTED
2026f6c: 81 e8 00 00 restore <== NOT EXECUTED
return 1;
}
}
if ((argc - arg) < 2)
printf ("error: you need at least a path and command, try %s -h\n", argv[0]);
2026f70: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
2026f74: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026f78: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026f7c: 40 00 9f 3c call 204ec6c <printf> <== NOT EXECUTED
2026f80: 90 12 23 48 or %o0, 0x348, %o0 <== NOT EXECUTED
2026f84: 81 c7 e0 08 ret <== NOT EXECUTED
2026f88: 81 e8 00 00 restore <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
{
if (argv[arg][0] != '-')
break;
switch (argv[arg][1])
2026f8c: c2 4c a0 01 ldsb [ %l2 + 1 ], %g1 <== NOT EXECUTED
2026f90: 80 a0 60 68 cmp %g1, 0x68 <== NOT EXECUTED
2026f94: 02 80 00 0a be 2026fbc <rtems_shell_debugrfs+0x170> <== NOT EXECUTED
2026f98: 80 a0 60 6c cmp %g1, 0x6c <== NOT EXECUTED
2026f9c: 02 80 00 0d be 2026fd0 <rtems_shell_debugrfs+0x184> <== NOT EXECUTED
2026fa0: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
printf ("%s: commands are:\n", argv[0]);
for (t = 0; t < (sizeof (table) / sizeof (const rtems_rfs_shell_cmd)); t++)
printf (" %s\t\t%s\n", table[t].name, table[t].help);
return 0;
default:
printf ("error: unknown option: %s\n", argv[arg]);
2026fa4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026fa8: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2026fac: 40 00 9f 30 call 204ec6c <printf> <== NOT EXECUTED
2026fb0: 90 12 23 28 or %o0, 0x328, %o0 <== NOT EXECUTED
return 1;
2026fb4: 81 c7 e0 08 ret <== NOT EXECUTED
2026fb8: 81 e8 00 00 restore <== NOT EXECUTED
break;
switch (argv[arg][1])
{
case 'h':
rtems_rfs_shell_usage (argv[0]);
2026fbc: d0 06 40 00 ld [ %i1 ], %o0 <== NOT EXECUTED
2026fc0: 7f ff fb 47 call 2025cdc <rtems_rfs_shell_usage> <== NOT EXECUTED
2026fc4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0;
2026fc8: 81 c7 e0 08 ret <== NOT EXECUTED
2026fcc: 81 e8 00 00 restore <== NOT EXECUTED
case 'l':
printf ("%s: commands are:\n", argv[0]);
2026fd0: d2 06 40 00 ld [ %i1 ], %o1 <== NOT EXECUTED
2026fd4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
2026fd8: 40 00 9f 25 call 204ec6c <printf> <== NOT EXECUTED
2026fdc: 90 12 23 00 or %o0, 0x300, %o0 ! 206a300 <rtems_rfs_ops+0x8a8><== NOT EXECUTED
for (t = 0; t < (sizeof (table) / sizeof (const rtems_rfs_shell_cmd)); t++)
printf (" %s\t\t%s\n", table[t].name, table[t].help);
2026fe0: d2 07 bf 74 ld [ %fp + -140 ], %o1 <== NOT EXECUTED
2026fe4: d4 07 bf 7c ld [ %fp + -132 ], %o2 <== NOT EXECUTED
2026fe8: 21 00 81 a8 sethi %hi(0x206a000), %l0 <== NOT EXECUTED
2026fec: 40 00 9f 20 call 204ec6c <printf> <== NOT EXECUTED
2026ff0: 90 14 23 18 or %l0, 0x318, %o0 ! 206a318 <rtems_rfs_ops+0x8c0><== NOT EXECUTED
2026ff4: d2 07 bf 80 ld [ %fp + -128 ], %o1 <== NOT EXECUTED
2026ff8: d4 07 bf 88 ld [ %fp + -120 ], %o2 <== NOT EXECUTED
2026ffc: 40 00 9f 1c call 204ec6c <printf> <== NOT EXECUTED
2027000: 90 14 23 18 or %l0, 0x318, %o0 <== NOT EXECUTED
2027004: d2 07 bf 8c ld [ %fp + -116 ], %o1 <== NOT EXECUTED
2027008: d4 07 bf 94 ld [ %fp + -108 ], %o2 <== NOT EXECUTED
202700c: 40 00 9f 18 call 204ec6c <printf> <== NOT EXECUTED
2027010: 90 14 23 18 or %l0, 0x318, %o0 <== NOT EXECUTED
2027014: d2 07 bf 98 ld [ %fp + -104 ], %o1 <== NOT EXECUTED
2027018: d4 07 bf a0 ld [ %fp + -96 ], %o2 <== NOT EXECUTED
202701c: 40 00 9f 14 call 204ec6c <printf> <== NOT EXECUTED
2027020: 90 14 23 18 or %l0, 0x318, %o0 <== NOT EXECUTED
2027024: d2 07 bf a4 ld [ %fp + -92 ], %o1 <== NOT EXECUTED
2027028: d4 07 bf ac ld [ %fp + -84 ], %o2 <== NOT EXECUTED
202702c: 90 14 23 18 or %l0, 0x318, %o0 <== NOT EXECUTED
2027030: 40 00 9f 0f call 204ec6c <printf> <== NOT EXECUTED
2027034: b0 10 20 00 clr %i0 <== NOT EXECUTED
2027038: 81 c7 e0 08 ret <== NOT EXECUTED
202703c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_rfs_file_system* fs;
if (rtems_rfs_get_fs (argv[arg], &fs) == 0)
{
for (t = 0; t < (sizeof (table) / sizeof (const rtems_rfs_shell_cmd)); t++)
if (strcmp (argv[arg + 1], table[t].name) == 0)
return table[t].handler (fs, argc - 2, argv + 2);
2027040: a5 2c a0 02 sll %l2, 2, %l2 <== NOT EXECUTED
2027044: 82 20 40 12 sub %g1, %l2, %g1 <== NOT EXECUTED
2027048: 82 07 80 01 add %fp, %g1, %g1 <== NOT EXECUTED
202704c: c2 00 7f 78 ld [ %g1 + -136 ], %g1 <== NOT EXECUTED
2027050: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
2027054: 92 04 7f fe add %l1, -2, %o1 <== NOT EXECUTED
2027058: 9f c0 40 00 call %g1 <== NOT EXECUTED
202705c: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
2027060: 81 c7 e0 08 ret <== NOT EXECUTED
2027064: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return -1;
}
if (sb.f_fsid != RTEMS_RFS_SB_MAGIC)
{
printf ("error: path '%s' is not on an RFS file system\n", path);
2027068: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
202706c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2027070: 40 00 9e ff call 204ec6c <printf> <== NOT EXECUTED
2027074: 90 12 23 b0 or %o0, 0x3b0, %o0 <== NOT EXECUTED
2027078: 81 c7 e0 08 ret <== NOT EXECUTED
202707c: 81 e8 00 00 restore <== NOT EXECUTED
int rc;
rc = statvfs (path, &sb);
if (rc < 0)
{
printf ("error: cannot statvfs path: %s: (%d) %s\n",
2027080: 40 00 8d 00 call 204a480 <__errno> <== NOT EXECUTED
2027084: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2027088: 40 00 8c fe call 204a480 <__errno> <== NOT EXECUTED
202708c: e0 02 00 00 ld [ %o0 ], %l0 <== NOT EXECUTED
2027090: 40 00 a7 ac call 2050f40 <strerror> <== NOT EXECUTED
2027094: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
2027098: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
202709c: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED
20270a0: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
20270a4: 11 00 81 a8 sethi %hi(0x206a000), %o0 <== NOT EXECUTED
20270a8: 40 00 9e f1 call 204ec6c <printf> <== NOT EXECUTED
20270ac: 90 12 23 80 or %o0, 0x380, %o0 ! 206a380 <rtems_rfs_ops+0x928><== NOT EXECUTED
20270b0: 81 c7 e0 08 ret <== NOT EXECUTED
20270b4: 81 e8 00 00 restore <== NOT EXECUTED
02025d40 <rtems_shell_rfs_format>:
return 1;
}
int
rtems_shell_rfs_format (int argc, char* argv[])
{
2025d40: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
rtems_rfs_format_config config;
const char* driver = NULL;
int arg;
memset (&config, 0, sizeof (rtems_rfs_format_config));
2025d44: a0 07 bf e8 add %fp, -24, %l0 <== NOT EXECUTED
2025d48: c0 27 bf e8 clr [ %fp + -24 ] <== NOT EXECUTED
2025d4c: c0 27 bf ec clr [ %fp + -20 ] <== NOT EXECUTED
2025d50: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
2025d54: c0 24 20 0c clr [ %l0 + 0xc ] <== NOT EXECUTED
2025d58: c0 24 20 10 clr [ %l0 + 0x10 ] <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
2025d5c: 80 a6 20 01 cmp %i0, 1 <== NOT EXECUTED
2025d60: 04 80 00 75 ble 2025f34 <rtems_shell_rfs_format+0x1f4> <== NOT EXECUTED
2025d64: c0 24 20 14 clr [ %l0 + 0x14 ] <== NOT EXECUTED
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
2025d68: 27 00 80 97 sethi %hi(0x2025c00), %l3 <== NOT EXECUTED
const char* driver = NULL;
int arg;
memset (&config, 0, sizeof (rtems_rfs_format_config));
for (arg = 1; arg < argc; arg++)
2025d6c: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
2025d70: a6 14 e0 24 or %l3, 0x24, %l3 <== NOT EXECUTED
const char* driver = NULL;
int arg;
memset (&config, 0, sizeof (rtems_rfs_format_config));
for (arg = 1; arg < argc; arg++)
2025d74: 82 10 20 00 clr %g1 <== NOT EXECUTED
}
config.group_inodes = strtoul (argv[arg], 0, 0);
break;
case 'I':
config.initialise_inodes = true;
2025d78: 10 80 00 09 b 2025d9c <rtems_shell_rfs_format+0x5c> <== NOT EXECUTED
2025d7c: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
return 1;
}
}
else
{
if (!driver)
2025d80: 12 80 00 5c bne 2025ef0 <rtems_shell_rfs_format+0x1b0> <== NOT EXECUTED
2025d84: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
const char* driver = NULL;
int arg;
memset (&config, 0, sizeof (rtems_rfs_format_config));
for (arg = 1; arg < argc; arg++)
2025d88: a2 04 60 01 inc %l1 <== NOT EXECUTED
2025d8c: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025d90: 04 80 00 1f ble 2025e0c <rtems_shell_rfs_format+0xcc> <== NOT EXECUTED
2025d94: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
2025d98: 82 10 00 12 mov %l2, %g1 <== NOT EXECUTED
{
if (argv[arg][0] == '-')
2025d9c: 85 2c 60 02 sll %l1, 2, %g2 <== NOT EXECUTED
2025da0: e4 06 40 02 ld [ %i1 + %g2 ], %l2 <== NOT EXECUTED
2025da4: c4 4c 80 00 ldsb [ %l2 ], %g2 <== NOT EXECUTED
2025da8: 80 a0 a0 2d cmp %g2, 0x2d <== NOT EXECUTED
2025dac: 12 bf ff f5 bne 2025d80 <rtems_shell_rfs_format+0x40> <== NOT EXECUTED
2025db0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
{
switch (argv[arg][1])
2025db4: c4 0c a0 01 ldub [ %l2 + 1 ], %g2 <== NOT EXECUTED
2025db8: 84 00 bf b7 add %g2, -73, %g2 <== NOT EXECUTED
2025dbc: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED
2025dc0: 80 a0 a0 2d cmp %g2, 0x2d <== NOT EXECUTED
2025dc4: 08 80 00 09 bleu 2025de8 <rtems_shell_rfs_format+0xa8> <== NOT EXECUTED
2025dc8: 85 28 a0 02 sll %g2, 2, %g2 <== NOT EXECUTED
}
config.inode_overhead = strtoul (argv[arg], 0, 0);
break;
default:
printf ("error: invalid option: %s\n", argv[arg]);
2025dcc: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2025dd0: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025dd4: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025dd8: 40 00 a3 a5 call 204ec6c <printf> <== NOT EXECUTED
2025ddc: 90 12 20 90 or %o0, 0x90, %o0 <== NOT EXECUTED
return 1;
2025de0: 81 c7 e0 08 ret <== NOT EXECUTED
2025de4: 81 e8 00 00 restore <== NOT EXECUTED
for (arg = 1; arg < argc; arg++)
{
if (argv[arg][0] == '-')
{
switch (argv[arg][1])
2025de8: c4 04 c0 02 ld [ %l3 + %g2 ], %g2 <== NOT EXECUTED
2025dec: 81 c0 80 00 jmp %g2 <== NOT EXECUTED
2025df0: 01 00 00 00 nop <== NOT EXECUTED
{
case 'v':
config.verbose = true;
2025df4: e8 2f bf fd stb %l4, [ %fp + -3 ] <== NOT EXECUTED
const char* driver = NULL;
int arg;
memset (&config, 0, sizeof (rtems_rfs_format_config));
for (arg = 1; arg < argc; arg++)
2025df8: a2 04 60 01 inc %l1 <== NOT EXECUTED
2025dfc: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025e00: 14 bf ff e6 bg 2025d98 <rtems_shell_rfs_format+0x58> <== NOT EXECUTED
2025e04: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
return 1;
}
}
}
if (!driver) {
2025e08: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
2025e0c: 02 80 00 4a be 2025f34 <rtems_shell_rfs_format+0x1f4> <== NOT EXECUTED
2025e10: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
printf ("error: no driver name provided\n");
return 1;
}
if (rtems_rfs_format (driver, &config) < 0)
2025e14: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2025e18: 40 00 6f b8 call 2041cf8 <rtems_rfs_format> <== NOT EXECUTED
2025e1c: b0 10 20 00 clr %i0 <== NOT EXECUTED
2025e20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2025e24: 06 80 00 39 bl 2025f08 <rtems_shell_rfs_format+0x1c8> <== NOT EXECUTED
2025e28: 01 00 00 00 nop <== NOT EXECUTED
driver, strerror (errno));
return 1;
}
return 0;
}
2025e2c: 81 c7 e0 08 ret <== NOT EXECUTED
2025e30: 81 e8 00 00 restore <== NOT EXECUTED
case 'v':
config.verbose = true;
break;
case 's':
arg++;
2025e34: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (arg >= argc)
2025e38: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025e3c: 04 80 00 4a ble 2025f64 <rtems_shell_rfs_format+0x224> <== NOT EXECUTED
2025e40: 85 2c 60 02 sll %l1, 2, %g2 <== NOT EXECUTED
{
printf ("error: block size needs an argument\n");
return 1;
}
config.block_size = strtoul (argv[arg], 0, 0);
2025e44: d0 06 40 02 ld [ %i1 + %g2 ], %o0 <== NOT EXECUTED
2025e48: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
2025e4c: 92 10 20 00 clr %o1 <== NOT EXECUTED
2025e50: 40 00 b2 fd call 2052a44 <strtoul> <== NOT EXECUTED
2025e54: 94 10 20 00 clr %o2 <== NOT EXECUTED
break;
2025e58: 10 bf ff cc b 2025d88 <rtems_shell_rfs_format+0x48> <== NOT EXECUTED
2025e5c: d0 27 bf e8 st %o0, [ %fp + -24 ] <== NOT EXECUTED
case 'I':
config.initialise_inodes = true;
break;
case 'o':
arg++;
2025e60: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (arg >= argc)
2025e64: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025e68: 04 80 00 4b ble 2025f94 <rtems_shell_rfs_format+0x254> <== NOT EXECUTED
2025e6c: 85 2c 60 02 sll %l1, 2, %g2 <== NOT EXECUTED
{
printf ("error: inode percentage overhead needs an argument\n");
return 1;
}
config.inode_overhead = strtoul (argv[arg], 0, 0);
2025e70: d0 06 40 02 ld [ %i1 + %g2 ], %o0 <== NOT EXECUTED
2025e74: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
2025e78: 92 10 20 00 clr %o1 <== NOT EXECUTED
2025e7c: 40 00 b2 f2 call 2052a44 <strtoul> <== NOT EXECUTED
2025e80: 94 10 20 00 clr %o2 <== NOT EXECUTED
break;
2025e84: 10 bf ff c1 b 2025d88 <rtems_shell_rfs_format+0x48> <== NOT EXECUTED
2025e88: d0 27 bf f4 st %o0, [ %fp + -12 ] <== NOT EXECUTED
}
config.group_blocks = strtoul (argv[arg], 0, 0);
break;
case 'i':
arg++;
2025e8c: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (arg >= argc)
2025e90: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025e94: 04 80 00 3a ble 2025f7c <rtems_shell_rfs_format+0x23c> <== NOT EXECUTED
2025e98: 85 2c 60 02 sll %l1, 2, %g2 <== NOT EXECUTED
{
printf ("error: group inode count needs an argument\n");
return 1;
}
config.group_inodes = strtoul (argv[arg], 0, 0);
2025e9c: d0 06 40 02 ld [ %i1 + %g2 ], %o0 <== NOT EXECUTED
2025ea0: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
2025ea4: 92 10 20 00 clr %o1 <== NOT EXECUTED
2025ea8: 40 00 b2 e7 call 2052a44 <strtoul> <== NOT EXECUTED
2025eac: 94 10 20 00 clr %o2 <== NOT EXECUTED
break;
2025eb0: 10 bf ff b6 b 2025d88 <rtems_shell_rfs_format+0x48> <== NOT EXECUTED
2025eb4: d0 27 bf f0 st %o0, [ %fp + -16 ] <== NOT EXECUTED
}
config.block_size = strtoul (argv[arg], 0, 0);
break;
case 'b':
arg++;
2025eb8: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (arg >= argc)
2025ebc: 80 a6 00 11 cmp %i0, %l1 <== NOT EXECUTED
2025ec0: 04 80 00 23 ble 2025f4c <rtems_shell_rfs_format+0x20c> <== NOT EXECUTED
2025ec4: 85 2c 60 02 sll %l1, 2, %g2 <== NOT EXECUTED
{
printf ("error: group block count needs an argument\n");
return 1;
}
config.group_blocks = strtoul (argv[arg], 0, 0);
2025ec8: d0 06 40 02 ld [ %i1 + %g2 ], %o0 <== NOT EXECUTED
2025ecc: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
2025ed0: 92 10 20 00 clr %o1 <== NOT EXECUTED
2025ed4: 40 00 b2 dc call 2052a44 <strtoul> <== NOT EXECUTED
2025ed8: 94 10 20 00 clr %o2 <== NOT EXECUTED
break;
2025edc: 10 bf ff ab b 2025d88 <rtems_shell_rfs_format+0x48> <== NOT EXECUTED
2025ee0: d0 27 bf ec st %o0, [ %fp + -20 ] <== NOT EXECUTED
}
config.group_inodes = strtoul (argv[arg], 0, 0);
break;
case 'I':
config.initialise_inodes = true;
2025ee4: e8 2f bf fc stb %l4, [ %fp + -4 ] <== NOT EXECUTED
break;
2025ee8: 10 bf ff a8 b 2025d88 <rtems_shell_rfs_format+0x48> <== NOT EXECUTED
2025eec: a4 10 00 01 mov %g1, %l2 <== NOT EXECUTED
{
if (!driver)
driver = argv[arg];
else
{
printf ("error: only one driver name allowed: %s\n", argv[arg]);
2025ef0: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025ef4: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025ef8: 40 00 a3 5d call 204ec6c <printf> <== NOT EXECUTED
2025efc: 90 12 20 b0 or %o0, 0xb0, %o0 <== NOT EXECUTED
return 1;
2025f00: 81 c7 e0 08 ret <== NOT EXECUTED
2025f04: 81 e8 00 00 restore <== NOT EXECUTED
return 1;
}
if (rtems_rfs_format (driver, &config) < 0)
{
printf ("error: format of %s failed: %s\n",
2025f08: 40 00 91 5e call 204a480 <__errno> <== NOT EXECUTED
2025f0c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f10: 40 00 ac 0c call 2050f40 <strerror> <== NOT EXECUTED
2025f14: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED
2025f18: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
2025f1c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2025f20: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025f24: 40 00 a3 52 call 204ec6c <printf> <== NOT EXECUTED
2025f28: 90 12 21 00 or %o0, 0x100, %o0 ! 2069d00 <rtems_rfs_ops+0x2a8><== NOT EXECUTED
driver, strerror (errno));
return 1;
}
return 0;
}
2025f2c: 81 c7 e0 08 ret <== NOT EXECUTED
2025f30: 81 e8 00 00 restore <== NOT EXECUTED
}
}
}
if (!driver) {
printf ("error: no driver name provided\n");
2025f34: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025f38: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f3c: 40 00 a3 f8 call 204ef1c <puts> <== NOT EXECUTED
2025f40: 90 12 20 e0 or %o0, 0xe0, %o0 <== NOT EXECUTED
return 1;
2025f44: 81 c7 e0 08 ret <== NOT EXECUTED
2025f48: 81 e8 00 00 restore <== NOT EXECUTED
case 'b':
arg++;
if (arg >= argc)
{
printf ("error: group block count needs an argument\n");
2025f4c: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025f50: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f54: 40 00 a3 f2 call 204ef1c <puts> <== NOT EXECUTED
2025f58: 90 12 23 f8 or %o0, 0x3f8, %o0 <== NOT EXECUTED
return 1;
2025f5c: 81 c7 e0 08 ret <== NOT EXECUTED
2025f60: 81 e8 00 00 restore <== NOT EXECUTED
case 's':
arg++;
if (arg >= argc)
{
printf ("error: block size needs an argument\n");
2025f64: 11 00 81 a6 sethi %hi(0x2069800), %o0 <== NOT EXECUTED
2025f68: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f6c: 40 00 a3 ec call 204ef1c <puts> <== NOT EXECUTED
2025f70: 90 12 23 d0 or %o0, 0x3d0, %o0 <== NOT EXECUTED
return 1;
2025f74: 81 c7 e0 08 ret <== NOT EXECUTED
2025f78: 81 e8 00 00 restore <== NOT EXECUTED
case 'i':
arg++;
if (arg >= argc)
{
printf ("error: group inode count needs an argument\n");
2025f7c: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025f80: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f84: 40 00 a3 e6 call 204ef1c <puts> <== NOT EXECUTED
2025f88: 90 12 20 28 or %o0, 0x28, %o0 <== NOT EXECUTED
return 1;
2025f8c: 81 c7 e0 08 ret <== NOT EXECUTED
2025f90: 81 e8 00 00 restore <== NOT EXECUTED
case 'o':
arg++;
if (arg >= argc)
{
printf ("error: inode percentage overhead needs an argument\n");
2025f94: 11 00 81 a7 sethi %hi(0x2069c00), %o0 <== NOT EXECUTED
2025f98: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2025f9c: 40 00 a3 e0 call 204ef1c <puts> <== NOT EXECUTED
2025fa0: 90 12 20 58 or %o0, 0x58, %o0 <== NOT EXECUTED
return 1;
2025fa4: 81 c7 e0 08 ret <== NOT EXECUTED
2025fa8: 81 e8 00 00 restore <== NOT EXECUTED
02015d3c <rtems_signal_send>:
rtems_status_code rtems_signal_send(
rtems_id id,
rtems_signal_set signal_set
)
{
2015d3c: 9d e3 bf 98 save %sp, -104, %sp
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
ASR_Information *asr;
if ( !signal_set )
2015d40: 80 a6 60 00 cmp %i1, 0
2015d44: 12 80 00 04 bne 2015d54 <rtems_signal_send+0x18>
2015d48: 82 10 20 0a mov 0xa, %g1
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2015d4c: 81 c7 e0 08 ret
2015d50: 91 e8 00 01 restore %g0, %g1, %o0
ASR_Information *asr;
if ( !signal_set )
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
2015d54: 90 10 00 18 mov %i0, %o0
2015d58: 40 00 11 7b call 201a344 <_Thread_Get>
2015d5c: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2015d60: c4 07 bf fc ld [ %fp + -4 ], %g2
ASR_Information *asr;
if ( !signal_set )
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
2015d64: a2 10 00 08 mov %o0, %l1
switch ( location ) {
2015d68: 80 a0 a0 00 cmp %g2, 0
2015d6c: 12 bf ff f8 bne 2015d4c <rtems_signal_send+0x10>
2015d70: 82 10 20 04 mov 4, %g1
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
2015d74: e0 02 21 68 ld [ %o0 + 0x168 ], %l0
asr = &api->Signal;
2015d78: c2 04 20 0c ld [ %l0 + 0xc ], %g1
2015d7c: 80 a0 60 00 cmp %g1, 0
2015d80: 02 80 00 26 be 2015e18 <rtems_signal_send+0xdc>
2015d84: 01 00 00 00 nop
if ( ! _ASR_Is_null_handler( asr->handler ) ) {
if ( asr->is_enabled ) {
2015d88: c2 0c 20 08 ldub [ %l0 + 8 ], %g1
2015d8c: 80 a0 60 00 cmp %g1, 0
2015d90: 02 80 00 16 be 2015de8 <rtems_signal_send+0xac>
2015d94: 01 00 00 00 nop
rtems_signal_set *signal_set
)
{
ISR_Level _level;
_ISR_Disable( _level );
2015d98: 7f ff e5 a8 call 200f438 <sparc_disable_interrupts>
2015d9c: 01 00 00 00 nop
*signal_set |= signals;
2015da0: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
2015da4: b2 10 40 19 or %g1, %i1, %i1
2015da8: f2 24 20 14 st %i1, [ %l0 + 0x14 ]
_ISR_Enable( _level );
2015dac: 7f ff e5 a7 call 200f448 <sparc_enable_interrupts>
2015db0: 01 00 00 00 nop
_ASR_Post_signals( signal_set, &asr->signals_posted );
the_thread->do_post_task_switch_extension = true;
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2015db4: 03 00 81 03 sethi %hi(0x2040c00), %g1
2015db8: c4 00 61 7c ld [ %g1 + 0x17c ], %g2 ! 2040d7c <_ISR_Nest_level>
if ( ! _ASR_Is_null_handler( asr->handler ) ) {
if ( asr->is_enabled ) {
_ASR_Post_signals( signal_set, &asr->signals_posted );
the_thread->do_post_task_switch_extension = true;
2015dbc: 82 10 20 01 mov 1, %g1
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2015dc0: 80 a0 a0 00 cmp %g2, 0
2015dc4: 02 80 00 10 be 2015e04 <rtems_signal_send+0xc8>
2015dc8: c2 2c 60 74 stb %g1, [ %l1 + 0x74 ]
2015dcc: 05 00 81 03 sethi %hi(0x2040c00), %g2
2015dd0: c4 00 a1 a0 ld [ %g2 + 0x1a0 ], %g2 ! 2040da0 <_Thread_Executing>
2015dd4: 80 a4 40 02 cmp %l1, %g2
2015dd8: 12 80 00 0b bne 2015e04 <rtems_signal_send+0xc8> <== NEVER TAKEN
2015ddc: 05 00 81 03 sethi %hi(0x2040c00), %g2
_ISR_Signals_to_thread_executing = true;
2015de0: 10 80 00 09 b 2015e04 <rtems_signal_send+0xc8>
2015de4: c2 28 a2 38 stb %g1, [ %g2 + 0x238 ] ! 2040e38 <_ISR_Signals_to_thread_executing>
rtems_signal_set *signal_set
)
{
ISR_Level _level;
_ISR_Disable( _level );
2015de8: 7f ff e5 94 call 200f438 <sparc_disable_interrupts>
2015dec: 01 00 00 00 nop
*signal_set |= signals;
2015df0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
2015df4: b2 10 40 19 or %g1, %i1, %i1
2015df8: f2 24 20 18 st %i1, [ %l0 + 0x18 ]
_ISR_Enable( _level );
2015dfc: 7f ff e5 93 call 200f448 <sparc_enable_interrupts>
2015e00: 01 00 00 00 nop
} else {
_ASR_Post_signals( signal_set, &asr->signals_pending );
}
_Thread_Enable_dispatch();
2015e04: 40 00 11 2c call 201a2b4 <_Thread_Enable_dispatch>
2015e08: 01 00 00 00 nop
2015e0c: 82 10 20 00 clr %g1 ! 0 <PROM_START>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2015e10: 81 c7 e0 08 ret
2015e14: 91 e8 00 01 restore %g0, %g1, %o0
_ASR_Post_signals( signal_set, &asr->signals_pending );
}
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
_Thread_Enable_dispatch();
2015e18: 40 00 11 27 call 201a2b4 <_Thread_Enable_dispatch>
2015e1c: 01 00 00 00 nop
return RTEMS_NOT_DEFINED;
2015e20: 10 bf ff cb b 2015d4c <rtems_signal_send+0x10>
2015e24: 82 10 20 0b mov 0xb, %g1 ! b <PROM_START+0xb>
02006968 <rtems_stack_checker_begin_extension>:
Thread_Control *the_thread
)
{
Stack_check_Control *the_pattern;
if ( the_thread->Object.id == 0 ) /* skip system tasks */
2006968: c2 02 20 08 ld [ %o0 + 8 ], %g1
200696c: 80 a0 60 00 cmp %g1, 0
2006970: 02 80 00 0c be 20069a0 <rtems_stack_checker_begin_extension+0x38><== NEVER TAKEN
2006974: 05 00 81 d3 sethi %hi(0x2074c00), %g2
return;
the_pattern = Stack_check_Get_pattern_area(&the_thread->Start.Initial_stack);
*the_pattern = Stack_check_Pattern;
2006978: c2 02 20 c8 ld [ %o0 + 0xc8 ], %g1
200697c: c6 00 a0 48 ld [ %g2 + 0x48 ], %g3
2006980: 84 10 a0 48 or %g2, 0x48, %g2
2006984: c6 20 60 08 st %g3, [ %g1 + 8 ]
2006988: c6 00 a0 04 ld [ %g2 + 4 ], %g3
200698c: c6 20 60 0c st %g3, [ %g1 + 0xc ]
2006990: c6 00 a0 08 ld [ %g2 + 8 ], %g3
2006994: c6 20 60 10 st %g3, [ %g1 + 0x10 ]
2006998: c4 00 a0 0c ld [ %g2 + 0xc ], %g2
200699c: c4 20 60 14 st %g2, [ %g1 + 0x14 ]
20069a0: 81 c3 e0 08 retl
02006e40 <rtems_stack_checker_create_extension>:
*/
bool rtems_stack_checker_create_extension(
Thread_Control *running __attribute__((unused)),
Thread_Control *the_thread
)
{
2006e40: 9d e3 bf a0 save %sp, -96, %sp
Stack_check_Initialize();
2006e44: 7f ff ff d9 call 2006da8 <Stack_check_Initialize>
2006e48: 01 00 00 00 nop
if (the_thread)
2006e4c: 80 a6 60 00 cmp %i1, 0
2006e50: 02 80 00 06 be 2006e68 <rtems_stack_checker_create_extension+0x28><== NEVER TAKEN
2006e54: 01 00 00 00 nop
Stack_check_Dope_stack(&the_thread->Start.Initial_stack);
2006e58: d4 06 60 c4 ld [ %i1 + 0xc4 ], %o2
2006e5c: d0 06 60 c8 ld [ %i1 + 0xc8 ], %o0
2006e60: 40 01 1b 67 call 204dbfc <memset>
2006e64: 92 10 20 a5 mov 0xa5, %o1
return true;
}
2006e68: 81 c7 e0 08 ret
2006e6c: 91 e8 20 01 restore %g0, 1, %o0
02006cb0 <rtems_stack_checker_is_blown>:
/*
* Check if blown
*/
bool rtems_stack_checker_is_blown( void )
{
2006cb0: 9d e3 bf a0 save %sp, -96, %sp
Stack_Control *the_stack = &_Thread_Executing->Start.Initial_stack;
2006cb4: 21 00 81 d3 sethi %hi(0x2074c00), %l0
2006cb8: c2 04 23 00 ld [ %l0 + 0x300 ], %g1 ! 2074f00 <_Thread_Executing>
)
{
#if defined(__GNUC__)
void *sp = __builtin_frame_address(0);
if ( sp < the_stack->area ) {
2006cbc: d0 00 60 c8 ld [ %g1 + 0xc8 ], %o0
2006cc0: 80 a7 80 08 cmp %fp, %o0
2006cc4: 0a 80 00 06 bcs 2006cdc <rtems_stack_checker_is_blown+0x2c><== NEVER TAKEN
2006cc8: a2 10 20 00 clr %l1
}
/*
* Check if blown
*/
bool rtems_stack_checker_is_blown( void )
2006ccc: c2 00 60 c4 ld [ %g1 + 0xc4 ], %g1
2006cd0: 82 02 00 01 add %o0, %g1, %g1
2006cd4: 80 a0 40 1e cmp %g1, %fp
2006cd8: a2 60 3f ff subx %g0, -1, %l1
/*
* The stack checker must be initialized before the pattern is there
* to check.
*/
if ( Stack_check_Initialized ) {
2006cdc: 03 00 81 c8 sethi %hi(0x2072000), %g1
2006ce0: c4 00 60 e8 ld [ %g1 + 0xe8 ], %g2 ! 20720e8 <Stack_check_Initialized>
2006ce4: 80 a0 a0 00 cmp %g2, 0
2006ce8: 02 80 00 09 be 2006d0c <rtems_stack_checker_is_blown+0x5c><== NEVER TAKEN
2006cec: 82 10 20 01 mov 1, %g1
pattern_ok = (!memcmp(
2006cf0: 90 02 20 08 add %o0, 8, %o0
2006cf4: 13 00 81 d3 sethi %hi(0x2074c00), %o1
2006cf8: 94 10 20 10 mov 0x10, %o2
2006cfc: 40 01 1a fc call 204d8ec <memcmp>
2006d00: 92 12 60 48 or %o1, 0x48, %o1
2006d04: 80 a0 00 08 cmp %g0, %o0
2006d08: 82 60 3f ff subx %g0, -1, %g1
}
/*
* The Stack Pointer and the Pattern Area are OK so return false.
*/
if ( sp_ok && pattern_ok )
2006d0c: 80 8c 60 ff btst 0xff, %l1
2006d10: 02 80 00 05 be 2006d24 <rtems_stack_checker_is_blown+0x74><== NEVER TAKEN
2006d14: 92 08 60 ff and %g1, 0xff, %o1
2006d18: 92 88 60 ff andcc %g1, 0xff, %o1
2006d1c: 12 80 00 05 bne 2006d30 <rtems_stack_checker_is_blown+0x80><== ALWAYS TAKEN
2006d20: 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 );
2006d24: d0 04 23 00 ld [ %l0 + 0x300 ], %o0 <== NOT EXECUTED
2006d28: 7f ff ff b8 call 2006c08 <Stack_check_report_blown_task> <== NOT EXECUTED
2006d2c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
return true;
}
2006d30: 81 c7 e0 08 ret
2006d34: 81 e8 00 00 restore
02006bec <rtems_stack_checker_report_usage>:
void rtems_stack_checker_report_usage( void )
{
rtems_stack_checker_report_usage_with_plugin( NULL, printk_plugin );
2006bec: 13 00 80 27 sethi %hi(0x2009c00), %o1 <== NOT EXECUTED
2006bf0: 90 10 20 00 clr %o0 <== NOT EXECUTED
2006bf4: 92 12 62 a8 or %o1, 0x2a8, %o1 <== NOT EXECUTED
2006bf8: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2006bfc: 7f ff ff e6 call 2006b94 <rtems_stack_checker_report_usage_with_plugin><== NOT EXECUTED
2006c00: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02006b94 <rtems_stack_checker_report_usage_with_plugin>:
void rtems_stack_checker_report_usage_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
2006b94: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
print_context = context;
2006b98: 23 00 81 c8 sethi %hi(0x2072000), %l1 <== NOT EXECUTED
print_handler = print;
2006b9c: 21 00 81 c8 sethi %hi(0x2072000), %l0 <== NOT EXECUTED
void rtems_stack_checker_report_usage_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
print_context = context;
2006ba0: f0 24 60 ec st %i0, [ %l1 + 0xec ] <== NOT EXECUTED
print_handler = print;
2006ba4: f2 24 20 f0 st %i1, [ %l0 + 0xf0 ] <== NOT EXECUTED
(*print)( context, "Stack usage by thread\n");
2006ba8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2006bac: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006bb0: 9f c6 40 00 call %i1 <== NOT EXECUTED
2006bb4: 92 12 63 30 or %o1, 0x330, %o1 ! 2065b30 <write_test_string.8866+0x470><== NOT EXECUTED
(*print)( context,
2006bb8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2006bbc: 13 00 81 96 sethi %hi(0x2065800), %o1 <== NOT EXECUTED
2006bc0: 9f c6 40 00 call %i1 <== NOT EXECUTED
2006bc4: 92 12 63 48 or %o1, 0x348, %o1 ! 2065b48 <write_test_string.8866+0x488><== 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 );
2006bc8: 11 00 80 1a sethi %hi(0x2006800), %o0 <== NOT EXECUTED
2006bcc: 40 00 20 9d call 200ee40 <rtems_iterate_over_all_threads> <== NOT EXECUTED
2006bd0: 90 12 22 08 or %o0, 0x208, %o0 ! 2006a08 <Stack_check_Dump_threads_usage><== NOT EXECUTED
/* dump interrupt stack info if any */
Stack_check_Dump_threads_usage((Thread_Control *) -1);
2006bd4: 7f ff ff 8d call 2006a08 <Stack_check_Dump_threads_usage> <== NOT EXECUTED
2006bd8: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
print_context = NULL;
2006bdc: c0 24 60 ec clr [ %l1 + 0xec ] <== NOT EXECUTED
print_handler = NULL;
2006be0: c0 24 20 f0 clr [ %l0 + 0xf0 ] <== NOT EXECUTED
}
2006be4: 81 c7 e0 08 ret <== NOT EXECUTED
2006be8: 81 e8 00 00 restore <== NOT EXECUTED
02006d38 <rtems_stack_checker_switch_extension>:
*/
void rtems_stack_checker_switch_extension(
Thread_Control *running __attribute__((unused)),
Thread_Control *heir __attribute__((unused))
)
{
2006d38: 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;
2006d3c: c2 06 20 c8 ld [ %i0 + 0xc8 ], %g1
)
{
#if defined(__GNUC__)
void *sp = __builtin_frame_address(0);
if ( sp < the_stack->area ) {
2006d40: 80 a7 80 01 cmp %fp, %g1
2006d44: 0a 80 00 07 bcs 2006d60 <rtems_stack_checker_switch_extension+0x28><== NEVER TAKEN
2006d48: 90 00 60 08 add %g1, 8, %o0
void rtems_stack_checker_switch_extension(
Thread_Control *running __attribute__((unused)),
Thread_Control *heir __attribute__((unused))
)
{
Stack_Control *the_stack = &running->Start.Initial_stack;
2006d4c: c4 06 20 c4 ld [ %i0 + 0xc4 ], %g2
2006d50: 82 00 40 02 add %g1, %g2, %g1
2006d54: 80 a7 80 01 cmp %fp, %g1
2006d58: 28 80 00 0b bleu,a 2006d84 <rtems_stack_checker_switch_extension+0x4c><== ALWAYS TAKEN
2006d5c: 13 00 81 d3 sethi %hi(0x2074c00), %o1
/*
* 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,
2006d60: 13 00 81 d3 sethi %hi(0x2074c00), %o1 <== NOT EXECUTED
2006d64: 94 10 20 10 mov 0x10, %o2 <== NOT EXECUTED
2006d68: 40 01 1a e1 call 204d8ec <memcmp> <== NOT EXECUTED
2006d6c: 92 12 60 48 or %o1, 0x48, %o1 <== NOT EXECUTED
2006d70: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
2006d74: b2 60 3f ff subx %g0, -1, %i1 <== NOT EXECUTED
(void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES));
if ( !sp_ok || !pattern_ok ) {
Stack_check_report_blown_task( running, pattern_ok );
2006d78: b2 0e 60 01 and %i1, 1, %i1 <== NOT EXECUTED
2006d7c: 7f ff ff a3 call 2006c08 <Stack_check_report_blown_task>
2006d80: 81 e8 00 00 restore
/*
* 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,
2006d84: 94 10 20 10 mov 0x10, %o2
2006d88: 92 12 60 48 or %o1, 0x48, %o1
2006d8c: 40 01 1a d8 call 204d8ec <memcmp>
2006d90: b2 10 20 00 clr %i1
(void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES));
if ( !sp_ok || !pattern_ok ) {
2006d94: 80 a2 20 00 cmp %o0, 0
2006d98: 12 bf ff f9 bne 2006d7c <rtems_stack_checker_switch_extension+0x44>
2006d9c: b2 0e 60 01 and %i1, 1, %i1
2006da0: 81 c7 e0 08 ret
2006da4: 81 e8 00 00 restore
0200cc04 <rtems_string_to_double>:
rtems_status_code rtems_string_to_double (
const char *s,
double *n,
char **endptr
)
{
200cc04: 9d e3 bf 90 save %sp, -112, %sp
200cc08: a0 10 00 18 mov %i0, %l0
double result;
char *end;
if ( !n )
200cc0c: 80 a6 60 00 cmp %i1, 0
200cc10: 02 80 00 2d be 200ccc4 <rtems_string_to_double+0xc0>
200cc14: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200cc18: 40 00 0d d5 call 201036c <__errno>
200cc1c: 01 00 00 00 nop
*n = 0;
result = strtod( s, &end );
200cc20: 92 07 bf fc add %fp, -4, %o1
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
200cc24: c0 22 00 00 clr [ %o0 ]
*n = 0;
200cc28: c0 26 40 00 clr [ %i1 ]
200cc2c: c0 26 60 04 clr [ %i1 + 4 ]
result = strtod( s, &end );
200cc30: 40 00 19 4e call 2013168 <strtod>
200cc34: 90 10 00 10 mov %l0, %o0
if ( endptr )
200cc38: 80 a6 a0 00 cmp %i2, 0
200cc3c: 02 80 00 03 be 200cc48 <rtems_string_to_double+0x44>
200cc40: c2 07 bf fc ld [ %fp + -4 ], %g1
*endptr = end;
200cc44: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200cc48: 80 a0 40 10 cmp %g1, %l0
200cc4c: 02 80 00 1e be 200ccc4 <rtems_string_to_double+0xc0>
200cc50: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cc54: c1 27 bf f4 st %f0, [ %fp + -12 ]
200cc58: 40 00 0d c5 call 201036c <__errno>
200cc5c: c3 27 bf f0 st %f1, [ %fp + -16 ]
200cc60: c2 02 00 00 ld [ %o0 ], %g1
200cc64: c1 07 bf f4 ld [ %fp + -12 ], %f0
200cc68: 80 a0 60 22 cmp %g1, 0x22
200cc6c: 02 80 00 05 be 200cc80 <rtems_string_to_double+0x7c>
200cc70: c3 07 bf f0 ld [ %fp + -16 ], %f1
(( result == 0 ) || ( result == HUGE_VAL ) || ( result == -HUGE_VAL )))
return RTEMS_INVALID_NUMBER;
*n = result;
200cc74: c1 3e 40 00 std %f0, [ %i1 ]
return RTEMS_SUCCESSFUL;
200cc78: 81 c7 e0 08 ret
200cc7c: 91 e8 20 00 restore %g0, 0, %o0
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cc80: 03 00 80 7d sethi %hi(0x201f400), %g1
200cc84: d1 18 62 e0 ldd [ %g1 + 0x2e0 ], %f8 ! 201f6e0 <_CPU_Trap_slot_template+0x14>
200cc88: 81 a8 0a 48 fcmpd %f0, %f8
200cc8c: 01 00 00 00 nop
200cc90: 13 80 00 0c fbe 200ccc0 <rtems_string_to_double+0xbc>
200cc94: 03 00 80 7d sethi %hi(0x201f400), %g1
200cc98: d1 18 62 e8 ldd [ %g1 + 0x2e8 ], %f8 ! 201f6e8 <_CPU_Trap_slot_template+0x1c>
200cc9c: 81 a8 0a c8 fcmped %f0, %f8
200cca0: 01 00 00 00 nop
200cca4: 0d 80 00 07 fbg 200ccc0 <rtems_string_to_double+0xbc>
200cca8: 03 00 80 7d sethi %hi(0x201f400), %g1
200ccac: d1 18 62 f0 ldd [ %g1 + 0x2f0 ], %f8 ! 201f6f0 <_CPU_Trap_slot_template+0x24><== NOT EXECUTED
200ccb0: 81 a8 0a c8 fcmped %f0, %f8 <== NOT EXECUTED
200ccb4: 01 00 00 00 nop <== NOT EXECUTED
200ccb8: 19 bf ff ef fbuge 200cc74 <rtems_string_to_double+0x70> <== NOT EXECUTED
200ccbc: 01 00 00 00 nop <== NOT EXECUTED
(( result == 0 ) || ( result == HUGE_VAL ) || ( result == -HUGE_VAL )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200ccc0: b0 10 20 0a mov 0xa, %i0 ! a <PROM_START+0xa>
}
200ccc4: 81 c7 e0 08 ret
200ccc8: 81 e8 00 00 restore
0200cccc <rtems_string_to_float>:
rtems_status_code rtems_string_to_float (
const char *s,
float *n,
char **endptr
)
{
200cccc: 9d e3 bf 90 save %sp, -112, %sp
200ccd0: a0 10 00 18 mov %i0, %l0
float result;
char *end;
if ( !n )
200ccd4: 80 a6 60 00 cmp %i1, 0
200ccd8: 02 80 00 2a be 200cd80 <rtems_string_to_float+0xb4>
200ccdc: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200cce0: 40 00 0d a3 call 201036c <__errno>
200cce4: 01 00 00 00 nop
*n = 0;
result = strtof( s, &end );
200cce8: 92 07 bf fc add %fp, -4, %o1
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
200ccec: c0 22 00 00 clr [ %o0 ]
*n = 0;
200ccf0: c0 26 40 00 clr [ %i1 ]
result = strtof( s, &end );
200ccf4: 40 00 19 08 call 2013114 <strtof>
200ccf8: 90 10 00 10 mov %l0, %o0
if ( endptr )
200ccfc: 80 a6 a0 00 cmp %i2, 0
200cd00: 02 80 00 03 be 200cd0c <rtems_string_to_float+0x40>
200cd04: c2 07 bf fc ld [ %fp + -4 ], %g1
*endptr = end;
200cd08: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200cd0c: 80 a0 40 10 cmp %g1, %l0
200cd10: 02 80 00 1c be 200cd80 <rtems_string_to_float+0xb4>
200cd14: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cd18: 40 00 0d 95 call 201036c <__errno>
200cd1c: c1 27 bf f4 st %f0, [ %fp + -12 ]
200cd20: c2 02 00 00 ld [ %o0 ], %g1
200cd24: 80 a0 60 22 cmp %g1, 0x22
200cd28: 02 80 00 05 be 200cd3c <rtems_string_to_float+0x70>
200cd2c: c1 07 bf f4 ld [ %fp + -12 ], %f0
(( result == 0 ) || ( result == HUGE_VALF ) || ( result == -HUGE_VALF )))
return RTEMS_INVALID_NUMBER;
*n = result;
200cd30: c1 26 40 00 st %f0, [ %i1 ]
return RTEMS_SUCCESSFUL;
200cd34: 81 c7 e0 08 ret
200cd38: 91 e8 20 00 restore %g0, 0, %o0
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cd3c: 03 00 80 7d sethi %hi(0x201f400), %g1
200cd40: d1 00 62 f8 ld [ %g1 + 0x2f8 ], %f8 ! 201f6f8 <_CPU_Trap_slot_template+0x2c>
200cd44: 81 a8 0a 28 fcmps %f0, %f8
200cd48: 01 00 00 00 nop
200cd4c: 13 80 00 0c fbe 200cd7c <rtems_string_to_float+0xb0>
200cd50: 03 00 80 7d sethi %hi(0x201f400), %g1
200cd54: d1 00 62 fc ld [ %g1 + 0x2fc ], %f8 ! 201f6fc <_CPU_Trap_slot_template+0x30>
200cd58: 81 a8 0a a8 fcmpes %f0, %f8
200cd5c: 01 00 00 00 nop
200cd60: 0d 80 00 07 fbg 200cd7c <rtems_string_to_float+0xb0>
200cd64: 03 00 80 7d sethi %hi(0x201f400), %g1
200cd68: d1 00 63 00 ld [ %g1 + 0x300 ], %f8 ! 201f700 <_CPU_Trap_slot_template+0x34><== NOT EXECUTED
200cd6c: 81 a8 0a a8 fcmpes %f0, %f8 <== NOT EXECUTED
200cd70: 01 00 00 00 nop <== NOT EXECUTED
200cd74: 19 bf ff ef fbuge 200cd30 <rtems_string_to_float+0x64> <== NOT EXECUTED
200cd78: 01 00 00 00 nop <== NOT EXECUTED
(( result == 0 ) || ( result == HUGE_VALF ) || ( result == -HUGE_VALF )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200cd7c: b0 10 20 0a mov 0xa, %i0 ! a <PROM_START+0xa>
}
200cd80: 81 c7 e0 08 ret
200cd84: 81 e8 00 00 restore
02021b84 <rtems_string_to_int>:
const char *s,
int *n,
char **endptr,
int base
)
{
2021b84: 9d e3 bf 98 save %sp, -104, %sp
2021b88: a0 10 00 18 mov %i0, %l0
long result;
char *end;
if ( !n )
2021b8c: 80 a6 60 00 cmp %i1, 0
2021b90: 02 80 00 19 be 2021bf4 <rtems_string_to_int+0x70>
2021b94: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
2021b98: 40 00 a2 3a call 204a480 <__errno>
2021b9c: 01 00 00 00 nop
2021ba0: c0 22 00 00 clr [ %o0 ]
*n = 0;
2021ba4: c0 26 40 00 clr [ %i1 ]
result = strtol( s, &end, base );
2021ba8: 94 10 00 1b mov %i3, %o2
2021bac: 90 10 00 10 mov %l0, %o0
2021bb0: 40 00 c2 6d call 2052564 <strtol>
2021bb4: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
2021bb8: 80 a6 a0 00 cmp %i2, 0
2021bbc: 02 80 00 20 be 2021c3c <rtems_string_to_int+0xb8>
2021bc0: a2 10 00 08 mov %o0, %l1
*endptr = end;
2021bc4: c2 07 bf fc ld [ %fp + -4 ], %g1
2021bc8: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
2021bcc: 80 a0 40 10 cmp %g1, %l0
2021bd0: 02 80 00 09 be 2021bf4 <rtems_string_to_int+0x70>
2021bd4: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021bd8: 40 00 a2 2a call 204a480 <__errno>
2021bdc: 01 00 00 00 nop
2021be0: c2 02 00 00 ld [ %o0 ], %g1
2021be4: 80 a0 60 22 cmp %g1, 0x22
2021be8: 02 80 00 05 be 2021bfc <rtems_string_to_int+0x78>
2021bec: b0 10 20 00 clr %i0
errno = ERANGE;
return RTEMS_INVALID_NUMBER;
}
#endif
*n = result;
2021bf0: e2 26 40 00 st %l1, [ %i1 ]
return RTEMS_SUCCESSFUL;
2021bf4: 81 c7 e0 08 ret
2021bf8: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021bfc: 03 1f ff ff sethi %hi(0x7ffffc00), %g1
2021c00: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff <RAM_END+0x7dbfffff>
2021c04: 80 a4 40 01 cmp %l1, %g1
2021c08: 12 80 00 05 bne 2021c1c <rtems_string_to_int+0x98> <== NEVER TAKEN
2021c0c: 80 a4 60 00 cmp %l1, 0
}
#endif
*n = result;
return RTEMS_SUCCESSFUL;
2021c10: b0 10 20 0a mov 0xa, %i0
}
2021c14: 81 c7 e0 08 ret
2021c18: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021c1c: 02 bf ff fd be 2021c10 <rtems_string_to_int+0x8c> <== NOT EXECUTED
2021c20: 03 20 00 00 sethi %hi(0x80000000), %g1 <== NOT EXECUTED
2021c24: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2021c28: 22 bf ff f3 be,a 2021bf4 <rtems_string_to_int+0x70> <== NOT EXECUTED
2021c2c: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
errno = ERANGE;
return RTEMS_INVALID_NUMBER;
}
#endif
*n = result;
2021c30: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
2021c34: 81 c7 e0 08 ret <== NOT EXECUTED
2021c38: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
2021c3c: 10 bf ff e4 b 2021bcc <rtems_string_to_int+0x48>
2021c40: c2 07 bf fc ld [ %fp + -4 ], %g1
0200cf2c <rtems_string_to_long>:
const char *s,
long *n,
char **endptr,
int base
)
{
200cf2c: 9d e3 bf 98 save %sp, -104, %sp
200cf30: a0 10 00 18 mov %i0, %l0
long result;
char *end;
if ( !n )
200cf34: 80 a6 60 00 cmp %i1, 0
200cf38: 02 80 00 19 be 200cf9c <rtems_string_to_long+0x70>
200cf3c: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200cf40: 40 00 0d 0b call 201036c <__errno>
200cf44: 01 00 00 00 nop
*n = 0;
result = strtol( s, &end, base );
200cf48: 94 10 00 1b mov %i3, %o2
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
200cf4c: c0 22 00 00 clr [ %o0 ]
*n = 0;
200cf50: c0 26 40 00 clr [ %i1 ]
result = strtol( s, &end, base );
200cf54: 90 10 00 10 mov %l0, %o0
200cf58: 40 00 19 0f call 2013394 <strtol>
200cf5c: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
200cf60: 80 a6 a0 00 cmp %i2, 0
200cf64: 02 80 00 20 be 200cfe4 <rtems_string_to_long+0xb8>
200cf68: a2 10 00 08 mov %o0, %l1
*endptr = end;
200cf6c: c2 07 bf fc ld [ %fp + -4 ], %g1
200cf70: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200cf74: 80 a0 40 10 cmp %g1, %l0
200cf78: 02 80 00 09 be 200cf9c <rtems_string_to_long+0x70>
200cf7c: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cf80: 40 00 0c fb call 201036c <__errno>
200cf84: 01 00 00 00 nop
200cf88: c2 02 00 00 ld [ %o0 ], %g1
200cf8c: 80 a0 60 22 cmp %g1, 0x22
200cf90: 02 80 00 05 be 200cfa4 <rtems_string_to_long+0x78>
200cf94: b0 10 20 00 clr %i0
(( result == 0 ) || ( result == LONG_MAX ) || ( result == LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
200cf98: e2 26 40 00 st %l1, [ %i1 ]
return RTEMS_SUCCESSFUL;
200cf9c: 81 c7 e0 08 ret
200cfa0: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cfa4: 03 1f ff ff sethi %hi(0x7ffffc00), %g1
200cfa8: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff <RAM_END+0x7dbfffff>
200cfac: 80 a4 40 01 cmp %l1, %g1
200cfb0: 12 80 00 05 bne 200cfc4 <rtems_string_to_long+0x98>
200cfb4: 80 a4 60 00 cmp %l1, 0
(( result == 0 ) || ( result == LONG_MAX ) || ( result == LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200cfb8: b0 10 20 0a mov 0xa, %i0
}
200cfbc: 81 c7 e0 08 ret
200cfc0: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cfc4: 02 bf ff fd be 200cfb8 <rtems_string_to_long+0x8c> <== NEVER TAKEN
200cfc8: 03 20 00 00 sethi %hi(0x80000000), %g1
200cfcc: 80 a4 40 01 cmp %l1, %g1
200cfd0: 22 bf ff f3 be,a 200cf9c <rtems_string_to_long+0x70> <== ALWAYS TAKEN
200cfd4: b0 10 20 0a mov 0xa, %i0
(( result == 0 ) || ( result == LONG_MAX ) || ( result == LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
200cfd8: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
200cfdc: 81 c7 e0 08 ret <== NOT EXECUTED
200cfe0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
200cfe4: 10 bf ff e4 b 200cf74 <rtems_string_to_long+0x48>
200cfe8: c2 07 bf fc ld [ %fp + -4 ], %g1
0200ce48 <rtems_string_to_long_long>:
const char *s,
long long *n,
char **endptr,
int base
)
{
200ce48: 9d e3 bf 98 save %sp, -104, %sp
200ce4c: a0 10 00 18 mov %i0, %l0
long long result;
char *end;
if ( !n )
200ce50: 80 a6 60 00 cmp %i1, 0
200ce54: 02 80 00 26 be 200ceec <rtems_string_to_long_long+0xa4>
200ce58: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200ce5c: 40 00 0d 44 call 201036c <__errno>
200ce60: 01 00 00 00 nop
*n = 0;
result = strtoll( s, &end, base );
200ce64: 94 10 00 1b mov %i3, %o2
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
200ce68: c0 22 00 00 clr [ %o0 ]
*n = 0;
200ce6c: c0 26 40 00 clr [ %i1 ]
200ce70: c0 26 60 04 clr [ %i1 + 4 ]
result = strtoll( s, &end, base );
200ce74: 90 10 00 10 mov %l0, %o0
200ce78: 40 00 19 51 call 20133bc <strtoll>
200ce7c: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
200ce80: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
errno = 0;
*n = 0;
result = strtoll( s, &end, base );
200ce84: a2 10 00 08 mov %o0, %l1
if ( endptr )
200ce88: 02 80 00 27 be 200cf24 <rtems_string_to_long_long+0xdc>
200ce8c: b6 10 00 09 mov %o1, %i3
*endptr = end;
200ce90: c2 07 bf fc ld [ %fp + -4 ], %g1
200ce94: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200ce98: 80 a0 40 10 cmp %g1, %l0
200ce9c: 02 80 00 14 be 200ceec <rtems_string_to_long_long+0xa4>
200cea0: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cea4: 40 00 0d 32 call 201036c <__errno>
200cea8: 01 00 00 00 nop
200ceac: c2 02 00 00 ld [ %o0 ], %g1
200ceb0: 80 a0 60 22 cmp %g1, 0x22
200ceb4: 02 80 00 06 be 200cecc <rtems_string_to_long_long+0x84>
200ceb8: 03 1f ff ff sethi %hi(0x7ffffc00), %g1
(( result == 0 ) || ( result == LONG_LONG_MAX ) || ( result == LONG_LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
200cebc: f6 26 60 04 st %i3, [ %i1 + 4 ]
200cec0: e2 26 40 00 st %l1, [ %i1 ]
return RTEMS_SUCCESSFUL;
200cec4: 81 c7 e0 08 ret
200cec8: 91 e8 20 00 restore %g0, 0, %o0
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cecc: 82 10 63 ff or %g1, 0x3ff, %g1
200ced0: 80 a4 40 01 cmp %l1, %g1
200ced4: 02 80 00 10 be 200cf14 <rtems_string_to_long_long+0xcc>
200ced8: 80 a6 ff ff cmp %i3, -1
200cedc: 80 94 40 1b orcc %l1, %i3, %g0
200cee0: 12 80 00 05 bne 200cef4 <rtems_string_to_long_long+0xac> <== ALWAYS TAKEN
200cee4: 03 20 00 00 sethi %hi(0x80000000), %g1
(( result == 0 ) || ( result == LONG_LONG_MAX ) || ( result == LONG_LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200cee8: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
}
200ceec: 81 c7 e0 08 ret
200cef0: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cef4: 80 a4 40 01 cmp %l1, %g1
200cef8: 32 bf ff f2 bne,a 200cec0 <rtems_string_to_long_long+0x78><== NEVER TAKEN
200cefc: f6 26 60 04 st %i3, [ %i1 + 4 ] <== NOT EXECUTED
200cf00: 80 a6 e0 00 cmp %i3, 0
200cf04: 32 bf ff ef bne,a 200cec0 <rtems_string_to_long_long+0x78><== NEVER TAKEN
200cf08: f6 26 60 04 st %i3, [ %i1 + 4 ] <== NOT EXECUTED
(( result == 0 ) || ( result == LONG_LONG_MAX ) || ( result == LONG_LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200cf0c: 81 c7 e0 08 ret
200cf10: 91 e8 20 0a restore %g0, 0xa, %o0
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200cf14: 12 bf ff f3 bne 200cee0 <rtems_string_to_long_long+0x98> <== NEVER TAKEN
200cf18: 80 94 40 1b orcc %l1, %i3, %g0
(( result == 0 ) || ( result == LONG_LONG_MAX ) || ( result == LONG_LONG_MIN )))
return RTEMS_INVALID_NUMBER;
*n = result;
return RTEMS_SUCCESSFUL;
200cf1c: 81 c7 e0 08 ret
200cf20: 91 e8 20 0a restore %g0, 0xa, %o0
200cf24: 10 bf ff dd b 200ce98 <rtems_string_to_long_long+0x50>
200cf28: c2 07 bf fc ld [ %fp + -4 ], %g1
02021c58 <rtems_string_to_unsigned_char>:
const char *s,
unsigned char *n,
char **endptr,
int base
)
{
2021c58: 9d e3 bf 98 save %sp, -104, %sp
2021c5c: a0 10 00 18 mov %i0, %l0
unsigned long result;
char *end;
if ( !n )
2021c60: 80 a6 60 00 cmp %i1, 0
2021c64: 02 80 00 28 be 2021d04 <rtems_string_to_unsigned_char+0xac>
2021c68: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
2021c6c: 40 00 a2 05 call 204a480 <__errno>
2021c70: 01 00 00 00 nop
2021c74: c0 22 00 00 clr [ %o0 ]
*n = 0;
2021c78: c0 2e 40 00 clrb [ %i1 ]
result = strtoul( s, &end, base );
2021c7c: 94 10 00 1b mov %i3, %o2
2021c80: 90 10 00 10 mov %l0, %o0
2021c84: 40 00 c3 70 call 2052a44 <strtoul>
2021c88: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
2021c8c: 80 a6 a0 00 cmp %i2, 0
2021c90: 02 80 00 1f be 2021d0c <rtems_string_to_unsigned_char+0xb4>
2021c94: a2 10 00 08 mov %o0, %l1
*endptr = end;
2021c98: c2 07 bf fc ld [ %fp + -4 ], %g1
2021c9c: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
2021ca0: 80 a0 40 10 cmp %g1, %l0
2021ca4: 02 80 00 18 be 2021d04 <rtems_string_to_unsigned_char+0xac>
2021ca8: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021cac: 40 00 a1 f5 call 204a480 <__errno>
2021cb0: 01 00 00 00 nop
2021cb4: c2 02 00 00 ld [ %o0 ], %g1
2021cb8: 80 a0 60 22 cmp %g1, 0x22
2021cbc: 02 80 00 07 be 2021cd8 <rtems_string_to_unsigned_char+0x80><== NEVER TAKEN
2021cc0: 80 a4 60 ff cmp %l1, 0xff
(( result == 0 ) || ( result == ULONG_MAX )))
return RTEMS_INVALID_NUMBER;
#if (UCHAR_MAX < ULONG_MAX)
if ( result > UCHAR_MAX ) {
2021cc4: 18 80 00 0c bgu 2021cf4 <rtems_string_to_unsigned_char+0x9c><== NEVER TAKEN
2021cc8: 01 00 00 00 nop
errno = ERANGE;
return RTEMS_INVALID_NUMBER;
}
#endif
*n = result;
2021ccc: e2 2e 40 00 stb %l1, [ %i1 ]
return RTEMS_SUCCESSFUL;
}
2021cd0: 81 c7 e0 08 ret
2021cd4: 91 e8 20 00 restore %g0, 0, %o0
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021cd8: 82 04 7f ff add %l1, -1, %g1 <== NOT EXECUTED
2021cdc: 80 a0 7f fd cmp %g1, -3 <== NOT EXECUTED
2021ce0: 18 80 00 09 bgu 2021d04 <rtems_string_to_unsigned_char+0xac><== NOT EXECUTED
2021ce4: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
(( result == 0 ) || ( result == ULONG_MAX )))
return RTEMS_INVALID_NUMBER;
#if (UCHAR_MAX < ULONG_MAX)
if ( result > UCHAR_MAX ) {
2021ce8: 80 a4 60 ff cmp %l1, 0xff <== NOT EXECUTED
2021cec: 28 bf ff f9 bleu,a 2021cd0 <rtems_string_to_unsigned_char+0x78><== NOT EXECUTED
2021cf0: e2 2e 40 00 stb %l1, [ %i1 ] <== NOT EXECUTED
errno = ERANGE;
2021cf4: 40 00 a1 e3 call 204a480 <__errno> <== NOT EXECUTED
2021cf8: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
2021cfc: 82 10 20 22 mov 0x22, %g1 <== NOT EXECUTED
2021d00: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return RTEMS_INVALID_NUMBER;
2021d04: 81 c7 e0 08 ret
2021d08: 81 e8 00 00 restore
2021d0c: 10 bf ff e5 b 2021ca0 <rtems_string_to_unsigned_char+0x48>
2021d10: c2 07 bf fc ld [ %fp + -4 ], %g1
0200d0bc <rtems_string_to_unsigned_int>:
const char *s,
unsigned int *n,
char **endptr,
int base
)
{
200d0bc: 9d e3 bf 98 save %sp, -104, %sp
200d0c0: a0 10 00 18 mov %i0, %l0
unsigned long result;
char *end;
if ( !n )
200d0c4: 80 a6 60 00 cmp %i1, 0
200d0c8: 02 80 00 19 be 200d12c <rtems_string_to_unsigned_int+0x70>
200d0cc: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200d0d0: 40 00 0c a7 call 201036c <__errno>
200d0d4: 01 00 00 00 nop
200d0d8: c0 22 00 00 clr [ %o0 ]
*n = 0;
result = strtoul( s, &end, base );
200d0dc: 94 10 00 1b mov %i3, %o2
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
*n = 0;
200d0e0: c0 26 40 00 clr [ %i1 ]
result = strtoul( s, &end, base );
200d0e4: 90 10 00 10 mov %l0, %o0
200d0e8: 40 00 19 e3 call 2013874 <strtoul>
200d0ec: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
200d0f0: 80 a6 a0 00 cmp %i2, 0
200d0f4: 02 80 00 17 be 200d150 <rtems_string_to_unsigned_int+0x94>
200d0f8: b6 10 00 08 mov %o0, %i3
*endptr = end;
200d0fc: c2 07 bf fc ld [ %fp + -4 ], %g1
200d100: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200d104: 80 a0 40 10 cmp %g1, %l0
200d108: 02 80 00 09 be 200d12c <rtems_string_to_unsigned_int+0x70>
200d10c: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200d110: 40 00 0c 97 call 201036c <__errno>
200d114: 01 00 00 00 nop
200d118: c2 02 00 00 ld [ %o0 ], %g1
200d11c: 80 a0 60 22 cmp %g1, 0x22
200d120: 02 80 00 05 be 200d134 <rtems_string_to_unsigned_int+0x78>
200d124: b0 10 20 00 clr %i0
errno = ERANGE;
return RTEMS_INVALID_NUMBER;
}
#endif
*n = result;
200d128: f6 26 40 00 st %i3, [ %i1 ]
return RTEMS_SUCCESSFUL;
}
200d12c: 81 c7 e0 08 ret
200d130: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200d134: 82 06 ff ff add %i3, -1, %g1
200d138: 80 a0 7f fd cmp %g1, -3
200d13c: 18 bf ff fc bgu 200d12c <rtems_string_to_unsigned_int+0x70><== ALWAYS TAKEN
200d140: b0 10 20 0a mov 0xa, %i0
errno = ERANGE;
return RTEMS_INVALID_NUMBER;
}
#endif
*n = result;
200d144: f6 26 40 00 st %i3, [ %i1 ] <== NOT EXECUTED
200d148: 81 c7 e0 08 ret <== NOT EXECUTED
200d14c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
200d150: 10 bf ff ed b 200d104 <rtems_string_to_unsigned_int+0x48>
200d154: c2 07 bf fc ld [ %fp + -4 ], %g1
02021d14 <rtems_string_to_unsigned_long>:
const char *s,
unsigned long *n,
char **endptr,
int base
)
{
2021d14: 9d e3 bf 98 save %sp, -104, %sp
2021d18: a0 10 00 18 mov %i0, %l0
unsigned long result;
char *end;
if ( !n )
2021d1c: 80 a6 60 00 cmp %i1, 0
2021d20: 02 80 00 19 be 2021d84 <rtems_string_to_unsigned_long+0x70>
2021d24: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
2021d28: 40 00 a1 d6 call 204a480 <__errno>
2021d2c: 01 00 00 00 nop
*n = 0;
result = strtoul( s, &end, base );
2021d30: 94 10 00 1b mov %i3, %o2
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
2021d34: c0 22 00 00 clr [ %o0 ]
*n = 0;
2021d38: c0 26 40 00 clr [ %i1 ]
result = strtoul( s, &end, base );
2021d3c: 90 10 00 10 mov %l0, %o0
2021d40: 40 00 c3 41 call 2052a44 <strtoul>
2021d44: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
2021d48: 80 a6 a0 00 cmp %i2, 0
2021d4c: 02 80 00 17 be 2021da8 <rtems_string_to_unsigned_long+0x94>
2021d50: b6 10 00 08 mov %o0, %i3
*endptr = end;
2021d54: c2 07 bf fc ld [ %fp + -4 ], %g1
2021d58: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
2021d5c: 80 a0 40 10 cmp %g1, %l0
2021d60: 02 80 00 09 be 2021d84 <rtems_string_to_unsigned_long+0x70>
2021d64: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021d68: 40 00 a1 c6 call 204a480 <__errno>
2021d6c: 01 00 00 00 nop
2021d70: c2 02 00 00 ld [ %o0 ], %g1
2021d74: 80 a0 60 22 cmp %g1, 0x22
2021d78: 02 80 00 05 be 2021d8c <rtems_string_to_unsigned_long+0x78>
2021d7c: b0 10 20 00 clr %i0
(( result == 0 ) || ( result == ULONG_MAX )))
return RTEMS_INVALID_NUMBER;
*n = result;
2021d80: f6 26 40 00 st %i3, [ %i1 ]
return RTEMS_SUCCESSFUL;
}
2021d84: 81 c7 e0 08 ret
2021d88: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
2021d8c: 82 06 ff ff add %i3, -1, %g1
2021d90: 80 a0 7f fd cmp %g1, -3
2021d94: 18 bf ff fc bgu 2021d84 <rtems_string_to_unsigned_long+0x70><== ALWAYS TAKEN
2021d98: b0 10 20 0a mov 0xa, %i0
(( result == 0 ) || ( result == ULONG_MAX )))
return RTEMS_INVALID_NUMBER;
*n = result;
2021d9c: f6 26 40 00 st %i3, [ %i1 ] <== NOT EXECUTED
2021da0: 81 c7 e0 08 ret <== NOT EXECUTED
2021da4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
2021da8: 10 bf ff ed b 2021d5c <rtems_string_to_unsigned_long+0x48>
2021dac: c2 07 bf fc ld [ %fp + -4 ], %g1
0200d158 <rtems_string_to_unsigned_long_long>:
const char *s,
unsigned long long *n,
char **endptr,
int base
)
{
200d158: 9d e3 bf 98 save %sp, -104, %sp
200d15c: a0 10 00 18 mov %i0, %l0
unsigned long long result;
char *end;
if ( !n )
200d160: 80 a6 60 00 cmp %i1, 0
200d164: 02 80 00 1c be 200d1d4 <rtems_string_to_unsigned_long_long+0x7c>
200d168: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
errno = 0;
200d16c: 40 00 0c 80 call 201036c <__errno>
200d170: 01 00 00 00 nop
*n = 0;
result = strtoull( s, &end, base );
200d174: 94 10 00 1b mov %i3, %o2
char *end;
if ( !n )
return RTEMS_INVALID_ADDRESS;
errno = 0;
200d178: c0 22 00 00 clr [ %o0 ]
*n = 0;
200d17c: c0 26 40 00 clr [ %i1 ]
200d180: c0 26 60 04 clr [ %i1 + 4 ]
result = strtoull( s, &end, base );
200d184: 90 10 00 10 mov %l0, %o0
200d188: 40 00 19 c5 call 201389c <strtoull>
200d18c: 92 07 bf fc add %fp, -4, %o1
if ( endptr )
200d190: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
errno = 0;
*n = 0;
result = strtoull( s, &end, base );
200d194: a4 10 00 08 mov %o0, %l2
if ( endptr )
200d198: 02 80 00 1b be 200d204 <rtems_string_to_unsigned_long_long+0xac>
200d19c: a6 10 00 09 mov %o1, %l3
*endptr = end;
200d1a0: c2 07 bf fc ld [ %fp + -4 ], %g1
200d1a4: c2 26 80 00 st %g1, [ %i2 ]
if ( end == s )
200d1a8: 80 a0 40 10 cmp %g1, %l0
200d1ac: 02 80 00 0a be 200d1d4 <rtems_string_to_unsigned_long_long+0x7c>
200d1b0: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200d1b4: 40 00 0c 6e call 201036c <__errno>
200d1b8: 01 00 00 00 nop
200d1bc: c2 02 00 00 ld [ %o0 ], %g1
200d1c0: 80 a0 60 22 cmp %g1, 0x22
200d1c4: 02 80 00 06 be 200d1dc <rtems_string_to_unsigned_long_long+0x84>
200d1c8: 86 84 ff ff addcc %l3, -1, %g3
(( result == 0 ) || ( result == ULONG_LONG_MAX )))
return RTEMS_INVALID_NUMBER;
*n = result;
200d1cc: e4 3e 40 00 std %l2, [ %i1 ]
200d1d0: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
200d1d4: 81 c7 e0 08 ret
200d1d8: 81 e8 00 00 restore
*endptr = end;
if ( end == s )
return RTEMS_NOT_DEFINED;
if ( ( errno == ERANGE ) &&
200d1dc: 84 44 bf ff addx %l2, -1, %g2
200d1e0: 80 a0 bf ff cmp %g2, -1
200d1e4: 32 bf ff fb bne,a 200d1d0 <rtems_string_to_unsigned_long_long+0x78><== NEVER TAKEN
200d1e8: e4 3e 40 00 std %l2, [ %i1 ] <== NOT EXECUTED
200d1ec: 80 a0 ff fd cmp %g3, -3
200d1f0: 18 bf ff f9 bgu 200d1d4 <rtems_string_to_unsigned_long_long+0x7c><== ALWAYS TAKEN
200d1f4: b0 10 20 0a mov 0xa, %i0
(( result == 0 ) || ( result == ULONG_LONG_MAX )))
return RTEMS_INVALID_NUMBER;
*n = result;
200d1f8: e4 3e 40 00 std %l2, [ %i1 ] <== NOT EXECUTED
200d1fc: 81 c7 e0 08 ret <== NOT EXECUTED
200d200: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
200d204: 10 bf ff e9 b 200d1a8 <rtems_string_to_unsigned_long_long+0x50>
200d208: c2 07 bf fc ld [ %fp + -4 ], %g1
020112dc <rtems_task_mode>:
rtems_status_code rtems_task_mode(
rtems_mode mode_set,
rtems_mode mask,
rtems_mode *previous_mode_set
)
{
20112dc: 9d e3 bf a0 save %sp, -96, %sp
ASR_Information *asr;
bool is_asr_enabled = false;
bool needs_asr_dispatching = false;
rtems_mode old_mode;
if ( !previous_mode_set )
20112e0: 80 a6 a0 00 cmp %i2, 0
20112e4: 02 80 00 44 be 20113f4 <rtems_task_mode+0x118>
20112e8: 82 10 20 09 mov 9, %g1
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
20112ec: 03 00 80 7d sethi %hi(0x201f400), %g1
20112f0: e0 00 60 60 ld [ %g1 + 0x60 ], %l0 ! 201f460 <_Thread_Executing>
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
20112f4: c4 0c 20 75 ldub [ %l0 + 0x75 ], %g2
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
20112f8: c2 04 20 7c ld [ %l0 + 0x7c ], %g1
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
20112fc: 80 a0 00 02 cmp %g0, %g2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
2011300: e2 04 21 68 ld [ %l0 + 0x168 ], %l1
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
2011304: a4 60 3f ff subx %g0, -1, %l2
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
2011308: 80 a0 60 00 cmp %g1, 0
201130c: 12 80 00 3c bne 20113fc <rtems_task_mode+0x120>
2011310: a5 2c a0 08 sll %l2, 8, %l2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
2011314: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
2011318: 80 a0 00 01 cmp %g0, %g1
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
old_mode |= _ISR_Get_level();
201131c: 7f ff e5 92 call 200a964 <_CPU_ISR_Get_level>
2011320: a6 60 3f ff subx %g0, -1, %l3
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
2011324: a7 2c e0 0a sll %l3, 0xa, %l3
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
2011328: a6 14 c0 08 or %l3, %o0, %l3
old_mode |= _ISR_Get_level();
*previous_mode_set = old_mode;
201132c: a4 14 c0 12 or %l3, %l2, %l2
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
2011330: 80 8e 61 00 btst 0x100, %i1
2011334: 02 80 00 06 be 201134c <rtems_task_mode+0x70>
2011338: e4 26 80 00 st %l2, [ %i2 ]
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
201133c: 83 36 20 08 srl %i0, 8, %g1
2011340: 82 18 60 01 xor %g1, 1, %g1
2011344: 82 08 60 01 and %g1, 1, %g1
2011348: c2 2c 20 75 stb %g1, [ %l0 + 0x75 ]
if ( mask & RTEMS_TIMESLICE_MASK ) {
201134c: 80 8e 62 00 btst 0x200, %i1
2011350: 02 80 00 0b be 201137c <rtems_task_mode+0xa0>
2011354: 80 8e 60 0f btst 0xf, %i1
if ( _Modes_Is_timeslice(mode_set) ) {
2011358: 80 8e 22 00 btst 0x200, %i0
201135c: 22 80 00 07 be,a 2011378 <rtems_task_mode+0x9c>
2011360: c0 24 20 7c clr [ %l0 + 0x7c ]
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
2011364: 03 00 80 7c sethi %hi(0x201f000), %g1
2011368: c2 00 62 f8 ld [ %g1 + 0x2f8 ], %g1 ! 201f2f8 <_Thread_Ticks_per_timeslice>
201136c: c2 24 20 78 st %g1, [ %l0 + 0x78 ]
if ( mask & RTEMS_PREEMPT_MASK )
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
if ( mask & RTEMS_TIMESLICE_MASK ) {
if ( _Modes_Is_timeslice(mode_set) ) {
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
2011370: 82 10 20 01 mov 1, %g1
2011374: c2 24 20 7c st %g1, [ %l0 + 0x7c ]
/*
* Set the new interrupt level
*/
if ( mask & RTEMS_INTERRUPT_MASK )
2011378: 80 8e 60 0f btst 0xf, %i1
201137c: 12 80 00 2d bne 2011430 <rtems_task_mode+0x154>
2011380: 01 00 00 00 nop
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
2011384: 80 8e 64 00 btst 0x400, %i1
2011388: 22 80 00 16 be,a 20113e0 <rtems_task_mode+0x104>
201138c: a0 10 20 00 clr %l0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
2011390: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
* Output:
* *previous_mode_set - previous mode set
* always return RTEMS_SUCCESSFUL;
*/
rtems_status_code rtems_task_mode(
2011394: b1 36 20 0a srl %i0, 0xa, %i0
2011398: b0 1e 20 01 xor %i0, 1, %i0
201139c: b0 0e 20 01 and %i0, 1, %i0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
20113a0: 80 a0 40 18 cmp %g1, %i0
20113a4: 22 80 00 0f be,a 20113e0 <rtems_task_mode+0x104>
20113a8: a0 10 20 00 clr %l0
)
{
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
20113ac: 7f ff c3 3e call 20020a4 <sparc_disable_interrupts>
20113b0: f0 2c 60 08 stb %i0, [ %l1 + 8 ]
_signals = information->signals_pending;
20113b4: c4 04 60 18 ld [ %l1 + 0x18 ], %g2
information->signals_pending = information->signals_posted;
20113b8: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
information->signals_posted = _signals;
20113bc: c4 24 60 14 st %g2, [ %l1 + 0x14 ]
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
_signals = information->signals_pending;
information->signals_pending = information->signals_posted;
20113c0: c2 24 60 18 st %g1, [ %l1 + 0x18 ]
information->signals_posted = _signals;
_ISR_Enable( _level );
20113c4: 7f ff c3 3c call 20020b4 <sparc_enable_interrupts>
20113c8: 01 00 00 00 nop
20113cc: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
20113d0: 80 a0 60 00 cmp %g1, 0
20113d4: 12 80 00 28 bne 2011474 <rtems_task_mode+0x198>
20113d8: 82 10 20 01 mov 1, %g1
if ( is_asr_enabled != asr->is_enabled ) {
asr->is_enabled = is_asr_enabled;
_ASR_Swap_signals( asr );
if ( _ASR_Are_signals_pending( asr ) ) {
needs_asr_dispatching = true;
executing->do_post_task_switch_extension = true;
20113dc: a0 10 20 00 clr %l0
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) )
20113e0: 03 00 80 7d sethi %hi(0x201f400), %g1
20113e4: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 201f540 <_System_state_Current>
20113e8: 80 a0 60 03 cmp %g1, 3
20113ec: 02 80 00 16 be 2011444 <rtems_task_mode+0x168> <== ALWAYS TAKEN
20113f0: 82 10 20 00 clr %g1
if ( _Thread_Evaluate_mode() || needs_asr_dispatching )
_Thread_Dispatch();
return RTEMS_SUCCESSFUL;
}
20113f4: 81 c7 e0 08 ret
20113f8: 91 e8 00 01 restore %g0, %g1, %o0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
20113fc: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
2011400: a4 14 a2 00 or %l2, 0x200, %l2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
2011404: 80 a0 00 01 cmp %g0, %g1
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
old_mode |= _ISR_Get_level();
2011408: 7f ff e5 57 call 200a964 <_CPU_ISR_Get_level>
201140c: a6 60 3f ff subx %g0, -1, %l3
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
2011410: a7 2c e0 0a sll %l3, 0xa, %l3
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
2011414: a6 14 c0 08 or %l3, %o0, %l3
old_mode |= _ISR_Get_level();
*previous_mode_set = old_mode;
2011418: a4 14 c0 12 or %l3, %l2, %l2
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
201141c: 80 8e 61 00 btst 0x100, %i1
2011420: 02 bf ff cb be 201134c <rtems_task_mode+0x70>
2011424: e4 26 80 00 st %l2, [ %i2 ]
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
2011428: 10 bf ff c6 b 2011340 <rtems_task_mode+0x64>
201142c: 83 36 20 08 srl %i0, 8, %g1
*/
RTEMS_INLINE_ROUTINE void _Modes_Set_interrupt_level (
Modes_Control mode_set
)
{
_ISR_Set_level( _Modes_Get_interrupt_level( mode_set ) );
2011430: 90 0e 20 0f and %i0, 0xf, %o0
2011434: 7f ff c3 20 call 20020b4 <sparc_enable_interrupts>
2011438: 91 2a 20 08 sll %o0, 8, %o0
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
201143c: 10 bf ff d3 b 2011388 <rtems_task_mode+0xac>
2011440: 80 8e 64 00 btst 0x400, %i1
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) )
if ( _Thread_Evaluate_mode() || needs_asr_dispatching )
2011444: 40 00 00 8f call 2011680 <_Thread_Evaluate_mode>
2011448: 01 00 00 00 nop
201144c: 80 8a 20 ff btst 0xff, %o0
2011450: 12 80 00 04 bne 2011460 <rtems_task_mode+0x184>
2011454: 80 8c 20 ff btst 0xff, %l0
2011458: 02 bf ff e7 be 20113f4 <rtems_task_mode+0x118>
201145c: 82 10 20 00 clr %g1
_Thread_Dispatch();
2011460: 7f ff dd e8 call 2008c00 <_Thread_Dispatch>
2011464: 01 00 00 00 nop
2011468: 82 10 20 00 clr %g1 ! 0 <PROM_START>
return RTEMS_SUCCESSFUL;
}
201146c: 81 c7 e0 08 ret
2011470: 91 e8 00 01 restore %g0, %g1, %o0
if ( is_asr_enabled != asr->is_enabled ) {
asr->is_enabled = is_asr_enabled;
_ASR_Swap_signals( asr );
if ( _ASR_Are_signals_pending( asr ) ) {
needs_asr_dispatching = true;
executing->do_post_task_switch_extension = true;
2011474: c2 2c 20 74 stb %g1, [ %l0 + 0x74 ]
2011478: 10 bf ff da b 20113e0 <rtems_task_mode+0x104>
201147c: a0 10 20 01 mov 1, %l0
0200b884 <rtems_task_set_priority>:
rtems_status_code rtems_task_set_priority(
rtems_id id,
rtems_task_priority new_priority,
rtems_task_priority *old_priority
)
{
200b884: 9d e3 bf 98 save %sp, -104, %sp
register Thread_Control *the_thread;
Objects_Locations location;
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
200b888: 80 a6 60 00 cmp %i1, 0
200b88c: 02 80 00 07 be 200b8a8 <rtems_task_set_priority+0x24>
200b890: 90 10 00 18 mov %i0, %o0
*/
RTEMS_INLINE_ROUTINE bool _RTEMS_tasks_Priority_is_valid (
rtems_task_priority the_priority
)
{
return ( ( the_priority >= RTEMS_MINIMUM_PRIORITY ) &&
200b894: 03 00 80 8d sethi %hi(0x2023400), %g1
200b898: c2 08 60 24 ldub [ %g1 + 0x24 ], %g1 ! 2023424 <rtems_maximum_priority>
200b89c: 80 a6 40 01 cmp %i1, %g1
200b8a0: 18 80 00 1c bgu 200b910 <rtems_task_set_priority+0x8c>
200b8a4: b0 10 20 13 mov 0x13, %i0
!_RTEMS_tasks_Priority_is_valid( new_priority ) )
return RTEMS_INVALID_PRIORITY;
if ( !old_priority )
200b8a8: 80 a6 a0 00 cmp %i2, 0
200b8ac: 02 80 00 19 be 200b910 <rtems_task_set_priority+0x8c>
200b8b0: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
200b8b4: 40 00 08 c9 call 200dbd8 <_Thread_Get>
200b8b8: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
200b8bc: c2 07 bf fc ld [ %fp + -4 ], %g1
200b8c0: 80 a0 60 00 cmp %g1, 0
200b8c4: 12 80 00 13 bne 200b910 <rtems_task_set_priority+0x8c>
200b8c8: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
/* XXX need helper to "convert" from core priority */
*old_priority = the_thread->current_priority;
200b8cc: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
if ( new_priority != RTEMS_CURRENT_PRIORITY ) {
200b8d0: 80 a6 60 00 cmp %i1, 0
200b8d4: 02 80 00 0d be 200b908 <rtems_task_set_priority+0x84>
200b8d8: c2 26 80 00 st %g1, [ %i2 ]
the_thread->real_priority = new_priority;
if ( the_thread->resource_count == 0 ||
200b8dc: c2 02 20 1c ld [ %o0 + 0x1c ], %g1
200b8e0: 80 a0 60 00 cmp %g1, 0
200b8e4: 02 80 00 06 be 200b8fc <rtems_task_set_priority+0x78>
200b8e8: f2 22 20 18 st %i1, [ %o0 + 0x18 ]
the_thread->current_priority > new_priority )
200b8ec: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
200b8f0: 80 a6 40 01 cmp %i1, %g1
200b8f4: 1a 80 00 05 bcc 200b908 <rtems_task_set_priority+0x84> <== ALWAYS TAKEN
200b8f8: 01 00 00 00 nop
_Thread_Change_priority( the_thread, new_priority, false );
200b8fc: 92 10 00 19 mov %i1, %o1
200b900: 40 00 06 f4 call 200d4d0 <_Thread_Change_priority>
200b904: 94 10 20 00 clr %o2
}
_Thread_Enable_dispatch();
200b908: 40 00 08 90 call 200db48 <_Thread_Enable_dispatch>
200b90c: b0 10 20 00 clr %i0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
200b910: 81 c7 e0 08 ret
200b914: 81 e8 00 00 restore
02030350 <rtems_task_variable_delete>:
rtems_status_code rtems_task_variable_delete(
rtems_id tid,
void **ptr
)
{
2030350: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *prev;
if ( !ptr )
2030354: 80 a6 60 00 cmp %i1, 0
2030358: 02 80 00 09 be 203037c <rtems_task_variable_delete+0x2c>
203035c: 82 10 20 09 mov 9, %g1
return RTEMS_INVALID_ADDRESS;
prev = NULL;
the_thread = _Thread_Get (tid, &location);
2030360: 90 10 00 18 mov %i0, %o0
2030364: 7f ff 7f 49 call 2010088 <_Thread_Get>
2030368: 92 07 bf fc add %fp, -4, %o1
switch (location) {
203036c: c4 07 bf fc ld [ %fp + -4 ], %g2
2030370: 80 a0 a0 00 cmp %g2, 0
2030374: 02 80 00 04 be 2030384 <rtems_task_variable_delete+0x34>
2030378: 82 10 20 04 mov 4, %g1
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
203037c: 81 c7 e0 08 ret
2030380: 91 e8 00 01 restore %g0, %g1, %o0
the_thread = _Thread_Get (tid, &location);
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
2030384: d2 02 21 78 ld [ %o0 + 0x178 ], %o1
while (tvp) {
2030388: 80 a2 60 00 cmp %o1, 0
203038c: 02 80 00 10 be 20303cc <rtems_task_variable_delete+0x7c>
2030390: 01 00 00 00 nop
if (tvp->ptr == ptr) {
2030394: c2 02 60 04 ld [ %o1 + 4 ], %g1
2030398: 80 a0 40 19 cmp %g1, %i1
203039c: 12 80 00 08 bne 20303bc <rtems_task_variable_delete+0x6c>
20303a0: 84 10 00 09 mov %o1, %g2
if (prev)
prev->next = tvp->next;
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
20303a4: 10 80 00 17 b 2030400 <rtems_task_variable_delete+0xb0>
20303a8: c2 02 40 00 ld [ %o1 ], %g1
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
20303ac: 80 a0 40 19 cmp %g1, %i1
20303b0: 22 80 00 0c be,a 20303e0 <rtems_task_variable_delete+0x90>
20303b4: c2 02 40 00 ld [ %o1 ], %g1
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp );
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
20303b8: 84 10 00 09 mov %o1, %g2
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
20303bc: d2 02 40 00 ld [ %o1 ], %o1
the_thread = _Thread_Get (tid, &location);
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
20303c0: 80 a2 60 00 cmp %o1, 0
20303c4: 32 bf ff fa bne,a 20303ac <rtems_task_variable_delete+0x5c><== ALWAYS TAKEN
20303c8: c2 02 60 04 ld [ %o1 + 4 ], %g1
return RTEMS_SUCCESSFUL;
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
20303cc: 7f ff 7f 0b call 200fff8 <_Thread_Enable_dispatch>
20303d0: 01 00 00 00 nop
20303d4: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
20303d8: 81 c7 e0 08 ret
20303dc: 91 e8 00 01 restore %g0, %g1, %o0
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
if (prev)
prev->next = tvp->next;
20303e0: c2 20 80 00 st %g1, [ %g2 ]
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp );
20303e4: 40 00 00 2d call 2030498 <_RTEMS_Tasks_Invoke_task_variable_dtor>
20303e8: 01 00 00 00 nop
_Thread_Enable_dispatch();
20303ec: 7f ff 7f 03 call 200fff8 <_Thread_Enable_dispatch>
20303f0: 01 00 00 00 nop
20303f4: 82 10 20 00 clr %g1 ! 0 <PROM_START>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
20303f8: 81 c7 e0 08 ret
20303fc: 91 e8 00 01 restore %g0, %g1, %o0
while (tvp) {
if (tvp->ptr == ptr) {
if (prev)
prev->next = tvp->next;
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
2030400: 10 bf ff f9 b 20303e4 <rtems_task_variable_delete+0x94>
2030404: c2 22 21 78 st %g1, [ %o0 + 0x178 ]
02030408 <rtems_task_variable_get>:
rtems_status_code rtems_task_variable_get(
rtems_id tid,
void **ptr,
void **result
)
{
2030408: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp;
if ( !ptr )
203040c: 80 a6 60 00 cmp %i1, 0
2030410: 02 80 00 1c be 2030480 <rtems_task_variable_get+0x78>
2030414: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
if ( !result )
2030418: 02 80 00 1a be 2030480 <rtems_task_variable_get+0x78>
203041c: 90 10 00 18 mov %i0, %o0
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
2030420: 7f ff 7f 1a call 2010088 <_Thread_Get>
2030424: 92 07 bf fc add %fp, -4, %o1
switch (location) {
2030428: c2 07 bf fc ld [ %fp + -4 ], %g1
203042c: 80 a0 60 00 cmp %g1, 0
2030430: 12 80 00 12 bne 2030478 <rtems_task_variable_get+0x70>
2030434: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
/*
* Figure out if the variable is in this task's list.
*/
tvp = the_thread->task_variables;
2030438: c2 02 21 78 ld [ %o0 + 0x178 ], %g1
while (tvp) {
203043c: 80 a0 60 00 cmp %g1, 0
2030440: 32 80 00 07 bne,a 203045c <rtems_task_variable_get+0x54>
2030444: c4 00 60 04 ld [ %g1 + 4 ], %g2
2030448: 30 80 00 10 b,a 2030488 <rtems_task_variable_get+0x80>
203044c: 80 a0 60 00 cmp %g1, 0
2030450: 02 80 00 0e be 2030488 <rtems_task_variable_get+0x80> <== NEVER TAKEN
2030454: 01 00 00 00 nop
if (tvp->ptr == ptr) {
2030458: c4 00 60 04 ld [ %g1 + 4 ], %g2
203045c: 80 a0 80 19 cmp %g2, %i1
2030460: 32 bf ff fb bne,a 203044c <rtems_task_variable_get+0x44>
2030464: c2 00 40 00 ld [ %g1 ], %g1
/*
* Should this return the current (i.e not the
* saved) value if `tid' is the current task?
*/
*result = tvp->tval;
2030468: c2 00 60 0c ld [ %g1 + 0xc ], %g1
_Thread_Enable_dispatch();
203046c: b0 10 20 00 clr %i0
2030470: 7f ff 7e e2 call 200fff8 <_Thread_Enable_dispatch>
2030474: c2 26 80 00 st %g1, [ %i2 ]
return RTEMS_SUCCESSFUL;
2030478: 81 c7 e0 08 ret
203047c: 81 e8 00 00 restore
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2030480: 81 c7 e0 08 ret
2030484: 91 e8 20 09 restore %g0, 9, %o0
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
2030488: 7f ff 7e dc call 200fff8 <_Thread_Enable_dispatch>
203048c: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
2030490: 81 c7 e0 08 ret
2030494: 81 e8 00 00 restore
020053b0 <rtems_termios_baud_to_index>:
#include <rtems/termiostypes.h>
int rtems_termios_baud_to_index(
rtems_termios_baud_t termios_baud
)
{
20053b0: 82 10 00 08 mov %o0, %g1
int baud_index;
switch (termios_baud) {
20053b4: 80 a2 20 09 cmp %o0, 9
20053b8: 02 80 00 2d be 200546c <rtems_termios_baud_to_index+0xbc> <== NEVER TAKEN
20053bc: 90 10 20 09 mov 9, %o0
20053c0: 80 a0 60 09 cmp %g1, 9
20053c4: 04 80 00 1a ble 200542c <rtems_termios_baud_to_index+0x7c><== ALWAYS TAKEN
20053c8: 80 a0 60 04 cmp %g1, 4
20053cc: 80 a0 60 0e cmp %g1, 0xe <== NOT EXECUTED
20053d0: 02 80 00 27 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20053d4: 90 10 20 0e mov 0xe, %o0 <== NOT EXECUTED
20053d8: 80 a0 60 0e cmp %g1, 0xe <== NOT EXECUTED
20053dc: 04 80 00 26 ble 2005474 <rtems_termios_baud_to_index+0xc4><== NOT EXECUTED
20053e0: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
20053e4: 05 00 00 04 sethi %hi(0x1000), %g2 <== NOT EXECUTED
20053e8: 86 10 a0 02 or %g2, 2, %g3 ! 1002 <PROM_START+0x1002> <== NOT EXECUTED
20053ec: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
20053f0: 02 80 00 1f be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20053f4: 90 10 20 11 mov 0x11, %o0 <== NOT EXECUTED
20053f8: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
20053fc: 04 80 00 38 ble 20054dc <rtems_termios_baud_to_index+0x12c><== NOT EXECUTED
2005400: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED
2005404: 86 10 a0 03 or %g2, 3, %g3 <== NOT EXECUTED
2005408: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED
200540c: 02 80 00 18 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
2005410: 90 10 20 12 mov 0x12, %o0 <== NOT EXECUTED
2005414: 84 10 a0 04 or %g2, 4, %g2 <== NOT EXECUTED
2005418: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200541c: 02 80 00 14 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
2005420: 90 10 20 13 mov 0x13, %o0 <== NOT EXECUTED
case B460800: baud_index = 19; break;
default: baud_index = -1; break;
}
return baud_index;
}
2005424: 81 c3 e0 08 retl
2005428: 90 10 3f ff mov -1, %o0
rtems_termios_baud_t termios_baud
)
{
int baud_index;
switch (termios_baud) {
200542c: 02 80 00 10 be 200546c <rtems_termios_baud_to_index+0xbc> <== NEVER TAKEN
2005430: 90 10 20 04 mov 4, %o0
2005434: 80 a0 60 04 cmp %g1, 4
2005438: 14 80 00 1c bg 20054a8 <rtems_termios_baud_to_index+0xf8> <== NEVER TAKEN
200543c: 80 a0 60 06 cmp %g1, 6
2005440: 80 a0 60 01 cmp %g1, 1
2005444: 02 80 00 0a be 200546c <rtems_termios_baud_to_index+0xbc> <== NEVER TAKEN
2005448: 90 10 20 01 mov 1, %o0
200544c: 80 a0 60 01 cmp %g1, 1
2005450: 04 80 00 2b ble 20054fc <rtems_termios_baud_to_index+0x14c><== ALWAYS TAKEN
2005454: 80 a0 60 02 cmp %g1, 2
2005458: 02 80 00 05 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
200545c: 90 10 20 02 mov 2, %o0 <== NOT EXECUTED
2005460: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED
2005464: 12 bf ff f0 bne 2005424 <rtems_termios_baud_to_index+0x74><== NOT EXECUTED
2005468: 90 10 20 03 mov 3, %o0 <== NOT EXECUTED
200546c: 81 c3 e0 08 retl <== NOT EXECUTED
2005470: 01 00 00 00 nop <== NOT EXECUTED
2005474: 02 bf ff fe be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
2005478: 90 10 20 0b mov 0xb, %o0 ! b <PROM_START+0xb> <== NOT EXECUTED
200547c: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED
2005480: 06 bf ff fb bl 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
2005484: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED
2005488: 80 a0 60 0c cmp %g1, 0xc <== NOT EXECUTED
200548c: 02 bf ff f8 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
2005490: 90 10 20 0c mov 0xc, %o0 <== NOT EXECUTED
2005494: 80 a0 60 0d cmp %g1, 0xd <== NOT EXECUTED
2005498: 12 bf ff e3 bne 2005424 <rtems_termios_baud_to_index+0x74><== NOT EXECUTED
200549c: 90 10 20 0d mov 0xd, %o0 <== NOT EXECUTED
20054a0: 81 c3 e0 08 retl <== NOT EXECUTED
20054a4: 01 00 00 00 nop <== NOT EXECUTED
20054a8: 02 bf ff f1 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20054ac: 90 10 20 06 mov 6, %o0 ! 6 <PROM_START+0x6> <== NOT EXECUTED
20054b0: 80 a0 60 06 cmp %g1, 6 <== NOT EXECUTED
20054b4: 06 bf ff ee bl 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20054b8: 90 10 20 05 mov 5, %o0 <== NOT EXECUTED
20054bc: 80 a0 60 07 cmp %g1, 7 <== NOT EXECUTED
20054c0: 02 bf ff eb be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20054c4: 90 10 20 07 mov 7, %o0 <== NOT EXECUTED
20054c8: 80 a0 60 08 cmp %g1, 8 <== NOT EXECUTED
20054cc: 12 bf ff d6 bne 2005424 <rtems_termios_baud_to_index+0x74><== NOT EXECUTED
20054d0: 90 10 20 08 mov 8, %o0 <== NOT EXECUTED
20054d4: 81 c3 e0 08 retl <== NOT EXECUTED
20054d8: 01 00 00 00 nop <== NOT EXECUTED
20054dc: 02 bf ff e4 be 200546c <rtems_termios_baud_to_index+0xbc> <== NOT EXECUTED
20054e0: 90 10 20 0f mov 0xf, %o0 ! f <PROM_START+0xf> <== NOT EXECUTED
20054e4: 84 10 a0 01 or %g2, 1, %g2 <== NOT EXECUTED
20054e8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
20054ec: 12 bf ff ce bne 2005424 <rtems_termios_baud_to_index+0x74><== NOT EXECUTED
20054f0: 90 10 20 10 mov 0x10, %o0 <== NOT EXECUTED
20054f4: 81 c3 e0 08 retl <== NOT EXECUTED
20054f8: 01 00 00 00 nop <== NOT EXECUTED
20054fc: 80 a0 60 00 cmp %g1, 0
2005500: 12 bf ff c9 bne 2005424 <rtems_termios_baud_to_index+0x74><== ALWAYS TAKEN
2005504: 90 10 20 00 clr %o0
case B460800: baud_index = 19; break;
default: baud_index = -1; break;
}
return baud_index;
}
2005508: 81 c3 e0 08 retl <== NOT EXECUTED
02005510 <rtems_termios_baud_to_number>:
#include <rtems/termiostypes.h>
int32_t rtems_termios_baud_to_number(
int termios_baud
)
{
2005510: 82 10 00 08 mov %o0, %g1
int32_t baud;
switch (termios_baud) {
2005514: 80 a2 20 09 cmp %o0, 9
2005518: 02 80 00 2f be 20055d4 <rtems_termios_baud_to_number+0xc4>
200551c: 90 10 24 b0 mov 0x4b0, %o0
2005520: 80 a0 60 09 cmp %g1, 9
2005524: 04 80 00 1c ble 2005594 <rtems_termios_baud_to_number+0x84>
2005528: 80 a0 60 04 cmp %g1, 4
case B600: baud = 600; break;
case B1200: baud = 1200; break;
case B1800: baud = 1800; break;
case B2400: baud = 2400; break;
case B4800: baud = 4800; break;
case B9600: baud = 9600; break;
200552c: 11 00 00 12 sethi %hi(0x4800), %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
2005530: 80 a0 60 0e cmp %g1, 0xe
2005534: 02 80 00 28 be 20055d4 <rtems_termios_baud_to_number+0xc4>
2005538: 90 12 23 00 or %o0, 0x300, %o0
200553c: 80 a0 60 0e cmp %g1, 0xe
2005540: 04 80 00 27 ble 20055dc <rtems_termios_baud_to_number+0xcc>
2005544: 80 a0 60 0b cmp %g1, 0xb
2005548: 05 00 00 04 sethi %hi(0x1000), %g2
case B2400: baud = 2400; break;
case B4800: baud = 4800; break;
case B9600: baud = 9600; break;
case B19200: baud = 19200; break;
case B38400: baud = 38400; break;
case B57600: baud = 57600; break;
200554c: 11 00 00 70 sethi %hi(0x1c000), %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
2005550: 86 10 a0 02 or %g2, 2, %g3
2005554: 80 a0 40 03 cmp %g1, %g3
2005558: 02 80 00 1f be 20055d4 <rtems_termios_baud_to_number+0xc4>
200555c: 90 12 22 00 or %o0, 0x200, %o0
2005560: 80 a0 40 03 cmp %g1, %g3
2005564: 04 80 00 3a ble 200564c <rtems_termios_baud_to_number+0x13c>
2005568: 11 00 00 25 sethi %hi(0x9400), %o0
200556c: 86 10 a0 03 or %g2, 3, %g3
2005570: 80 a0 40 03 cmp %g1, %g3
2005574: 02 80 00 18 be 20055d4 <rtems_termios_baud_to_number+0xc4>
2005578: 11 00 00 e1 sethi %hi(0x38400), %o0
200557c: 84 10 a0 04 or %g2, 4, %g2
2005580: 80 a0 40 02 cmp %g1, %g2
2005584: 02 80 00 14 be 20055d4 <rtems_termios_baud_to_number+0xc4><== ALWAYS TAKEN
2005588: 11 00 01 c2 sethi %hi(0x70800), %o0
case B460800: baud = 460800; break;
default: baud = -1; break;
}
return baud;
}
200558c: 81 c3 e0 08 retl
2005590: 90 10 3f ff mov -1, %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
2005594: 02 80 00 10 be 20055d4 <rtems_termios_baud_to_number+0xc4>
2005598: 90 10 20 86 mov 0x86, %o0
200559c: 80 a0 60 04 cmp %g1, 4
20055a0: 14 80 00 1e bg 2005618 <rtems_termios_baud_to_number+0x108>
20055a4: 80 a0 60 06 cmp %g1, 6
20055a8: 80 a0 60 01 cmp %g1, 1
20055ac: 02 80 00 0a be 20055d4 <rtems_termios_baud_to_number+0xc4>
20055b0: 90 10 20 32 mov 0x32, %o0
20055b4: 80 a0 60 01 cmp %g1, 1
20055b8: 04 80 00 2f ble 2005674 <rtems_termios_baud_to_number+0x164>
20055bc: 80 a0 60 02 cmp %g1, 2
20055c0: 02 80 00 05 be 20055d4 <rtems_termios_baud_to_number+0xc4>
20055c4: 90 10 20 4b mov 0x4b, %o0
20055c8: 80 a0 60 03 cmp %g1, 3
20055cc: 12 bf ff f0 bne 200558c <rtems_termios_baud_to_number+0x7c><== NEVER TAKEN
20055d0: 90 10 20 6e mov 0x6e, %o0
20055d4: 81 c3 e0 08 retl
20055d8: 01 00 00 00 nop
20055dc: 02 bf ff fe be 20055d4 <rtems_termios_baud_to_number+0xc4>
20055e0: 90 10 29 60 mov 0x960, %o0 ! 960 <PROM_START+0x960>
20055e4: 80 a0 60 0b cmp %g1, 0xb
20055e8: 06 bf ff fb bl 20055d4 <rtems_termios_baud_to_number+0xc4>
20055ec: 90 10 27 08 mov 0x708, %o0
case B200: baud = 200; break;
case B300: baud = 300; break;
case B600: baud = 600; break;
case B1200: baud = 1200; break;
case B1800: baud = 1800; break;
case B2400: baud = 2400; break;
20055f0: 90 02 28 f8 add %o0, 0x8f8, %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
20055f4: 80 a0 60 0c cmp %g1, 0xc
20055f8: 02 bf ff f7 be 20055d4 <rtems_termios_baud_to_number+0xc4>
20055fc: 90 12 22 c0 or %o0, 0x2c0, %o0
case B300: baud = 300; break;
case B600: baud = 600; break;
case B1200: baud = 1200; break;
case B1800: baud = 1800; break;
case B2400: baud = 2400; break;
case B4800: baud = 4800; break;
2005600: 11 00 00 09 sethi %hi(0x2400), %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
2005604: 80 a0 60 0d cmp %g1, 0xd
2005608: 12 bf ff e1 bne 200558c <rtems_termios_baud_to_number+0x7c><== NEVER TAKEN
200560c: 90 12 21 80 or %o0, 0x180, %o0
2005610: 81 c3 e0 08 retl
2005614: 01 00 00 00 nop
2005618: 02 bf ff ef be 20055d4 <rtems_termios_baud_to_number+0xc4>
200561c: 90 10 20 c8 mov 0xc8, %o0 ! c8 <PROM_START+0xc8>
2005620: 80 a0 60 06 cmp %g1, 6
2005624: 06 bf ff ec bl 20055d4 <rtems_termios_baud_to_number+0xc4>
2005628: 90 10 20 96 mov 0x96, %o0
200562c: 80 a0 60 07 cmp %g1, 7
2005630: 02 bf ff e9 be 20055d4 <rtems_termios_baud_to_number+0xc4>
2005634: 90 10 21 2c mov 0x12c, %o0
2005638: 80 a0 60 08 cmp %g1, 8
200563c: 12 bf ff d4 bne 200558c <rtems_termios_baud_to_number+0x7c><== NEVER TAKEN
2005640: 90 10 22 58 mov 0x258, %o0
2005644: 81 c3 e0 08 retl
2005648: 01 00 00 00 nop
200564c: 80 a0 60 0f cmp %g1, 0xf
2005650: 02 bf ff e1 be 20055d4 <rtems_termios_baud_to_number+0xc4>
2005654: 90 12 22 00 or %o0, 0x200, %o0
2005658: 84 10 a0 01 or %g2, 1, %g2
case B1800: baud = 1800; break;
case B2400: baud = 2400; break;
case B4800: baud = 4800; break;
case B9600: baud = 9600; break;
case B19200: baud = 19200; break;
case B38400: baud = 38400; break;
200565c: 11 00 00 38 sethi %hi(0xe000), %o0
int termios_baud
)
{
int32_t baud;
switch (termios_baud) {
2005660: 80 a0 40 02 cmp %g1, %g2
2005664: 12 bf ff ca bne 200558c <rtems_termios_baud_to_number+0x7c><== NEVER TAKEN
2005668: 90 12 21 00 or %o0, 0x100, %o0
200566c: 81 c3 e0 08 retl
2005670: 01 00 00 00 nop
2005674: 80 a0 60 00 cmp %g1, 0
2005678: 12 bf ff c5 bne 200558c <rtems_termios_baud_to_number+0x7c>
200567c: 90 10 20 00 clr %o0
case B460800: baud = 460800; break;
default: baud = -1; break;
}
return baud;
}
2005680: 81 c3 e0 08 retl
02003e70 <rtems_termios_bufsize>:
int cbufsize,
int raw_input,
int raw_output
)
{
rtems_termios_cbufsize = cbufsize;
2003e70: 03 00 80 7a sethi %hi(0x201e800), %g1 <== NOT EXECUTED
2003e74: d0 20 61 70 st %o0, [ %g1 + 0x170 ] ! 201e970 <rtems_termios_cbufsize><== NOT EXECUTED
rtems_termios_raw_input_size = raw_input;
2003e78: 03 00 80 7a sethi %hi(0x201e800), %g1 <== NOT EXECUTED
rtems_termios_raw_output_size = raw_output;
return RTEMS_SUCCESSFUL;
}
2003e7c: 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;
2003e80: d2 20 61 74 st %o1, [ %g1 + 0x174 ] <== NOT EXECUTED
rtems_termios_raw_output_size = raw_output;
2003e84: 03 00 80 7a sethi %hi(0x201e800), %g1 <== NOT EXECUTED
return RTEMS_SUCCESSFUL;
}
2003e88: 81 c3 e0 08 retl <== NOT EXECUTED
2003e8c: d4 20 61 78 st %o2, [ %g1 + 0x178 ] ! 201e978 <rtems_termios_raw_output_size><== NOT EXECUTED
020055c0 <rtems_termios_close>:
}
}
rtems_status_code
rtems_termios_close (void *arg)
{
20055c0: 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);
20055c4: 23 00 80 7c sethi %hi(0x201f000), %l1
rtems_status_code
rtems_termios_close (void *arg)
{
rtems_libio_open_close_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
20055c8: c2 06 00 00 ld [ %i0 ], %g1
rtems_status_code sc;
sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
20055cc: d0 04 62 10 ld [ %l1 + 0x210 ], %o0
rtems_status_code
rtems_termios_close (void *arg)
{
rtems_libio_open_close_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
20055d0: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
rtems_status_code sc;
sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
20055d4: 92 10 20 00 clr %o1
20055d8: 40 00 04 bf call 20068d4 <rtems_semaphore_obtain>
20055dc: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL)
20055e0: 80 a2 20 00 cmp %o0, 0
20055e4: 12 80 00 6e bne 200579c <rtems_termios_close+0x1dc> <== NEVER TAKEN
20055e8: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
if (--tty->refcount == 0) {
20055ec: c2 04 20 08 ld [ %l0 + 8 ], %g1
20055f0: 82 00 7f ff add %g1, -1, %g1
20055f4: 80 a0 60 00 cmp %g1, 0
20055f8: 12 80 00 3a bne 20056e0 <rtems_termios_close+0x120>
20055fc: c2 24 20 08 st %g1, [ %l0 + 8 ]
if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
2005600: c4 04 20 cc ld [ %l0 + 0xcc ], %g2
2005604: 03 00 80 7b sethi %hi(0x201ec00), %g1
2005608: 85 28 a0 05 sll %g2, 5, %g2
200560c: 82 10 63 40 or %g1, 0x340, %g1
2005610: 82 00 40 02 add %g1, %g2, %g1
2005614: c2 00 60 04 ld [ %g1 + 4 ], %g1
2005618: 80 a0 60 00 cmp %g1, 0
200561c: 22 80 00 48 be,a 200573c <rtems_termios_close+0x17c> <== ALWAYS TAKEN
2005620: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
/*
* call discipline-specific close
*/
sc = rtems_termios_linesw[tty->t_line].l_close(tty);
2005624: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005628: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
}
drainOutput (tty);
}
if (tty->device.outputUsesInterrupts
200562c: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1 <== NOT EXECUTED
2005630: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
2005634: 22 80 00 4f be,a 2005770 <rtems_termios_close+0x1b0> <== NOT EXECUTED
2005638: d0 04 20 c4 ld [ %l0 + 0xc4 ], %o0 <== NOT EXECUTED
tty->txTaskId,
TERMIOS_TX_TERMINATE_EVENT);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
}
if (tty->device.lastClose)
200563c: c2 04 20 9c ld [ %l0 + 0x9c ], %g1 <== NOT EXECUTED
2005640: 80 a0 60 00 cmp %g1, 0
2005644: 22 80 00 07 be,a 2005660 <rtems_termios_close+0xa0> <== ALWAYS TAKEN
2005648: c2 04 00 00 ld [ %l0 ], %g1
(*tty->device.lastClose)(tty->major, tty->minor, arg);
200564c: d0 04 20 0c ld [ %l0 + 0xc ], %o0 <== NOT EXECUTED
2005650: d2 04 20 10 ld [ %l0 + 0x10 ], %o1 <== NOT EXECUTED
2005654: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005658: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
if (tty->forw == NULL) {
200565c: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
2005660: 80 a0 60 00 cmp %g1, 0
2005664: 22 80 00 27 be,a 2005700 <rtems_termios_close+0x140>
2005668: c2 04 20 04 ld [ %l0 + 4 ], %g1
if ( rtems_termios_ttyTail != NULL ) {
rtems_termios_ttyTail->forw = NULL;
}
}
else {
tty->forw->back = tty->back;
200566c: c4 04 20 04 ld [ %l0 + 4 ], %g2
2005670: c4 20 60 04 st %g2, [ %g1 + 4 ]
}
if (tty->back == NULL) {
2005674: c4 04 20 04 ld [ %l0 + 4 ], %g2
2005678: 80 a0 a0 00 cmp %g2, 0
200567c: 22 80 00 2b be,a 2005728 <rtems_termios_close+0x168> <== ALWAYS TAKEN
2005680: 05 00 80 7c sethi %hi(0x201f000), %g2
if ( rtems_termios_ttyHead != NULL ) {
rtems_termios_ttyHead->back = NULL;
}
}
else {
tty->back->forw = tty->forw;
2005684: c2 20 80 00 st %g1, [ %g2 ] <== NOT EXECUTED
}
rtems_semaphore_delete (tty->isem);
2005688: 40 00 04 66 call 2006820 <rtems_semaphore_delete>
200568c: d0 04 20 14 ld [ %l0 + 0x14 ], %o0
rtems_semaphore_delete (tty->osem);
2005690: 40 00 04 64 call 2006820 <rtems_semaphore_delete>
2005694: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
rtems_semaphore_delete (tty->rawOutBuf.Semaphore);
2005698: 40 00 04 62 call 2006820 <rtems_semaphore_delete>
200569c: d0 04 20 8c ld [ %l0 + 0x8c ], %o0
if ((tty->device.pollRead == NULL) ||
20056a0: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
20056a4: 80 a0 60 00 cmp %g1, 0
20056a8: 02 80 00 13 be 20056f4 <rtems_termios_close+0x134> <== NEVER TAKEN
20056ac: 01 00 00 00 nop
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN))
20056b0: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1
20056b4: 80 a0 60 02 cmp %g1, 2
20056b8: 02 80 00 0f be 20056f4 <rtems_termios_close+0x134> <== NEVER TAKEN
20056bc: 01 00 00 00 nop
rtems_semaphore_delete (tty->rawInBuf.Semaphore);
free (tty->rawInBuf.theBuf);
20056c0: 7f ff f5 8b call 2002cec <free>
20056c4: d0 04 20 58 ld [ %l0 + 0x58 ], %o0
free (tty->rawOutBuf.theBuf);
20056c8: 7f ff f5 89 call 2002cec <free>
20056cc: d0 04 20 7c ld [ %l0 + 0x7c ], %o0
free (tty->cbuf);
20056d0: 7f ff f5 87 call 2002cec <free>
20056d4: d0 04 20 1c ld [ %l0 + 0x1c ], %o0
free (tty);
20056d8: 7f ff f5 85 call 2002cec <free>
20056dc: 90 10 00 10 mov %l0, %o0
}
rtems_semaphore_release (rtems_termios_ttyMutex);
20056e0: d0 04 62 10 ld [ %l1 + 0x210 ], %o0
20056e4: 40 00 04 c3 call 20069f0 <rtems_semaphore_release>
20056e8: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
20056ec: 81 c7 e0 08 ret
20056f0: 81 e8 00 00 restore
rtems_semaphore_delete (tty->isem);
rtems_semaphore_delete (tty->osem);
rtems_semaphore_delete (tty->rawOutBuf.Semaphore);
if ((tty->device.pollRead == NULL) ||
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN))
rtems_semaphore_delete (tty->rawInBuf.Semaphore);
20056f4: 40 00 04 4b call 2006820 <rtems_semaphore_delete> <== NOT EXECUTED
20056f8: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
20056fc: 30 bf ff f1 b,a 20056c0 <rtems_termios_close+0x100> <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
}
if (tty->device.lastClose)
(*tty->device.lastClose)(tty->major, tty->minor, arg);
if (tty->forw == NULL) {
rtems_termios_ttyTail = tty->back;
2005700: 05 00 80 7c sethi %hi(0x201f000), %g2
if ( rtems_termios_ttyTail != NULL ) {
2005704: 80 a0 60 00 cmp %g1, 0
2005708: 02 80 00 27 be 20057a4 <rtems_termios_close+0x1e4> <== ALWAYS TAKEN
200570c: c2 20 a2 14 st %g1, [ %g2 + 0x214 ]
}
}
else {
tty->forw->back = tty->back;
}
if (tty->back == NULL) {
2005710: c4 04 20 04 ld [ %l0 + 4 ], %g2 <== NOT EXECUTED
if (tty->device.lastClose)
(*tty->device.lastClose)(tty->major, tty->minor, arg);
if (tty->forw == NULL) {
rtems_termios_ttyTail = tty->back;
if ( rtems_termios_ttyTail != NULL ) {
rtems_termios_ttyTail->forw = NULL;
2005714: c0 20 40 00 clr [ %g1 ] <== NOT EXECUTED
}
}
else {
tty->forw->back = tty->back;
}
if (tty->back == NULL) {
2005718: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
200571c: 12 bf ff da bne 2005684 <rtems_termios_close+0xc4> <== NOT EXECUTED
2005720: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
rtems_termios_ttyHead = tty->forw;
2005724: 05 00 80 7c sethi %hi(0x201f000), %g2 <== NOT EXECUTED
if ( rtems_termios_ttyHead != NULL ) {
2005728: 80 a0 60 00 cmp %g1, 0
200572c: 02 bf ff d7 be 2005688 <rtems_termios_close+0xc8> <== NEVER TAKEN
2005730: c2 20 a2 18 st %g1, [ %g2 + 0x218 ]
rtems_termios_ttyHead->back = NULL;
2005734: 10 bf ff d5 b 2005688 <rtems_termios_close+0xc8>
2005738: c0 20 60 04 clr [ %g1 + 4 ]
}
else {
/*
* default: just flush output buffer
*/
sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
200573c: 92 10 20 00 clr %o1
2005740: 40 00 04 65 call 20068d4 <rtems_semaphore_obtain>
2005744: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL) {
2005748: 80 a2 20 00 cmp %o0, 0
200574c: 12 80 00 14 bne 200579c <rtems_termios_close+0x1dc> <== NEVER TAKEN
2005750: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
}
drainOutput (tty);
2005754: 7f ff fd 79 call 2004d38 <drainOutput>
2005758: 90 10 00 10 mov %l0, %o0
}
if (tty->device.outputUsesInterrupts
200575c: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1
2005760: 80 a0 60 02 cmp %g1, 2
2005764: 32 bf ff b7 bne,a 2005640 <rtems_termios_close+0x80> <== ALWAYS TAKEN
2005768: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
== TERMIOS_TASK_DRIVEN) {
/*
* send "terminate" to I/O tasks
*/
sc = rtems_event_send(
200576c: d0 04 20 c4 ld [ %l0 + 0xc4 ], %o0 <== NOT EXECUTED
2005770: 40 00 03 1c call 20063e0 <rtems_event_send> <== NOT EXECUTED
2005774: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
tty->rxTaskId,
TERMIOS_RX_TERMINATE_EVENT);
if (sc != RTEMS_SUCCESSFUL)
2005778: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200577c: 12 80 00 08 bne 200579c <rtems_termios_close+0x1dc> <== NOT EXECUTED
2005780: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
sc = rtems_event_send(
2005784: d0 04 20 c8 ld [ %l0 + 0xc8 ], %o0 <== NOT EXECUTED
2005788: 40 00 03 16 call 20063e0 <rtems_event_send> <== NOT EXECUTED
200578c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
tty->txTaskId,
TERMIOS_TX_TERMINATE_EVENT);
if (sc != RTEMS_SUCCESSFUL)
2005790: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2005794: 22 bf ff ab be,a 2005640 <rtems_termios_close+0x80> <== NOT EXECUTED
2005798: c2 04 20 9c ld [ %l0 + 0x9c ], %g1 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
200579c: 40 00 05 ef call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
20057a0: 01 00 00 00 nop <== NOT EXECUTED
}
else {
tty->forw->back = tty->back;
}
if (tty->back == NULL) {
rtems_termios_ttyHead = tty->forw;
20057a4: 03 00 80 7c sethi %hi(0x201f000), %g1
20057a8: 10 bf ff b8 b 2005688 <rtems_termios_close+0xc8>
20057ac: c0 20 62 18 clr [ %g1 + 0x218 ] ! 201f218 <rtems_termios_ttyHead>
020040a8 <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)
{
20040a8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_status_code sc;
/*
* sum up character count already sent
*/
tty->t_dqlen += len;
20040ac: c4 06 20 90 ld [ %i0 + 0x90 ], %g2 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
20040b0: c2 06 20 b4 ld [ %i0 + 0xb4 ], %g1 <== NOT EXECUTED
rtems_status_code sc;
/*
* sum up character count already sent
*/
tty->t_dqlen += len;
20040b4: 84 00 80 19 add %g2, %i1, %g2 <== NOT EXECUTED
20040b8: c4 26 20 90 st %g2, [ %i0 + 0x90 ] <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
20040bc: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
20040c0: 02 80 00 10 be 2004100 <rtems_termios_dequeue_characters+0x58><== NOT EXECUTED
20040c4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
TERMIOS_TX_START_EVENT);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
return 0; /* nothing to output in IRQ... */
}
else if (tty->t_line == PPPDISC ) {
20040c8: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 <== NOT EXECUTED
20040cc: 80 a0 60 05 cmp %g1, 5 <== NOT EXECUTED
20040d0: 02 80 00 04 be 20040e0 <rtems_termios_dequeue_characters+0x38><== NOT EXECUTED
20040d4: 03 00 80 7b sethi %hi(0x201ec00), %g1 <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
}
return 0; /* nothing to output in IRQ... */
}
else {
return rtems_termios_refill_transmitter(tty);
20040d8: 7f ff ff 74 call 2003ea8 <rtems_termios_refill_transmitter><== NOT EXECUTED
20040dc: 81 e8 00 00 restore <== NOT EXECUTED
}
else if (tty->t_line == PPPDISC ) {
/*
* call any line discipline start function
*/
if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
20040e0: c2 00 63 f4 ld [ %g1 + 0x3f4 ], %g1 <== NOT EXECUTED
20040e4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20040e8: 02 80 00 04 be 20040f8 <rtems_termios_dequeue_characters+0x50><== NOT EXECUTED
20040ec: 01 00 00 00 nop <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
20040f0: 9f c0 40 00 call %g1 <== NOT EXECUTED
20040f4: 01 00 00 00 nop <== NOT EXECUTED
return 0; /* nothing to output in IRQ... */
}
else {
return rtems_termios_refill_transmitter(tty);
}
}
20040f8: 81 c7 e0 08 ret <== NOT EXECUTED
20040fc: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
/*
* send wake up to transmitter task
*/
sc = rtems_event_send(tty->txTaskId,
2004100: d0 06 20 c8 ld [ %i0 + 0xc8 ], %o0 <== NOT EXECUTED
2004104: 40 00 08 b7 call 20063e0 <rtems_event_send> <== NOT EXECUTED
2004108: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
TERMIOS_TX_START_EVENT);
if (sc != RTEMS_SUCCESSFUL)
200410c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2004110: 02 bf ff fa be 20040f8 <rtems_termios_dequeue_characters+0x50><== NOT EXECUTED
2004114: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
2004118: 40 00 0b 90 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
02004124 <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)
{
2004124: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
char c;
int dropped = 0;
bool flow_rcv = false; /* true, if flow control char received */
rtems_interrupt_level level;
if (rtems_termios_linesw[tty->t_line].l_rint != NULL) {
2004128: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 <== NOT EXECUTED
200412c: 23 00 80 7b sethi %hi(0x201ec00), %l1 <== NOT EXECUTED
2004130: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED
2004134: a2 14 63 40 or %l1, 0x340, %l1 <== NOT EXECUTED
2004138: 82 00 60 10 add %g1, 0x10, %g1 <== NOT EXECUTED
200413c: c2 04 40 01 ld [ %l1 + %g1 ], %g1 <== NOT EXECUTED
2004140: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004144: 02 80 00 22 be 20041cc <rtems_termios_enqueue_raw_characters+0xa8><== NOT EXECUTED
2004148: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
while (len--) {
200414c: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
2004150: 22 80 00 0f be,a 200418c <rtems_termios_enqueue_raw_characters+0x68><== NOT EXECUTED
2004154: c2 04 20 e4 ld [ %l0 + 0xe4 ], %g1 <== NOT EXECUTED
2004158: 10 80 00 05 b 200416c <rtems_termios_enqueue_raw_characters+0x48><== NOT EXECUTED
200415c: a4 10 20 00 clr %l2 <== NOT EXECUTED
2004160: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED
2004164: 82 00 60 10 add %g1, 0x10, %g1 <== NOT EXECUTED
2004168: c2 04 40 01 ld [ %l1 + %g1 ], %g1 <== NOT EXECUTED
c = *buf++;
rtems_termios_linesw[tty->t_line].l_rint(c,tty);
200416c: d0 4e 40 12 ldsb [ %i1 + %l2 ], %o0 <== NOT EXECUTED
2004170: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004174: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2004178: a4 04 a0 01 inc %l2 <== 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--) {
200417c: 80 a6 80 12 cmp %i2, %l2 <== NOT EXECUTED
2004180: 32 bf ff f8 bne,a 2004160 <rtems_termios_enqueue_raw_characters+0x3c><== NOT EXECUTED
2004184: 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 )) {
2004188: c2 04 20 e4 ld [ %l0 + 0xe4 ], %g1 <== NOT EXECUTED
200418c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004190: 12 80 00 0d bne 20041c4 <rtems_termios_enqueue_raw_characters+0xa0><== NOT EXECUTED
2004194: 01 00 00 00 nop <== NOT EXECUTED
2004198: c2 04 20 dc ld [ %l0 + 0xdc ], %g1 <== NOT EXECUTED
200419c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20041a0: 02 80 00 09 be 20041c4 <rtems_termios_enqueue_raw_characters+0xa0><== NOT EXECUTED
20041a4: 01 00 00 00 nop <== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
20041a8: d2 04 20 e0 ld [ %l0 + 0xe0 ], %o1 <== NOT EXECUTED
20041ac: 9f c0 40 00 call %g1 <== NOT EXECUTED
20041b0: 90 04 20 30 add %l0, 0x30, %o0 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
20041b4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
20041b8: c2 24 20 e4 st %g1, [ %l0 + 0xe4 ] <== NOT EXECUTED
20041bc: 81 c7 e0 08 ret <== NOT EXECUTED
20041c0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
}
}
tty->rawInBufDropped += dropped;
rtems_semaphore_release (tty->rawInBuf.Semaphore);
return dropped;
}
20041c4: 81 c7 e0 08 ret <== NOT EXECUTED
20041c8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
/*
* check to see if rcv wakeup callback was set
*/
if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
20041cc: a2 10 00 1a mov %i2, %l1 <== NOT EXECUTED
if ((tty->flow_ctrl & FL_OSTOP) ||
(tty->rawOutBufState == rob_idle)) {
/* if tx is stopped due to XOFF or out of data */
/* call write function here */
tty->flow_ctrl |= FL_ISNTXOF;
(*tty->device.write)(tty->minor,
20041d0: ae 06 20 4a add %i0, 0x4a, %l7 <== NOT EXECUTED
/*
* check to see if rcv wakeup callback was set
*/
if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
20041d4: ac 06 20 30 add %i0, 0x30, %l6 <== NOT EXECUTED
20041d8: a8 10 20 00 clr %l4 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
}
return 0;
}
while (len--) {
20041dc: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
20041e0: 02 80 00 1c be 2004250 <rtems_termios_enqueue_raw_characters+0x12c><== NOT EXECUTED
20041e4: b0 10 20 00 clr %i0 <== NOT EXECUTED
c = *buf++;
/* FIXME: implement IXANY: any character restarts output */
/* if incoming XON/XOFF controls outgoing stream: */
if (tty->flow_ctrl & FL_MDXON) {
20041e8: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
20041ec: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED
20041f0: 02 80 00 0b be 200421c <rtems_termios_enqueue_raw_characters+0xf8><== NOT EXECUTED
20041f4: e4 0e 40 00 ldub [ %i1 ], %l2 <== NOT EXECUTED
/* if received char is V_STOP and V_START (both are equal value) */
if (c == tty->termios.c_cc[VSTOP]) {
20041f8: c4 0c 20 4a ldub [ %l0 + 0x4a ], %g2 <== NOT EXECUTED
20041fc: 83 2c a0 18 sll %l2, 0x18, %g1 <== NOT EXECUTED
2004200: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED
2004204: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004208: 02 80 00 63 be 2004394 <rtems_termios_enqueue_raw_characters+0x270><== NOT EXECUTED
200420c: c4 0c 20 49 ldub [ %l0 + 0x49 ], %g2 <== NOT EXECUTED
/* stop output */
tty->flow_ctrl |= FL_ORCVXOF;
}
flow_rcv = true;
}
else if (c == tty->termios.c_cc[VSTART]) {
2004210: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004214: 02 80 00 68 be 20043b4 <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED
2004218: 01 00 00 00 nop <== NOT EXECUTED
/* restart output */
tty->flow_ctrl &= ~FL_ORCVXOF;
flow_rcv = true;
}
}
if (flow_rcv) {
200421c: 80 8d 20 ff btst 0xff, %l4 <== NOT EXECUTED
2004220: 02 80 00 22 be 20042a8 <rtems_termios_enqueue_raw_characters+0x184><== NOT EXECUTED
2004224: 01 00 00 00 nop <== NOT EXECUTED
/* restart output according to FL_ORCVXOF flag */
if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) {
2004228: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
200422c: 82 08 60 30 and %g1, 0x30, %g1 <== NOT EXECUTED
2004230: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED
2004234: 02 80 00 0e be 200426c <rtems_termios_enqueue_raw_characters+0x148><== NOT EXECUTED
2004238: 01 00 00 00 nop <== NOT EXECUTED
}
return 0;
}
while (len--) {
c = *buf++;
200423c: b2 06 60 01 inc %i1 <== NOT EXECUTED
2004240: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
}
return 0;
}
while (len--) {
2004244: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2004248: 12 bf ff e8 bne 20041e8 <rtems_termios_enqueue_raw_characters+0xc4><== NOT EXECUTED
200424c: 01 00 00 00 nop <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
}
}
}
}
tty->rawInBufDropped += dropped;
2004250: c2 04 20 78 ld [ %l0 + 0x78 ], %g1 <== NOT EXECUTED
rtems_semaphore_release (tty->rawInBuf.Semaphore);
2004254: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
}
}
}
}
tty->rawInBufDropped += dropped;
2004258: 82 00 40 18 add %g1, %i0, %g1 <== NOT EXECUTED
rtems_semaphore_release (tty->rawInBuf.Semaphore);
200425c: 40 00 09 e5 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004260: c2 24 20 78 st %g1, [ %l0 + 0x78 ] <== NOT EXECUTED
return dropped;
2004264: 81 c7 e0 08 ret <== NOT EXECUTED
2004268: 81 e8 00 00 restore <== 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);
200426c: 7f ff f7 8e call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2004270: 01 00 00 00 nop <== NOT EXECUTED
2004274: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_OSTOP;
2004278: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */
if (tty->rawOutBufState != rob_idle) {
200427c: 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;
2004280: 84 08 bf df and %g2, -33, %g2 <== NOT EXECUTED
2004284: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */
if (tty->rawOutBufState != rob_idle) {
2004288: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200428c: 12 80 00 57 bne 20043e8 <rtems_termios_enqueue_raw_characters+0x2c4><== NOT EXECUTED
2004290: 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);
}
/* reenable interrupts */
rtems_interrupt_enable(level);
2004294: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
2004298: 7f ff f7 87 call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
200429c: b2 06 60 01 inc %i1 <== NOT EXECUTED
}
return 0;
}
while (len--) {
c = *buf++;
20042a0: 10 bf ff e9 b 2004244 <rtems_termios_enqueue_raw_characters+0x120><== NOT EXECUTED
20042a4: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
/* reenable interrupts */
rtems_interrupt_enable(level);
}
}
else {
newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;
20042a8: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED
20042ac: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED
20042b0: 40 00 5b d2 call 201b1f8 <.urem> <== NOT EXECUTED
20042b4: 90 02 20 01 inc %o0 <== NOT EXECUTED
/* if chars_in_buffer > highwater */
rtems_interrupt_disable(level);
20042b8: 7f ff f7 7b call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
20042bc: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
20042c0: aa 10 00 08 mov %o0, %l5 <== NOT EXECUTED
if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)
20042c4: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED
20042c8: d0 04 20 64 ld [ %l0 + 0x64 ], %o0 <== NOT EXECUTED
20042cc: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED
20042d0: 90 22 00 01 sub %o0, %g1, %o0 <== NOT EXECUTED
20042d4: 40 00 5b c9 call 201b1f8 <.urem> <== NOT EXECUTED
20042d8: 90 02 00 13 add %o0, %l3, %o0 <== NOT EXECUTED
% tty->rawInBuf.Size)
> tty->highwater) &&
20042dc: c2 04 20 c0 ld [ %l0 + 0xc0 ], %g1 <== NOT EXECUTED
20042e0: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
20042e4: 08 80 00 13 bleu 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
20042e8: 01 00 00 00 nop <== NOT EXECUTED
!(tty->flow_ctrl & FL_IREQXOF)) {
20042ec: 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)
20042f0: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
20042f4: 12 80 00 0f bne 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
20042f8: 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;
20042fc: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2004300: 82 10 60 01 or %g1, 1, %g1 <== NOT EXECUTED
2004304: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))
2004308: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
200430c: 82 08 64 02 and %g1, 0x402, %g1 <== NOT EXECUTED
2004310: 80 a0 64 00 cmp %g1, 0x400 <== NOT EXECUTED
2004314: 02 80 00 3d be 2004408 <rtems_termios_enqueue_raw_characters+0x2e4><== NOT EXECUTED
2004318: 01 00 00 00 nop <== NOT EXECUTED
(*tty->device.write)(tty->minor,
(void *)&(tty->termios.c_cc[VSTOP]),
1);
}
}
else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF))
200431c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2004320: 82 08 61 04 and %g1, 0x104, %g1 <== NOT EXECUTED
2004324: 80 a0 61 00 cmp %g1, 0x100 <== NOT EXECUTED
2004328: 02 80 00 49 be 200444c <rtems_termios_enqueue_raw_characters+0x328><== NOT EXECUTED
200432c: 01 00 00 00 nop <== NOT EXECUTED
tty->device.stopRemoteTx(tty->minor);
}
}
}
/* reenable interrupts */
rtems_interrupt_enable(level);
2004330: 7f ff f7 61 call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004334: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED
if (newTail == tty->rawInBuf.Head) {
2004338: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED
200433c: 80 a0 40 13 cmp %g1, %l3 <== NOT EXECUTED
2004340: 22 80 00 22 be,a 20043c8 <rtems_termios_enqueue_raw_characters+0x2a4><== NOT EXECUTED
2004344: b0 06 20 01 inc %i0 <== NOT EXECUTED
dropped++;
}
else {
tty->rawInBuf.theBuf[newTail] = c;
2004348: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED
200434c: e4 28 40 13 stb %l2, [ %g1 + %l3 ] <== 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 )) {
2004350: 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;
2004354: e6 24 20 60 st %l3, [ %l0 + 0x60 ] <== NOT EXECUTED
/*
* check to see if rcv wakeup callback was set
*/
if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
2004358: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200435c: 32 bf ff b9 bne,a 2004240 <rtems_termios_enqueue_raw_characters+0x11c><== NOT EXECUTED
2004360: b2 06 60 01 inc %i1 <== NOT EXECUTED
2004364: c2 04 20 dc ld [ %l0 + 0xdc ], %g1 <== NOT EXECUTED
2004368: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200436c: 22 bf ff b5 be,a 2004240 <rtems_termios_enqueue_raw_characters+0x11c><== NOT EXECUTED
2004370: b2 06 60 01 inc %i1 <== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
2004374: d2 04 20 e0 ld [ %l0 + 0xe0 ], %o1 <== NOT EXECUTED
2004378: 9f c0 40 00 call %g1 <== NOT EXECUTED
200437c: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
2004380: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
}
return 0;
}
while (len--) {
c = *buf++;
2004384: b2 06 60 01 inc %i1 <== NOT EXECUTED
/*
* check to see if rcv wakeup callback was set
*/
if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
tty->tty_rcvwakeup = 1;
2004388: c2 24 20 e4 st %g1, [ %l0 + 0xe4 ] <== NOT EXECUTED
}
return 0;
}
while (len--) {
c = *buf++;
200438c: 10 bf ff ae b 2004244 <rtems_termios_enqueue_raw_characters+0x120><== NOT EXECUTED
2004390: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
/* FIXME: implement IXANY: any character restarts output */
/* if incoming XON/XOFF controls outgoing stream: */
if (tty->flow_ctrl & FL_MDXON) {
/* if received char is V_STOP and V_START (both are equal value) */
if (c == tty->termios.c_cc[VSTOP]) {
if (c == tty->termios.c_cc[VSTART]) {
2004394: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004398: 02 80 00 0f be 20043d4 <rtems_termios_enqueue_raw_characters+0x2b0><== NOT EXECUTED
200439c: 01 00 00 00 nop <== NOT EXECUTED
tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
}
else {
/* VSTOP received (other code than VSTART) */
/* stop output */
tty->flow_ctrl |= FL_ORCVXOF;
20043a0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
}
}
}
tty->rawInBufDropped += dropped;
rtems_semaphore_release (tty->rawInBuf.Semaphore);
return dropped;
20043a4: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
}
else {
/* VSTOP received (other code than VSTART) */
/* stop output */
tty->flow_ctrl |= FL_ORCVXOF;
20043a8: 82 10 60 10 or %g1, 0x10, %g1 <== NOT EXECUTED
20043ac: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
20043b0: 30 bf ff 9e b,a 2004228 <rtems_termios_enqueue_raw_characters+0x104><== NOT EXECUTED
flow_rcv = true;
}
else if (c == tty->termios.c_cc[VSTART]) {
/* VSTART received */
/* restart output */
tty->flow_ctrl &= ~FL_ORCVXOF;
20043b4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
}
}
}
tty->rawInBufDropped += dropped;
rtems_semaphore_release (tty->rawInBuf.Semaphore);
return dropped;
20043b8: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
flow_rcv = true;
}
else if (c == tty->termios.c_cc[VSTART]) {
/* VSTART received */
/* restart output */
tty->flow_ctrl &= ~FL_ORCVXOF;
20043bc: 82 08 7f ef and %g1, -17, %g1 <== NOT EXECUTED
20043c0: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
20043c4: 30 bf ff 99 b,a 2004228 <rtems_termios_enqueue_raw_characters+0x104><== NOT EXECUTED
}
return 0;
}
while (len--) {
c = *buf++;
20043c8: b2 06 60 01 inc %i1 <== NOT EXECUTED
20043cc: 10 bf ff 9e b 2004244 <rtems_termios_enqueue_raw_characters+0x120><== NOT EXECUTED
20043d0: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED
/* if received char is V_STOP and V_START (both are equal value) */
if (c == tty->termios.c_cc[VSTOP]) {
if (c == tty->termios.c_cc[VSTART]) {
/* received VSTOP and VSTART==VSTOP? */
/* then toggle "stop output" status */
tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
20043d4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
}
}
}
tty->rawInBufDropped += dropped;
rtems_semaphore_release (tty->rawInBuf.Semaphore);
return dropped;
20043d8: a8 10 20 01 mov 1, %l4 <== NOT EXECUTED
/* if received char is V_STOP and V_START (both are equal value) */
if (c == tty->termios.c_cc[VSTOP]) {
if (c == tty->termios.c_cc[VSTART]) {
/* received VSTOP and VSTART==VSTOP? */
/* then toggle "stop output" status */
tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
20043dc: 82 18 60 10 xor %g1, 0x10, %g1 <== NOT EXECUTED
20043e0: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
20043e4: 30 bf ff 91 b,a 2004228 <rtems_termios_enqueue_raw_characters+0x104><== NOT EXECUTED
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,
&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1);
20043e8: 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,
20043ec: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 <== NOT EXECUTED
20043f0: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
20043f4: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
20043f8: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
20043fc: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004400: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2004404: 30 bf ff a4 b,a 2004294 <rtems_termios_enqueue_raw_characters+0x170><== NOT EXECUTED
!(tty->flow_ctrl & FL_IREQXOF)) {
/* incoming data stream should be stopped */
tty->flow_ctrl |= FL_IREQXOF;
if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))
== (FL_MDXOF ) ){
if ((tty->flow_ctrl & FL_OSTOP) ||
2004408: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
200440c: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
2004410: 12 80 00 06 bne 2004428 <rtems_termios_enqueue_raw_characters+0x304><== NOT EXECUTED
2004414: 01 00 00 00 nop <== NOT EXECUTED
(tty->rawOutBufState == rob_idle)) {
2004418: c2 04 20 94 ld [ %l0 + 0x94 ], %g1 <== NOT EXECUTED
200441c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004420: 12 bf ff c4 bne 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
2004424: 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;
2004428: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
200442c: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
2004430: 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;
2004434: 84 10 a0 02 or %g2, 2, %g2 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2004438: 92 10 00 17 mov %l7, %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;
200443c: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2004440: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004444: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2004448: 30 bf ff ba b,a 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
1);
}
}
else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF))
== (FL_MDRTS ) ) {
tty->flow_ctrl |= FL_IRTSOFF;
200444c: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* deactivate RTS line */
if (tty->device.stopRemoteTx != NULL) {
2004450: 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;
2004454: 84 10 a0 04 or %g2, 4, %g2 <== NOT EXECUTED
2004458: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* deactivate RTS line */
if (tty->device.stopRemoteTx != NULL) {
200445c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004460: 02 bf ff b4 be 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
2004464: 01 00 00 00 nop <== NOT EXECUTED
tty->device.stopRemoteTx(tty->minor);
2004468: 9f c0 40 00 call %g1 <== NOT EXECUTED
200446c: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
2004470: 30 bf ff b0 b,a 2004330 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
02003e20 <rtems_termios_initialize>:
struct rtems_termios_tty *rtems_termios_ttyTail;
rtems_id rtems_termios_ttyMutex;
void
rtems_termios_initialize (void)
{
2003e20: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc;
/*
* Create the mutex semaphore for the tty list
*/
if (!rtems_termios_ttyMutex) {
2003e24: 19 00 80 7c sethi %hi(0x201f000), %o4
2003e28: c2 03 22 10 ld [ %o4 + 0x210 ], %g1 ! 201f210 <rtems_termios_ttyMutex>
2003e2c: 80 a0 60 00 cmp %g1, 0
2003e30: 02 80 00 04 be 2003e40 <rtems_termios_initialize+0x20>
2003e34: 98 13 22 10 or %o4, 0x210, %o4
2003e38: 81 c7 e0 08 ret
2003e3c: 81 e8 00 00 restore
sc = rtems_semaphore_create (
2003e40: 11 15 14 9b sethi %hi(0x54526c00), %o0
2003e44: 92 10 20 01 mov 1, %o1
2003e48: 90 12 21 69 or %o0, 0x169, %o0
2003e4c: 94 10 20 54 mov 0x54, %o2
2003e50: 40 00 0a 00 call 2006650 <rtems_semaphore_create>
2003e54: 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)
2003e58: 80 a2 20 00 cmp %o0, 0
2003e5c: 02 bf ff f7 be 2003e38 <rtems_termios_initialize+0x18> <== ALWAYS TAKEN
2003e60: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
2003e64: 40 00 0c 3d call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
020051b4 <rtems_termios_ioctl>:
}
}
rtems_status_code
rtems_termios_ioctl (void *arg)
{
20051b4: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_ioctl_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
20051b8: c2 06 00 00 ld [ %i0 ], %g1
struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer;
rtems_status_code sc;
args->ioctl_return = 0;
20051bc: 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;
20051c0: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer;
20051c4: 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);
20051c8: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
20051cc: 92 10 20 00 clr %o1
20051d0: 40 00 05 c1 call 20068d4 <rtems_semaphore_obtain>
20051d4: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL) {
20051d8: a2 92 20 00 orcc %o0, 0, %l1
20051dc: 32 80 00 16 bne,a 2005234 <rtems_termios_ioctl+0x80> <== NEVER TAKEN
20051e0: e2 26 20 0c st %l1, [ %i0 + 0xc ] <== NOT EXECUTED
args->ioctl_return = sc;
return sc;
}
switch (args->command) {
20051e4: c2 06 20 04 ld [ %i0 + 4 ], %g1
20051e8: 80 a0 60 04 cmp %g1, 4
20051ec: 22 80 00 0c be,a 200521c <rtems_termios_ioctl+0x68> <== NEVER TAKEN
20051f0: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
20051f4: 18 80 00 12 bgu 200523c <rtems_termios_ioctl+0x88> <== NEVER TAKEN
20051f8: 05 10 01 19 sethi %hi(0x40046400), %g2
20051fc: 80 a0 60 02 cmp %g1, 2
2005200: 22 80 00 26 be,a 2005298 <rtems_termios_ioctl+0xe4>
2005204: d2 06 20 08 ld [ %i0 + 8 ], %o1
2005208: 08 80 00 81 bleu 200540c <rtems_termios_ioctl+0x258>
200520c: 80 a0 60 01 cmp %g1, 1
if (tty->device.setAttributes)
(*tty->device.setAttributes)(tty->minor, &tty->termios);
break;
case RTEMS_IO_TCDRAIN:
drainOutput (tty);
2005210: 7f ff fe ca call 2004d38 <drainOutput>
2005214: 90 10 00 10 mov %l0, %o0
break;
2005218: 30 80 00 04 b,a 2005228 <rtems_termios_ioctl+0x74>
case RTEMS_IO_SNDWAKEUP:
tty->tty_snd = *wakeup;
break;
case RTEMS_IO_RCVWAKEUP:
tty->tty_rcv = *wakeup;
200521c: c2 24 20 dc st %g1, [ %l0 + 0xdc ] <== NOT EXECUTED
2005220: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
2005224: c2 24 20 e0 st %g1, [ %l0 + 0xe0 ] <== NOT EXECUTED
/* Half guess that this is the right operation */
*(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
}
break;
}
rtems_semaphore_release (tty->osem);
2005228: 40 00 05 f2 call 20069f0 <rtems_semaphore_release>
200522c: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
args->ioctl_return = sc;
2005230: e2 26 20 0c st %l1, [ %i0 + 0xc ]
return sc;
}
2005234: 81 c7 e0 08 ret
2005238: 91 e8 00 11 restore %g0, %l1, %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) {
200523c: 84 10 a2 7f or %g2, 0x27f, %g2 <== NOT EXECUTED
2005240: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2005244: 02 80 00 66 be 20053dc <rtems_termios_ioctl+0x228> <== NOT EXECUTED
2005248: 01 00 00 00 nop <== NOT EXECUTED
200524c: 18 80 00 77 bgu 2005428 <rtems_termios_ioctl+0x274> <== NOT EXECUTED
2005250: 05 10 01 1d sethi %hi(0x40047400), %g2 <== NOT EXECUTED
2005254: 80 a0 60 05 cmp %g1, 5 <== NOT EXECUTED
2005258: 22 80 00 98 be,a 20054b8 <rtems_termios_ioctl+0x304> <== NOT EXECUTED
200525c: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
default:
if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {
2005260: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
2005264: 03 00 80 7b sethi %hi(0x201ec00), %g1 <== NOT EXECUTED
2005268: 85 28 a0 05 sll %g2, 5, %g2 <== NOT EXECUTED
200526c: 82 10 63 40 or %g1, 0x340, %g1 <== NOT EXECUTED
2005270: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
2005274: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED
2005278: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200527c: 02 bf ff eb be 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
2005280: a2 10 20 0a mov 0xa, %l1 <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_ioctl(tty,args);
2005284: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2005288: 9f c0 40 00 call %g1 <== NOT EXECUTED
200528c: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
2005290: 10 bf ff e6 b 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
2005294: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
case RTEMS_IO_GET_ATTRIBUTES:
*(struct termios *)args->buffer = tty->termios;
break;
case RTEMS_IO_SET_ATTRIBUTES:
tty->termios = *(struct termios *)args->buffer;
2005298: a4 04 20 30 add %l0, 0x30, %l2
200529c: 94 10 20 24 mov 0x24, %o2
20052a0: 40 00 34 13 call 20122ec <memcpy>
20052a4: 90 10 00 12 mov %l2, %o0
/*
* check for flow control options to be switched off
*/
/* check for outgoing XON/XOFF flow control switched off */
if (( tty->flow_ctrl & FL_MDXON) &&
20052a8: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1
20052ac: 80 88 62 00 btst 0x200, %g1
20052b0: 02 80 00 19 be 2005314 <rtems_termios_ioctl+0x160>
20052b4: 01 00 00 00 nop
20052b8: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
20052bc: 80 88 64 00 btst 0x400, %g1
20052c0: 12 80 00 15 bne 2005314 <rtems_termios_ioctl+0x160> <== ALWAYS TAKEN
20052c4: 01 00 00 00 nop
!(tty->termios.c_iflag & IXON)) {
/* clear related flags in flow_ctrl */
tty->flow_ctrl &= ~(FL_MDXON | FL_ORCVXOF);
20052c8: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
20052cc: 82 08 7d ef and %g1, -529, %g1 <== NOT EXECUTED
20052d0: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* has output been stopped due to received XOFF? */
if (tty->flow_ctrl & FL_OSTOP) {
20052d4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
20052d8: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
20052dc: 02 80 00 0e be 2005314 <rtems_termios_ioctl+0x160> <== NOT EXECUTED
20052e0: 01 00 00 00 nop <== NOT EXECUTED
/* disable interrupts */
rtems_interrupt_disable(level);
20052e4: 7f ff f3 70 call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
20052e8: 01 00 00 00 nop <== NOT EXECUTED
20052ec: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_OSTOP;
20052f0: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */
if (tty->rawOutBufState != rob_idle) {
20052f4: 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;
20052f8: 84 08 bf df and %g2, -33, %g2 <== NOT EXECUTED
20052fc: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */
if (tty->rawOutBufState != rob_idle) {
2005300: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005304: 12 80 00 a7 bne 20055a0 <rtems_termios_ioctl+0x3ec> <== NOT EXECUTED
2005308: 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);
}
/* reenable interrupts */
rtems_interrupt_enable(level);
200530c: 7f ff f3 6a call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2005310: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
}
}
/* check for incoming XON/XOFF flow control switched off */
if (( tty->flow_ctrl & FL_MDXOF) &&
2005314: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1
2005318: 80 88 64 00 btst 0x400, %g1
200531c: 02 80 00 0c be 200534c <rtems_termios_ioctl+0x198> <== ALWAYS TAKEN
2005320: 03 00 00 04 sethi %hi(0x1000), %g1
2005324: c4 04 20 30 ld [ %l0 + 0x30 ], %g2 <== NOT EXECUTED
2005328: 80 88 80 01 btst %g2, %g1 <== NOT EXECUTED
200532c: 12 80 00 08 bne 200534c <rtems_termios_ioctl+0x198> <== NOT EXECUTED
2005330: 01 00 00 00 nop <== NOT EXECUTED
!(tty->termios.c_iflag & IXOFF)) {
/* clear related flags in flow_ctrl */
tty->flow_ctrl &= ~(FL_MDXOF);
2005334: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2005338: 82 08 7b ff and %g1, -1025, %g1 <== NOT EXECUTED
200533c: 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);
2005340: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2005344: 82 08 7f fd and %g1, -3, %g1 <== NOT EXECUTED
2005348: 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) &&
200534c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1
2005350: 80 88 61 00 btst 0x100, %g1
2005354: 12 80 00 5d bne 20054c8 <rtems_termios_ioctl+0x314> <== NEVER TAKEN
2005358: c4 04 20 38 ld [ %l0 + 0x38 ], %g2
/*
* check for flow control options to be switched on
*/
/* check for incoming RTS/CTS flow control switched on */
if (tty->termios.c_cflag & CRTSCTS) {
200535c: 80 a0 a0 00 cmp %g2, 0
2005360: 06 80 00 84 bl 2005570 <rtems_termios_ioctl+0x3bc> <== NEVER TAKEN
2005364: 01 00 00 00 nop
tty->flow_ctrl |= FL_MDRTS;
}
/* check for incoming XON/XOF flow control switched on */
if (tty->termios.c_iflag & IXOFF) {
2005368: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
200536c: 05 00 00 04 sethi %hi(0x1000), %g2
2005370: 80 88 40 02 btst %g1, %g2
2005374: 02 80 00 06 be 200538c <rtems_termios_ioctl+0x1d8> <== ALWAYS TAKEN
2005378: 80 88 64 00 btst 0x400, %g1
tty->flow_ctrl |= FL_MDXOF;
200537c: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
2005380: 84 10 a4 00 or %g2, 0x400, %g2 <== NOT EXECUTED
2005384: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
}
/* check for outgoing XON/XOF flow control switched on */
if (tty->termios.c_iflag & IXON) {
2005388: 80 88 64 00 btst 0x400, %g1 <== NOT EXECUTED
200538c: 22 80 00 06 be,a 20053a4 <rtems_termios_ioctl+0x1f0> <== NEVER TAKEN
2005390: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->flow_ctrl |= FL_MDXON;
2005394: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1
2005398: 82 10 62 00 or %g1, 0x200, %g1
200539c: 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) {
20053a0: c2 04 20 3c ld [ %l0 + 0x3c ], %g1
20053a4: 80 88 60 02 btst 2, %g1
20053a8: 02 80 00 5e be 2005520 <rtems_termios_ioctl+0x36c>
20053ac: 01 00 00 00 nop
else
tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks;
}
else {
if (tty->termios.c_cc[VMIN]) {
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
20053b0: c0 24 20 6c clr [ %l0 + 0x6c ]
tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;
20053b4: c0 24 20 70 clr [ %l0 + 0x70 ]
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
20053b8: c0 24 20 74 clr [ %l0 + 0x74 ]
else {
tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT;
}
}
}
if (tty->device.setAttributes)
20053bc: c2 04 20 a8 ld [ %l0 + 0xa8 ], %g1
20053c0: 80 a0 60 00 cmp %g1, 0
20053c4: 02 bf ff 99 be 2005228 <rtems_termios_ioctl+0x74>
20053c8: 01 00 00 00 nop
(*tty->device.setAttributes)(tty->minor, &tty->termios);
20053cc: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
20053d0: 9f c0 40 00 call %g1
20053d4: 92 10 00 12 mov %l2, %o1
20053d8: 30 bf ff 94 b,a 2005228 <rtems_termios_ioctl+0x74>
*(int*)(args->buffer)=tty->t_line;
break;
#endif
case FIONREAD:
{
int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head;
20053dc: c4 04 20 60 ld [ %l0 + 0x60 ], %g2 <== NOT EXECUTED
20053e0: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED
if ( rawnc < 0 )
20053e4: 82 a0 80 01 subcc %g2, %g1, %g1 <== NOT EXECUTED
20053e8: 0c 80 00 5f bneg 2005564 <rtems_termios_ioctl+0x3b0> <== NOT EXECUTED
20053ec: 01 00 00 00 nop <== NOT EXECUTED
rawnc += tty->rawInBuf.Size;
/* Half guess that this is the right operation */
*(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
20053f0: c8 04 20 20 ld [ %l0 + 0x20 ], %g4 <== NOT EXECUTED
20053f4: c4 04 20 24 ld [ %l0 + 0x24 ], %g2 <== NOT EXECUTED
20053f8: c6 06 20 08 ld [ %i0 + 8 ], %g3 <== NOT EXECUTED
20053fc: 84 21 00 02 sub %g4, %g2, %g2 <== NOT EXECUTED
2005400: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2005404: 10 bf ff 89 b 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
2005408: c2 20 c0 00 st %g1, [ %g3 ] <== 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) {
200540c: 32 bf ff 96 bne,a 2005264 <rtems_termios_ioctl+0xb0> <== NEVER TAKEN
2005410: 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;
2005414: d0 06 20 08 ld [ %i0 + 8 ], %o0
2005418: 92 04 20 30 add %l0, 0x30, %o1
200541c: 40 00 33 b4 call 20122ec <memcpy>
2005420: 94 10 20 24 mov 0x24, %o2
break;
2005424: 30 bf ff 81 b,a 2005228 <rtems_termios_ioctl+0x74>
sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL) {
args->ioctl_return = sc;
return sc;
}
switch (args->command) {
2005428: 84 10 a0 1a or %g2, 0x1a, %g2 <== NOT EXECUTED
200542c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2005430: 02 80 00 1e be 20054a8 <rtems_termios_ioctl+0x2f4> <== NOT EXECUTED
2005434: 05 20 01 1d sethi %hi(0x80047400), %g2 <== NOT EXECUTED
2005438: 84 10 a0 1b or %g2, 0x1b, %g2 ! 8004741b <RAM_END+0x7dc4741b><== NOT EXECUTED
200543c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2005440: 32 bf ff 89 bne,a 2005264 <rtems_termios_ioctl+0xb0> <== NOT EXECUTED
2005444: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
#if 1 /* FIXME */
case TIOCSETD:
/*
* close old line discipline
*/
if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
2005448: c2 04 20 cc ld [ %l0 + 0xcc ], %g1 <== NOT EXECUTED
200544c: 25 00 80 7b sethi %hi(0x201ec00), %l2 <== NOT EXECUTED
2005450: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED
2005454: a4 14 a3 40 or %l2, 0x340, %l2 <== NOT EXECUTED
2005458: 82 04 80 01 add %l2, %g1, %g1 <== NOT EXECUTED
200545c: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED
2005460: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005464: 22 80 00 06 be,a 200547c <rtems_termios_ioctl+0x2c8> <== NOT EXECUTED
2005468: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_close(tty);
200546c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005470: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2005474: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
}
tty->t_line=*(int*)(args->buffer);
2005478: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
tty->t_sc = NULL; /* ensure that no more valid data */
200547c: c0 24 20 d0 clr [ %l0 + 0xd0 ] <== NOT EXECUTED
* close old line discipline
*/
if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
sc = rtems_termios_linesw[tty->t_line].l_close(tty);
}
tty->t_line=*(int*)(args->buffer);
2005480: 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) {
2005484: 83 28 a0 05 sll %g2, 5, %g1 <== NOT EXECUTED
2005488: c2 04 80 01 ld [ %l2 + %g1 ], %g1 <== NOT EXECUTED
200548c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005490: 02 bf ff 66 be 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
2005494: c4 24 20 cc st %g2, [ %l0 + 0xcc ] <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_open(tty);
2005498: 9f c0 40 00 call %g1 <== NOT EXECUTED
200549c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
20054a0: 10 bf ff 62 b 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
20054a4: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
}
break;
case TIOCGETD:
*(int*)(args->buffer)=tty->t_line;
20054a8: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED
20054ac: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
break;
20054b0: 10 bf ff 5e b 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
20054b4: c4 20 40 00 st %g2, [ %g1 ] <== NOT EXECUTED
case RTEMS_IO_TCDRAIN:
drainOutput (tty);
break;
case RTEMS_IO_SNDWAKEUP:
tty->tty_snd = *wakeup;
20054b8: c2 24 20 d4 st %g1, [ %l0 + 0xd4 ] <== NOT EXECUTED
20054bc: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
break;
20054c0: 10 bf ff 5a b 2005228 <rtems_termios_ioctl+0x74> <== NOT EXECUTED
20054c4: c2 24 20 d8 st %g1, [ %l0 + 0xd8 ] <== NOT EXECUTED
/* FIXME: what happens, if we had sent XOFF but not yet XON? */
tty->flow_ctrl &= ~(FL_ISNTXOF);
}
/* check for incoming RTS/CTS flow control switched off */
if (( tty->flow_ctrl & FL_MDRTS) &&
20054c8: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
20054cc: 06 80 00 29 bl 2005570 <rtems_termios_ioctl+0x3bc> <== NOT EXECUTED
20054d0: 01 00 00 00 nop <== NOT EXECUTED
!(tty->termios.c_cflag & CRTSCTS)) {
/* clear related flags in flow_ctrl */
tty->flow_ctrl &= ~(FL_MDRTS);
20054d4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
20054d8: 82 08 7e ff and %g1, -257, %g1 <== NOT EXECUTED
20054dc: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* restart remote Tx, if it was stopped */
if ((tty->flow_ctrl & FL_IRTSOFF) &&
20054e0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
20054e4: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED
20054e8: 02 80 00 09 be 200550c <rtems_termios_ioctl+0x358> <== NOT EXECUTED
20054ec: 01 00 00 00 nop <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) {
20054f0: 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) &&
20054f4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20054f8: 02 80 00 05 be 200550c <rtems_termios_ioctl+0x358> <== NOT EXECUTED
20054fc: 01 00 00 00 nop <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) {
tty->device.startRemoteTx(tty->minor);
2005500: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005504: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
2005508: c4 04 20 38 ld [ %l0 + 0x38 ], %g2 <== NOT EXECUTED
}
tty->flow_ctrl &= ~(FL_IRTSOFF);
200550c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2005510: 82 08 7f fb and %g1, -5, %g1 <== NOT EXECUTED
2005514: 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) {
2005518: 10 bf ff 92 b 2005360 <rtems_termios_ioctl+0x1ac> <== NOT EXECUTED
200551c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED
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;
2005520: 40 00 03 24 call 20061b0 <rtems_clock_get_ticks_per_second>
2005524: e6 0c 20 46 ldub [ %l0 + 0x46 ], %l3
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
}
else {
tty->vtimeTicks = tty->termios.c_cc[VTIME] *
2005528: 40 00 56 4e call 201ae60 <.umul>
200552c: 92 10 00 13 mov %l3, %o1
2005530: 40 00 56 86 call 201af48 <.udiv>
2005534: 92 10 20 0a mov 0xa, %o1
rtems_clock_get_ticks_per_second() / 10;
if (tty->termios.c_cc[VTIME]) {
2005538: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1
200553c: 80 a0 60 00 cmp %g1, 0
2005540: 02 80 00 11 be 2005584 <rtems_termios_ioctl+0x3d0> <== ALWAYS TAKEN
2005544: d0 24 20 54 st %o0, [ %l0 + 0x54 ]
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
tty->rawInBufSemaphoreTimeout = tty->vtimeTicks;
if (tty->termios.c_cc[VMIN])
2005548: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED
}
else {
tty->vtimeTicks = tty->termios.c_cc[VTIME] *
rtems_clock_get_ticks_per_second() / 10;
if (tty->termios.c_cc[VTIME]) {
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
200554c: c0 24 20 6c clr [ %l0 + 0x6c ] <== NOT EXECUTED
tty->rawInBufSemaphoreTimeout = tty->vtimeTicks;
if (tty->termios.c_cc[VMIN])
2005550: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005554: 12 bf ff 99 bne 20053b8 <rtems_termios_ioctl+0x204> <== NOT EXECUTED
2005558: d0 24 20 70 st %o0, [ %l0 + 0x70 ] <== NOT EXECUTED
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
else
tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks;
200555c: 10 bf ff 98 b 20053bc <rtems_termios_ioctl+0x208> <== NOT EXECUTED
2005560: d0 24 20 74 st %o0, [ %l0 + 0x74 ] <== NOT EXECUTED
#endif
case FIONREAD:
{
int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head;
if ( rawnc < 0 )
rawnc += tty->rawInBuf.Size;
2005564: c4 04 20 64 ld [ %l0 + 0x64 ], %g2 <== NOT EXECUTED
2005568: 10 bf ff a2 b 20053f0 <rtems_termios_ioctl+0x23c> <== NOT EXECUTED
200556c: 82 00 40 02 add %g1, %g2, %g1 <== 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) {
tty->flow_ctrl |= FL_MDRTS;
2005570: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2005574: 82 10 61 00 or %g1, 0x100, %g1 <== NOT EXECUTED
2005578: 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) {
200557c: 10 bf ff 7c b 200536c <rtems_termios_ioctl+0x1b8> <== NOT EXECUTED
2005580: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 <== NOT EXECUTED
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
else
tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks;
}
else {
if (tty->termios.c_cc[VMIN]) {
2005584: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1
2005588: 80 a0 60 00 cmp %g1, 0
200558c: 32 bf ff 8a bne,a 20053b4 <rtems_termios_ioctl+0x200> <== ALWAYS TAKEN
2005590: c0 24 20 6c clr [ %l0 + 0x6c ]
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
}
else {
tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT;
2005594: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
2005598: 10 bf ff 89 b 20053bc <rtems_termios_ioctl+0x208> <== NOT EXECUTED
200559c: c2 24 20 6c st %g1, [ %l0 + 0x6c ] <== NOT EXECUTED
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,
&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
20055a0: 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,
20055a4: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 <== NOT EXECUTED
20055a8: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
20055ac: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
20055b0: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
20055b4: 9f c0 40 00 call %g1 <== NOT EXECUTED
20055b8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
20055bc: 30 bf ff 54 b,a 200530c <rtems_termios_ioctl+0x158> <== NOT EXECUTED
0200d164 <rtems_termios_number_to_baud>:
#include <rtems/termiostypes.h>
int rtems_termios_number_to_baud(
int32_t baud
)
{
200d164: 82 10 00 08 mov %o0, %g1
int termios_baud;
switch (baud) {
200d168: 80 a2 24 b0 cmp %o0, 0x4b0
200d16c: 02 80 00 32 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d170: 90 10 20 09 mov 9, %o0
200d174: 80 a0 64 b0 cmp %g1, 0x4b0
200d178: 04 80 00 1e ble 200d1f0 <rtems_termios_number_to_baud+0x8c>
200d17c: 80 a0 60 86 cmp %g1, 0x86
200d180: 05 00 00 12 sethi %hi(0x4800), %g2
200d184: 84 10 a3 00 or %g2, 0x300, %g2 ! 4b00 <PROM_START+0x4b00>
200d188: 80 a0 40 02 cmp %g1, %g2
200d18c: 02 80 00 2a be 200d234 <rtems_termios_number_to_baud+0xd0>
200d190: 90 10 20 0e mov 0xe, %o0
200d194: 80 a0 40 02 cmp %g1, %g2
200d198: 04 80 00 29 ble 200d23c <rtems_termios_number_to_baud+0xd8>
200d19c: 80 a0 69 60 cmp %g1, 0x960
200d1a0: 07 00 00 70 sethi %hi(0x1c000), %g3
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;
200d1a4: 05 00 00 04 sethi %hi(0x1000), %g2
int32_t baud
)
{
int termios_baud;
switch (baud) {
200d1a8: 86 10 e2 00 or %g3, 0x200, %g3
200d1ac: 80 a0 40 03 cmp %g1, %g3
200d1b0: 02 80 00 21 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d1b4: 90 10 a0 02 or %g2, 2, %o0
200d1b8: 80 a0 40 03 cmp %g1, %g3
200d1bc: 04 80 00 46 ble 200d2d4 <rtems_termios_number_to_baud+0x170>
200d1c0: 07 00 00 25 sethi %hi(0x9400), %g3
200d1c4: 07 00 00 e1 sethi %hi(0x38400), %g3
200d1c8: 80 a0 40 03 cmp %g1, %g3
200d1cc: 02 80 00 1a be 200d234 <rtems_termios_number_to_baud+0xd0>
200d1d0: 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;
200d1d4: 90 10 a0 04 or %g2, 4, %o0
int32_t baud
)
{
int termios_baud;
switch (baud) {
200d1d8: 05 00 01 c2 sethi %hi(0x70800), %g2
200d1dc: 80 a0 40 02 cmp %g1, %g2
200d1e0: 02 80 00 4b be 200d30c <rtems_termios_number_to_baud+0x1a8><== ALWAYS TAKEN
200d1e4: 01 00 00 00 nop
case 460800: termios_baud = B460800; break;
default: termios_baud = -1; break;
}
return termios_baud;
}
200d1e8: 81 c3 e0 08 retl
200d1ec: 90 10 3f ff mov -1, %o0 ! ffffffff <RAM_END+0xfdbfffff>
int32_t baud
)
{
int termios_baud;
switch (baud) {
200d1f0: 02 80 00 11 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d1f4: 90 10 20 04 mov 4, %o0
200d1f8: 80 a0 60 86 cmp %g1, 0x86
200d1fc: 04 80 00 21 ble 200d280 <rtems_termios_number_to_baud+0x11c>
200d200: 80 a0 60 32 cmp %g1, 0x32
200d204: 80 a0 60 c8 cmp %g1, 0xc8
200d208: 02 80 00 0b be 200d234 <rtems_termios_number_to_baud+0xd0>
200d20c: 90 10 20 06 mov 6, %o0
200d210: 80 a0 60 c8 cmp %g1, 0xc8
200d214: 04 80 00 28 ble 200d2b4 <rtems_termios_number_to_baud+0x150>
200d218: 80 a0 60 96 cmp %g1, 0x96
200d21c: 80 a0 61 2c cmp %g1, 0x12c
200d220: 02 80 00 05 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d224: 90 10 20 07 mov 7, %o0
200d228: 80 a0 62 58 cmp %g1, 0x258
200d22c: 12 bf ff ef bne 200d1e8 <rtems_termios_number_to_baud+0x84><== NEVER TAKEN
200d230: 90 10 20 08 mov 8, %o0
200d234: 81 c3 e0 08 retl
200d238: 01 00 00 00 nop
200d23c: 02 bf ff fe be 200d234 <rtems_termios_number_to_baud+0xd0>
200d240: 90 10 20 0b mov 0xb, %o0 ! b <PROM_START+0xb>
200d244: 80 a0 69 60 cmp %g1, 0x960
200d248: 04 80 00 2f ble 200d304 <rtems_termios_number_to_baud+0x1a0>
200d24c: 80 a0 67 08 cmp %g1, 0x708
200d250: 05 00 00 04 sethi %hi(0x1000), %g2
200d254: 84 10 a2 c0 or %g2, 0x2c0, %g2 ! 12c0 <PROM_START+0x12c0>
200d258: 80 a0 40 02 cmp %g1, %g2
200d25c: 02 bf ff f6 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d260: 90 10 20 0c mov 0xc, %o0
200d264: 05 00 00 09 sethi %hi(0x2400), %g2
200d268: 84 10 a1 80 or %g2, 0x180, %g2 ! 2580 <PROM_START+0x2580>
200d26c: 80 a0 40 02 cmp %g1, %g2
200d270: 12 bf ff de bne 200d1e8 <rtems_termios_number_to_baud+0x84>
200d274: 90 10 20 0d mov 0xd, %o0
200d278: 81 c3 e0 08 retl
200d27c: 01 00 00 00 nop
200d280: 02 bf ff ed be 200d234 <rtems_termios_number_to_baud+0xd0>
200d284: 90 10 20 01 mov 1, %o0 ! 1 <PROM_START+0x1>
200d288: 80 a0 60 32 cmp %g1, 0x32
200d28c: 04 80 00 0e ble 200d2c4 <rtems_termios_number_to_baud+0x160>
200d290: 80 a0 60 00 cmp %g1, 0
200d294: 80 a0 60 4b cmp %g1, 0x4b
200d298: 02 bf ff e7 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d29c: 90 10 20 02 mov 2, %o0
200d2a0: 80 a0 60 6e cmp %g1, 0x6e
200d2a4: 12 bf ff d1 bne 200d1e8 <rtems_termios_number_to_baud+0x84><== NEVER TAKEN
200d2a8: 90 10 20 03 mov 3, %o0
200d2ac: 81 c3 e0 08 retl
200d2b0: 01 00 00 00 nop
200d2b4: 12 bf ff cd bne 200d1e8 <rtems_termios_number_to_baud+0x84><== NEVER TAKEN
200d2b8: 90 10 20 05 mov 5, %o0 ! 5 <PROM_START+0x5>
200d2bc: 81 c3 e0 08 retl
200d2c0: 01 00 00 00 nop
200d2c4: 12 bf ff c9 bne 200d1e8 <rtems_termios_number_to_baud+0x84>
200d2c8: 90 10 20 00 clr %o0 ! 0 <PROM_START>
case 460800: termios_baud = B460800; break;
default: termios_baud = -1; break;
}
return termios_baud;
}
200d2cc: 81 c3 e0 08 retl
200d2d0: 01 00 00 00 nop
int32_t baud
)
{
int termios_baud;
switch (baud) {
200d2d4: 86 10 e2 00 or %g3, 0x200, %g3
200d2d8: 80 a0 40 03 cmp %g1, %g3
200d2dc: 02 bf ff d6 be 200d234 <rtems_termios_number_to_baud+0xd0>
200d2e0: 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;
200d2e4: 90 10 a0 01 or %g2, 1, %o0
int32_t baud
)
{
int termios_baud;
switch (baud) {
200d2e8: 05 00 00 38 sethi %hi(0xe000), %g2
200d2ec: 84 10 a1 00 or %g2, 0x100, %g2 ! e100 <PROM_START+0xe100>
200d2f0: 80 a0 40 02 cmp %g1, %g2
200d2f4: 32 bf ff d0 bne,a 200d234 <rtems_termios_number_to_baud+0xd0><== NEVER TAKEN
200d2f8: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
200d2fc: 81 c3 e0 08 retl
200d300: 01 00 00 00 nop
200d304: 12 bf ff b9 bne 200d1e8 <rtems_termios_number_to_baud+0x84><== NEVER TAKEN
200d308: 90 10 20 0a mov 0xa, %o0 ! a <PROM_START+0xa>
200d30c: 81 c3 e0 08 retl
020057b0 <rtems_termios_open>:
rtems_device_major_number major,
rtems_device_minor_number minor,
void *arg,
const rtems_termios_callbacks *callbacks
)
{
20057b0: 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,
20057b4: 23 00 80 7c sethi %hi(0x201f000), %l1
20057b8: d0 04 62 10 ld [ %l1 + 0x210 ], %o0 ! 201f210 <rtems_termios_ttyMutex>
20057bc: 92 10 20 00 clr %o1
20057c0: 40 00 04 45 call 20068d4 <rtems_semaphore_obtain>
20057c4: 94 10 20 00 clr %o2
RTEMS_WAIT, RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
20057c8: a0 92 20 00 orcc %o0, 0, %l0
20057cc: 32 80 00 29 bne,a 2005870 <rtems_termios_open+0xc0> <== NEVER TAKEN
20057d0: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
return sc;
for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) {
20057d4: 29 00 80 7c sethi %hi(0x201f000), %l4
20057d8: e4 05 22 18 ld [ %l4 + 0x218 ], %l2 ! 201f218 <rtems_termios_ttyHead>
20057dc: 80 a4 a0 00 cmp %l2, 0
20057e0: 32 80 00 08 bne,a 2005800 <rtems_termios_open+0x50>
20057e4: c2 04 a0 0c ld [ %l2 + 0xc ], %g1
static char c = 'a';
/*
* Create a new device
*/
tty = calloc (1, sizeof (struct rtems_termios_tty));
20057e8: 10 80 00 33 b 20058b4 <rtems_termios_open+0x104>
20057ec: 90 10 20 01 mov 1, %o0
*/
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) {
20057f0: 80 a4 a0 00 cmp %l2, 0
20057f4: 02 80 00 30 be 20058b4 <rtems_termios_open+0x104> <== ALWAYS TAKEN
20057f8: 90 10 20 01 mov 1, %o0
if ((tty->major == major) && (tty->minor == minor))
20057fc: c2 04 a0 0c ld [ %l2 + 0xc ], %g1 <== NOT EXECUTED
2005800: 80 a0 40 18 cmp %g1, %i0
2005804: 32 bf ff fb bne,a 20057f0 <rtems_termios_open+0x40>
2005808: e4 04 80 00 ld [ %l2 ], %l2
200580c: c2 04 a0 10 ld [ %l2 + 0x10 ], %g1
2005810: 80 a0 40 19 cmp %g1, %i1
2005814: 32 bf ff f7 bne,a 20057f0 <rtems_termios_open+0x40> <== NEVER TAKEN
2005818: e4 04 80 00 ld [ %l2 ], %l2 <== NOT EXECUTED
if (c++ == 'z')
c = 'a';
}
args->iop->data1 = tty;
if (!tty->refcount++) {
200581c: c2 04 a0 08 ld [ %l2 + 8 ], %g1
*/
if (c++ == 'z')
c = 'a';
}
args->iop->data1 = tty;
2005820: c6 06 80 00 ld [ %i2 ], %g3
if (!tty->refcount++) {
2005824: 84 00 60 01 add %g1, 1, %g2
*/
if (c++ == 'z')
c = 'a';
}
args->iop->data1 = tty;
2005828: e4 20 e0 38 st %l2, [ %g3 + 0x38 ]
if (!tty->refcount++) {
200582c: 80 a0 60 00 cmp %g1, 0
2005830: 12 80 00 0d bne 2005864 <rtems_termios_open+0xb4>
2005834: c4 24 a0 08 st %g2, [ %l2 + 8 ]
if (tty->device.firstOpen)
2005838: c2 04 a0 98 ld [ %l2 + 0x98 ], %g1
200583c: 80 a0 60 00 cmp %g1, 0
2005840: 02 80 00 05 be 2005854 <rtems_termios_open+0xa4>
2005844: 90 10 00 18 mov %i0, %o0
(*tty->device.firstOpen)(major, minor, arg);
2005848: 92 10 00 19 mov %i1, %o1
200584c: 9f c0 40 00 call %g1
2005850: 94 10 00 1a mov %i2, %o2
/*
* start I/O tasks, if needed
*/
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
2005854: c2 04 a0 b4 ld [ %l2 + 0xb4 ], %g1
2005858: 80 a0 60 02 cmp %g1, 2
200585c: 22 80 00 07 be,a 2005878 <rtems_termios_open+0xc8> <== NEVER TAKEN
2005860: d0 04 a0 c4 ld [ %l2 + 0xc4 ], %o0 <== NOT EXECUTED
(rtems_task_argument)tty);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
}
}
rtems_semaphore_release (rtems_termios_ttyMutex);
2005864: 40 00 04 63 call 20069f0 <rtems_semaphore_release>
2005868: d0 04 62 10 ld [ %l1 + 0x210 ], %o0
return RTEMS_SUCCESSFUL;
}
200586c: b0 10 00 10 mov %l0, %i0
2005870: 81 c7 e0 08 ret
2005874: 81 e8 00 00 restore
(*tty->device.firstOpen)(major, minor, arg);
/*
* start I/O tasks, if needed
*/
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
sc = rtems_task_start(tty->rxTaskId,
2005878: 13 00 80 17 sethi %hi(0x2005c00), %o1 <== NOT EXECUTED
200587c: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
2005880: 40 00 05 30 call 2006d40 <rtems_task_start> <== NOT EXECUTED
2005884: 92 12 60 a0 or %o1, 0xa0, %o1 <== NOT EXECUTED
rtems_termios_rxdaemon,
(rtems_task_argument)tty);
if (sc != RTEMS_SUCCESSFUL)
2005888: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200588c: 12 80 00 bf bne 2005b88 <rtems_termios_open+0x3d8> <== NOT EXECUTED
2005890: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
sc = rtems_task_start(tty->txTaskId,
2005894: d0 04 a0 c8 ld [ %l2 + 0xc8 ], %o0 <== NOT EXECUTED
2005898: 13 00 80 17 sethi %hi(0x2005c00), %o1 <== NOT EXECUTED
200589c: 40 00 05 29 call 2006d40 <rtems_task_start> <== NOT EXECUTED
20058a0: 92 12 60 08 or %o1, 8, %o1 ! 2005c08 <rtems_termios_txdaemon><== NOT EXECUTED
rtems_termios_txdaemon,
(rtems_task_argument)tty);
if (sc != RTEMS_SUCCESSFUL)
20058a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20058a8: 02 bf ff ef be 2005864 <rtems_termios_open+0xb4> <== NOT EXECUTED
20058ac: 01 00 00 00 nop <== NOT EXECUTED
20058b0: 30 80 00 b6 b,a 2005b88 <rtems_termios_open+0x3d8> <== NOT EXECUTED
static char c = 'a';
/*
* Create a new device
*/
tty = calloc (1, sizeof (struct rtems_termios_tty));
20058b4: 7f ff f4 6b call 2002a60 <calloc>
20058b8: 92 10 20 e8 mov 0xe8, %o1
if (tty == NULL) {
20058bc: a6 92 20 00 orcc %o0, 0, %l3
20058c0: 02 80 00 99 be 2005b24 <rtems_termios_open+0x374> <== NEVER TAKEN
20058c4: a4 10 00 13 mov %l3, %l2
return RTEMS_NO_MEMORY;
}
/*
* allocate raw input buffer
*/
tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE;
20058c8: 03 00 80 7a sethi %hi(0x201e800), %g1
20058cc: c2 00 61 74 ld [ %g1 + 0x174 ], %g1 ! 201e974 <rtems_termios_raw_input_size>
20058d0: c2 24 e0 64 st %g1, [ %l3 + 0x64 ]
tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);
20058d4: d0 04 e0 64 ld [ %l3 + 0x64 ], %o0
20058d8: 7f ff f5 ed call 200308c <malloc>
20058dc: 01 00 00 00 nop
if (tty->rawInBuf.theBuf == NULL) {
20058e0: 80 a2 20 00 cmp %o0, 0
20058e4: 02 80 00 8e be 2005b1c <rtems_termios_open+0x36c> <== NEVER TAKEN
20058e8: d0 24 e0 58 st %o0, [ %l3 + 0x58 ]
return RTEMS_NO_MEMORY;
}
/*
* allocate raw output buffer
*/
tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE;
20058ec: 03 00 80 7a sethi %hi(0x201e800), %g1
20058f0: c2 00 61 78 ld [ %g1 + 0x178 ], %g1 ! 201e978 <rtems_termios_raw_output_size>
20058f4: c2 24 e0 88 st %g1, [ %l3 + 0x88 ]
tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);
20058f8: d0 04 e0 88 ld [ %l3 + 0x88 ], %o0
20058fc: 7f ff f5 e4 call 200308c <malloc>
2005900: 01 00 00 00 nop
if (tty->rawOutBuf.theBuf == NULL) {
2005904: 80 a2 20 00 cmp %o0, 0
2005908: 02 80 00 8c be 2005b38 <rtems_termios_open+0x388> <== NEVER TAKEN
200590c: d0 24 e0 7c st %o0, [ %l3 + 0x7c ]
return RTEMS_NO_MEMORY;
}
/*
* allocate cooked buffer
*/
tty->cbuf = malloc (CBUFSIZE);
2005910: 03 00 80 7a sethi %hi(0x201e800), %g1
2005914: 7f ff f5 de call 200308c <malloc>
2005918: d0 00 61 70 ld [ %g1 + 0x170 ], %o0 ! 201e970 <rtems_termios_cbufsize>
if (tty->cbuf == NULL) {
200591c: 80 a2 20 00 cmp %o0, 0
2005920: 02 80 00 9c be 2005b90 <rtems_termios_open+0x3e0> <== NEVER TAKEN
2005924: d0 24 e0 1c st %o0, [ %l3 + 0x1c ]
tty->tty_rcvwakeup = 0;
/*
* link tty
*/
tty->forw = rtems_termios_ttyHead;
2005928: c2 05 22 18 ld [ %l4 + 0x218 ], %g1
return RTEMS_NO_MEMORY;
}
/*
* Initialize wakeup callbacks
*/
tty->tty_snd.sw_pfn = NULL;
200592c: c0 24 e0 d4 clr [ %l3 + 0xd4 ]
tty->tty_snd.sw_arg = NULL;
2005930: c0 24 e0 d8 clr [ %l3 + 0xd8 ]
tty->tty_rcv.sw_pfn = NULL;
2005934: c0 24 e0 dc clr [ %l3 + 0xdc ]
tty->tty_rcv.sw_arg = NULL;
2005938: c0 24 e0 e0 clr [ %l3 + 0xe0 ]
tty->tty_rcvwakeup = 0;
200593c: c0 24 e0 e4 clr [ %l3 + 0xe4 ]
/*
* link tty
*/
tty->forw = rtems_termios_ttyHead;
2005940: c2 24 c0 00 st %g1, [ %l3 ]
tty->back = NULL;
if (rtems_termios_ttyHead != NULL)
2005944: 80 a0 60 00 cmp %g1, 0
2005948: 02 80 00 03 be 2005954 <rtems_termios_open+0x1a4>
200594c: c0 24 e0 04 clr [ %l3 + 4 ]
rtems_termios_ttyHead->back = tty;
2005950: e6 20 60 04 st %l3, [ %g1 + 4 ]
rtems_termios_ttyHead = tty;
if (rtems_termios_ttyTail == NULL)
2005954: 03 00 80 7c sethi %hi(0x201f000), %g1
2005958: c4 00 62 14 ld [ %g1 + 0x214 ], %g2 ! 201f214 <rtems_termios_ttyTail>
200595c: 80 a0 a0 00 cmp %g2, 0
2005960: 02 80 00 a8 be 2005c00 <rtems_termios_open+0x450>
2005964: e6 25 22 18 st %l3, [ %l4 + 0x218 ]
tty->major = major;
/*
* Set up mutex semaphores
*/
sc = rtems_semaphore_create (
2005968: 29 00 80 7a sethi %hi(0x201e800), %l4
200596c: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0 ! 201e97c <c.6404>
2005970: 03 15 14 9a sethi %hi(0x54526800), %g1
2005974: 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;
2005978: f2 24 e0 10 st %i1, [ %l3 + 0x10 ]
tty->major = major;
200597c: f0 24 e0 0c st %i0, [ %l3 + 0xc ]
/*
* Set up mutex semaphores
*/
sc = rtems_semaphore_create (
2005980: 90 12 00 01 or %o0, %g1, %o0
2005984: 92 10 20 01 mov 1, %o1
2005988: 94 10 20 54 mov 0x54, %o2
200598c: 96 10 20 00 clr %o3
2005990: 40 00 03 30 call 2006650 <rtems_semaphore_create>
2005994: 98 04 e0 14 add %l3, 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)
2005998: 80 a2 20 00 cmp %o0, 0
200599c: 12 80 00 7b bne 2005b88 <rtems_termios_open+0x3d8> <== NEVER TAKEN
20059a0: 03 15 14 9b sethi %hi(0x54526c00), %g1
rtems_fatal_error_occurred (sc);
sc = rtems_semaphore_create (
20059a4: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0
20059a8: 82 10 63 00 or %g1, 0x300, %g1
20059ac: 92 10 20 01 mov 1, %o1
20059b0: 90 12 00 01 or %o0, %g1, %o0
20059b4: 94 10 20 54 mov 0x54, %o2
20059b8: 96 10 20 00 clr %o3
20059bc: 40 00 03 25 call 2006650 <rtems_semaphore_create>
20059c0: 98 04 e0 18 add %l3, 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)
20059c4: 80 a2 20 00 cmp %o0, 0
20059c8: 12 80 00 70 bne 2005b88 <rtems_termios_open+0x3d8> <== NEVER TAKEN
20059cc: 03 15 14 9e sethi %hi(0x54527800), %g1
rtems_fatal_error_occurred (sc);
sc = rtems_semaphore_create (
20059d0: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0
20059d4: 92 10 20 00 clr %o1
20059d8: 90 12 00 01 or %o0, %g1, %o0
20059dc: 94 10 20 20 mov 0x20, %o2
20059e0: 96 10 20 00 clr %o3
20059e4: 40 00 03 1b call 2006650 <rtems_semaphore_create>
20059e8: 98 04 e0 8c add %l3, 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)
20059ec: 80 a2 20 00 cmp %o0, 0
20059f0: 12 80 00 66 bne 2005b88 <rtems_termios_open+0x3d8> <== NEVER TAKEN
20059f4: 92 10 00 1b mov %i3, %o1
rtems_fatal_error_occurred (sc);
tty->rawOutBufState = rob_idle;
20059f8: c0 24 e0 94 clr [ %l3 + 0x94 ]
/*
* Set callbacks
*/
tty->device = *callbacks;
20059fc: 90 04 e0 98 add %l3, 0x98, %o0
2005a00: 40 00 32 3b call 20122ec <memcpy>
2005a04: 94 10 20 20 mov 0x20, %o2
/*
* Create I/O tasks
*/
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
2005a08: c2 04 e0 b4 ld [ %l3 + 0xb4 ], %g1
2005a0c: 80 a0 60 02 cmp %g1, 2
2005a10: 02 80 00 65 be 2005ba4 <rtems_termios_open+0x3f4> <== NEVER TAKEN
2005a14: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0
&tty->rxTaskId);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
}
if ((tty->device.pollRead == NULL) ||
2005a18: c2 04 e0 a0 ld [ %l3 + 0xa0 ], %g1
2005a1c: 80 a0 60 00 cmp %g1, 0
2005a20: 02 80 00 4f be 2005b5c <rtems_termios_open+0x3ac> <== NEVER TAKEN
2005a24: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){
2005a28: c2 04 e0 b4 ld [ %l3 + 0xb4 ], %g1
2005a2c: 80 a0 60 02 cmp %g1, 2
2005a30: 02 80 00 4c be 2005b60 <rtems_termios_open+0x3b0> <== NEVER TAKEN
2005a34: 03 15 14 9c sethi %hi(0x54527000), %g1
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;
2005a38: c0 24 e0 b8 clr [ %l3 + 0xb8 ]
/*
* set low/highwater mark for XON/XOFF support
*/
tty->lowwater = tty->rawInBuf.Size * 1/2;
2005a3c: c6 04 e0 64 ld [ %l3 + 0x64 ], %g3
tty->highwater = tty->rawInBuf.Size * 3/4;
/*
* Bump name characer
*/
if (c++ == 'z')
2005a40: c2 0d 21 7c ldub [ %l4 + 0x17c ], %g1
/* 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;
2005a44: 87 30 e0 01 srl %g3, 1, %g3
2005a48: c6 24 e0 bc st %g3, [ %l3 + 0xbc ]
}
/*
* Set default parameters
*/
tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL;
2005a4c: 07 00 00 09 sethi %hi(0x2400), %g3
2005a50: 86 10 e1 02 or %g3, 0x102, %g3 ! 2502 <PROM_START+0x2502>
2005a54: c6 24 e0 30 st %g3, [ %l3 + 0x30 ]
tty->termios.c_oflag = OPOST | ONLCR | XTABS;
2005a58: 07 00 00 06 sethi %hi(0x1800), %g3
2005a5c: 86 10 e0 05 or %g3, 5, %g3 ! 1805 <PROM_START+0x1805>
2005a60: c6 24 e0 34 st %g3, [ %l3 + 0x34 ]
tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL;
2005a64: 86 10 28 bd mov 0x8bd, %g3
2005a68: c6 24 e0 38 st %g3, [ %l3 + 0x38 ]
tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL;
2005a6c: 07 00 00 20 sethi %hi(0x8000), %g3
2005a70: 86 10 e2 3b or %g3, 0x23b, %g3 ! 823b <PROM_START+0x823b>
2005a74: c6 24 e0 3c st %g3, [ %l3 + 0x3c ]
tty->termios.c_cc[VINTR] = '\003';
2005a78: 86 10 20 03 mov 3, %g3
2005a7c: c6 2c e0 41 stb %g3, [ %l3 + 0x41 ]
tty->termios.c_cc[VQUIT] = '\034';
2005a80: 86 10 20 1c mov 0x1c, %g3
2005a84: c6 2c e0 42 stb %g3, [ %l3 + 0x42 ]
tty->termios.c_cc[VERASE] = '\177';
2005a88: 86 10 20 7f mov 0x7f, %g3
2005a8c: c6 2c e0 43 stb %g3, [ %l3 + 0x43 ]
tty->termios.c_cc[VKILL] = '\025';
2005a90: 86 10 20 15 mov 0x15, %g3
2005a94: c6 2c e0 44 stb %g3, [ %l3 + 0x44 ]
tty->termios.c_cc[VEOF] = '\004';
2005a98: 86 10 20 04 mov 4, %g3
2005a9c: c6 2c e0 45 stb %g3, [ %l3 + 0x45 ]
tty->termios.c_cc[VEOL] = '\000';
tty->termios.c_cc[VEOL2] = '\000';
tty->termios.c_cc[VSTART] = '\021';
2005aa0: 86 10 20 11 mov 0x11, %g3
2005aa4: c6 2c e0 49 stb %g3, [ %l3 + 0x49 ]
tty->termios.c_cc[VSTOP] = '\023';
2005aa8: 86 10 20 13 mov 0x13, %g3
2005aac: c6 2c e0 4a stb %g3, [ %l3 + 0x4a ]
tty->termios.c_cc[VSUSP] = '\032';
2005ab0: 86 10 20 1a mov 0x1a, %g3
2005ab4: c6 2c e0 4b stb %g3, [ %l3 + 0x4b ]
tty->termios.c_cc[VREPRINT] = '\022';
2005ab8: 86 10 20 12 mov 0x12, %g3
2005abc: c6 2c e0 4d stb %g3, [ %l3 + 0x4d ]
tty->termios.c_cc[VDISCARD] = '\017';
2005ac0: 86 10 20 0f mov 0xf, %g3
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;
2005ac4: c4 04 e0 64 ld [ %l3 + 0x64 ], %g2
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';
2005ac8: c6 2c e0 4e stb %g3, [ %l3 + 0x4e ]
tty->termios.c_cc[VWERASE] = '\027';
2005acc: 86 10 20 17 mov 0x17, %g3
2005ad0: c6 2c e0 4f stb %g3, [ %l3 + 0x4f ]
tty->termios.c_cc[VLNEXT] = '\026';
2005ad4: 86 10 20 16 mov 0x16, %g3
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';
2005ad8: c0 2c e0 4c clrb [ %l3 + 0x4c ]
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';
2005adc: c6 2c e0 50 stb %g3, [ %l3 + 0x50 ]
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';
tty->termios.c_cc[VEOL2] = '\000';
2005ae0: c0 2c e0 51 clrb [ %l3 + 0x51 ]
tty->flow_ctrl = 0;
/*
* set low/highwater mark for XON/XOFF support
*/
tty->lowwater = tty->rawInBuf.Size * 1/2;
tty->highwater = tty->rawInBuf.Size * 3/4;
2005ae4: 87 28 a0 01 sll %g2, 1, %g3
2005ae8: 84 00 c0 02 add %g3, %g2, %g2
2005aec: 85 30 a0 02 srl %g2, 2, %g2
2005af0: c4 24 e0 c0 st %g2, [ %l3 + 0xc0 ]
/*
* Bump name characer
*/
if (c++ == 'z')
2005af4: 84 00 60 01 add %g1, 1, %g2
2005af8: 83 28 60 18 sll %g1, 0x18, %g1
2005afc: 83 38 60 18 sra %g1, 0x18, %g1
2005b00: 80 a0 60 7a cmp %g1, 0x7a
2005b04: 12 bf ff 46 bne 200581c <rtems_termios_open+0x6c> <== ALWAYS TAKEN
2005b08: c4 2d 21 7c stb %g2, [ %l4 + 0x17c ]
c = 'a';
2005b0c: 84 10 20 61 mov 0x61, %g2 <== NOT EXECUTED
2005b10: 03 00 80 7a sethi %hi(0x201e800), %g1 <== NOT EXECUTED
2005b14: 10 bf ff 42 b 200581c <rtems_termios_open+0x6c> <== NOT EXECUTED
2005b18: c4 28 61 7c stb %g2, [ %g1 + 0x17c ] ! 201e97c <c.6404> <== NOT EXECUTED
* allocate raw input buffer
*/
tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE;
tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);
if (tty->rawInBuf.theBuf == NULL) {
free(tty);
2005b1c: 7f ff f4 74 call 2002cec <free> <== NOT EXECUTED
2005b20: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
rtems_semaphore_release (rtems_termios_ttyMutex);
2005b24: d0 04 62 10 ld [ %l1 + 0x210 ], %o0 <== NOT EXECUTED
2005b28: 40 00 03 b2 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2005b2c: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
2005b30: 81 c7 e0 08 ret <== NOT EXECUTED
2005b34: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED
* allocate raw output buffer
*/
tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE;
tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);
if (tty->rawOutBuf.theBuf == NULL) {
free((void *)(tty->rawInBuf.theBuf));
2005b38: d0 04 e0 58 ld [ %l3 + 0x58 ], %o0 <== NOT EXECUTED
free(tty);
rtems_semaphore_release (rtems_termios_ttyMutex);
2005b3c: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED
* allocate cooked buffer
*/
tty->cbuf = malloc (CBUFSIZE);
if (tty->cbuf == NULL) {
free((void *)(tty->rawOutBuf.theBuf));
free((void *)(tty->rawInBuf.theBuf));
2005b40: 7f ff f4 6b call 2002cec <free> <== NOT EXECUTED
2005b44: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED
free(tty);
2005b48: 7f ff f4 69 call 2002cec <free> <== NOT EXECUTED
2005b4c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
rtems_semaphore_release (rtems_termios_ttyMutex);
2005b50: 40 00 03 a8 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2005b54: d0 04 62 10 ld [ %l1 + 0x210 ], %o0 <== NOT EXECUTED
return RTEMS_NO_MEMORY;
2005b58: 30 bf ff 46 b,a 2005870 <rtems_termios_open+0xc0> <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
}
if ((tty->device.pollRead == NULL) ||
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){
sc = rtems_semaphore_create (
2005b5c: 03 15 14 9c sethi %hi(0x54527000), %g1 <== NOT EXECUTED
2005b60: 82 10 62 00 or %g1, 0x200, %g1 ! 54527200 <RAM_END+0x52127200><== NOT EXECUTED
2005b64: 92 10 20 00 clr %o1 <== NOT EXECUTED
2005b68: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
2005b6c: 94 10 20 24 mov 0x24, %o2 <== NOT EXECUTED
2005b70: 96 10 20 00 clr %o3 <== NOT EXECUTED
2005b74: 40 00 02 b7 call 2006650 <rtems_semaphore_create> <== NOT EXECUTED
2005b78: 98 04 e0 68 add %l3, 0x68, %o4 <== NOT EXECUTED
rtems_build_name ('T', 'R', 'r', c),
0,
RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_PRIORITY,
RTEMS_NO_PRIORITY,
&tty->rawInBuf.Semaphore);
if (sc != RTEMS_SUCCESSFUL)
2005b7c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2005b80: 02 bf ff ae be 2005a38 <rtems_termios_open+0x288> <== NOT EXECUTED
2005b84: 01 00 00 00 nop <== NOT EXECUTED
sc = rtems_task_start(tty->txTaskId,
rtems_termios_txdaemon,
(rtems_task_argument)tty);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
2005b88: 40 00 04 f4 call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
2005b8c: 01 00 00 00 nop <== NOT EXECUTED
/*
* allocate cooked buffer
*/
tty->cbuf = malloc (CBUFSIZE);
if (tty->cbuf == NULL) {
free((void *)(tty->rawOutBuf.theBuf));
2005b90: d0 04 e0 7c ld [ %l3 + 0x7c ], %o0 <== NOT EXECUTED
2005b94: 7f ff f4 56 call 2002cec <free> <== NOT EXECUTED
2005b98: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED
free((void *)(tty->rawInBuf.theBuf));
2005b9c: 10 bf ff e9 b 2005b40 <rtems_termios_open+0x390> <== NOT EXECUTED
2005ba0: d0 04 e0 58 ld [ %l3 + 0x58 ], %o0 <== NOT EXECUTED
/*
* Create I/O tasks
*/
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
sc = rtems_task_create (
2005ba4: 03 15 1e 15 sethi %hi(0x54785400), %g1 <== NOT EXECUTED
2005ba8: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
2005bac: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
2005bb0: 94 10 24 00 mov 0x400, %o2 <== NOT EXECUTED
2005bb4: 96 10 25 00 mov 0x500, %o3 <== NOT EXECUTED
2005bb8: 98 10 20 00 clr %o4 <== NOT EXECUTED
2005bbc: 40 00 03 b9 call 2006aa0 <rtems_task_create> <== NOT EXECUTED
2005bc0: 9a 04 e0 c8 add %l3, 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)
2005bc4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2005bc8: 12 bf ff f0 bne 2005b88 <rtems_termios_open+0x3d8> <== NOT EXECUTED
2005bcc: 03 14 9e 15 sethi %hi(0x52785400), %g1 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
sc = rtems_task_create (
2005bd0: d0 4d 21 7c ldsb [ %l4 + 0x17c ], %o0 <== NOT EXECUTED
2005bd4: 92 10 20 09 mov 9, %o1 <== NOT EXECUTED
2005bd8: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED
2005bdc: 94 10 24 00 mov 0x400, %o2 <== NOT EXECUTED
2005be0: 96 10 25 00 mov 0x500, %o3 <== NOT EXECUTED
2005be4: 98 10 20 00 clr %o4 <== NOT EXECUTED
2005be8: 40 00 03 ae call 2006aa0 <rtems_task_create> <== NOT EXECUTED
2005bec: 9a 04 e0 c4 add %l3, 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)
2005bf0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2005bf4: 22 bf ff 8a be,a 2005a1c <rtems_termios_open+0x26c> <== NOT EXECUTED
2005bf8: c2 04 e0 a0 ld [ %l3 + 0xa0 ], %g1 <== NOT EXECUTED
2005bfc: 30 bf ff e3 b,a 2005b88 <rtems_termios_open+0x3d8> <== NOT EXECUTED
tty->back = NULL;
if (rtems_termios_ttyHead != NULL)
rtems_termios_ttyHead->back = tty;
rtems_termios_ttyHead = tty;
if (rtems_termios_ttyTail == NULL)
rtems_termios_ttyTail = tty;
2005c00: 10 bf ff 5a b 2005968 <rtems_termios_open+0x1b8>
2005c04: e6 20 62 14 st %l3, [ %g1 + 0x214 ]
02004474 <rtems_termios_puts>:
* Send characters to device-specific code
*/
void
rtems_termios_puts (
const void *_buf, int len, struct rtems_termios_tty *tty)
{
2004474: 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) {
2004478: c2 06 a0 b4 ld [ %i2 + 0xb4 ], %g1
200447c: 80 a0 60 00 cmp %g1, 0
2004480: 02 80 00 42 be 2004588 <rtems_termios_puts+0x114> <== ALWAYS TAKEN
2004484: a8 10 00 18 mov %i0, %l4
(*tty->device.write)(tty->minor, (void *)buf, len);
return;
}
newHead = tty->rawOutBuf.Head;
2004488: e6 06 a0 80 ld [ %i2 + 0x80 ], %l3 <== NOT EXECUTED
while (len) {
200448c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
2004490: 02 80 00 43 be 200459c <rtems_termios_puts+0x128> <== NOT EXECUTED
2004494: a4 10 20 02 mov 2, %l2 <== NOT EXECUTED
}
else {
/* remember that output has been stopped due to flow ctrl*/
tty->flow_ctrl |= FL_OSTOP;
}
tty->rawOutBufState = rob_busy;
2004498: aa 10 20 01 mov 1, %l5 <== NOT EXECUTED
* len -= ncopy
*
* To minimize latency, the memcpy should be done
* with interrupts enabled.
*/
newHead = (newHead + 1) % tty->rawOutBuf.Size;
200449c: d2 06 a0 88 ld [ %i2 + 0x88 ], %o1 <== NOT EXECUTED
20044a0: 40 00 5b 56 call 201b1f8 <.urem> <== NOT EXECUTED
20044a4: 90 04 e0 01 add %l3, 1, %o0 <== NOT EXECUTED
rtems_interrupt_disable (level);
20044a8: 7f ff f6 ff call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
20044ac: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
20044b0: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
while (newHead == tty->rawOutBuf.Tail) {
20044b4: e2 06 a0 84 ld [ %i2 + 0x84 ], %l1 <== NOT EXECUTED
20044b8: 80 a4 40 13 cmp %l1, %l3 <== NOT EXECUTED
20044bc: 12 80 00 13 bne 2004508 <rtems_termios_puts+0x94> <== NOT EXECUTED
20044c0: 01 00 00 00 nop <== NOT EXECUTED
tty->rawOutBufState = rob_wait;
20044c4: e4 26 a0 94 st %l2, [ %i2 + 0x94 ] <== NOT EXECUTED
rtems_interrupt_enable (level);
20044c8: 7f ff f6 fb call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
20044cc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
20044d0: d0 06 a0 8c ld [ %i2 + 0x8c ], %o0 <== NOT EXECUTED
20044d4: 92 10 20 00 clr %o1 <== NOT EXECUTED
20044d8: 40 00 08 ff call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
20044dc: 94 10 20 00 clr %o2 <== NOT EXECUTED
RTEMS_WAIT,
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
20044e0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20044e4: 12 80 00 30 bne 20045a4 <rtems_termios_puts+0x130> <== NOT EXECUTED
20044e8: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
rtems_interrupt_disable (level);
20044ec: 7f ff f6 ee call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
20044f0: 01 00 00 00 nop <== NOT EXECUTED
20044f4: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
* To minimize latency, the memcpy should be done
* with interrupts enabled.
*/
newHead = (newHead + 1) % tty->rawOutBuf.Size;
rtems_interrupt_disable (level);
while (newHead == tty->rawOutBuf.Tail) {
20044f8: c2 06 a0 84 ld [ %i2 + 0x84 ], %g1 <== NOT EXECUTED
20044fc: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2004500: 22 bf ff f2 be,a 20044c8 <rtems_termios_puts+0x54> <== NOT EXECUTED
2004504: e4 26 a0 94 st %l2, [ %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++;
2004508: c2 06 a0 80 ld [ %i2 + 0x80 ], %g1 <== NOT EXECUTED
200450c: c6 0d 00 00 ldub [ %l4 ], %g3 <== NOT EXECUTED
2004510: c4 06 a0 7c ld [ %i2 + 0x7c ], %g2 <== NOT EXECUTED
2004514: c6 28 80 01 stb %g3, [ %g2 + %g1 ] <== NOT EXECUTED
tty->rawOutBuf.Head = newHead;
if (tty->rawOutBufState == rob_idle) {
2004518: c2 06 a0 94 ld [ %i2 + 0x94 ], %g1 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
rtems_interrupt_disable (level);
}
tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;
tty->rawOutBuf.Head = newHead;
200451c: e6 26 a0 80 st %l3, [ %i2 + 0x80 ] <== NOT EXECUTED
if (tty->rawOutBufState == rob_idle) {
2004520: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004524: 12 80 00 0a bne 200454c <rtems_termios_puts+0xd8> <== NOT EXECUTED
2004528: 01 00 00 00 nop <== NOT EXECUTED
/* check, whether XOFF has been received */
if (!(tty->flow_ctrl & FL_ORCVXOF)) {
200452c: c2 06 a0 b8 ld [ %i2 + 0xb8 ], %g1 <== NOT EXECUTED
2004530: 80 88 60 10 btst 0x10, %g1 <== NOT EXECUTED
2004534: 02 80 00 0c be 2004564 <rtems_termios_puts+0xf0> <== NOT EXECUTED
2004538: 01 00 00 00 nop <== NOT EXECUTED
(*tty->device.write)(tty->minor,
(char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
}
else {
/* remember that output has been stopped due to flow ctrl*/
tty->flow_ctrl |= FL_OSTOP;
200453c: c2 06 a0 b8 ld [ %i2 + 0xb8 ], %g1 <== NOT EXECUTED
2004540: 82 10 60 20 or %g1, 0x20, %g1 <== NOT EXECUTED
2004544: c2 26 a0 b8 st %g1, [ %i2 + 0xb8 ] <== NOT EXECUTED
}
tty->rawOutBufState = rob_busy;
2004548: ea 26 a0 94 st %l5, [ %i2 + 0x94 ] <== NOT EXECUTED
}
rtems_interrupt_enable (level);
200454c: 7f ff f6 da call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004550: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
(*tty->device.write)(tty->minor, (void *)buf, len);
return;
}
newHead = tty->rawOutBuf.Head;
while (len) {
2004554: b2 86 7f ff addcc %i1, -1, %i1 <== NOT EXECUTED
2004558: 02 80 00 11 be 200459c <rtems_termios_puts+0x128> <== NOT EXECUTED
200455c: a8 05 20 01 inc %l4 <== NOT EXECUTED
2004560: 30 bf ff cf b,a 200449c <rtems_termios_puts+0x28> <== NOT EXECUTED
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,
(char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
2004564: c4 06 a0 84 ld [ %i2 + 0x84 ], %g2 <== NOT EXECUTED
tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;
tty->rawOutBuf.Head = newHead;
if (tty->rawOutBufState == rob_idle) {
/* check, whether XOFF has been received */
if (!(tty->flow_ctrl & FL_ORCVXOF)) {
(*tty->device.write)(tty->minor,
2004568: d2 06 a0 7c ld [ %i2 + 0x7c ], %o1 <== NOT EXECUTED
200456c: c2 06 a0 a4 ld [ %i2 + 0xa4 ], %g1 <== NOT EXECUTED
2004570: d0 06 a0 10 ld [ %i2 + 0x10 ], %o0 <== NOT EXECUTED
2004574: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED
2004578: 9f c0 40 00 call %g1 <== NOT EXECUTED
200457c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
}
else {
/* remember that output has been stopped due to flow ctrl*/
tty->flow_ctrl |= FL_OSTOP;
}
tty->rawOutBufState = rob_busy;
2004580: 10 bf ff f3 b 200454c <rtems_termios_puts+0xd8> <== NOT EXECUTED
2004584: ea 26 a0 94 st %l5, [ %i2 + 0x94 ] <== NOT EXECUTED
unsigned int newHead;
rtems_interrupt_level level;
rtems_status_code sc;
if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
(*tty->device.write)(tty->minor, (void *)buf, len);
2004588: d0 06 a0 10 ld [ %i2 + 0x10 ], %o0
200458c: c2 06 a0 a4 ld [ %i2 + 0xa4 ], %g1
2004590: 92 10 00 18 mov %i0, %o1
2004594: 9f c0 40 00 call %g1
2004598: 94 10 00 19 mov %i1, %o2
return;
200459c: 81 c7 e0 08 ret
20045a0: 81 e8 00 00 restore
rtems_interrupt_enable (level);
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
RTEMS_WAIT,
RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred (sc);
20045a4: 40 00 0a 6d call 2006f58 <rtems_fatal_error_occurred> <== NOT EXECUTED
02004dcc <rtems_termios_read>:
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_termios_read (void *arg)
{
2004dcc: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_rw_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
2004dd0: c2 06 00 00 ld [ %i0 ], %g1
uint32_t count = args->count;
2004dd4: e6 06 20 14 ld [ %i0 + 0x14 ], %l3
rtems_status_code
rtems_termios_read (void *arg)
{
rtems_libio_rw_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
2004dd8: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
uint32_t count = args->count;
char *buffer = args->buffer;
2004ddc: e8 06 20 10 ld [ %i0 + 0x10 ], %l4
rtems_status_code sc;
sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004de0: d0 04 20 14 ld [ %l0 + 0x14 ], %o0
return RTEMS_SUCCESSFUL;
}
rtems_status_code
rtems_termios_read (void *arg)
{
2004de4: ac 10 00 18 mov %i0, %l6
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);
2004de8: 92 10 20 00 clr %o1
2004dec: 40 00 06 ba call 20068d4 <rtems_semaphore_obtain>
2004df0: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL)
2004df4: b0 92 20 00 orcc %o0, 0, %i0
2004df8: 12 80 00 10 bne 2004e38 <rtems_termios_read+0x6c> <== NEVER TAKEN
2004dfc: 05 00 80 7b sethi %hi(0x201ec00), %g2
return sc;
if (rtems_termios_linesw[tty->t_line].l_read != NULL) {
2004e00: c2 04 20 cc ld [ %l0 + 0xcc ], %g1
2004e04: 83 28 60 05 sll %g1, 5, %g1
2004e08: 84 10 a3 40 or %g2, 0x340, %g2
2004e0c: 82 00 60 08 add %g1, 8, %g1
2004e10: c2 00 80 01 ld [ %g2 + %g1 ], %g1
2004e14: 80 a0 60 00 cmp %g1, 0
2004e18: 02 80 00 0a be 2004e40 <rtems_termios_read+0x74> <== ALWAYS TAKEN
2004e1c: 92 10 00 16 mov %l6, %o1
sc = rtems_termios_linesw[tty->t_line].l_read(tty,args);
2004e20: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004e24: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2004e28: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
tty->tty_rcvwakeup = 0;
rtems_semaphore_release (tty->isem);
2004e2c: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED
2004e30: 40 00 06 f0 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004e34: c0 24 20 e4 clr [ %l0 + 0xe4 ] <== NOT EXECUTED
return sc;
2004e38: 81 c7 e0 08 ret <== NOT EXECUTED
2004e3c: 81 e8 00 00 restore <== NOT EXECUTED
}
if (tty->cindex == tty->ccount) {
2004e40: c4 04 20 24 ld [ %l0 + 0x24 ], %g2
2004e44: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2004e48: 80 a0 80 01 cmp %g2, %g1
2004e4c: 22 80 00 20 be,a 2004ecc <rtems_termios_read+0x100> <== ALWAYS TAKEN
2004e50: c4 04 20 28 ld [ %l0 + 0x28 ], %g2
else
sc = fillBufferQueue (tty);
if (sc != RTEMS_SUCCESSFUL)
tty->cindex = tty->ccount = 0;
}
while (count && (tty->cindex < tty->ccount)) {
2004e54: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2004e58: 22 80 00 16 be,a 2004eb0 <rtems_termios_read+0xe4> <== NOT EXECUTED
2004e5c: c2 05 a0 14 ld [ %l6 + 0x14 ], %g1 <== NOT EXECUTED
2004e60: c2 04 20 24 ld [ %l0 + 0x24 ], %g1 <== NOT EXECUTED
2004e64: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
2004e68: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
2004e6c: 26 80 00 09 bl,a 2004e90 <rtems_termios_read+0xc4> <== NOT EXECUTED
2004e70: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++];
count--;
}
args->bytes_moved = args->count - count;
2004e74: 10 80 00 0f b 2004eb0 <rtems_termios_read+0xe4> <== NOT EXECUTED
2004e78: c2 05 a0 14 ld [ %l6 + 0x14 ], %g1 <== NOT EXECUTED
else
sc = fillBufferQueue (tty);
if (sc != RTEMS_SUCCESSFUL)
tty->cindex = tty->ccount = 0;
}
while (count && (tty->cindex < tty->ccount)) {
2004e7c: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
2004e80: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004e84: 24 80 00 0b ble,a 2004eb0 <rtems_termios_read+0xe4> <== NOT EXECUTED
2004e88: c2 05 a0 14 ld [ %l6 + 0x14 ], %g1 <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++];
2004e8c: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED
else
sc = fillBufferQueue (tty);
if (sc != RTEMS_SUCCESSFUL)
tty->cindex = tty->ccount = 0;
}
while (count && (tty->cindex < tty->ccount)) {
2004e90: a6 84 ff ff addcc %l3, -1, %l3 <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++];
2004e94: c4 08 80 01 ldub [ %g2 + %g1 ], %g2 <== NOT EXECUTED
2004e98: 82 00 60 01 inc %g1 <== NOT EXECUTED
2004e9c: c4 2d 00 00 stb %g2, [ %l4 ] <== NOT EXECUTED
2004ea0: c2 24 20 24 st %g1, [ %l0 + 0x24 ] <== NOT EXECUTED
else
sc = fillBufferQueue (tty);
if (sc != RTEMS_SUCCESSFUL)
tty->cindex = tty->ccount = 0;
}
while (count && (tty->cindex < tty->ccount)) {
2004ea4: 12 bf ff f6 bne 2004e7c <rtems_termios_read+0xb0> <== NOT EXECUTED
2004ea8: a8 05 20 01 inc %l4 <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++];
count--;
}
args->bytes_moved = args->count - count;
2004eac: c2 05 a0 14 ld [ %l6 + 0x14 ], %g1 <== NOT EXECUTED
tty->tty_rcvwakeup = 0;
2004eb0: 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;
2004eb4: a6 20 40 13 sub %g1, %l3, %l3 <== NOT EXECUTED
2004eb8: e6 25 a0 1c st %l3, [ %l6 + 0x1c ] <== NOT EXECUTED
tty->tty_rcvwakeup = 0;
rtems_semaphore_release (tty->isem);
2004ebc: 40 00 06 cd call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004ec0: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED
return sc;
}
2004ec4: 81 c7 e0 08 ret <== NOT EXECUTED
2004ec8: 81 e8 00 00 restore <== NOT EXECUTED
}
if (tty->cindex == tty->ccount) {
tty->cindex = tty->ccount = 0;
tty->read_start_column = tty->column;
if (tty->device.pollRead != NULL
&& tty->device.outputUsesInterrupts == TERMIOS_POLLED)
2004ecc: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
rtems_semaphore_release (tty->isem);
return sc;
}
if (tty->cindex == tty->ccount) {
tty->cindex = tty->ccount = 0;
tty->read_start_column = tty->column;
2004ed0: c4 24 20 2c st %g2, [ %l0 + 0x2c ]
tty->tty_rcvwakeup = 0;
rtems_semaphore_release (tty->isem);
return sc;
}
if (tty->cindex == tty->ccount) {
tty->cindex = tty->ccount = 0;
2004ed4: c0 24 20 20 clr [ %l0 + 0x20 ]
tty->read_start_column = tty->column;
if (tty->device.pollRead != NULL
2004ed8: 80 a0 60 00 cmp %g1, 0
2004edc: 02 80 00 06 be 2004ef4 <rtems_termios_read+0x128> <== NEVER TAKEN
2004ee0: c0 24 20 24 clr [ %l0 + 0x24 ]
&& tty->device.outputUsesInterrupts == TERMIOS_POLLED)
2004ee4: c4 04 20 b4 ld [ %l0 + 0xb4 ], %g2
2004ee8: 80 a0 a0 00 cmp %g2, 0
2004eec: 22 80 00 6e be,a 20050a4 <rtems_termios_read+0x2d8> <== ALWAYS TAKEN
2004ef0: c4 04 20 3c ld [ %l0 + 0x3c ], %g2
* Fill the input buffer from the raw input queue
*/
static rtems_status_code
fillBufferQueue (struct rtems_termios_tty *tty)
{
rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout;
2004ef4: e2 04 20 74 ld [ %l0 + 0x74 ], %l1 <== NOT EXECUTED
while ( wait ) {
/*
* Process characters read from raw queue
*/
while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
2004ef8: 25 00 80 7a sethi %hi(0x201e800), %l2 <== 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,
2004efc: ae 04 20 49 add %l0, 0x49, %l7 <== NOT EXECUTED
while ( wait ) {
/*
* Process characters read from raw queue
*/
while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
2004f00: a4 14 a1 70 or %l2, 0x170, %l2 <== 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,
2004f04: aa 10 20 01 mov 1, %l5 <== NOT EXECUTED
while ( wait ) {
/*
* Process characters read from raw queue
*/
while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
2004f08: c4 04 20 5c ld [ %l0 + 0x5c ], %g2 <== NOT EXECUTED
2004f0c: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED
2004f10: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004f14: 02 80 00 43 be 2005020 <rtems_termios_read+0x254> <== NOT EXECUTED
2004f18: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
2004f1c: c4 04 80 00 ld [ %l2 ], %g2 <== NOT EXECUTED
2004f20: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
2004f24: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
2004f28: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004f2c: 04 80 00 3d ble 2005020 <rtems_termios_read+0x254> <== NOT EXECUTED
2004f30: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
(tty->ccount < (CBUFSIZE-1))) {
unsigned char c;
unsigned int newHead;
newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;
2004f34: d0 04 20 5c ld [ %l0 + 0x5c ], %o0 <== NOT EXECUTED
2004f38: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED
2004f3c: 40 00 58 af call 201b1f8 <.urem> <== NOT EXECUTED
2004f40: 90 02 20 01 inc %o0 <== NOT EXECUTED
c = tty->rawInBuf.theBuf[newHead];
2004f44: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED
2004f48: e2 08 40 08 ldub [ %g1 + %o0 ], %l1 <== NOT EXECUTED
tty->rawInBuf.Head = newHead;
2004f4c: d0 24 20 5c st %o0, [ %l0 + 0x5c ] <== NOT EXECUTED
if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)
2004f50: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED
2004f54: c4 04 20 64 ld [ %l0 + 0x64 ], %g2 <== NOT EXECUTED
2004f58: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED
2004f5c: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED
2004f60: 40 00 58 a6 call 201b1f8 <.urem> <== NOT EXECUTED
2004f64: 90 20 40 08 sub %g1, %o0, %o0 <== NOT EXECUTED
2004f68: c2 04 20 bc ld [ %l0 + 0xbc ], %g1 <== NOT EXECUTED
2004f6c: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
2004f70: 3a 80 00 18 bcc,a 2004fd0 <rtems_termios_read+0x204> <== NOT EXECUTED
2004f74: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
% tty->rawInBuf.Size)
< tty->lowwater) {
tty->flow_ctrl &= ~FL_IREQXOF;
2004f78: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2004f7c: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED
2004f80: 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))
2004f84: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2004f88: 82 08 62 02 and %g1, 0x202, %g1 <== NOT EXECUTED
2004f8c: 80 a0 62 02 cmp %g1, 0x202 <== NOT EXECUTED
2004f90: 22 80 00 37 be,a 200506c <rtems_termios_read+0x2a0> <== NOT EXECUTED
2004f94: c2 04 20 94 ld [ %l0 + 0x94 ], %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) {
2004f98: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2004f9c: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
2004fa0: 22 80 00 0c be,a 2004fd0 <rtems_termios_read+0x204> <== NOT EXECUTED
2004fa4: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_IRTSOFF;
2004fa8: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* activate RTS line */
if (tty->device.startRemoteTx != NULL) {
2004fac: 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;
2004fb0: 84 08 bf fb and %g2, -5, %g2 <== NOT EXECUTED
2004fb4: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* activate RTS line */
if (tty->device.startRemoteTx != NULL) {
2004fb8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004fbc: 22 80 00 05 be,a 2004fd0 <rtems_termios_read+0x204> <== NOT EXECUTED
2004fc0: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->device.startRemoteTx(tty->minor);
2004fc4: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004fc8: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
}
}
}
/* continue processing new character */
if (tty->termios.c_lflag & ICANON) {
2004fcc: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
2004fd0: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
2004fd4: 02 80 00 1d be 2005048 <rtems_termios_read+0x27c> <== NOT EXECUTED
2004fd8: 90 0c 60 ff and %l1, 0xff, %o0 <== NOT EXECUTED
if (siproc (c, tty))
2004fdc: 7f ff ff 0f call 2004c18 <siproc> <== NOT EXECUTED
2004fe0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
2004fe4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
2004fe8: 32 80 00 02 bne,a 2004ff0 <rtems_termios_read+0x224> <== NOT EXECUTED
2004fec: aa 10 20 00 clr %l5 <== NOT EXECUTED
while ( wait ) {
/*
* Process characters read from raw queue
*/
while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
2004ff0: c4 04 20 5c ld [ %l0 + 0x5c ], %g2 <== NOT EXECUTED
2004ff4: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED
2004ff8: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2004ffc: 02 80 00 08 be 200501c <rtems_termios_read+0x250> <== NOT EXECUTED
2005000: e2 04 20 70 ld [ %l0 + 0x70 ], %l1 <== NOT EXECUTED
2005004: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
2005008: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
200500c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
2005010: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2005014: 06 bf ff c8 bl 2004f34 <rtems_termios_read+0x168> <== NOT EXECUTED
2005018: 01 00 00 00 nop <== NOT EXECUTED
}
/*
* Wait for characters
*/
if ( wait ) {
200501c: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
2005020: 02 bf ff 8e be 2004e58 <rtems_termios_read+0x8c> <== NOT EXECUTED
2005024: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
sc = rtems_semaphore_obtain (tty->rawInBuf.Semaphore,
2005028: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED
200502c: d2 04 20 6c ld [ %l0 + 0x6c ], %o1 <== NOT EXECUTED
2005030: 40 00 06 29 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
2005034: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions,
timeout);
if (sc != RTEMS_SUCCESSFUL)
2005038: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
200503c: 02 bf ff b3 be 2004f08 <rtems_termios_read+0x13c> <== NOT EXECUTED
2005040: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2005044: 30 bf ff 85 b,a 2004e58 <rtems_termios_read+0x8c> <== NOT EXECUTED
if (tty->termios.c_lflag & ICANON) {
if (siproc (c, tty))
wait = 0;
}
else {
siproc (c, tty);
2005048: 7f ff fe f4 call 2004c18 <siproc> <== NOT EXECUTED
200504c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
2005050: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED
2005054: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
2005058: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
200505c: 06 bf ff e5 bl 2004ff0 <rtems_termios_read+0x224> <== NOT EXECUTED
2005060: 01 00 00 00 nop <== NOT EXECUTED
2005064: 10 bf ff e3 b 2004ff0 <rtems_termios_read+0x224> <== NOT EXECUTED
2005068: aa 10 20 00 clr %l5 ! 0 <PROM_START> <== 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))
200506c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005070: 22 80 00 07 be,a 200508c <rtems_termios_read+0x2c0> <== NOT EXECUTED
2005074: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
== (FL_MDXON | FL_ISNTXOF))
&& ((tty->rawOutBufState == rob_idle)
|| (tty->flow_ctrl & FL_OSTOP))) {
2005078: 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))
200507c: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED
2005080: 02 bf ff c6 be 2004f98 <rtems_termios_read+0x1cc> <== NOT EXECUTED
2005084: 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,
2005088: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
200508c: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
2005090: 92 10 00 17 mov %l7, %o1 <== NOT EXECUTED
2005094: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005098: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
}
}
}
/* continue processing new character */
if (tty->termios.c_lflag & ICANON) {
200509c: 10 bf ff cd b 2004fd0 <rtems_termios_read+0x204> <== NOT EXECUTED
20050a0: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
static rtems_status_code
fillBufferPoll (struct rtems_termios_tty *tty)
{
int n;
if (tty->termios.c_lflag & ICANON) {
20050a4: 80 88 a0 02 btst 2, %g2
20050a8: 02 80 00 0e be 20050e0 <rtems_termios_read+0x314>
20050ac: 01 00 00 00 nop
for (;;) {
n = (*tty->device.pollRead)(tty->minor);
20050b0: 9f c0 40 00 call %g1
20050b4: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
if (n < 0) {
20050b8: 80 a2 20 00 cmp %o0, 0
20050bc: 06 80 00 3a bl 20051a4 <rtems_termios_read+0x3d8> <== ALWAYS TAKEN
20050c0: 90 0a 20 ff and %o0, 0xff, %o0
rtems_task_wake_after (1);
}
else {
if (siproc (n, tty))
20050c4: 7f ff fe d5 call 2004c18 <siproc> <== NOT EXECUTED
20050c8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
20050cc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
20050d0: 12 bf ff 62 bne 2004e58 <rtems_termios_read+0x8c> <== NOT EXECUTED
20050d4: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
static rtems_status_code
fillBufferPoll (struct rtems_termios_tty *tty)
{
int n;
if (tty->termios.c_lflag & ICANON) {
20050d8: 10 bf ff f6 b 20050b0 <rtems_termios_read+0x2e4> <== NOT EXECUTED
20050dc: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
}
}
}
else {
rtems_interval then, now;
then = rtems_clock_get_ticks_since_boot();
20050e0: 40 00 04 3c call 20061d0 <rtems_clock_get_ticks_since_boot>
20050e4: 01 00 00 00 nop
20050e8: a2 10 00 08 mov %o0, %l1
for (;;) {
n = (*tty->device.pollRead)(tty->minor);
20050ec: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
20050f0: 9f c0 40 00 call %g1
20050f4: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
if (n < 0) {
20050f8: 80 a2 20 00 cmp %o0, 0
20050fc: 06 80 00 10 bl 200513c <rtems_termios_read+0x370> <== ALWAYS TAKEN
2005100: 90 0a 20 ff and %o0, 0xff, %o0
}
}
rtems_task_wake_after (1);
}
else {
siproc (n, tty);
2005104: 7f ff fe c5 call 2004c18 <siproc> <== NOT EXECUTED
2005108: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
200510c: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED
2005110: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED
2005114: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2005118: 16 bf ff 4f bge 2004e54 <rtems_termios_read+0x88> <== NOT EXECUTED
200511c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
break;
if (tty->termios.c_cc[VMIN] && tty->termios.c_cc[VTIME])
2005120: 22 bf ff f4 be,a 20050f0 <rtems_termios_read+0x324> <== NOT EXECUTED
2005124: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
2005128: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1 <== NOT EXECUTED
200512c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005130: 22 bf ff f0 be,a 20050f0 <rtems_termios_read+0x324> <== NOT EXECUTED
2005134: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
2005138: 30 bf ff ea b,a 20050e0 <rtems_termios_read+0x314> <== NOT EXECUTED
rtems_interval then, now;
then = rtems_clock_get_ticks_since_boot();
for (;;) {
n = (*tty->device.pollRead)(tty->minor);
if (n < 0) {
if (tty->termios.c_cc[VMIN]) {
200513c: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1
2005140: 80 a0 60 00 cmp %g1, 0
2005144: 02 80 00 0d be 2005178 <rtems_termios_read+0x3ac> <== NEVER TAKEN
2005148: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1
if (tty->termios.c_cc[VTIME] && tty->ccount) {
200514c: 80 a0 60 00 cmp %g1, 0
2005150: 02 80 00 06 be 2005168 <rtems_termios_read+0x39c> <== ALWAYS TAKEN
2005154: 01 00 00 00 nop
2005158: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED
200515c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005160: 12 80 00 09 bne 2005184 <rtems_termios_read+0x3b8> <== NOT EXECUTED
2005164: 01 00 00 00 nop <== NOT EXECUTED
now = rtems_clock_get_ticks_since_boot();
if ((now - then) > tty->vtimeTicks) {
break;
}
}
rtems_task_wake_after (1);
2005168: 40 00 07 13 call 2006db4 <rtems_task_wake_after>
200516c: 90 10 20 01 mov 1, %o0 ! 1 <PROM_START+0x1>
}
else {
rtems_interval then, now;
then = rtems_clock_get_ticks_since_boot();
for (;;) {
n = (*tty->device.pollRead)(tty->minor);
2005170: 10 bf ff e0 b 20050f0 <rtems_termios_read+0x324>
2005174: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
break;
}
}
}
else {
if (!tty->termios.c_cc[VTIME])
2005178: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200517c: 02 bf ff 37 be 2004e58 <rtems_termios_read+0x8c> <== NOT EXECUTED
2005180: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
break;
now = rtems_clock_get_ticks_since_boot();
2005184: 40 00 04 13 call 20061d0 <rtems_clock_get_ticks_since_boot><== NOT EXECUTED
2005188: 01 00 00 00 nop <== NOT EXECUTED
if ((now - then) > tty->vtimeTicks) {
200518c: c2 04 20 54 ld [ %l0 + 0x54 ], %g1 <== NOT EXECUTED
2005190: 90 22 00 11 sub %o0, %l1, %o0 <== NOT EXECUTED
2005194: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED
2005198: 08 bf ff f4 bleu 2005168 <rtems_termios_read+0x39c> <== NOT EXECUTED
200519c: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
20051a0: 30 bf ff 2e b,a 2004e58 <rtems_termios_read+0x8c> <== NOT EXECUTED
if (tty->termios.c_lflag & ICANON) {
for (;;) {
n = (*tty->device.pollRead)(tty->minor);
if (n < 0) {
rtems_task_wake_after (1);
20051a4: 40 00 07 04 call 2006db4 <rtems_task_wake_after>
20051a8: 90 10 20 01 mov 1, %o0
static rtems_status_code
fillBufferPoll (struct rtems_termios_tty *tty)
{
int n;
if (tty->termios.c_lflag & ICANON) {
20051ac: 10 bf ff c1 b 20050b0 <rtems_termios_read+0x2e4>
20051b0: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
02003ea8 <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)
{
2003ea8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int nToSend;
rtems_interrupt_level level;
int len;
/* check for XOF/XON to send */
if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))
2003eac: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 <== NOT EXECUTED
2003eb0: 82 08 64 03 and %g1, 0x403, %g1 <== NOT EXECUTED
2003eb4: 80 a0 64 01 cmp %g1, 0x401 <== NOT EXECUTED
2003eb8: 02 80 00 44 be 2003fc8 <rtems_termios_refill_transmitter+0x120><== NOT EXECUTED
2003ebc: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
rtems_interrupt_enable(level);
nToSend = 1;
}
else if ((tty->flow_ctrl & (FL_IREQXOF | FL_ISNTXOF))
2003ec0: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 <== NOT EXECUTED
2003ec4: 82 08 60 03 and %g1, 3, %g1 <== NOT EXECUTED
2003ec8: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
2003ecc: 22 80 00 50 be,a 200400c <rtems_termios_refill_transmitter+0x164><== NOT EXECUTED
2003ed0: c2 06 20 a4 ld [ %i0 + 0xa4 ], %g1 <== NOT EXECUTED
rtems_interrupt_enable(level);
nToSend = 1;
}
else {
if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {
2003ed4: c4 06 20 80 ld [ %i0 + 0x80 ], %g2 <== NOT EXECUTED
2003ed8: c2 06 20 84 ld [ %i0 + 0x84 ], %g1 <== NOT EXECUTED
2003edc: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED
2003ee0: 22 80 00 30 be,a 2003fa0 <rtems_termios_refill_transmitter+0xf8><== NOT EXECUTED
2003ee4: c2 06 20 94 ld [ %i0 + 0x94 ], %g1 <== NOT EXECUTED
rtems_semaphore_release (tty->rawOutBuf.Semaphore);
}
return 0;
}
rtems_interrupt_disable(level);
2003ee8: 7f ff f8 6f call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2003eec: 01 00 00 00 nop <== NOT EXECUTED
len = tty->t_dqlen;
2003ef0: e2 06 20 90 ld [ %i0 + 0x90 ], %l1 <== NOT EXECUTED
tty->t_dqlen = 0;
2003ef4: c0 26 20 90 clr [ %i0 + 0x90 ] <== NOT EXECUTED
rtems_interrupt_enable(level);
2003ef8: 7f ff f8 6f call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2003efc: 01 00 00 00 nop <== NOT EXECUTED
newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;
2003f00: d0 06 20 84 ld [ %i0 + 0x84 ], %o0 <== NOT EXECUTED
2003f04: d2 06 20 88 ld [ %i0 + 0x88 ], %o1 <== NOT EXECUTED
2003f08: 40 00 5c bc call 201b1f8 <.urem> <== NOT EXECUTED
2003f0c: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
tty->rawOutBuf.Tail = newTail;
if (tty->rawOutBufState == rob_wait) {
2003f10: c2 06 20 94 ld [ %i0 + 0x94 ], %g1 <== NOT EXECUTED
len = tty->t_dqlen;
tty->t_dqlen = 0;
rtems_interrupt_enable(level);
newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;
tty->rawOutBuf.Tail = newTail;
2003f14: d0 24 20 84 st %o0, [ %l0 + 0x84 ] <== NOT EXECUTED
if (tty->rawOutBufState == rob_wait) {
2003f18: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
2003f1c: 02 80 00 55 be 2004070 <rtems_termios_refill_transmitter+0x1c8><== NOT EXECUTED
2003f20: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
/*
* wake up any pending writer task
*/
rtems_semaphore_release (tty->rawOutBuf.Semaphore);
}
if (newTail == tty->rawOutBuf.Head) {
2003f24: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 <== NOT EXECUTED
2003f28: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED
2003f2c: 22 80 00 48 be,a 200404c <rtems_termios_refill_transmitter+0x1a4><== NOT EXECUTED
2003f30: c2 04 20 d4 ld [ %l0 + 0xd4 ], %g1 <== NOT EXECUTED
if ( tty->tty_snd.sw_pfn != NULL) {
(*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg);
}
}
/* check, whether output should stop due to received XOFF */
else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF))
2003f34: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2003f38: 82 08 62 10 and %g1, 0x210, %g1 <== NOT EXECUTED
2003f3c: 80 a0 62 10 cmp %g1, 0x210 <== NOT EXECUTED
2003f40: 02 80 00 4f be 200407c <rtems_termios_refill_transmitter+0x1d4><== NOT EXECUTED
2003f44: 01 00 00 00 nop <== NOT EXECUTED
}
else {
/*
* Buffer not empty, start tranmitter
*/
if (newTail > tty->rawOutBuf.Head)
2003f48: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 <== NOT EXECUTED
2003f4c: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED
2003f50: 18 80 00 1b bgu 2003fbc <rtems_termios_refill_transmitter+0x114><== NOT EXECUTED
2003f54: 01 00 00 00 nop <== NOT EXECUTED
nToSend = tty->rawOutBuf.Size - newTail;
else
nToSend = tty->rawOutBuf.Head - newTail;
2003f58: f0 04 20 80 ld [ %l0 + 0x80 ], %i0 <== NOT EXECUTED
2003f5c: b0 26 00 11 sub %i0, %l1, %i0 <== NOT EXECUTED
/* when flow control XON or XOF, don't send blocks of data */
/* to allow fast reaction on incoming flow ctrl and low latency*/
/* for outgoing flow control */
if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) {
2003f60: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
2003f64: 80 88 66 00 btst 0x600, %g1 <== NOT EXECUTED
2003f68: 02 80 00 04 be 2003f78 <rtems_termios_refill_transmitter+0xd0><== NOT EXECUTED
2003f6c: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
2003f70: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2003f74: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
nToSend = 1;
}
tty->rawOutBufState = rob_busy; /*apm*/
(*tty->device.write)(tty->minor,
2003f78: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 <== NOT EXECUTED
2003f7c: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
2003f80: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
/* 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*/
2003f84: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2003f88: 92 02 40 11 add %o1, %l1, %o1 <== NOT EXECUTED
2003f8c: 9f c0 40 00 call %g1 <== NOT EXECUTED
2003f90: c4 24 20 94 st %g2, [ %l0 + 0x94 ] <== NOT EXECUTED
&tty->rawOutBuf.theBuf[newTail],
nToSend);
}
tty->rawOutBuf.Tail = newTail; /*apm*/
2003f94: e2 24 20 84 st %l1, [ %l0 + 0x84 ] <== NOT EXECUTED
}
return nToSend;
}
2003f98: 81 c7 e0 08 ret <== NOT EXECUTED
2003f9c: 81 e8 00 00 restore <== NOT EXECUTED
else {
if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {
/*
* buffer was empty
*/
if (tty->rawOutBufState == rob_wait) {
2003fa0: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
2003fa4: 12 bf ff fd bne 2003f98 <rtems_termios_refill_transmitter+0xf0><== NOT EXECUTED
2003fa8: b0 10 20 00 clr %i0 <== NOT EXECUTED
/*
* this should never happen...
*/
rtems_semaphore_release (tty->rawOutBuf.Semaphore);
2003fac: 40 00 0a 91 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2003fb0: d0 04 20 8c ld [ %l0 + 0x8c ], %o0 <== NOT EXECUTED
2003fb4: 81 c7 e0 08 ret <== NOT EXECUTED
2003fb8: 81 e8 00 00 restore <== NOT EXECUTED
else {
/*
* Buffer not empty, start tranmitter
*/
if (newTail > tty->rawOutBuf.Head)
nToSend = tty->rawOutBuf.Size - newTail;
2003fbc: f0 04 20 88 ld [ %l0 + 0x88 ], %i0 <== NOT EXECUTED
2003fc0: 10 bf ff e8 b 2003f60 <rtems_termios_refill_transmitter+0xb8><== NOT EXECUTED
2003fc4: b0 26 00 11 sub %i0, %l1, %i0 <== NOT EXECUTED
/* check for XOF/XON to send */
if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))
== (FL_MDXOF | FL_IREQXOF)) {
/* XOFF should be sent now... */
(*tty->device.write)(tty->minor,
2003fc8: c2 06 20 a4 ld [ %i0 + 0xa4 ], %g1 <== NOT EXECUTED
2003fcc: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
2003fd0: 92 06 20 4a add %i0, 0x4a, %o1 <== NOT EXECUTED
2003fd4: 9f c0 40 00 call %g1 <== NOT EXECUTED
2003fd8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTOP]), 1);
rtems_interrupt_disable(level);
2003fdc: 7f ff f8 32 call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2003fe0: 01 00 00 00 nop <== NOT EXECUTED
tty->t_dqlen--;
2003fe4: c4 06 20 90 ld [ %i0 + 0x90 ], %g2 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
2003fe8: 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--;
2003fec: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
2003ff0: 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--;
2003ff4: c4 26 20 90 st %g2, [ %i0 + 0x90 ] <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
2003ff8: c2 26 20 b8 st %g1, [ %i0 + 0xb8 ] <== NOT EXECUTED
rtems_interrupt_enable(level);
2003ffc: 7f ff f8 2e call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004000: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2004004: 81 c7 e0 08 ret <== NOT EXECUTED
2004008: 81 e8 00 00 restore <== NOT EXECUTED
* FIXME: this .write call will generate another
* dequeue callback. This will advance the "Tail" in the data
* buffer, although the corresponding data is not yet out!
* Therefore the dequeue "length" should be reduced by 1
*/
(*tty->device.write)(tty->minor,
200400c: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
2004010: 92 06 20 49 add %i0, 0x49, %o1 <== NOT EXECUTED
2004014: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004018: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTART]), 1);
rtems_interrupt_disable(level);
200401c: 7f ff f8 22 call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2004020: 01 00 00 00 nop <== NOT EXECUTED
tty->t_dqlen--;
2004024: c4 06 20 90 ld [ %i0 + 0x90 ], %g2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2004028: 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--;
200402c: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2004030: 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--;
2004034: c4 26 20 90 st %g2, [ %i0 + 0x90 ] <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2004038: c2 26 20 b8 st %g1, [ %i0 + 0xb8 ] <== NOT EXECUTED
rtems_interrupt_enable(level);
200403c: 7f ff f8 1e call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
2004040: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
2004044: 81 c7 e0 08 ret <== NOT EXECUTED
2004048: 81 e8 00 00 restore <== NOT EXECUTED
}
if (newTail == tty->rawOutBuf.Head) {
/*
* Buffer has become empty
*/
tty->rawOutBufState = rob_idle;
200404c: c0 24 20 94 clr [ %l0 + 0x94 ] <== NOT EXECUTED
nToSend = 0;
/*
* check to see if snd wakeup callback was set
*/
if ( tty->tty_snd.sw_pfn != NULL) {
2004050: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2004054: 02 bf ff d0 be 2003f94 <rtems_termios_refill_transmitter+0xec><== NOT EXECUTED
2004058: b0 10 20 00 clr %i0 <== NOT EXECUTED
(*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg);
200405c: d2 04 20 d8 ld [ %l0 + 0xd8 ], %o1 <== NOT EXECUTED
2004060: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004064: 90 04 20 30 add %l0, 0x30, %o0 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
(*tty->device.write)(tty->minor,
&tty->rawOutBuf.theBuf[newTail],
nToSend);
}
tty->rawOutBuf.Tail = newTail; /*apm*/
2004068: e2 24 20 84 st %l1, [ %l0 + 0x84 ] <== NOT EXECUTED
200406c: 30 bf ff f6 b,a 2004044 <rtems_termios_refill_transmitter+0x19c><== NOT EXECUTED
tty->rawOutBuf.Tail = newTail;
if (tty->rawOutBufState == rob_wait) {
/*
* wake up any pending writer task
*/
rtems_semaphore_release (tty->rawOutBuf.Semaphore);
2004070: 40 00 0a 60 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004074: d0 06 20 8c ld [ %i0 + 0x8c ], %o0 <== NOT EXECUTED
2004078: 30 bf ff ab b,a 2003f24 <rtems_termios_refill_transmitter+0x7c><== NOT EXECUTED
/* check, whether output should stop due to received XOFF */
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);
200407c: 7f ff f8 0a call 20020a4 <sparc_disable_interrupts> <== NOT EXECUTED
2004080: 01 00 00 00 nop <== NOT EXECUTED
tty->flow_ctrl |= FL_OSTOP;
2004084: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
2004088: 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;
200408c: 82 10 60 20 or %g1, 0x20, %g1 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
2004090: 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;
2004094: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
rtems_interrupt_enable(level);
2004098: 7f ff f8 07 call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
200409c: b0 10 20 00 clr %i0 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
(*tty->device.write)(tty->minor,
&tty->rawOutBuf.theBuf[newTail],
nToSend);
}
tty->rawOutBuf.Tail = newTail; /*apm*/
20040a0: e2 24 20 84 st %l1, [ %l0 + 0x84 ] <== NOT EXECUTED
20040a4: 30 bf ff e8 b,a 2004044 <rtems_termios_refill_transmitter+0x19c><== NOT EXECUTED
02005ca0 <rtems_termios_rxdaemon>:
/*
* this task actually processes any receive events
*/
static rtems_task rtems_termios_rxdaemon(rtems_task_argument argument)
{
2005ca0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
2005ca4: a0 07 bf f8 add %fp, -8, %l0 <== NOT EXECUTED
2005ca8: a2 07 bf ff add %fp, -1, %l1 <== NOT EXECUTED
char c_buf;
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2005cac: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2005cb0: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2005cb4: 94 10 20 00 clr %o2 <== NOT EXECUTED
2005cb8: 40 00 01 69 call 200625c <rtems_event_receive> <== NOT EXECUTED
2005cbc: 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) {
2005cc0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2005cc4: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2005cc8: 32 80 00 16 bne,a 2005d20 <rtems_termios_rxdaemon+0x80> <== NOT EXECUTED
2005ccc: c0 26 20 c4 clr [ %i0 + 0xc4 ] <== NOT EXECUTED
}
else {
/*
* do something
*/
c = tty->device.pollRead(tty->minor);
2005cd0: c2 06 20 a0 ld [ %i0 + 0xa0 ], %g1 <== NOT EXECUTED
2005cd4: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005cd8: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
if (c != EOF) {
2005cdc: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED
2005ce0: 02 bf ff f3 be 2005cac <rtems_termios_rxdaemon+0xc> <== NOT EXECUTED
2005ce4: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
/*
* pollRead did call enqueue on its own
*/
c_buf = c;
2005ce8: d0 2f bf ff stb %o0, [ %fp + -1 ] <== NOT EXECUTED
rtems_termios_enqueue_raw_characters (
2005cec: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
2005cf0: 7f ff f9 0d call 2004124 <rtems_termios_enqueue_raw_characters><== NOT EXECUTED
2005cf4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
char c_buf;
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2005cf8: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2005cfc: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2005d00: 94 10 20 00 clr %o2 <== NOT EXECUTED
2005d04: 40 00 01 56 call 200625c <rtems_event_receive> <== NOT EXECUTED
2005d08: 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) {
2005d0c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
2005d10: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2005d14: 22 bf ff f0 be,a 2005cd4 <rtems_termios_rxdaemon+0x34> <== NOT EXECUTED
2005d18: c2 06 20 a0 ld [ %i0 + 0xa0 ], %g1 <== NOT EXECUTED
tty->rxTaskId = 0;
2005d1c: c0 26 20 c4 clr [ %i0 + 0xc4 ] <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
2005d20: 40 00 03 ab call 2006bcc <rtems_task_delete> <== NOT EXECUTED
2005d24: 90 10 20 00 clr %o0 <== NOT EXECUTED
char c_buf;
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2005d28: 10 bf ff e2 b 2005cb0 <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED
2005d2c: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
02003e90 <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);
2003e90: d0 02 20 c4 ld [ %o0 + 0xc4 ], %o0 <== NOT EXECUTED
2003e94: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2003e98: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED
2003e9c: 40 00 09 51 call 20063e0 <rtems_event_send> <== NOT EXECUTED
2003ea0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02005c08 <rtems_termios_txdaemon>:
/*
* this task actually processes any transmit events
*/
static rtems_task rtems_termios_txdaemon(rtems_task_argument argument)
{
2005c08: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
2005c0c: 23 00 80 7b sethi %hi(0x201ec00), %l1 <== NOT EXECUTED
2005c10: a0 07 bf fc add %fp, -4, %l0 <== NOT EXECUTED
2005c14: a2 14 63 40 or %l1, 0x340, %l1 <== NOT EXECUTED
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_TX_START_EVENT |
2005c18: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2005c1c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2005c20: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2005c24: 40 00 01 8e call 200625c <rtems_event_receive> <== NOT EXECUTED
2005c28: 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) {
2005c2c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2005c30: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2005c34: 12 80 00 16 bne 2005c8c <rtems_termios_txdaemon+0x84> <== NOT EXECUTED
2005c38: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
}
else {
/*
* call any line discipline start function
*/
if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
2005c3c: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 <== NOT EXECUTED
2005c40: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED
2005c44: 82 04 40 01 add %l1, %g1, %g1 <== NOT EXECUTED
2005c48: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 <== NOT EXECUTED
2005c4c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2005c50: 02 80 00 04 be 2005c60 <rtems_termios_txdaemon+0x58> <== NOT EXECUTED
2005c54: 01 00 00 00 nop <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
2005c58: 9f c0 40 00 call %g1 <== NOT EXECUTED
2005c5c: 01 00 00 00 nop <== NOT EXECUTED
}
/*
* try to push further characters to device
*/
rtems_termios_refill_transmitter(tty);
2005c60: 7f ff f8 92 call 2003ea8 <rtems_termios_refill_transmitter><== NOT EXECUTED
2005c64: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_TX_START_EVENT |
2005c68: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
2005c6c: 94 10 20 00 clr %o2 <== NOT EXECUTED
2005c70: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
2005c74: 40 00 01 7a call 200625c <rtems_event_receive> <== NOT EXECUTED
2005c78: 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) {
2005c7c: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED
2005c80: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED
2005c84: 02 bf ff ee be 2005c3c <rtems_termios_txdaemon+0x34> <== NOT EXECUTED
2005c88: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
tty->txTaskId = 0;
2005c8c: c0 26 20 c8 clr [ %i0 + 0xc8 ] <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
2005c90: 40 00 03 cf call 2006bcc <rtems_task_delete> <== NOT EXECUTED
2005c94: 90 10 20 00 clr %o0 <== NOT EXECUTED
while (1) {
/*
* wait for rtems event
*/
rtems_event_receive((TERMIOS_TX_START_EVENT |
2005c98: 10 bf ff e1 b 2005c1c <rtems_termios_txdaemon+0x14> <== NOT EXECUTED
2005c9c: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
02004c64 <rtems_termios_write>:
rtems_termios_puts (&c, 1, tty);
}
rtems_status_code
rtems_termios_write (void *arg)
{
2004c64: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_rw_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
2004c68: c2 06 00 00 ld [ %i0 ], %g1
rtems_status_code sc;
sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004c6c: 92 10 20 00 clr %o1
rtems_status_code
rtems_termios_write (void *arg)
{
rtems_libio_rw_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
2004c70: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
rtems_status_code sc;
sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004c74: 94 10 20 00 clr %o2
2004c78: 40 00 07 17 call 20068d4 <rtems_semaphore_obtain>
2004c7c: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
if (sc != RTEMS_SUCCESSFUL)
2004c80: a2 92 20 00 orcc %o0, 0, %l1
2004c84: 12 80 00 0f bne 2004cc0 <rtems_termios_write+0x5c> <== NEVER TAKEN
2004c88: 03 00 80 7b sethi %hi(0x201ec00), %g1
return sc;
if (rtems_termios_linesw[tty->t_line].l_write != NULL) {
2004c8c: c4 04 20 cc ld [ %l0 + 0xcc ], %g2
2004c90: 85 28 a0 05 sll %g2, 5, %g2
2004c94: 82 10 63 40 or %g1, 0x340, %g1
2004c98: 82 00 40 02 add %g1, %g2, %g1
2004c9c: c2 00 60 0c ld [ %g1 + 0xc ], %g1
2004ca0: 80 a0 60 00 cmp %g1, 0
2004ca4: 02 80 00 09 be 2004cc8 <rtems_termios_write+0x64> <== ALWAYS TAKEN
2004ca8: 92 10 00 18 mov %i0, %o1
sc = rtems_termios_linesw[tty->t_line].l_write(tty,args);
2004cac: 9f c0 40 00 call %g1 <== NOT EXECUTED
2004cb0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
2004cb4: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
rtems_semaphore_release (tty->osem);
2004cb8: 40 00 07 4e call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004cbc: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 <== NOT EXECUTED
rtems_termios_puts (args->buffer, args->count, tty);
args->bytes_moved = args->count;
}
rtems_semaphore_release (tty->osem);
return sc;
}
2004cc0: 81 c7 e0 08 ret <== NOT EXECUTED
2004cc4: 91 e8 00 11 restore %g0, %l1, %o0 <== NOT EXECUTED
if (rtems_termios_linesw[tty->t_line].l_write != NULL) {
sc = rtems_termios_linesw[tty->t_line].l_write(tty,args);
rtems_semaphore_release (tty->osem);
return sc;
}
if (tty->termios.c_oflag & OPOST) {
2004cc8: c2 04 20 34 ld [ %l0 + 0x34 ], %g1
2004ccc: 80 88 60 01 btst 1, %g1
2004cd0: 22 80 00 16 be,a 2004d28 <rtems_termios_write+0xc4> <== NEVER TAKEN
2004cd4: d0 1e 20 10 ldd [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
uint32_t count = args->count;
2004cd8: e6 06 20 14 ld [ %i0 + 0x14 ], %l3
char *buffer = args->buffer;
2004cdc: e8 06 20 10 ld [ %i0 + 0x10 ], %l4
while (count--)
2004ce0: 80 a4 e0 00 cmp %l3, 0
2004ce4: a4 10 20 00 clr %l2
2004ce8: 02 80 00 0a be 2004d10 <rtems_termios_write+0xac> <== NEVER TAKEN
2004cec: 82 10 20 00 clr %g1
oproc (*buffer++, tty);
2004cf0: d0 0d 00 12 ldub [ %l4 + %l2 ], %o0
2004cf4: 7f ff fe 2f call 20045b0 <oproc>
2004cf8: 92 10 00 10 mov %l0, %o1
2004cfc: a4 04 a0 01 inc %l2
return sc;
}
if (tty->termios.c_oflag & OPOST) {
uint32_t count = args->count;
char *buffer = args->buffer;
while (count--)
2004d00: 80 a4 80 13 cmp %l2, %l3
2004d04: 32 bf ff fc bne,a 2004cf4 <rtems_termios_write+0x90>
2004d08: d0 0d 00 12 ldub [ %l4 + %l2 ], %o0
oproc (*buffer++, tty);
args->bytes_moved = args->count;
}
else {
rtems_termios_puts (args->buffer, args->count, tty);
args->bytes_moved = args->count;
2004d0c: c2 06 20 14 ld [ %i0 + 0x14 ], %g1
2004d10: c2 26 20 1c st %g1, [ %i0 + 0x1c ]
}
rtems_semaphore_release (tty->osem);
2004d14: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
2004d18: 40 00 07 36 call 20069f0 <rtems_semaphore_release>
2004d1c: b0 10 00 11 mov %l1, %i0
return sc;
}
2004d20: 81 c7 e0 08 ret
2004d24: 81 e8 00 00 restore
while (count--)
oproc (*buffer++, tty);
args->bytes_moved = args->count;
}
else {
rtems_termios_puts (args->buffer, args->count, tty);
2004d28: 7f ff fd d3 call 2004474 <rtems_termios_puts> <== NOT EXECUTED
2004d2c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
args->bytes_moved = args->count;
2004d30: 10 bf ff f8 b 2004d10 <rtems_termios_write+0xac> <== NOT EXECUTED
2004d34: c2 06 20 14 ld [ %i0 + 0x14 ], %g1 <== NOT EXECUTED
02016778 <rtems_timer_cancel>:
*/
rtems_status_code rtems_timer_cancel(
rtems_id id
)
{
2016778: 9d e3 bf 98 save %sp, -104, %sp
RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get (
Objects_Id id,
Objects_Locations *location
)
{
return (Timer_Control *)
201677c: 11 00 81 05 sethi %hi(0x2041400), %o0
2016780: 92 10 00 18 mov %i0, %o1
2016784: 90 12 22 94 or %o0, 0x294, %o0
2016788: 40 00 0b f5 call 201975c <_Objects_Get>
201678c: 94 07 bf fc add %fp, -4, %o2
Timer_Control *the_timer;
Objects_Locations location;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
2016790: c2 07 bf fc ld [ %fp + -4 ], %g1
2016794: 80 a0 60 00 cmp %g1, 0
2016798: 12 80 00 0a bne 20167c0 <rtems_timer_cancel+0x48>
201679c: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
if ( !_Timer_Is_dormant_class( the_timer->the_class ) )
20167a0: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
20167a4: 80 a0 60 04 cmp %g1, 4
20167a8: 02 80 00 04 be 20167b8 <rtems_timer_cancel+0x40> <== NEVER TAKEN
20167ac: 01 00 00 00 nop
(void) _Watchdog_Remove( &the_timer->Ticker );
20167b0: 40 00 15 4a call 201bcd8 <_Watchdog_Remove>
20167b4: 90 02 20 10 add %o0, 0x10, %o0
_Thread_Enable_dispatch();
20167b8: 40 00 0e bf call 201a2b4 <_Thread_Enable_dispatch>
20167bc: b0 10 20 00 clr %i0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
20167c0: 81 c7 e0 08 ret
20167c4: 81 e8 00 00 restore
02016c84 <rtems_timer_server_fire_when>:
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
2016c84: 9d e3 bf 98 save %sp, -104, %sp
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
2016c88: 03 00 81 05 sethi %hi(0x2041400), %g1
2016c8c: e0 00 62 d4 ld [ %g1 + 0x2d4 ], %l0 ! 20416d4 <_Timer_server>
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
2016c90: a2 10 00 18 mov %i0, %l1
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
2016c94: 80 a4 20 00 cmp %l0, 0
2016c98: 02 80 00 34 be 2016d68 <rtems_timer_server_fire_when+0xe4>
2016c9c: b0 10 20 0e mov 0xe, %i0
return RTEMS_INCORRECT_STATE;
if ( !_TOD_Is_set )
2016ca0: 03 00 81 03 sethi %hi(0x2040c00), %g1
2016ca4: c2 08 60 f4 ldub [ %g1 + 0xf4 ], %g1 ! 2040cf4 <_TOD_Is_set>
2016ca8: 80 a0 60 00 cmp %g1, 0
2016cac: 02 80 00 2f be 2016d68 <rtems_timer_server_fire_when+0xe4><== NEVER TAKEN
2016cb0: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( !routine )
2016cb4: 80 a6 a0 00 cmp %i2, 0
2016cb8: 02 80 00 2c be 2016d68 <rtems_timer_server_fire_when+0xe4>
2016cbc: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
2016cc0: 7f ff f3 d6 call 2013c18 <_TOD_Validate>
2016cc4: 90 10 00 19 mov %i1, %o0
2016cc8: 80 8a 20 ff btst 0xff, %o0
2016ccc: 12 80 00 04 bne 2016cdc <rtems_timer_server_fire_when+0x58>
2016cd0: 01 00 00 00 nop
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2016cd4: 81 c7 e0 08 ret
2016cd8: 91 e8 20 14 restore %g0, 0x14, %o0
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( wall_time );
2016cdc: 7f ff f3 99 call 2013b40 <_TOD_To_seconds>
2016ce0: 90 10 00 19 mov %i1, %o0
if ( seconds <= _TOD_Seconds_since_epoch() )
2016ce4: 25 00 81 03 sethi %hi(0x2040c00), %l2
2016ce8: c2 04 a1 74 ld [ %l2 + 0x174 ], %g1 ! 2040d74 <_TOD_Now>
2016cec: 80 a2 00 01 cmp %o0, %g1
2016cf0: 08 bf ff f9 bleu 2016cd4 <rtems_timer_server_fire_when+0x50>
2016cf4: b2 10 00 08 mov %o0, %i1
2016cf8: 11 00 81 05 sethi %hi(0x2041400), %o0
2016cfc: 92 10 00 11 mov %l1, %o1
2016d00: 90 12 22 94 or %o0, 0x294, %o0
2016d04: 40 00 0a 96 call 201975c <_Objects_Get>
2016d08: 94 07 bf fc add %fp, -4, %o2
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
2016d0c: c2 07 bf fc ld [ %fp + -4 ], %g1
2016d10: a6 10 00 08 mov %o0, %l3
2016d14: 80 a0 60 00 cmp %g1, 0
2016d18: 12 80 00 14 bne 2016d68 <rtems_timer_server_fire_when+0xe4>
2016d1c: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
2016d20: 40 00 13 ee call 201bcd8 <_Watchdog_Remove>
2016d24: 90 02 20 10 add %o0, 0x10, %o0
the_watchdog->routine = routine;
the_watchdog->id = id;
2016d28: e2 24 e0 30 st %l1, [ %l3 + 0x30 ]
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d2c: c4 04 a1 74 ld [ %l2 + 0x174 ], %g2
(*timer_server->schedule_operation)( timer_server, the_timer );
2016d30: c2 04 20 04 ld [ %l0 + 4 ], %g1
2016d34: 90 10 00 10 mov %l0, %o0
2016d38: 92 10 00 13 mov %l3, %o1
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d3c: b2 26 40 02 sub %i1, %g2, %i1
the_timer = _Timer_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
2016d40: 84 10 20 03 mov 3, %g2
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2016d44: f4 24 e0 2c st %i2, [ %l3 + 0x2c ]
2016d48: c4 24 e0 38 st %g2, [ %l3 + 0x38 ]
the_watchdog->id = id;
the_watchdog->user_data = user_data;
2016d4c: f6 24 e0 34 st %i3, [ %l3 + 0x34 ]
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d50: f2 24 e0 1c st %i1, [ %l3 + 0x1c ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2016d54: c0 24 e0 18 clr [ %l3 + 0x18 ]
(*timer_server->schedule_operation)( timer_server, the_timer );
2016d58: 9f c0 40 00 call %g1
2016d5c: b0 10 20 00 clr %i0
_Thread_Enable_dispatch();
2016d60: 40 00 0d 55 call 201a2b4 <_Thread_Enable_dispatch>
2016d64: 01 00 00 00 nop
return RTEMS_SUCCESSFUL;
2016d68: 81 c7 e0 08 ret
2016d6c: 81 e8 00 00 restore
02007d00 <rtems_verror>:
static int rtems_verror(
rtems_error_code_t error_flag,
const char *printf_format,
va_list arglist
)
{
2007d00: 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)
2007d04: 29 08 00 00 sethi %hi(0x20000000), %l4 <== NOT EXECUTED
2007d08: a8 8e 00 14 andcc %i0, %l4, %l4 <== NOT EXECUTED
2007d0c: 02 80 00 0f be 2007d48 <rtems_verror+0x48> <== NOT EXECUTED
2007d10: 05 00 80 a3 sethi %hi(0x2028c00), %g2 <== NOT EXECUTED
{
if (rtems_panic_in_progress++)
2007d14: c6 00 a0 9c ld [ %g2 + 0x9c ], %g3 ! 2028c9c <rtems_panic_in_progress><== NOT EXECUTED
2007d18: 82 00 e0 01 add %g3, 1, %g1 <== NOT EXECUTED
2007d1c: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED
2007d20: 02 80 00 07 be 2007d3c <rtems_verror+0x3c> <== NOT EXECUTED
2007d24: c2 20 a0 9c st %g1, [ %g2 + 0x9c ] <== NOT EXECUTED
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2007d28: 03 00 80 a3 sethi %hi(0x2028c00), %g1 <== NOT EXECUTED
2007d2c: c6 00 62 70 ld [ %g1 + 0x270 ], %g3 ! 2028e70 <_Thread_Dispatch_disable_level><== NOT EXECUTED
2007d30: 86 00 e0 01 inc %g3 <== NOT EXECUTED
2007d34: c6 20 62 70 st %g3, [ %g1 + 0x270 ] <== NOT EXECUTED
RTEMS_COMPILER_MEMORY_BARRIER();
2007d38: c2 00 a0 9c ld [ %g2 + 0x9c ], %g1 <== NOT EXECUTED
_Thread_Disable_dispatch(); /* disable task switches */
/* don't aggravate things */
if (rtems_panic_in_progress > 2)
2007d3c: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
2007d40: 14 80 00 3c bg 2007e30 <rtems_verror+0x130> <== NOT EXECUTED
2007d44: a4 10 20 00 clr %l2 <== NOT EXECUTED
return 0;
}
(void) fflush(stdout); /* in case stdout/stderr same */
2007d48: 21 00 80 a1 sethi %hi(0x2028400), %l0 <== NOT EXECUTED
2007d4c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 ! 2028410 <_impure_ptr><== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK;
2007d50: 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 */
2007d54: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
2007d58: 40 00 3f 07 call 2017974 <fflush> <== NOT EXECUTED
2007d5c: a2 10 20 00 clr %l1 <== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK;
if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */
2007d60: 03 10 00 00 sethi %hi(0x40000000), %g1 <== NOT EXECUTED
2007d64: 80 8e 00 01 btst %i0, %g1 <== NOT EXECUTED
2007d68: 12 80 00 45 bne 2007e7c <rtems_verror+0x17c> <== NOT EXECUTED
2007d6c: a6 2e 00 13 andn %i0, %l3, %l3 <== 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);
2007d70: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2007d74: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2007d78: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
2007d7c: 40 00 56 85 call 201d790 <vfprintf> <== NOT EXECUTED
2007d80: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (status)
2007d84: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
2007d88: 12 80 00 31 bne 2007e4c <rtems_verror+0x14c> <== NOT EXECUTED
2007d8c: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
if (local_errno)
2007d90: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2007d94: 02 80 00 12 be 2007ddc <rtems_verror+0xdc> <== NOT EXECUTED
2007d98: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
{
if ((local_errno > 0) && *strerror(local_errno))
2007d9c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
2007da0: 04 80 00 09 ble 2007dc4 <rtems_verror+0xc4> <== NOT EXECUTED
2007da4: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007da8: 40 00 43 1a call 2018a10 <strerror> <== NOT EXECUTED
2007dac: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2007db0: c2 4a 00 00 ldsb [ %o0 ], %g1 <== NOT EXECUTED
2007db4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2007db8: 12 80 00 35 bne 2007e8c <rtems_verror+0x18c> <== NOT EXECUTED
2007dbc: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno));
else
chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno);
2007dc0: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007dc4: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
2007dc8: 92 12 62 48 or %o1, 0x248, %o1 <== NOT EXECUTED
2007dcc: 40 00 3f be call 2017cc4 <fprintf> <== NOT EXECUTED
2007dd0: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED
2007dd4: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
}
chars_written += fprintf(stderr, "\n");
2007dd8: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED
2007ddc: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007de0: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
2007de4: 40 00 3f b8 call 2017cc4 <fprintf> <== NOT EXECUTED
2007de8: 92 12 62 60 or %o1, 0x260, %o1 <== NOT EXECUTED
(void) fflush(stderr);
2007dec: c2 04 20 10 ld [ %l0 + 0x10 ], %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");
2007df0: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
(void) fflush(stderr);
2007df4: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED
2007df8: 40 00 3e df call 2017974 <fflush> <== NOT EXECUTED
2007dfc: a4 04 c0 12 add %l3, %l2, %l2 <== NOT EXECUTED
if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT))
2007e00: 03 0c 00 00 sethi %hi(0x30000000), %g1 <== NOT EXECUTED
2007e04: 80 8e 00 01 btst %i0, %g1 <== NOT EXECUTED
2007e08: 02 80 00 0a be 2007e30 <rtems_verror+0x130> <== NOT EXECUTED
2007e0c: 80 a5 20 00 cmp %l4, 0 <== NOT EXECUTED
{
if (error_flag & RTEMS_ERROR_PANIC)
2007e10: 22 80 00 0a be,a 2007e38 <rtems_verror+0x138> <== NOT EXECUTED
2007e14: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
{
rtems_error(0, "fatal error, exiting");
2007e18: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007e1c: 90 10 20 00 clr %o0 <== NOT EXECUTED
2007e20: 40 00 00 32 call 2007ee8 <rtems_error> <== NOT EXECUTED
2007e24: 92 12 62 68 or %o1, 0x268, %o1 <== NOT EXECUTED
_exit(local_errno);
2007e28: 40 00 03 58 call 2008b88 <_exit> <== NOT EXECUTED
2007e2c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_error(0, "fatal error, aborting");
abort();
}
}
return chars_written;
}
2007e30: 81 c7 e0 08 ret <== NOT EXECUTED
2007e34: 91 e8 00 12 restore %g0, %l2, %o0 <== NOT EXECUTED
rtems_error(0, "fatal error, exiting");
_exit(local_errno);
}
else
{
rtems_error(0, "fatal error, aborting");
2007e38: 90 10 20 00 clr %o0 <== NOT EXECUTED
2007e3c: 40 00 00 2b call 2007ee8 <rtems_error> <== NOT EXECUTED
2007e40: 92 12 62 80 or %o1, 0x280, %o1 <== NOT EXECUTED
abort();
2007e44: 40 00 3d b4 call 2017514 <abort> <== NOT EXECUTED
2007e48: 01 00 00 00 nop <== NOT EXECUTED
#endif
chars_written += vfprintf(stderr, printf_format, arglist);
if (status)
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
2007e4c: 03 00 80 a1 sethi %hi(0x2028400), %g1 <== NOT EXECUTED
2007e50: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 ! 2028410 <_impure_ptr><== NOT EXECUTED
2007e54: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2007e58: 7f ff ff a3 call 2007ce4 <rtems_status_text> <== NOT EXECUTED
2007e5c: e6 00 60 0c ld [ %g1 + 0xc ], %l3 <== NOT EXECUTED
2007e60: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007e64: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2007e68: 92 12 62 28 or %o1, 0x228, %o1 <== NOT EXECUTED
2007e6c: 40 00 3f 96 call 2017cc4 <fprintf> <== NOT EXECUTED
2007e70: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
2007e74: 10 bf ff c7 b 2007d90 <rtems_verror+0x90> <== NOT EXECUTED
2007e78: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
(void) fflush(stdout); /* in case stdout/stderr same */
status = error_flag & ~RTEMS_ERROR_MASK;
if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */
local_errno = errno;
2007e7c: 40 00 3d b4 call 201754c <__errno> <== NOT EXECUTED
2007e80: 01 00 00 00 nop <== NOT EXECUTED
2007e84: 10 bf ff bb b 2007d70 <rtems_verror+0x70> <== NOT EXECUTED
2007e88: e2 02 00 00 ld [ %o0 ], %l1 <== NOT EXECUTED
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
if (local_errno)
{
if ((local_errno > 0) && *strerror(local_errno))
chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno));
2007e8c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2007e90: 40 00 42 e0 call 2018a10 <strerror> <== NOT EXECUTED
2007e94: e6 00 60 0c ld [ %g1 + 0xc ], %l3 <== NOT EXECUTED
2007e98: 13 00 80 98 sethi %hi(0x2026000), %o1 <== NOT EXECUTED
2007e9c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED
2007ea0: 92 12 62 38 or %o1, 0x238, %o1 <== NOT EXECUTED
2007ea4: 40 00 3f 88 call 2017cc4 <fprintf> <== NOT EXECUTED
2007ea8: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
if (status)
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
if (local_errno)
{
if ((local_errno > 0) && *strerror(local_errno))
2007eac: 10 bf ff cb b 2007dd8 <rtems_verror+0xd8> <== NOT EXECUTED
2007eb0: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
0202cd58 <scanInt>:
/*
* Extract an integer value from the database
*/
static int
scanInt(FILE *fp, int *val)
{
202cd58: 9d e3 bf a0 save %sp, -96, %sp
202cd5c: 27 1f ff ff sethi %hi(0x7ffffc00), %l3
unsigned int limit = INT_MAX;
int sign = 0;
int d;
for (;;) {
c = getc(fp);
202cd60: 2b 00 81 c5 sethi %hi(0x2071400), %l5
limit++;
continue;
}
sign = 1;
}
if (!isdigit(c))
202cd64: 29 00 81 c5 sethi %hi(0x2071400), %l4
/*
* Extract an integer value from the database
*/
static int
scanInt(FILE *fp, int *val)
{
202cd68: a6 14 e3 ff or %l3, 0x3ff, %l3
unsigned int limit = INT_MAX;
int sign = 0;
int d;
for (;;) {
c = getc(fp);
202cd6c: aa 15 62 08 or %l5, 0x208, %l5
limit++;
continue;
}
sign = 1;
}
if (!isdigit(c))
202cd70: a8 15 21 fc or %l4, 0x1fc, %l4
/*
* Extract an integer value from the database
*/
static int
scanInt(FILE *fp, int *val)
{
202cd74: a4 10 20 00 clr %l2
202cd78: a2 10 20 00 clr %l1
unsigned int limit = INT_MAX;
int sign = 0;
int d;
for (;;) {
c = getc(fp);
202cd7c: c2 06 20 04 ld [ %i0 + 4 ], %g1
202cd80: 82 00 7f ff add %g1, -1, %g1
202cd84: 80 a0 60 00 cmp %g1, 0
202cd88: 06 80 00 24 bl 202ce18 <scanInt+0xc0> <== NEVER TAKEN
202cd8c: c2 26 20 04 st %g1, [ %i0 + 4 ]
202cd90: c2 06 00 00 ld [ %i0 ], %g1
202cd94: e0 08 40 00 ldub [ %g1 ], %l0
202cd98: 84 00 60 01 add %g1, 1, %g2
if (c == ':')
202cd9c: 80 a4 20 3a cmp %l0, 0x3a
202cda0: 02 80 00 25 be 202ce34 <scanInt+0xdc>
202cda4: c4 26 00 00 st %g2, [ %i0 ]
break;
if (sign == 0) {
202cda8: 80 a4 a0 00 cmp %l2, 0
202cdac: 32 80 00 06 bne,a 202cdc4 <scanInt+0x6c> <== NEVER TAKEN
202cdb0: c2 05 00 00 ld [ %l4 ], %g1 <== NOT EXECUTED
if (c == '-') {
202cdb4: 80 a4 20 2d cmp %l0, 0x2d
202cdb8: 02 80 00 30 be 202ce78 <scanInt+0x120> <== NEVER TAKEN
202cdbc: a4 10 20 01 mov 1, %l2
limit++;
continue;
}
sign = 1;
}
if (!isdigit(c))
202cdc0: c2 05 00 00 ld [ %l4 ], %g1
202cdc4: 82 00 40 10 add %g1, %l0, %g1
202cdc8: c2 08 60 01 ldub [ %g1 + 1 ], %g1
202cdcc: 80 88 60 04 btst 4, %g1
202cdd0: 02 80 00 28 be 202ce70 <scanInt+0x118> <== NEVER TAKEN
202cdd4: 90 10 00 13 mov %l3, %o0
return 0;
d = c - '0';
if ((i > (limit / 10))
202cdd8: 40 00 d6 eb call 2062984 <.udiv>
202cddc: 92 10 20 0a mov 0xa, %o1
202cde0: 80 a4 40 08 cmp %l1, %o0
202cde4: 18 80 00 23 bgu 202ce70 <scanInt+0x118> <== NEVER TAKEN
202cde8: 01 00 00 00 nop
202cdec: 02 80 00 1b be 202ce58 <scanInt+0x100> <== NEVER TAKEN
202cdf0: a0 04 3f d0 add %l0, -48, %l0
|| ((i == (limit / 10)) && (d > (limit % 10))))
return 0;
i = i * 10 + d;
202cdf4: 83 2c 60 03 sll %l1, 3, %g1
202cdf8: a3 2c 60 01 sll %l1, 1, %l1
202cdfc: a2 04 40 01 add %l1, %g1, %l1
unsigned int limit = INT_MAX;
int sign = 0;
int d;
for (;;) {
c = getc(fp);
202ce00: c2 06 20 04 ld [ %i0 + 4 ], %g1
return 0;
d = c - '0';
if ((i > (limit / 10))
|| ((i == (limit / 10)) && (d > (limit % 10))))
return 0;
i = i * 10 + d;
202ce04: a2 04 00 11 add %l0, %l1, %l1
unsigned int limit = INT_MAX;
int sign = 0;
int d;
for (;;) {
c = getc(fp);
202ce08: 82 00 7f ff add %g1, -1, %g1
202ce0c: 80 a0 60 00 cmp %g1, 0
202ce10: 16 bf ff e0 bge 202cd90 <scanInt+0x38> <== ALWAYS TAKEN
202ce14: c2 26 20 04 st %g1, [ %i0 + 4 ]
202ce18: d0 05 40 00 ld [ %l5 ], %o0 <== NOT EXECUTED
202ce1c: 40 00 8b e4 call 204fdac <__srget_r> <== NOT EXECUTED
202ce20: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
202ce24: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
if (c == ':')
202ce28: 80 a4 20 3a cmp %l0, 0x3a <== NOT EXECUTED
202ce2c: 12 bf ff e0 bne 202cdac <scanInt+0x54> <== NOT EXECUTED
202ce30: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
if ((i > (limit / 10))
|| ((i == (limit / 10)) && (d > (limit % 10))))
return 0;
i = i * 10 + d;
}
if (sign == 0)
202ce34: 80 a4 a0 00 cmp %l2, 0
202ce38: 02 80 00 0e be 202ce70 <scanInt+0x118> <== NEVER TAKEN
202ce3c: 90 10 00 12 mov %l2, %o0
return 0;
*val = i * sign;
202ce40: 92 10 00 11 mov %l1, %o1
202ce44: 7f ff 57 52 call 2002b8c <.umul>
202ce48: b0 10 20 01 mov 1, %i0
202ce4c: d0 26 40 00 st %o0, [ %i1 ]
return 1;
202ce50: 81 c7 e0 08 ret
202ce54: 81 e8 00 00 restore
sign = 1;
}
if (!isdigit(c))
return 0;
d = c - '0';
if ((i > (limit / 10))
202ce58: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
202ce5c: 40 00 d7 76 call 2062c34 <.urem> <== NOT EXECUTED
202ce60: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
202ce64: 80 a4 00 08 cmp %l0, %o0 <== NOT EXECUTED
202ce68: 08 bf ff e4 bleu 202cdf8 <scanInt+0xa0> <== NOT EXECUTED
202ce6c: 83 2c 60 03 sll %l1, 3, %g1 <== NOT EXECUTED
}
if (sign == 0)
return 0;
*val = i * sign;
return 1;
}
202ce70: 81 c7 e0 08 ret <== NOT EXECUTED
202ce74: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if (c == ':')
break;
if (sign == 0) {
if (c == '-') {
sign = -1;
limit++;
202ce78: a6 04 e0 01 inc %l3 <== NOT EXECUTED
continue;
202ce7c: 10 bf ff c0 b 202cd7c <scanInt+0x24> <== NOT EXECUTED
202ce80: a4 10 3f ff mov -1, %l2 <== NOT EXECUTED
0202ce84 <scanString>:
/*
* Extract a string value from the database
*/
static int
scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag)
{
202ce84: 9d e3 bf a0 save %sp, -96, %sp
int c;
*name = *bufp;
202ce88: c2 06 80 00 ld [ %i2 ], %g1
for (;;) {
c = getc(fp);
202ce8c: 21 00 81 c5 sethi %hi(0x2071400), %l0
static int
scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag)
{
int c;
*name = *bufp;
202ce90: c2 26 40 00 st %g1, [ %i1 ]
for (;;) {
c = getc(fp);
202ce94: 10 80 00 19 b 202cef8 <scanString+0x74>
202ce98: a0 14 22 08 or %l0, 0x208, %l0
202ce9c: c2 06 00 00 ld [ %i0 ], %g1
202cea0: d0 08 40 00 ldub [ %g1 ], %o0
202cea4: 84 00 60 01 add %g1, 1, %g2
if (c == ':') {
202cea8: 80 a2 20 3a cmp %o0, 0x3a
202ceac: 02 80 00 1e be 202cf24 <scanString+0xa0>
202ceb0: c4 26 00 00 st %g2, [ %i0 ]
if (nlFlag)
return 0;
break;
}
if (c == '\n') {
202ceb4: 80 a2 20 0a cmp %o0, 0xa
202ceb8: 02 80 00 28 be 202cf58 <scanString+0xd4>
202cebc: 80 a2 3f ff cmp %o0, -1
if (!nlFlag)
return 0;
break;
}
if (c == EOF)
202cec0: 02 80 00 29 be 202cf64 <scanString+0xe0> <== NEVER TAKEN
202cec4: 01 00 00 00 nop
return 0;
if (*nleft < 2)
202cec8: c2 06 c0 00 ld [ %i3 ], %g1
202cecc: 80 a0 60 01 cmp %g1, 1
202ced0: 08 80 00 25 bleu 202cf64 <scanString+0xe0> <== NEVER TAKEN
202ced4: 01 00 00 00 nop
return 0;
**bufp = c;
202ced8: c2 06 80 00 ld [ %i2 ], %g1
202cedc: d0 28 40 00 stb %o0, [ %g1 ]
++(*bufp);
202cee0: c4 06 80 00 ld [ %i2 ], %g2
--(*nleft);
202cee4: c2 06 c0 00 ld [ %i3 ], %g1
if (c == EOF)
return 0;
if (*nleft < 2)
return 0;
**bufp = c;
++(*bufp);
202cee8: 84 00 a0 01 inc %g2
--(*nleft);
202ceec: 82 00 7f ff add %g1, -1, %g1
if (c == EOF)
return 0;
if (*nleft < 2)
return 0;
**bufp = c;
++(*bufp);
202cef0: c4 26 80 00 st %g2, [ %i2 ]
--(*nleft);
202cef4: c2 26 c0 00 st %g1, [ %i3 ]
{
int c;
*name = *bufp;
for (;;) {
c = getc(fp);
202cef8: c2 06 20 04 ld [ %i0 + 4 ], %g1
202cefc: 82 00 7f ff add %g1, -1, %g1
202cf00: 80 a0 60 00 cmp %g1, 0
202cf04: 16 bf ff e6 bge 202ce9c <scanString+0x18>
202cf08: c2 26 20 04 st %g1, [ %i0 + 4 ]
202cf0c: d0 04 00 00 ld [ %l0 ], %o0
202cf10: 40 00 8b a7 call 204fdac <__srget_r>
202cf14: 92 10 00 18 mov %i0, %o1
if (c == ':') {
202cf18: 80 a2 20 3a cmp %o0, 0x3a
202cf1c: 12 bf ff e7 bne 202ceb8 <scanString+0x34> <== ALWAYS TAKEN
202cf20: 80 a2 20 0a cmp %o0, 0xa
if (nlFlag)
202cf24: 80 a7 20 00 cmp %i4, 0
202cf28: 12 80 00 0f bne 202cf64 <scanString+0xe0> <== NEVER TAKEN
202cf2c: 01 00 00 00 nop
return 0;
**bufp = c;
++(*bufp);
--(*nleft);
}
**bufp = '\0';
202cf30: c2 06 80 00 ld [ %i2 ], %g1
202cf34: c0 28 40 00 clrb [ %g1 ]
++(*bufp);
202cf38: c4 06 80 00 ld [ %i2 ], %g2
--(*nleft);
202cf3c: c2 06 c0 00 ld [ %i3 ], %g1
**bufp = c;
++(*bufp);
--(*nleft);
}
**bufp = '\0';
++(*bufp);
202cf40: 84 00 a0 01 inc %g2
--(*nleft);
202cf44: 82 00 7f ff add %g1, -1, %g1
**bufp = c;
++(*bufp);
--(*nleft);
}
**bufp = '\0';
++(*bufp);
202cf48: c4 26 80 00 st %g2, [ %i2 ]
--(*nleft);
202cf4c: c2 26 c0 00 st %g1, [ %i3 ]
return 1;
202cf50: 81 c7 e0 08 ret
202cf54: 91 e8 20 01 restore %g0, 1, %o0
if (nlFlag)
return 0;
break;
}
if (c == '\n') {
if (!nlFlag)
202cf58: 80 a7 20 00 cmp %i4, 0
202cf5c: 32 bf ff f6 bne,a 202cf34 <scanString+0xb0> <== ALWAYS TAKEN
202cf60: c2 06 80 00 ld [ %i2 ], %g1
}
**bufp = '\0';
++(*bufp);
--(*nleft);
return 1;
}
202cf64: 81 c7 e0 08 ret <== NOT EXECUTED
202cf68: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0202cf6c <scangr>:
FILE *fp,
struct group *grp,
char *buffer,
size_t bufsize
)
{
202cf6c: 9d e3 bf 98 save %sp, -104, %sp
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202cf70: 98 10 20 00 clr %o4
FILE *fp,
struct group *grp,
char *buffer,
size_t bufsize
)
{
202cf74: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
202cf78: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202cf7c: a2 07 a0 4c add %fp, 0x4c, %l1
202cf80: a0 07 a0 50 add %fp, 0x50, %l0
202cf84: 90 10 00 18 mov %i0, %o0
202cf88: 92 10 00 19 mov %i1, %o1
202cf8c: 94 10 00 11 mov %l1, %o2
202cf90: 7f ff ff bd call 202ce84 <scanString>
202cf94: 96 10 00 10 mov %l0, %o3
202cf98: 80 a2 20 00 cmp %o0, 0
202cf9c: 12 80 00 04 bne 202cfac <scangr+0x40> <== ALWAYS TAKEN
202cfa0: 90 10 00 18 mov %i0, %o0
grp->gr_mem[memcount++] = cp + 1;
}
}
grp->gr_mem[memcount] = NULL;
return 1;
}
202cfa4: 81 c7 e0 08 ret <== NOT EXECUTED
202cfa8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
202cfac: 92 06 60 04 add %i1, 4, %o1
202cfb0: 94 10 00 11 mov %l1, %o2
202cfb4: 96 10 00 10 mov %l0, %o3
202cfb8: 7f ff ff b3 call 202ce84 <scanString>
202cfbc: 98 10 20 00 clr %o4
{
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202cfc0: 80 a2 20 00 cmp %o0, 0
202cfc4: 02 bf ff f8 be 202cfa4 <scangr+0x38> <== NEVER TAKEN
202cfc8: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
|| !scanInt(fp, &grgid)
202cfcc: 7f ff ff 63 call 202cd58 <scanInt>
202cfd0: 92 07 bf fc add %fp, -4, %o1
{
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202cfd4: 80 a2 20 00 cmp %o0, 0
202cfd8: 02 bf ff f3 be 202cfa4 <scangr+0x38> <== NEVER TAKEN
202cfdc: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
|| !scanInt(fp, &grgid)
|| !scanString(fp, &grmem, &buffer, &bufsize, 1))
202cfe0: 94 10 00 11 mov %l1, %o2
202cfe4: 96 10 00 10 mov %l0, %o3
202cfe8: 92 07 bf f8 add %fp, -8, %o1
202cfec: 7f ff ff a6 call 202ce84 <scanString>
202cff0: 98 10 20 01 mov 1, %o4
{
int grgid;
char *grmem, *cp;
int memcount;
if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202cff4: 80 a2 20 00 cmp %o0, 0
202cff8: 02 bf ff eb be 202cfa4 <scangr+0x38> <== NEVER TAKEN
202cffc: da 07 bf f8 ld [ %fp + -8 ], %o5
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
|| !scanInt(fp, &grgid)
|| !scanString(fp, &grmem, &buffer, &bufsize, 1))
return 0;
grp->gr_gid = grgid;
202d000: c2 07 bf fc ld [ %fp + -4 ], %g1
/*
* Determine number of members
*/
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d004: 84 10 00 0d mov %o5, %g2
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;
202d008: c2 36 60 08 sth %g1, [ %i1 + 8 ]
/*
* Determine number of members
*/
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d00c: c6 0b 40 00 ldub [ %o5 ], %g3
202d010: 88 10 20 01 mov 1, %g4
202d014: 83 28 e0 18 sll %g3, 0x18, %g1
202d018: 80 a0 60 00 cmp %g1, 0
202d01c: 02 80 00 0e be 202d054 <scangr+0xe8> <== NEVER TAKEN
202d020: 86 10 20 17 mov 0x17, %g3
202d024: 84 00 a0 01 inc %g2
202d028: c6 08 80 00 ldub [ %g2 ], %g3
if(*cp == ',')
202d02c: 83 38 60 18 sra %g1, 0x18, %g1
memcount++;
202d030: 82 18 60 2c xor %g1, 0x2c, %g1
202d034: 80 a0 00 01 cmp %g0, %g1
grp->gr_gid = grgid;
/*
* Determine number of members
*/
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d038: 83 28 e0 18 sll %g3, 0x18, %g1
if(*cp == ',')
memcount++;
202d03c: 88 61 3f ff subx %g4, -1, %g4
grp->gr_gid = grgid;
/*
* Determine number of members
*/
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d040: 80 a0 60 00 cmp %g1, 0
202d044: 32 bf ff f9 bne,a 202d028 <scangr+0xbc>
202d048: 84 00 a0 01 inc %g2
202d04c: 87 29 20 02 sll %g4, 2, %g3
202d050: 86 00 e0 13 add %g3, 0x13, %g3
}
/*
* Hack to produce (hopefully) a suitably-aligned array of pointers
*/
if (bufsize < (((memcount+1)*sizeof(char *)) + 15))
202d054: c2 07 a0 50 ld [ %fp + 0x50 ], %g1
202d058: 80 a0 40 03 cmp %g1, %g3
202d05c: 0a bf ff d2 bcs 202cfa4 <scangr+0x38> <== NEVER TAKEN
202d060: c4 07 a0 4c ld [ %fp + 0x4c ], %g2
/*
* Fill in pointer array
*/
grp->gr_mem[0] = grmem;
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d064: 86 10 20 01 mov 1, %g3
/*
* 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);
202d068: 84 00 a0 0f add %g2, 0xf, %g2
202d06c: 84 08 bf f0 and %g2, -16, %g2
/*
* Fill in pointer array
*/
grp->gr_mem[0] = grmem;
202d070: da 20 80 00 st %o5, [ %g2 ]
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d074: c2 07 bf f8 ld [ %fp + -8 ], %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);
202d078: c4 26 60 0c st %g2, [ %i1 + 0xc ]
/*
* Fill in pointer array
*/
grp->gr_mem[0] = grmem;
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d07c: c4 08 40 00 ldub [ %g1 ], %g2
202d080: 88 10 20 04 mov 4, %g4
202d084: 85 28 a0 18 sll %g2, 0x18, %g2
202d088: 80 a0 a0 00 cmp %g2, 0
202d08c: 12 80 00 09 bne 202d0b0 <scangr+0x144> <== ALWAYS TAKEN
202d090: 82 00 60 01 inc %g1
if(*cp == ',') {
*cp = '\0';
grp->gr_mem[memcount++] = cp + 1;
}
}
grp->gr_mem[memcount] = NULL;
202d094: 10 80 00 13 b 202d0e0 <scangr+0x174> <== NOT EXECUTED
202d098: c2 06 60 0c ld [ %i1 + 0xc ], %g1 <== NOT EXECUTED
/*
* Fill in pointer array
*/
grp->gr_mem[0] = grmem;
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d09c: c4 08 40 00 ldub [ %g1 ], %g2 <== NOT EXECUTED
202d0a0: 85 28 a0 18 sll %g2, 0x18, %g2
202d0a4: 80 a0 a0 00 cmp %g2, 0
202d0a8: 02 80 00 0c be 202d0d8 <scangr+0x16c>
202d0ac: 82 00 60 01 inc %g1
if(*cp == ',') {
202d0b0: 85 38 a0 18 sra %g2, 0x18, %g2
202d0b4: 80 a0 a0 2c cmp %g2, 0x2c
202d0b8: 32 bf ff fa bne,a 202d0a0 <scangr+0x134> <== ALWAYS TAKEN
202d0bc: c4 08 40 00 ldub [ %g1 ], %g2
*cp = '\0';
202d0c0: c0 28 7f ff clrb [ %g1 + -1 ] <== NOT EXECUTED
grp->gr_mem[memcount++] = cp + 1;
202d0c4: c8 06 60 0c ld [ %i1 + 0xc ], %g4 <== NOT EXECUTED
202d0c8: 85 28 e0 02 sll %g3, 2, %g2 <== NOT EXECUTED
202d0cc: 86 00 e0 01 inc %g3 <== NOT EXECUTED
202d0d0: 10 bf ff f3 b 202d09c <scangr+0x130> <== NOT EXECUTED
202d0d4: c2 21 00 02 st %g1, [ %g4 + %g2 ] <== NOT EXECUTED
/*
* Fill in pointer array
*/
grp->gr_mem[0] = grmem;
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
202d0d8: 89 28 e0 02 sll %g3, 2, %g4
if(*cp == ',') {
*cp = '\0';
grp->gr_mem[memcount++] = cp + 1;
}
}
grp->gr_mem[memcount] = NULL;
202d0dc: c2 06 60 0c ld [ %i1 + 0xc ], %g1
202d0e0: c0 20 40 04 clr [ %g1 + %g4 ]
return 1;
202d0e4: 81 c7 e0 08 ret
202d0e8: 91 e8 20 01 restore %g0, 1, %o0
0202d138 <scanpw>:
FILE *fp,
struct passwd *pwd,
char *buffer,
size_t bufsize
)
{
202d138: 9d e3 bf 98 save %sp, -104, %sp
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d13c: 98 10 20 00 clr %o4
FILE *fp,
struct passwd *pwd,
char *buffer,
size_t bufsize
)
{
202d140: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
202d144: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d148: a2 07 a0 4c add %fp, 0x4c, %l1
202d14c: a0 07 a0 50 add %fp, 0x50, %l0
202d150: 90 10 00 18 mov %i0, %o0
202d154: 92 10 00 19 mov %i1, %o1
202d158: 94 10 00 11 mov %l1, %o2
202d15c: 7f ff ff 4a call 202ce84 <scanString>
202d160: 96 10 00 10 mov %l0, %o3
202d164: 80 a2 20 00 cmp %o0, 0
202d168: 12 80 00 04 bne 202d178 <scanpw+0x40> <== ALWAYS TAKEN
202d16c: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1))
return 0;
pwd->pw_uid = pwuid;
pwd->pw_gid = pwgid;
return 1;
}
202d170: 81 c7 e0 08 ret <== NOT EXECUTED
202d174: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)
202d178: 92 06 60 04 add %i1, 4, %o1
202d17c: 94 10 00 11 mov %l1, %o2
202d180: 96 10 00 10 mov %l0, %o3
202d184: 7f ff ff 40 call 202ce84 <scanString>
202d188: 98 10 20 00 clr %o4
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d18c: 80 a2 20 00 cmp %o0, 0
202d190: 02 bf ff f8 be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d194: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)
|| !scanInt(fp, &pwuid)
202d198: 7f ff fe f0 call 202cd58 <scanInt>
202d19c: 92 07 bf fc add %fp, -4, %o1
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d1a0: 80 a2 20 00 cmp %o0, 0
202d1a4: 02 bf ff f3 be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d1a8: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)
|| !scanInt(fp, &pwuid)
|| !scanInt(fp, &pwgid)
202d1ac: 7f ff fe eb call 202cd58 <scanInt>
202d1b0: 92 07 bf f8 add %fp, -8, %o1
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d1b4: 80 a2 20 00 cmp %o0, 0
202d1b8: 02 bf ff ee be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d1bc: 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)
202d1c0: 92 06 60 0c add %i1, 0xc, %o1
202d1c4: 94 10 00 11 mov %l1, %o2
202d1c8: 96 10 00 10 mov %l0, %o3
202d1cc: 7f ff ff 2e call 202ce84 <scanString>
202d1d0: 98 10 20 00 clr %o4
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d1d4: 80 a2 20 00 cmp %o0, 0
202d1d8: 02 bf ff e6 be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d1dc: 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)
202d1e0: 92 06 60 10 add %i1, 0x10, %o1
202d1e4: 94 10 00 11 mov %l1, %o2
202d1e8: 96 10 00 10 mov %l0, %o3
202d1ec: 7f ff ff 26 call 202ce84 <scanString>
202d1f0: 98 10 20 00 clr %o4
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d1f4: 80 a2 20 00 cmp %o0, 0
202d1f8: 02 bf ff de be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d1fc: 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)
202d200: 92 06 60 14 add %i1, 0x14, %o1
202d204: 94 10 00 11 mov %l1, %o2
202d208: 96 10 00 10 mov %l0, %o3
202d20c: 7f ff ff 1e call 202ce84 <scanString>
202d210: 98 10 20 00 clr %o4
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d214: 80 a2 20 00 cmp %o0, 0
202d218: 02 bf ff d6 be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d21c: 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))
202d220: 94 10 00 11 mov %l1, %o2
202d224: 96 10 00 10 mov %l0, %o3
202d228: 92 06 60 18 add %i1, 0x18, %o1
202d22c: 7f ff ff 16 call 202ce84 <scanString>
202d230: 98 10 20 01 mov 1, %o4
size_t bufsize
)
{
int pwuid, pwgid;
if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
202d234: 80 a2 20 00 cmp %o0, 0
202d238: 02 bf ff ce be 202d170 <scanpw+0x38> <== NEVER TAKEN
202d23c: 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;
202d240: c2 36 60 08 sth %g1, [ %i1 + 8 ]
pwd->pw_gid = pwgid;
202d244: c2 07 bf f8 ld [ %fp + -8 ], %g1
202d248: c2 36 60 0a sth %g1, [ %i1 + 0xa ]
return 1;
202d24c: 81 c7 e0 08 ret
202d250: 91 e8 20 01 restore %g0, 1, %o0
02007338 <sched_get_priority_max>:
#include <rtems/posix/priority.h>
int sched_get_priority_max(
int policy
)
{
2007338: 9d e3 bf a0 save %sp, -96, %sp
switch ( policy ) {
200733c: 80 a6 20 04 cmp %i0, 4
2007340: 08 80 00 08 bleu 2007360 <sched_get_priority_max+0x28>
2007344: 82 10 20 01 mov 1, %g1
case SCHED_RR:
case SCHED_SPORADIC:
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
2007348: 40 00 2d dc call 2012ab8 <__errno>
200734c: b0 10 3f ff mov -1, %i0
2007350: 82 10 20 16 mov 0x16, %g1
2007354: c2 22 00 00 st %g1, [ %o0 ]
2007358: 81 c7 e0 08 ret
200735c: 81 e8 00 00 restore
int sched_get_priority_max(
int policy
)
{
switch ( policy ) {
2007360: b1 28 40 18 sll %g1, %i0, %i0
2007364: 80 8e 20 17 btst 0x17, %i0
2007368: 02 bf ff f8 be 2007348 <sched_get_priority_max+0x10> <== NEVER TAKEN
200736c: 03 00 80 7f sethi %hi(0x201fc00), %g1
default:
rtems_set_errno_and_return_minus_one( EINVAL );
}
return POSIX_SCHEDULER_MAXIMUM_PRIORITY;
2007370: f0 08 62 78 ldub [ %g1 + 0x278 ], %i0 ! 201fe78 <rtems_maximum_priority>
}
2007374: 81 c7 e0 08 ret
2007378: 91 ee 3f ff restore %i0, -1, %o0
0200737c <sched_get_priority_min>:
#include <rtems/posix/priority.h>
int sched_get_priority_min(
int policy
)
{
200737c: 9d e3 bf a0 save %sp, -96, %sp
switch ( policy ) {
2007380: 80 a6 20 04 cmp %i0, 4
2007384: 08 80 00 08 bleu 20073a4 <sched_get_priority_min+0x28>
2007388: 82 10 20 01 mov 1, %g1
case SCHED_RR:
case SCHED_SPORADIC:
break;
default:
rtems_set_errno_and_return_minus_one( EINVAL );
200738c: 40 00 2d cb call 2012ab8 <__errno>
2007390: b0 10 3f ff mov -1, %i0
2007394: 82 10 20 16 mov 0x16, %g1
2007398: c2 22 00 00 st %g1, [ %o0 ]
}
return POSIX_SCHEDULER_MINIMUM_PRIORITY;
}
200739c: 81 c7 e0 08 ret
20073a0: 81 e8 00 00 restore
int sched_get_priority_min(
int policy
)
{
switch ( policy ) {
20073a4: b1 28 40 18 sll %g1, %i0, %i0
20073a8: 80 8e 20 17 btst 0x17, %i0
20073ac: 02 bf ff f8 be 200738c <sched_get_priority_min+0x10> <== NEVER TAKEN
20073b0: b0 10 20 01 mov 1, %i0
default:
rtems_set_errno_and_return_minus_one( EINVAL );
}
return POSIX_SCHEDULER_MINIMUM_PRIORITY;
}
20073b4: 81 c7 e0 08 ret
20073b8: 81 e8 00 00 restore
020073bc <sched_rr_get_interval>:
int sched_rr_get_interval(
pid_t pid,
struct timespec *interval
)
{
20073bc: 9d e3 bf a0 save %sp, -96, %sp
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid && pid != getpid() )
20073c0: 80 a6 20 00 cmp %i0, 0
20073c4: 12 80 00 0a bne 20073ec <sched_rr_get_interval+0x30> <== ALWAYS TAKEN
20073c8: 80 a6 60 00 cmp %i1, 0
rtems_set_errno_and_return_minus_one( ESRCH );
if ( !interval )
20073cc: 02 80 00 13 be 2007418 <sched_rr_get_interval+0x5c>
20073d0: 03 00 80 82 sethi %hi(0x2020800), %g1
rtems_set_errno_and_return_minus_one( EINVAL );
_Timespec_From_ticks( _Thread_Ticks_per_timeslice, interval );
20073d4: d0 00 60 e8 ld [ %g1 + 0xe8 ], %o0 ! 20208e8 <_Thread_Ticks_per_timeslice>
20073d8: 92 10 00 19 mov %i1, %o1
20073dc: 40 00 0f 17 call 200b038 <_Timespec_From_ticks>
20073e0: b0 10 20 00 clr %i0
return 0;
}
20073e4: 81 c7 e0 08 ret
20073e8: 81 e8 00 00 restore
{
/*
* Only supported for the "calling process" (i.e. this node).
*/
if ( pid && pid != getpid() )
20073ec: 7f ff f0 88 call 200360c <getpid>
20073f0: 01 00 00 00 nop
20073f4: 80 a2 00 18 cmp %o0, %i0
20073f8: 02 bf ff f5 be 20073cc <sched_rr_get_interval+0x10>
20073fc: 80 a6 60 00 cmp %i1, 0
rtems_set_errno_and_return_minus_one( ESRCH );
2007400: 40 00 2d ae call 2012ab8 <__errno>
2007404: b0 10 3f ff mov -1, %i0
2007408: 82 10 20 03 mov 3, %g1
200740c: c2 22 00 00 st %g1, [ %o0 ]
2007410: 81 c7 e0 08 ret
2007414: 81 e8 00 00 restore
if ( !interval )
rtems_set_errno_and_return_minus_one( EINVAL );
2007418: 40 00 2d a8 call 2012ab8 <__errno>
200741c: b0 10 3f ff mov -1, %i0
2007420: 82 10 20 16 mov 0x16, %g1
2007424: c2 22 00 00 st %g1, [ %o0 ]
2007428: 81 c7 e0 08 ret
200742c: 81 e8 00 00 restore
02009a88 <sem_open>:
int oflag,
...
/* mode_t mode, */
/* unsigned int value */
)
{
2009a88: 9d e3 bf 90 save %sp, -112, %sp
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2009a8c: 03 00 80 96 sethi %hi(0x2025800), %g1
2009a90: c4 00 60 d0 ld [ %g1 + 0xd0 ], %g2 ! 20258d0 <_Thread_Dispatch_disable_level>
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
va_start(arg, oflag);
2009a94: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
2009a98: 84 00 a0 01 inc %g2
2009a9c: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
2009aa0: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
2009aa4: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
2009aa8: c4 20 60 d0 st %g2, [ %g1 + 0xd0 ]
POSIX_Semaphore_Control *the_semaphore;
Objects_Locations location;
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
2009aac: a0 8e 62 00 andcc %i1, 0x200, %l0
2009ab0: 12 80 00 26 bne 2009b48 <sem_open+0xc0>
2009ab4: 82 07 a0 54 add %fp, 0x54, %g1
2009ab8: a2 10 20 00 clr %l1
mode = (mode_t) va_arg( arg, unsigned int );
value = va_arg( arg, unsigned int );
va_end(arg);
}
status = _POSIX_Semaphore_Name_to_id( name, &the_semaphore_id );
2009abc: 90 10 00 18 mov %i0, %o0
2009ac0: 40 00 1f f3 call 2011a8c <_POSIX_Semaphore_Name_to_id>
2009ac4: 92 07 bf f8 add %fp, -8, %o1
* and we can just return a pointer to the id. Otherwise we may
* need to check to see if this is a "semaphore does not exist"
* or some other miscellaneous error on the name.
*/
if ( status ) {
2009ac8: a4 92 20 00 orcc %o0, 0, %l2
2009acc: 22 80 00 0e be,a 2009b04 <sem_open+0x7c>
2009ad0: b2 0e 6a 00 and %i1, 0xa00, %i1
/*
* Unless provided a valid name that did not already exist
* and we are willing to create then it is an error.
*/
if ( !( status == ENOENT && (oflag & O_CREAT) ) ) {
2009ad4: 80 a4 a0 02 cmp %l2, 2
2009ad8: 12 80 00 04 bne 2009ae8 <sem_open+0x60> <== NEVER TAKEN
2009adc: 80 a4 20 00 cmp %l0, 0
2009ae0: 12 80 00 1d bne 2009b54 <sem_open+0xcc>
2009ae4: 94 10 00 11 mov %l1, %o2
_Thread_Enable_dispatch();
2009ae8: 40 00 0b 58 call 200c848 <_Thread_Enable_dispatch>
2009aec: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one_cast( status, sem_t * );
2009af0: 40 00 31 42 call 2015ff8 <__errno>
2009af4: 01 00 00 00 nop
2009af8: e4 22 00 00 st %l2, [ %o0 ]
2009afc: 81 c7 e0 08 ret
2009b00: 81 e8 00 00 restore
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
2009b04: 80 a6 6a 00 cmp %i1, 0xa00
2009b08: 02 80 00 1f be 2009b84 <sem_open+0xfc>
2009b0c: d2 07 bf f8 ld [ %fp + -8 ], %o1
2009b10: 94 07 bf f0 add %fp, -16, %o2
2009b14: 11 00 80 96 sethi %hi(0x2025800), %o0
2009b18: 40 00 08 bb call 200be04 <_Objects_Get>
2009b1c: 90 12 23 e0 or %o0, 0x3e0, %o0 ! 2025be0 <_POSIX_Semaphore_Information>
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );
}
the_semaphore = _POSIX_Semaphore_Get( &the_semaphore_id, &location );
the_semaphore->open_count += 1;
2009b20: c2 02 20 18 ld [ %o0 + 0x18 ], %g1
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
_Thread_Enable_dispatch();
rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );
}
the_semaphore = _POSIX_Semaphore_Get( &the_semaphore_id, &location );
2009b24: d0 27 bf f4 st %o0, [ %fp + -12 ]
the_semaphore->open_count += 1;
2009b28: 82 00 60 01 inc %g1
_Thread_Enable_dispatch();
2009b2c: 40 00 0b 47 call 200c848 <_Thread_Enable_dispatch>
2009b30: c2 22 20 18 st %g1, [ %o0 + 0x18 ]
_Thread_Enable_dispatch();
2009b34: 40 00 0b 45 call 200c848 <_Thread_Enable_dispatch>
2009b38: 01 00 00 00 nop
return_id:
#if defined(RTEMS_USE_16_BIT_OBJECT)
the_semaphore->Semaphore_id = the_semaphore->Object.id;
id = &the_semaphore->Semaphore_id;
#else
id = (sem_t *)&the_semaphore->Object.id;
2009b3c: f0 07 bf f4 ld [ %fp + -12 ], %i0
#endif
return id;
}
2009b40: 81 c7 e0 08 ret
2009b44: 91 ee 20 08 restore %i0, 8, %o0
_Thread_Disable_dispatch();
if ( oflag & O_CREAT ) {
va_start(arg, oflag);
mode = (mode_t) va_arg( arg, unsigned int );
value = va_arg( arg, unsigned int );
2009b48: e2 07 a0 50 ld [ %fp + 0x50 ], %l1
2009b4c: 10 bf ff dc b 2009abc <sem_open+0x34>
2009b50: c2 27 bf fc st %g1, [ %fp + -4 ]
/*
* At this point, the semaphore does not exist and everything has been
* checked. We should go ahead and create a semaphore.
*/
status =_POSIX_Semaphore_Create_support(
2009b54: 90 10 00 18 mov %i0, %o0
2009b58: 92 10 20 00 clr %o1
2009b5c: 40 00 1f 71 call 2011920 <_POSIX_Semaphore_Create_support>
2009b60: 96 07 bf f4 add %fp, -12, %o3
/*
* errno was set by Create_support, so don't set it again.
*/
_Thread_Enable_dispatch();
2009b64: 40 00 0b 39 call 200c848 <_Thread_Enable_dispatch>
2009b68: a0 10 00 08 mov %o0, %l0
if ( status == -1 )
2009b6c: 80 a4 3f ff cmp %l0, -1
2009b70: 02 bf ff e3 be 2009afc <sem_open+0x74>
2009b74: b0 10 3f ff mov -1, %i0
return_id:
#if defined(RTEMS_USE_16_BIT_OBJECT)
the_semaphore->Semaphore_id = the_semaphore->Object.id;
id = &the_semaphore->Semaphore_id;
#else
id = (sem_t *)&the_semaphore->Object.id;
2009b78: f0 07 bf f4 ld [ %fp + -12 ], %i0
2009b7c: 81 c7 e0 08 ret
2009b80: 91 ee 20 08 restore %i0, 8, %o0
/*
* Check for existence with creation.
*/
if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {
_Thread_Enable_dispatch();
2009b84: 40 00 0b 31 call 200c848 <_Thread_Enable_dispatch>
2009b88: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );
2009b8c: 40 00 31 1b call 2015ff8 <__errno>
2009b90: 01 00 00 00 nop
2009b94: 82 10 20 11 mov 0x11, %g1 ! 11 <PROM_START+0x11>
2009b98: c2 22 00 00 st %g1, [ %o0 ]
2009b9c: 81 c7 e0 08 ret
2009ba0: 81 e8 00 00 restore
02009c00 <sem_timedwait>:
int sem_timedwait(
sem_t *sem,
const struct timespec *abstime
)
{
2009c00: 9d e3 bf 98 save %sp, -104, %sp
*
* If the status is POSIX_ABSOLUTE_TIMEOUT_INVALID,
* POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST, or POSIX_ABSOLUTE_TIMEOUT_IS_NOW,
* then we should not wait.
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
2009c04: 90 10 00 19 mov %i1, %o0
2009c08: 40 00 1c cf call 2010f44 <_POSIX_Absolute_timeout_to_ticks>
2009c0c: 92 07 bf fc add %fp, -4, %o1
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
2009c10: 80 a2 20 03 cmp %o0, 3
2009c14: 02 80 00 07 be 2009c30 <sem_timedwait+0x30> <== ALWAYS TAKEN
2009c18: d4 07 bf fc ld [ %fp + -4 ], %o2
do_wait = false;
lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks );
2009c1c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
2009c20: 40 00 1f bd call 2011b14 <_POSIX_Semaphore_Wait_support> <== NOT EXECUTED
2009c24: 92 10 20 00 clr %o1 <== NOT EXECUTED
break;
}
}
return lock_status;
}
2009c28: 81 c7 e0 08 ret <== NOT EXECUTED
2009c2c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
*/
status = _POSIX_Absolute_timeout_to_ticks( abstime, &ticks );
if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )
do_wait = false;
lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks );
2009c30: 90 10 00 18 mov %i0, %o0
2009c34: 40 00 1f b8 call 2011b14 <_POSIX_Semaphore_Wait_support>
2009c38: 92 10 20 01 mov 1, %o1
break;
}
}
return lock_status;
}
2009c3c: 81 c7 e0 08 ret
2009c40: 91 e8 00 08 restore %g0, %o0, %o0
0202cce4 <setgid>:
int setgid(
gid_t gid
)
{
_POSIX_types_Gid = gid;
202cce4: 03 00 81 c3 sethi %hi(0x2070c00), %g1 <== NOT EXECUTED
202cce8: c2 00 62 24 ld [ %g1 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
202ccec: d0 30 60 34 sth %o0, [ %g1 + 0x34 ] <== NOT EXECUTED
return 0;
}
202ccf0: 81 c3 e0 08 retl <== NOT EXECUTED
202ccf4: 90 10 20 00 clr %o0 <== NOT EXECUTED
0202d38c <setgrent>:
return NULL;
return &grent;
}
void setgrent(void)
{
202d38c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
init_etc_passwd_group();
202d390: 7f ff ff c4 call 202d2a0 <init_etc_passwd_group> <== NOT EXECUTED
202d394: 21 00 81 d2 sethi %hi(0x2074800), %l0 <== NOT EXECUTED
if (group_fp != NULL)
202d398: d0 04 21 5c ld [ %l0 + 0x15c ], %o0 ! 207495c <group_fp> <== NOT EXECUTED
202d39c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d3a0: 22 80 00 05 be,a 202d3b4 <setgrent+0x28> <== NOT EXECUTED
202d3a4: 11 00 81 ab sethi %hi(0x206ac00), %o0 <== NOT EXECUTED
fclose(group_fp);
202d3a8: 40 00 74 8e call 204a5e0 <fclose> <== NOT EXECUTED
202d3ac: 01 00 00 00 nop <== NOT EXECUTED
group_fp = fopen("/etc/group", "r");
202d3b0: 11 00 81 ab sethi %hi(0x206ac00), %o0 <== NOT EXECUTED
202d3b4: 13 00 81 ab sethi %hi(0x206ac00), %o1 <== NOT EXECUTED
202d3b8: 90 12 22 90 or %o0, 0x290, %o0 <== NOT EXECUTED
202d3bc: 40 00 76 d9 call 204af20 <fopen> <== NOT EXECUTED
202d3c0: 92 12 62 18 or %o1, 0x218, %o1 <== NOT EXECUTED
202d3c4: d0 24 21 5c st %o0, [ %l0 + 0x15c ] <== NOT EXECUTED
}
202d3c8: 81 c7 e0 08 ret <== NOT EXECUTED
202d3cc: 81 e8 00 00 restore <== NOT EXECUTED
0202d58c <setpwent>:
return NULL;
return &pwent;
}
void setpwent(void)
{
202d58c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
init_etc_passwd_group();
202d590: 7f ff ff 44 call 202d2a0 <init_etc_passwd_group> <== NOT EXECUTED
202d594: 21 00 81 d2 sethi %hi(0x2074800), %l0 <== NOT EXECUTED
if (passwd_fp != NULL)
202d598: d0 04 20 74 ld [ %l0 + 0x74 ], %o0 ! 2074874 <passwd_fp> <== NOT EXECUTED
202d59c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202d5a0: 22 80 00 05 be,a 202d5b4 <setpwent+0x28> <== NOT EXECUTED
202d5a4: 11 00 81 ab sethi %hi(0x206ac00), %o0 <== NOT EXECUTED
fclose(passwd_fp);
202d5a8: 40 00 74 0e call 204a5e0 <fclose> <== NOT EXECUTED
202d5ac: 01 00 00 00 nop <== NOT EXECUTED
passwd_fp = fopen("/etc/passwd", "r");
202d5b0: 11 00 81 ab sethi %hi(0x206ac00), %o0 <== NOT EXECUTED
202d5b4: 13 00 81 ab sethi %hi(0x206ac00), %o1 <== NOT EXECUTED
202d5b8: 90 12 22 08 or %o0, 0x208, %o0 <== NOT EXECUTED
202d5bc: 40 00 76 59 call 204af20 <fopen> <== NOT EXECUTED
202d5c0: 92 12 62 18 or %o1, 0x218, %o1 <== NOT EXECUTED
202d5c4: d0 24 20 74 st %o0, [ %l0 + 0x74 ] <== NOT EXECUTED
}
202d5c8: 81 c7 e0 08 ret <== NOT EXECUTED
202d5cc: 81 e8 00 00 restore <== NOT EXECUTED
02008a24 <setuid>:
int setuid(
uid_t uid
)
{
_POSIX_types_Uid = uid;
2008a24: 03 00 81 c3 sethi %hi(0x2070c00), %g1 <== NOT EXECUTED
2008a28: c2 00 62 24 ld [ %g1 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env><== NOT EXECUTED
2008a2c: d0 30 60 32 sth %o0, [ %g1 + 0x32 ] <== NOT EXECUTED
return 0;
}
2008a30: 81 c3 e0 08 retl <== NOT EXECUTED
2008a34: 90 10 20 00 clr %o0 <== NOT EXECUTED
020071f4 <sigaction>:
int sigaction(
int sig,
const struct sigaction *act,
struct sigaction *oact
)
{
20071f4: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
if ( oact )
20071f8: 80 a6 a0 00 cmp %i2, 0
20071fc: 02 80 00 0d be 2007230 <sigaction+0x3c>
2007200: 87 2e 20 04 sll %i0, 4, %g3
*oact = _POSIX_signals_Vectors[ sig ];
2007204: 05 00 80 87 sethi %hi(0x2021c00), %g2
2007208: 83 2e 20 02 sll %i0, 2, %g1
200720c: 84 10 a2 b8 or %g2, 0x2b8, %g2
2007210: 82 20 c0 01 sub %g3, %g1, %g1
2007214: c6 00 80 01 ld [ %g2 + %g1 ], %g3
2007218: 82 00 80 01 add %g2, %g1, %g1
200721c: c6 26 80 00 st %g3, [ %i2 ]
2007220: c4 00 60 04 ld [ %g1 + 4 ], %g2
2007224: c4 26 a0 04 st %g2, [ %i2 + 4 ]
2007228: c2 00 60 08 ld [ %g1 + 8 ], %g1
200722c: c2 26 a0 08 st %g1, [ %i2 + 8 ]
if ( !sig )
2007230: 80 a6 20 00 cmp %i0, 0
2007234: 02 80 00 33 be 2007300 <sigaction+0x10c>
2007238: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(sig) )
200723c: 82 06 3f ff add %i0, -1, %g1
2007240: 80 a0 60 1f cmp %g1, 0x1f
2007244: 18 80 00 2f bgu 2007300 <sigaction+0x10c>
2007248: 80 a6 20 09 cmp %i0, 9
*
* NOTE: Solaris documentation claims to "silently enforce" this which
* contradicts the POSIX specification.
*/
if ( sig == SIGKILL )
200724c: 02 80 00 2d be 2007300 <sigaction+0x10c>
2007250: 80 a6 60 00 cmp %i1, 0
/*
* Evaluate the new action structure and set the global signal vector
* appropriately.
*/
if ( act ) {
2007254: 02 80 00 1a be 20072bc <sigaction+0xc8> <== NEVER TAKEN
2007258: 82 10 20 00 clr %g1
/*
* Unless the user is installing the default signal actions, then
* we can just copy the provided sigaction structure into the vectors.
*/
_ISR_Disable( level );
200725c: 7f ff ed 22 call 20026e4 <sparc_disable_interrupts>
2007260: 01 00 00 00 nop
2007264: b4 10 00 08 mov %o0, %i2
if ( act->sa_handler == SIG_DFL ) {
2007268: c2 06 60 08 ld [ %i1 + 8 ], %g1
200726c: 80 a0 60 00 cmp %g1, 0
2007270: 02 80 00 15 be 20072c4 <sigaction+0xd0>
2007274: 83 2e 20 04 sll %i0, 4, %g1
_POSIX_signals_Vectors[ sig ] = _POSIX_signals_Default_vectors[ sig ];
} else {
_POSIX_signals_Clear_process_signals( sig );
2007278: 40 00 1d cc call 200e9a8 <_POSIX_signals_Clear_process_signals>
200727c: 90 10 00 18 mov %i0, %o0
_POSIX_signals_Vectors[ sig ] = *act;
2007280: c4 06 40 00 ld [ %i1 ], %g2
2007284: 87 2e 20 04 sll %i0, 4, %g3
2007288: 03 00 80 87 sethi %hi(0x2021c00), %g1
200728c: b1 2e 20 02 sll %i0, 2, %i0
2007290: 82 10 62 b8 or %g1, 0x2b8, %g1
2007294: b0 20 c0 18 sub %g3, %i0, %i0
2007298: c4 20 40 18 st %g2, [ %g1 + %i0 ]
200729c: c4 06 60 04 ld [ %i1 + 4 ], %g2
20072a0: b0 00 40 18 add %g1, %i0, %i0
20072a4: c4 26 20 04 st %g2, [ %i0 + 4 ]
20072a8: c2 06 60 08 ld [ %i1 + 8 ], %g1
20072ac: c2 26 20 08 st %g1, [ %i0 + 8 ]
}
_ISR_Enable( level );
20072b0: 7f ff ed 11 call 20026f4 <sparc_enable_interrupts>
20072b4: 90 10 00 1a mov %i2, %o0
20072b8: 82 10 20 00 clr %g1
* + If we are now ignoring a signal that was previously pending,
* we clear the pending signal indicator.
*/
return 0;
}
20072bc: 81 c7 e0 08 ret
20072c0: 91 e8 00 01 restore %g0, %g1, %o0
* we can just copy the provided sigaction structure into the vectors.
*/
_ISR_Disable( level );
if ( act->sa_handler == SIG_DFL ) {
_POSIX_signals_Vectors[ sig ] = _POSIX_signals_Default_vectors[ sig ];
20072c4: b1 2e 20 02 sll %i0, 2, %i0
20072c8: b0 20 40 18 sub %g1, %i0, %i0
20072cc: 03 00 80 7f sethi %hi(0x201fc00), %g1
20072d0: 82 10 63 a8 or %g1, 0x3a8, %g1 ! 201ffa8 <_POSIX_signals_Default_vectors>
20072d4: c8 00 40 18 ld [ %g1 + %i0 ], %g4
20072d8: 82 00 40 18 add %g1, %i0, %g1
20072dc: c6 00 60 08 ld [ %g1 + 8 ], %g3
20072e0: c4 00 60 04 ld [ %g1 + 4 ], %g2
20072e4: 03 00 80 87 sethi %hi(0x2021c00), %g1
20072e8: 82 10 62 b8 or %g1, 0x2b8, %g1 ! 2021eb8 <_POSIX_signals_Vectors>
20072ec: c8 20 40 18 st %g4, [ %g1 + %i0 ]
20072f0: b0 00 40 18 add %g1, %i0, %i0
20072f4: c6 26 20 08 st %g3, [ %i0 + 8 ]
20072f8: 10 bf ff ee b 20072b0 <sigaction+0xbc>
20072fc: c4 26 20 04 st %g2, [ %i0 + 4 ]
* NOTE: Solaris documentation claims to "silently enforce" this which
* contradicts the POSIX specification.
*/
if ( sig == SIGKILL )
rtems_set_errno_and_return_minus_one( EINVAL );
2007300: 40 00 2e 8d call 2012d34 <__errno>
2007304: 01 00 00 00 nop
2007308: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16>
200730c: c2 22 00 00 st %g1, [ %o0 ]
2007310: 10 bf ff eb b 20072bc <sigaction+0xc8>
2007314: 82 10 3f ff mov -1, %g1
02009544 <sigsuspend>:
#include <rtems/seterr.h>
int sigsuspend(
const sigset_t *sigmask
)
{
2009544: 9d e3 bf 98 save %sp, -104, %sp
int status;
POSIX_API_Control *api;
api = _Thread_Executing->API_Extensions[ THREAD_API_POSIX ];
status = sigprocmask( SIG_BLOCK, sigmask, &saved_signals_blocked );
2009548: 90 10 20 01 mov 1, %o0
200954c: 92 10 00 18 mov %i0, %o1
2009550: a0 07 bf fc add %fp, -4, %l0
2009554: 7f ff ff f1 call 2009518 <sigprocmask>
2009558: 94 10 00 10 mov %l0, %o2
(void) sigfillset( &all_signals );
200955c: a2 07 bf f8 add %fp, -8, %l1
2009560: 7f ff ff b7 call 200943c <sigfillset>
2009564: 90 10 00 11 mov %l1, %o0
status = sigtimedwait( &all_signals, NULL, NULL );
2009568: 90 10 00 11 mov %l1, %o0
200956c: 92 10 20 00 clr %o1
2009570: 40 00 00 2b call 200961c <sigtimedwait>
2009574: 94 10 20 00 clr %o2
(void) sigprocmask( SIG_SETMASK, &saved_signals_blocked, NULL );
2009578: 92 10 00 10 mov %l0, %o1
status = sigprocmask( SIG_BLOCK, sigmask, &saved_signals_blocked );
(void) sigfillset( &all_signals );
status = sigtimedwait( &all_signals, NULL, NULL );
200957c: a2 10 00 08 mov %o0, %l1
(void) sigprocmask( SIG_SETMASK, &saved_signals_blocked, NULL );
2009580: 94 10 20 00 clr %o2
2009584: 7f ff ff e5 call 2009518 <sigprocmask>
2009588: 90 10 20 00 clr %o0
/*
* sigtimedwait() returns the signal number while sigsuspend()
* is supposed to return -1 and EINTR when a signal is caught.
*/
if ( status != -1 )
200958c: 80 a4 7f ff cmp %l1, -1
2009590: 12 80 00 05 bne 20095a4 <sigsuspend+0x60> <== ALWAYS TAKEN
2009594: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINTR );
return status;
}
2009598: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED
200959c: 81 c7 e0 08 ret <== NOT EXECUTED
20095a0: 81 e8 00 00 restore <== NOT EXECUTED
/*
* sigtimedwait() returns the signal number while sigsuspend()
* is supposed to return -1 and EINTR when a signal is caught.
*/
if ( status != -1 )
rtems_set_errno_and_return_minus_one( EINTR );
20095a4: 40 00 2d bb call 2014c90 <__errno>
20095a8: b0 10 3f ff mov -1, %i0
20095ac: 82 10 20 04 mov 4, %g1
20095b0: c2 22 00 00 st %g1, [ %o0 ]
20095b4: 81 c7 e0 08 ret
20095b8: 81 e8 00 00 restore
02007780 <sigtimedwait>:
int sigtimedwait(
const sigset_t *set,
siginfo_t *info,
const struct timespec *timeout
)
{
2007780: 9d e3 bf 90 save %sp, -112, %sp
ISR_Level level;
/*
* Error check parameters before disabling interrupts.
*/
if ( !set )
2007784: 80 a6 20 00 cmp %i0, 0
2007788: 02 80 00 69 be 200792c <sigtimedwait+0x1ac>
200778c: 80 a6 a0 00 cmp %i2, 0
/* NOTE: This is very specifically a RELATIVE not ABSOLUTE time
* in the Open Group specification.
*/
interval = 0;
if ( timeout ) {
2007790: 22 80 00 0c be,a 20077c0 <sigtimedwait+0x40>
2007794: b4 10 20 00 clr %i2
if ( !_Timespec_Is_valid( timeout ) )
2007798: 40 00 0f 15 call 200b3ec <_Timespec_Is_valid>
200779c: 90 10 00 1a mov %i2, %o0
20077a0: 80 8a 20 ff btst 0xff, %o0
20077a4: 02 80 00 62 be 200792c <sigtimedwait+0x1ac>
20077a8: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
interval = _Timespec_To_ticks( timeout );
20077ac: 40 00 0f 37 call 200b488 <_Timespec_To_ticks>
20077b0: 90 10 00 1a mov %i2, %o0
if ( !interval )
20077b4: b4 92 20 00 orcc %o0, 0, %i2
20077b8: 02 80 00 5d be 200792c <sigtimedwait+0x1ac> <== NEVER TAKEN
20077bc: 01 00 00 00 nop
/*
* Initialize local variables.
*/
the_info = ( info ) ? info : &signal_information;
20077c0: 80 a6 60 00 cmp %i1, 0
20077c4: 02 80 00 03 be 20077d0 <sigtimedwait+0x50>
20077c8: a0 07 bf f4 add %fp, -12, %l0
20077cc: a0 10 00 19 mov %i1, %l0
the_thread = _Thread_Executing;
20077d0: 23 00 80 87 sethi %hi(0x2021c00), %l1
20077d4: f2 04 62 60 ld [ %l1 + 0x260 ], %i1 ! 2021e60 <_Thread_Executing>
* What if they are already pending?
*/
/* API signals pending? */
_ISR_Disable( level );
20077d8: 7f ff ec a1 call 2002a5c <sparc_disable_interrupts>
20077dc: e6 06 61 6c ld [ %i1 + 0x16c ], %l3
20077e0: a4 10 00 08 mov %o0, %l2
if ( *set & api->signals_pending ) {
20077e4: c2 06 00 00 ld [ %i0 ], %g1
20077e8: c4 04 e0 d0 ld [ %l3 + 0xd0 ], %g2
20077ec: 80 88 40 02 btst %g1, %g2
20077f0: 12 80 00 3e bne 20078e8 <sigtimedwait+0x168>
20077f4: 01 00 00 00 nop
return the_info->si_signo;
}
/* Process pending signals? */
if ( *set & _POSIX_signals_Pending ) {
20077f8: 05 00 80 89 sethi %hi(0x2022400), %g2
20077fc: c4 00 a1 1c ld [ %g2 + 0x11c ], %g2 ! 202251c <_POSIX_signals_Pending>
2007800: 80 88 40 02 btst %g1, %g2
2007804: 12 80 00 28 bne 20078a4 <sigtimedwait+0x124>
2007808: 03 00 80 87 sethi %hi(0x2021c00), %g1
200780c: c4 00 61 a0 ld [ %g1 + 0x1a0 ], %g2 ! 2021da0 <_Thread_Dispatch_disable_level>
2007810: 84 00 a0 01 inc %g2
2007814: c4 20 61 a0 st %g2, [ %g1 + 0x1a0 ]
the_info->si_code = SI_USER;
the_info->si_value.sival_int = 0;
return signo;
}
the_info->si_signo = -1;
2007818: 82 10 3f ff mov -1, %g1
200781c: c2 24 00 00 st %g1, [ %l0 ]
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
the_thread->Wait.return_code = EINTR;
2007820: 82 10 20 04 mov 4, %g1
2007824: c2 26 60 34 st %g1, [ %i1 + 0x34 ]
the_thread->Wait.option = *set;
2007828: c2 06 00 00 ld [ %i0 ], %g1
the_thread->Wait.return_argument = the_info;
200782c: e0 26 60 28 st %l0, [ %i1 + 0x28 ]
the_info->si_signo = -1;
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
the_thread->Wait.return_code = EINTR;
the_thread->Wait.option = *set;
2007830: c2 26 60 30 st %g1, [ %i1 + 0x30 ]
}
the_info->si_signo = -1;
_Thread_Disable_dispatch();
the_thread->Wait.queue = &_POSIX_signals_Wait_queue;
2007834: 25 00 80 89 sethi %hi(0x2022400), %l2
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2007838: 82 10 20 01 mov 1, %g1
200783c: a4 14 a0 b4 or %l2, 0xb4, %l2
2007840: e4 26 60 44 st %l2, [ %i1 + 0x44 ]
2007844: c2 24 a0 30 st %g1, [ %l2 + 0x30 ]
the_thread->Wait.return_code = EINTR;
the_thread->Wait.option = *set;
the_thread->Wait.return_argument = the_info;
_Thread_queue_Enter_critical_section( &_POSIX_signals_Wait_queue );
_ISR_Enable( level );
2007848: 7f ff ec 89 call 2002a6c <sparc_enable_interrupts>
200784c: 01 00 00 00 nop
_Thread_queue_Enqueue( &_POSIX_signals_Wait_queue, interval );
2007850: 90 10 00 12 mov %l2, %o0
2007854: 92 10 00 1a mov %i2, %o1
2007858: 15 00 80 2b sethi %hi(0x200ac00), %o2
200785c: 40 00 0c 7d call 200aa50 <_Thread_queue_Enqueue_with_handler>
2007860: 94 12 a2 24 or %o2, 0x224, %o2 ! 200ae24 <_Thread_queue_Timeout>
_Thread_Enable_dispatch();
2007864: 40 00 0b 08 call 200a484 <_Thread_Enable_dispatch>
2007868: 01 00 00 00 nop
/*
* When the thread is set free by a signal, it is need to eliminate
* the signal.
*/
_POSIX_signals_Clear_signals( api, the_info->si_signo, the_info, false, false );
200786c: d2 04 00 00 ld [ %l0 ], %o1
2007870: 94 10 00 10 mov %l0, %o2
2007874: 96 10 20 00 clr %o3
2007878: 98 10 20 00 clr %o4
200787c: 40 00 1e 72 call 200f244 <_POSIX_signals_Clear_signals>
2007880: 90 10 00 13 mov %l3, %o0
errno = _Thread_Executing->Wait.return_code;
2007884: 40 00 2e 18 call 20130e4 <__errno>
2007888: 01 00 00 00 nop
200788c: c2 04 62 60 ld [ %l1 + 0x260 ], %g1
2007890: c2 00 60 34 ld [ %g1 + 0x34 ], %g1
2007894: c2 22 00 00 st %g1, [ %o0 ]
return the_info->si_signo;
2007898: f0 04 00 00 ld [ %l0 ], %i0
}
200789c: 81 c7 e0 08 ret
20078a0: 81 e8 00 00 restore
}
/* Process pending signals? */
if ( *set & _POSIX_signals_Pending ) {
signo = _POSIX_signals_Get_highest( _POSIX_signals_Pending );
20078a4: 7f ff ff 9f call 2007720 <_POSIX_signals_Get_highest>
20078a8: 90 10 00 02 mov %g2, %o0
_POSIX_signals_Clear_signals( api, signo, the_info, true, false );
20078ac: 94 10 00 10 mov %l0, %o2
}
/* Process pending signals? */
if ( *set & _POSIX_signals_Pending ) {
signo = _POSIX_signals_Get_highest( _POSIX_signals_Pending );
20078b0: b0 10 00 08 mov %o0, %i0
_POSIX_signals_Clear_signals( api, signo, the_info, true, false );
20078b4: 96 10 20 01 mov 1, %o3
20078b8: 90 10 00 13 mov %l3, %o0
20078bc: 92 10 00 18 mov %i0, %o1
20078c0: 40 00 1e 61 call 200f244 <_POSIX_signals_Clear_signals>
20078c4: 98 10 20 00 clr %o4
_ISR_Enable( level );
20078c8: 7f ff ec 69 call 2002a6c <sparc_enable_interrupts>
20078cc: 90 10 00 12 mov %l2, %o0
the_info->si_signo = signo;
the_info->si_code = SI_USER;
20078d0: 82 10 20 01 mov 1, %g1
the_info->si_value.sival_int = 0;
20078d4: c0 24 20 08 clr [ %l0 + 8 ]
if ( *set & _POSIX_signals_Pending ) {
signo = _POSIX_signals_Get_highest( _POSIX_signals_Pending );
_POSIX_signals_Clear_signals( api, signo, the_info, true, false );
_ISR_Enable( level );
the_info->si_signo = signo;
20078d8: f0 24 00 00 st %i0, [ %l0 ]
the_info->si_code = SI_USER;
20078dc: c2 24 20 04 st %g1, [ %l0 + 4 ]
the_info->si_value.sival_int = 0;
return signo;
20078e0: 81 c7 e0 08 ret
20078e4: 81 e8 00 00 restore
/* API signals pending? */
_ISR_Disable( level );
if ( *set & api->signals_pending ) {
/* XXX real info later */
the_info->si_signo = _POSIX_signals_Get_highest( api->signals_pending );
20078e8: 7f ff ff 8e call 2007720 <_POSIX_signals_Get_highest>
20078ec: 90 10 00 02 mov %g2, %o0
_POSIX_signals_Clear_signals(
20078f0: 94 10 00 10 mov %l0, %o2
/* API signals pending? */
_ISR_Disable( level );
if ( *set & api->signals_pending ) {
/* XXX real info later */
the_info->si_signo = _POSIX_signals_Get_highest( api->signals_pending );
20078f4: 92 10 00 08 mov %o0, %o1
_POSIX_signals_Clear_signals(
20078f8: 96 10 20 00 clr %o3
20078fc: 90 10 00 13 mov %l3, %o0
/* API signals pending? */
_ISR_Disable( level );
if ( *set & api->signals_pending ) {
/* XXX real info later */
the_info->si_signo = _POSIX_signals_Get_highest( api->signals_pending );
2007900: d2 24 00 00 st %o1, [ %l0 ]
_POSIX_signals_Clear_signals(
2007904: 40 00 1e 50 call 200f244 <_POSIX_signals_Clear_signals>
2007908: 98 10 20 00 clr %o4
the_info->si_signo,
the_info,
false,
false
);
_ISR_Enable( level );
200790c: 7f ff ec 58 call 2002a6c <sparc_enable_interrupts>
2007910: 90 10 00 12 mov %l2, %o0
the_info->si_code = SI_USER;
2007914: 82 10 20 01 mov 1, %g1
the_info->si_value.sival_int = 0;
2007918: c0 24 20 08 clr [ %l0 + 8 ]
return the_info->si_signo;
200791c: f0 04 00 00 ld [ %l0 ], %i0
false,
false
);
_ISR_Enable( level );
the_info->si_code = SI_USER;
2007920: c2 24 20 04 st %g1, [ %l0 + 4 ]
the_info->si_value.sival_int = 0;
return the_info->si_signo;
2007924: 81 c7 e0 08 ret
2007928: 81 e8 00 00 restore
rtems_set_errno_and_return_minus_one( EINVAL );
interval = _Timespec_To_ticks( timeout );
if ( !interval )
rtems_set_errno_and_return_minus_one( EINVAL );
200792c: 40 00 2d ee call 20130e4 <__errno>
2007930: b0 10 3f ff mov -1, %i0
2007934: 82 10 20 16 mov 0x16, %g1
2007938: c2 22 00 00 st %g1, [ %o0 ]
200793c: 81 c7 e0 08 ret
2007940: 81 e8 00 00 restore
020097f4 <sigwait>:
int sigwait(
const sigset_t *set,
int *sig
)
{
20097f4: 9d e3 bf a0 save %sp, -96, %sp
int status;
status = sigtimedwait( set, NULL, NULL );
20097f8: 92 10 20 00 clr %o1
20097fc: 90 10 00 18 mov %i0, %o0
2009800: 7f ff ff 87 call 200961c <sigtimedwait>
2009804: 94 10 20 00 clr %o2
if ( status != -1 ) {
2009808: 80 a2 3f ff cmp %o0, -1
200980c: 02 80 00 07 be 2009828 <sigwait+0x34>
2009810: 80 a6 60 00 cmp %i1, 0
if ( sig )
2009814: 02 80 00 03 be 2009820 <sigwait+0x2c> <== NEVER TAKEN
2009818: b0 10 20 00 clr %i0
*sig = status;
200981c: d0 26 40 00 st %o0, [ %i1 ]
2009820: 81 c7 e0 08 ret
2009824: 81 e8 00 00 restore
return 0;
}
return errno;
2009828: 40 00 2d 1a call 2014c90 <__errno>
200982c: 01 00 00 00 nop
2009830: f0 02 00 00 ld [ %o0 ], %i0
}
2009834: 81 c7 e0 08 ret
2009838: 81 e8 00 00 restore
02004c18 <siproc>:
/*
* Process input character, with semaphore.
*/
static int
siproc (unsigned char c, struct rtems_termios_tty *tty)
{
2004c18: 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)) {
2004c1c: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED
2004c20: 80 88 6e 78 btst 0xe78, %g1 <== NOT EXECUTED
2004c24: 32 80 00 05 bne,a 2004c38 <siproc+0x20> <== NOT EXECUTED
2004c28: d0 06 60 18 ld [ %i1 + 0x18 ], %o0 <== 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);
2004c2c: b0 0e 20 ff and %i0, 0xff, %i0 <== NOT EXECUTED
2004c30: 7f ff ff 7a call 2004a18 <iproc> <== NOT EXECUTED
2004c34: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Obtain output semaphore if character will be echoed
*/
if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) {
rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004c38: 94 10 20 00 clr %o2 <== NOT EXECUTED
2004c3c: 40 00 07 26 call 20068d4 <rtems_semaphore_obtain> <== NOT EXECUTED
2004c40: 92 10 20 00 clr %o1 <== NOT EXECUTED
i = iproc (c, tty);
2004c44: 90 0e 20 ff and %i0, 0xff, %o0 <== NOT EXECUTED
2004c48: 7f ff ff 74 call 2004a18 <iproc> <== NOT EXECUTED
2004c4c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
2004c50: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release (tty->osem);
2004c54: 40 00 07 67 call 20069f0 <rtems_semaphore_release> <== NOT EXECUTED
2004c58: d0 06 60 18 ld [ %i1 + 0x18 ], %o0 <== NOT EXECUTED
}
else {
i = iproc (c, tty);
}
return i;
}
2004c5c: 81 c7 e0 08 ret <== NOT EXECUTED
2004c60: 81 e8 00 00 restore <== NOT EXECUTED
0200a3a0 <stat>:
int _STAT_NAME(
const char *path,
struct stat *buf
)
{
200a3a0: 9d e3 bf 88 save %sp, -120, %sp
/*
* Check to see if we were passed a valid pointer.
*/
if ( !buf )
200a3a4: 80 a6 60 00 cmp %i1, 0
200a3a8: 02 80 00 34 be 200a478 <stat+0xd8>
200a3ac: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
status = rtems_filesystem_evaluate_path( path, strlen( path ),
200a3b0: 40 01 1b f0 call 2051370 <strlen>
200a3b4: 90 10 00 18 mov %i0, %o0
200a3b8: a0 07 bf ec add %fp, -20, %l0
200a3bc: 92 10 00 08 mov %o0, %o1
200a3c0: 94 10 20 00 clr %o2
200a3c4: 90 10 00 18 mov %i0, %o0
200a3c8: 96 10 00 10 mov %l0, %o3
200a3cc: 98 10 20 01 mov 1, %o4
200a3d0: 7f ff f9 24 call 2008860 <rtems_filesystem_evaluate_path>
200a3d4: b0 10 3f ff mov -1, %i0
0, &loc, _STAT_FOLLOW_LINKS );
if ( status != 0 )
200a3d8: 80 a2 20 00 cmp %o0, 0
200a3dc: 12 80 00 25 bne 200a470 <stat+0xd0>
200a3e0: c2 07 bf f4 ld [ %fp + -12 ], %g1
return -1;
if ( !loc.handlers->fstat_h ){
200a3e4: c4 00 60 18 ld [ %g1 + 0x18 ], %g2
200a3e8: 80 a0 a0 00 cmp %g2, 0
200a3ec: 02 80 00 29 be 200a490 <stat+0xf0> <== NEVER TAKEN
200a3f0: 92 10 00 19 mov %i1, %o1
/*
* Zero out the stat structure so the various support
* versions of stat don't have to.
*/
memset( buf, 0, sizeof(struct stat) );
200a3f4: c0 26 40 00 clr [ %i1 ]
200a3f8: c0 26 60 04 clr [ %i1 + 4 ]
200a3fc: c0 26 60 08 clr [ %i1 + 8 ]
200a400: c0 26 60 0c clr [ %i1 + 0xc ]
200a404: c0 26 60 10 clr [ %i1 + 0x10 ]
200a408: c0 26 60 14 clr [ %i1 + 0x14 ]
200a40c: c0 26 60 18 clr [ %i1 + 0x18 ]
200a410: c0 26 60 1c clr [ %i1 + 0x1c ]
200a414: c0 26 60 20 clr [ %i1 + 0x20 ]
200a418: c0 26 60 24 clr [ %i1 + 0x24 ]
200a41c: c0 26 60 28 clr [ %i1 + 0x28 ]
200a420: c0 26 60 2c clr [ %i1 + 0x2c ]
200a424: c0 26 60 30 clr [ %i1 + 0x30 ]
200a428: c0 26 60 34 clr [ %i1 + 0x34 ]
200a42c: c0 26 60 38 clr [ %i1 + 0x38 ]
200a430: c0 26 60 3c clr [ %i1 + 0x3c ]
200a434: c0 26 60 40 clr [ %i1 + 0x40 ]
200a438: c0 26 60 44 clr [ %i1 + 0x44 ]
status = (*loc.handlers->fstat_h)( &loc, buf );
200a43c: c2 00 60 18 ld [ %g1 + 0x18 ], %g1
200a440: 9f c0 40 00 call %g1
200a444: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
200a448: c2 07 bf f8 ld [ %fp + -8 ], %g1
200a44c: 80 a0 60 00 cmp %g1, 0
200a450: 02 80 00 08 be 200a470 <stat+0xd0> <== NEVER TAKEN
200a454: b0 10 00 08 mov %o0, %i0
200a458: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
200a45c: 80 a0 60 00 cmp %g1, 0
200a460: 02 80 00 1a be 200a4c8 <stat+0x128> <== NEVER TAKEN
200a464: 01 00 00 00 nop
200a468: 9f c0 40 00 call %g1
200a46c: 90 10 00 10 mov %l0, %o0
return status;
}
200a470: 81 c7 e0 08 ret
200a474: 81 e8 00 00 restore
/*
* Check to see if we were passed a valid pointer.
*/
if ( !buf )
rtems_set_errno_and_return_minus_one( EFAULT );
200a478: 40 01 00 02 call 204a480 <__errno>
200a47c: b0 10 3f ff mov -1, %i0
200a480: 82 10 20 0e mov 0xe, %g1
200a484: c2 22 00 00 st %g1, [ %o0 ]
200a488: 81 c7 e0 08 ret
200a48c: 81 e8 00 00 restore
0, &loc, _STAT_FOLLOW_LINKS );
if ( status != 0 )
return -1;
if ( !loc.handlers->fstat_h ){
rtems_filesystem_freenode( &loc );
200a490: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
200a494: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200a498: 02 80 00 08 be 200a4b8 <stat+0x118> <== NOT EXECUTED
200a49c: 01 00 00 00 nop <== NOT EXECUTED
200a4a0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
200a4a4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
200a4a8: 02 80 00 04 be 200a4b8 <stat+0x118> <== NOT EXECUTED
200a4ac: 01 00 00 00 nop <== NOT EXECUTED
200a4b0: 9f c0 40 00 call %g1 <== NOT EXECUTED
200a4b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
200a4b8: 40 00 ff f2 call 204a480 <__errno> <== NOT EXECUTED
200a4bc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200a4c0: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
200a4c4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
200a4c8: 81 c7 e0 08 ret <== NOT EXECUTED
200a4cc: 81 e8 00 00 restore <== NOT EXECUTED
0202e724 <statvfs>:
#include <sys/statvfs.h>
int
statvfs (const char *path, struct statvfs *sb)
{
202e724: 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 ) )
202e728: 40 00 8b 12 call 2051370 <strlen> <== NOT EXECUTED
202e72c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202e730: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED
202e734: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED
202e738: 94 10 20 00 clr %o2 <== NOT EXECUTED
202e73c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
202e740: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED
202e744: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
202e748: 7f ff 68 46 call 2008860 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
202e74c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202e750: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202e754: 12 80 00 23 bne 202e7e0 <statvfs+0xbc> <== NOT EXECUTED
202e758: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
return -1;
mt_entry = loc.mt_entry;
fs_mount_root = &mt_entry->mt_fs_root;
202e75c: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED
202e760: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 <== NOT EXECUTED
202e764: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e768: 02 80 00 20 be 202e7e8 <statvfs+0xc4> <== NOT EXECUTED
202e76c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
if ( !fs_mount_root->ops->statvfs_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
memset (sb, 0, sizeof (struct statvfs));
202e770: c0 26 40 00 clr [ %i1 ] <== NOT EXECUTED
202e774: c0 26 60 04 clr [ %i1 + 4 ] <== NOT EXECUTED
202e778: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED
202e77c: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED
202e780: c0 26 60 10 clr [ %i1 + 0x10 ] <== NOT EXECUTED
202e784: c0 26 60 14 clr [ %i1 + 0x14 ] <== NOT EXECUTED
202e788: c0 26 60 18 clr [ %i1 + 0x18 ] <== NOT EXECUTED
202e78c: c0 26 60 1c clr [ %i1 + 0x1c ] <== NOT EXECUTED
202e790: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
202e794: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
202e798: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
202e79c: c0 26 60 2c clr [ %i1 + 0x2c ] <== NOT EXECUTED
202e7a0: c0 26 60 30 clr [ %i1 + 0x30 ] <== NOT EXECUTED
202e7a4: c0 26 60 34 clr [ %i1 + 0x34 ] <== NOT EXECUTED
result = ( fs_mount_root->ops->statvfs_h )( fs_mount_root, sb );
202e7a8: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED
202e7ac: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 <== NOT EXECUTED
202e7b0: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e7b4: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
202e7b8: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
202e7bc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e7c0: 02 80 00 08 be 202e7e0 <statvfs+0xbc> <== NOT EXECUTED
202e7c4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
202e7c8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
202e7cc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e7d0: 02 80 00 0a be 202e7f8 <statvfs+0xd4> <== NOT EXECUTED
202e7d4: 01 00 00 00 nop <== NOT EXECUTED
202e7d8: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e7dc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return result;
}
202e7e0: 81 c7 e0 08 ret <== NOT EXECUTED
202e7e4: 81 e8 00 00 restore <== NOT EXECUTED
mt_entry = loc.mt_entry;
fs_mount_root = &mt_entry->mt_fs_root;
if ( !fs_mount_root->ops->statvfs_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
202e7e8: 40 00 6f 26 call 204a480 <__errno> <== NOT EXECUTED
202e7ec: 01 00 00 00 nop <== NOT EXECUTED
202e7f0: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
202e7f4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202e7f8: 81 c7 e0 08 ret <== NOT EXECUTED
202e7fc: 81 e8 00 00 restore <== NOT EXECUTED
0202e860 <symlink>:
int symlink(
const char *actualpath,
const char *sympath
)
{
202e860: 9d e3 bf 80 save %sp, -128, %sp
rtems_filesystem_location_info_t loc;
int i;
const char *name_start;
int result;
rtems_filesystem_get_start_loc( sympath, &i, &loc );
202e864: a0 07 bf e4 add %fp, -28, %l0
202e868: 90 10 00 19 mov %i1, %o0
202e86c: 92 07 bf fc add %fp, -4, %o1
202e870: 7f ff 6f 1e call 200a4e8 <rtems_filesystem_get_start_loc>
202e874: 94 10 00 10 mov %l0, %o2
if ( !loc.ops->evalformake_h ) {
202e878: c2 07 bf f0 ld [ %fp + -16 ], %g1
202e87c: c2 00 60 04 ld [ %g1 + 4 ], %g1
202e880: 80 a0 60 00 cmp %g1, 0
202e884: 02 80 00 24 be 202e914 <symlink+0xb4> <== NEVER TAKEN
202e888: a2 10 00 18 mov %i0, %l1
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start );
202e88c: d0 07 bf fc ld [ %fp + -4 ], %o0
202e890: 92 10 00 10 mov %l0, %o1
202e894: 90 06 40 08 add %i1, %o0, %o0
202e898: 94 07 bf f8 add %fp, -8, %o2
202e89c: 9f c0 40 00 call %g1
202e8a0: b0 10 3f ff mov -1, %i0
if ( result != 0 )
202e8a4: 80 a2 20 00 cmp %o0, 0
202e8a8: 12 80 00 13 bne 202e8f4 <symlink+0x94>
202e8ac: c4 07 bf f0 ld [ %fp + -16 ], %g2
return -1;
if ( !loc.ops->symlink_h ) {
202e8b0: c2 00 a0 38 ld [ %g2 + 0x38 ], %g1
202e8b4: 80 a0 60 00 cmp %g1, 0
202e8b8: 02 80 00 11 be 202e8fc <symlink+0x9c> <== NEVER TAKEN
202e8bc: d4 07 bf f8 ld [ %fp + -8 ], %o2
rtems_filesystem_freenode( &loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.ops->symlink_h)( &loc, actualpath, name_start);
202e8c0: 92 10 00 11 mov %l1, %o1
202e8c4: 9f c0 40 00 call %g1
202e8c8: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
202e8cc: c2 07 bf f0 ld [ %fp + -16 ], %g1
202e8d0: 80 a0 60 00 cmp %g1, 0
202e8d4: 02 80 00 08 be 202e8f4 <symlink+0x94> <== NEVER TAKEN
202e8d8: b0 10 00 08 mov %o0, %i0
202e8dc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202e8e0: 80 a0 60 00 cmp %g1, 0
202e8e4: 02 80 00 10 be 202e924 <symlink+0xc4> <== NEVER TAKEN
202e8e8: 01 00 00 00 nop
202e8ec: 9f c0 40 00 call %g1
202e8f0: 90 10 00 10 mov %l0, %o0
return result;
}
202e8f4: 81 c7 e0 08 ret
202e8f8: 81 e8 00 00 restore
result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start );
if ( result != 0 )
return -1;
if ( !loc.ops->symlink_h ) {
rtems_filesystem_freenode( &loc );
202e8fc: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
202e900: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202e904: 02 80 00 04 be 202e914 <symlink+0xb4> <== NOT EXECUTED
202e908: 01 00 00 00 nop <== NOT EXECUTED
202e90c: 9f c0 40 00 call %g1 <== NOT EXECUTED
202e910: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202e914: 40 00 6e db call 204a480 <__errno> <== NOT EXECUTED
202e918: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202e91c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202e920: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202e924: 81 c7 e0 08 ret <== NOT EXECUTED
202e928: 81 e8 00 00 restore <== NOT EXECUTED
020054ac <sync_per_thread>:
fdatasync(fn);
}
/* iterate over all FILE *'s for this thread */
static void sync_per_thread(Thread_Control *t)
{
20054ac: 9d e3 bf a0 save %sp, -96, %sp
/*
* The sync_wrapper() function will operate on the current thread's
* reent structure so we will temporarily use that.
*/
this_reent = t->libc_reent;
20054b0: c2 06 21 64 ld [ %i0 + 0x164 ], %g1
if ( this_reent ) {
20054b4: 80 a0 60 00 cmp %g1, 0
20054b8: 02 80 00 0b be 20054e4 <sync_per_thread+0x38> <== NEVER TAKEN
20054bc: 21 00 80 85 sethi %hi(0x2021400), %l0
current_reent = _Thread_Executing->libc_reent;
20054c0: c4 04 20 a0 ld [ %l0 + 0xa0 ], %g2 ! 20214a0 <_Thread_Executing>
_Thread_Executing->libc_reent = this_reent;
_fwalk (t->libc_reent, sync_wrapper);
20054c4: 13 00 80 15 sethi %hi(0x2005400), %o1
* The sync_wrapper() function will operate on the current thread's
* reent structure so we will temporarily use that.
*/
this_reent = t->libc_reent;
if ( this_reent ) {
current_reent = _Thread_Executing->libc_reent;
20054c8: e2 00 a1 64 ld [ %g2 + 0x164 ], %l1
_Thread_Executing->libc_reent = this_reent;
20054cc: c2 20 a1 64 st %g1, [ %g2 + 0x164 ]
_fwalk (t->libc_reent, sync_wrapper);
20054d0: d0 06 21 64 ld [ %i0 + 0x164 ], %o0
20054d4: 40 00 3a 9f call 2013f50 <_fwalk>
20054d8: 92 12 61 14 or %o1, 0x114, %o1
_Thread_Executing->libc_reent = current_reent;
20054dc: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
20054e0: e2 20 61 64 st %l1, [ %g1 + 0x164 ]
20054e4: 81 c7 e0 08 ret
20054e8: 81 e8 00 00 restore
020063fc <sysconf>:
*/
long sysconf(
int name
)
{
20063fc: 9d e3 bf a0 save %sp, -96, %sp
if ( name == _SC_CLK_TCK )
2006400: 80 a6 20 02 cmp %i0, 2
2006404: 02 80 00 0f be 2006440 <sysconf+0x44>
2006408: 82 10 00 18 mov %i0, %g1
return (TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick());
if ( name == _SC_OPEN_MAX )
200640c: 80 a6 20 04 cmp %i0, 4
2006410: 02 80 00 13 be 200645c <sysconf+0x60>
2006414: 80 a6 20 33 cmp %i0, 0x33
return rtems_libio_number_iops;
if ( name == _SC_GETPW_R_SIZE_MAX )
2006418: 02 80 00 08 be 2006438 <sysconf+0x3c>
200641c: b0 10 24 00 mov 0x400, %i0
return 1024;
if ( name == _SC_PAGESIZE )
2006420: 80 a0 60 08 cmp %g1, 8
2006424: 02 80 00 05 be 2006438 <sysconf+0x3c>
2006428: b0 06 2c 00 add %i0, 0xc00, %i0
return PAGE_SIZE;
#if defined(__sparc__)
if ( name == 515 ) /* Solaris _SC_STACK_PROT */
200642c: 80 a0 62 03 cmp %g1, 0x203
2006430: 12 80 00 0f bne 200646c <sysconf+0x70> <== ALWAYS TAKEN
2006434: b0 10 20 00 clr %i0
return 0;
#endif
rtems_set_errno_and_return_minus_one( EINVAL );
}
2006438: 81 c7 e0 08 ret
200643c: 81 e8 00 00 restore
long sysconf(
int name
)
{
if ( name == _SC_CLK_TCK )
return (TOD_MICROSECONDS_PER_SECOND /
2006440: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006444: d2 00 61 c8 ld [ %g1 + 0x1c8 ], %o1 ! 201fdc8 <Configuration+0xc>
2006448: 11 00 03 d0 sethi %hi(0xf4000), %o0
200644c: 40 00 55 f8 call 201bc2c <.udiv>
2006450: 90 12 22 40 or %o0, 0x240, %o0 ! f4240 <PROM_START+0xf4240>
2006454: 81 c7 e0 08 ret
2006458: 91 e8 00 08 restore %g0, %o0, %o0
rtems_configuration_get_microseconds_per_tick());
if ( name == _SC_OPEN_MAX )
return rtems_libio_number_iops;
200645c: 03 00 80 7f sethi %hi(0x201fc00), %g1
2006460: f0 00 60 e4 ld [ %g1 + 0xe4 ], %i0 ! 201fce4 <rtems_libio_number_iops>
2006464: 81 c7 e0 08 ret
2006468: 81 e8 00 00 restore
#if defined(__sparc__)
if ( name == 515 ) /* Solaris _SC_STACK_PROT */
return 0;
#endif
rtems_set_errno_and_return_minus_one( EINVAL );
200646c: 40 00 2f 4d call 20121a0 <__errno>
2006470: b0 10 3f ff mov -1, %i0
2006474: 82 10 20 16 mov 0x16, %g1
2006478: c2 22 00 00 st %g1, [ %o0 ]
}
200647c: 81 c7 e0 08 ret
2006480: 81 e8 00 00 restore
0201632c <tcsetattr>:
int tcsetattr(
int fd,
int opt,
struct termios *tp
)
{
201632c: 9d e3 bf a0 save %sp, -96, %sp
switch (opt) {
2016330: 80 a6 60 00 cmp %i1, 0
2016334: 02 80 00 10 be 2016374 <tcsetattr+0x48> <== ALWAYS TAKEN
2016338: 80 a6 60 01 cmp %i1, 1
201633c: 02 80 00 08 be 201635c <tcsetattr+0x30> <== NOT EXECUTED
2016340: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
default:
rtems_set_errno_and_return_minus_one( ENOTSUP );
2016344: 40 00 17 f2 call 201c30c <__errno> <== NOT EXECUTED
2016348: 01 00 00 00 nop <== NOT EXECUTED
201634c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
2016350: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
* Fall through to....
*/
case TCSANOW:
return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );
}
}
2016354: 81 c7 e0 08 ret <== NOT EXECUTED
2016358: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
switch (opt) {
default:
rtems_set_errno_and_return_minus_one( ENOTSUP );
case TCSADRAIN:
if (ioctl( fd, RTEMS_IO_TCDRAIN, NULL ) < 0)
201635c: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED
2016360: 40 00 12 8d call 201ad94 <ioctl> <== NOT EXECUTED
2016364: 94 10 20 00 clr %o2 <== NOT EXECUTED
2016368: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
201636c: 06 bf ff fa bl 2016354 <tcsetattr+0x28> <== NOT EXECUTED
2016370: 01 00 00 00 nop <== NOT EXECUTED
return -1;
/*
* Fall through to....
*/
case TCSANOW:
return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );
2016374: 40 00 12 88 call 201ad94 <ioctl>
2016378: 93 e8 20 02 restore %g0, 2, %o1
0200676c <timer_create>:
int timer_create(
clockid_t clock_id,
struct sigevent *evp,
timer_t *timerid
)
{
200676c: 9d e3 bf a0 save %sp, -96, %sp
POSIX_Timer_Control *ptimer;
if ( clock_id != CLOCK_REALTIME )
2006770: 80 a6 20 01 cmp %i0, 1
2006774: 12 80 00 3d bne 2006868 <timer_create+0xfc>
2006778: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !timerid )
200677c: 02 80 00 3b be 2006868 <timer_create+0xfc>
2006780: 80 a6 60 00 cmp %i1, 0
/*
* The data of the structure evp are checked in order to verify if they
* are coherent.
*/
if (evp != NULL) {
2006784: 02 80 00 0e be 20067bc <timer_create+0x50>
2006788: 03 00 80 8f sethi %hi(0x2023c00), %g1
/* The structure has data */
if ( ( evp->sigev_notify != SIGEV_NONE ) &&
200678c: c2 06 40 00 ld [ %i1 ], %g1
2006790: 82 00 7f ff add %g1, -1, %g1
2006794: 80 a0 60 01 cmp %g1, 1
2006798: 18 80 00 34 bgu 2006868 <timer_create+0xfc> <== NEVER TAKEN
200679c: 01 00 00 00 nop
( evp->sigev_notify != SIGEV_SIGNAL ) ) {
/* The value of the field sigev_notify is not valid */
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( !evp->sigev_signo )
20067a0: c2 06 60 04 ld [ %i1 + 4 ], %g1
20067a4: 80 a0 60 00 cmp %g1, 0
20067a8: 02 80 00 30 be 2006868 <timer_create+0xfc> <== NEVER TAKEN
20067ac: 82 00 7f ff add %g1, -1, %g1
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(evp->sigev_signo) )
20067b0: 80 a0 60 1f cmp %g1, 0x1f
20067b4: 18 80 00 2d bgu 2006868 <timer_create+0xfc> <== NEVER TAKEN
20067b8: 03 00 80 8f sethi %hi(0x2023c00), %g1
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
20067bc: c4 00 60 70 ld [ %g1 + 0x70 ], %g2 ! 2023c70 <_Thread_Dispatch_disable_level>
20067c0: 84 00 a0 01 inc %g2
20067c4: c4 20 60 70 st %g2, [ %g1 + 0x70 ]
* the inactive chain of free timer control blocks.
*/
RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Allocate( void )
{
return (POSIX_Timer_Control *) _Objects_Allocate( &_POSIX_Timer_Information );
20067c8: 21 00 80 8f sethi %hi(0x2023c00), %l0
20067cc: 40 00 08 41 call 20088d0 <_Objects_Allocate>
20067d0: 90 14 23 c0 or %l0, 0x3c0, %o0 ! 2023fc0 <_POSIX_Timer_Information>
/*
* Allocate a timer
*/
ptimer = _POSIX_Timer_Allocate();
if ( !ptimer ) {
20067d4: 80 a2 20 00 cmp %o0, 0
20067d8: 02 80 00 2a be 2006880 <timer_create+0x114>
20067dc: 82 10 20 02 mov 2, %g1
rtems_set_errno_and_return_minus_one( EAGAIN );
}
/* The data of the created timer are stored to use them later */
ptimer->state = POSIX_TIMER_STATE_CREATE_NEW;
20067e0: c2 2a 20 3c stb %g1, [ %o0 + 0x3c ]
ptimer->thread_id = _Thread_Executing->Object.id;
20067e4: 03 00 80 8f sethi %hi(0x2023c00), %g1
20067e8: c2 00 61 30 ld [ %g1 + 0x130 ], %g1 ! 2023d30 <_Thread_Executing>
if ( evp != NULL ) {
20067ec: 80 a6 60 00 cmp %i1, 0
}
/* The data of the created timer are stored to use them later */
ptimer->state = POSIX_TIMER_STATE_CREATE_NEW;
ptimer->thread_id = _Thread_Executing->Object.id;
20067f0: c2 00 60 08 ld [ %g1 + 8 ], %g1
if ( evp != NULL ) {
20067f4: 02 80 00 08 be 2006814 <timer_create+0xa8>
20067f8: c2 22 20 38 st %g1, [ %o0 + 0x38 ]
ptimer->inf.sigev_notify = evp->sigev_notify;
ptimer->inf.sigev_signo = evp->sigev_signo;
ptimer->inf.sigev_value = evp->sigev_value;
20067fc: c2 06 60 08 ld [ %i1 + 8 ], %g1
ptimer->state = POSIX_TIMER_STATE_CREATE_NEW;
ptimer->thread_id = _Thread_Executing->Object.id;
if ( evp != NULL ) {
ptimer->inf.sigev_notify = evp->sigev_notify;
2006800: c6 06 40 00 ld [ %i1 ], %g3
ptimer->inf.sigev_signo = evp->sigev_signo;
2006804: c4 06 60 04 ld [ %i1 + 4 ], %g2
ptimer->state = POSIX_TIMER_STATE_CREATE_NEW;
ptimer->thread_id = _Thread_Executing->Object.id;
if ( evp != NULL ) {
ptimer->inf.sigev_notify = evp->sigev_notify;
2006808: c6 22 20 40 st %g3, [ %o0 + 0x40 ]
ptimer->inf.sigev_signo = evp->sigev_signo;
200680c: c4 22 20 44 st %g2, [ %o0 + 0x44 ]
ptimer->inf.sigev_value = evp->sigev_value;
2006810: c2 22 20 48 st %g1, [ %o0 + 0x48 ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2006814: c4 12 20 0a lduh [ %o0 + 0xa ], %g2
2006818: a0 14 23 c0 or %l0, 0x3c0, %l0
200681c: c6 04 20 1c ld [ %l0 + 0x1c ], %g3
2006820: c2 02 20 08 ld [ %o0 + 8 ], %g1
2006824: 85 28 a0 02 sll %g2, 2, %g2
2006828: d0 20 c0 02 st %o0, [ %g3 + %g2 ]
_Objects_Get_index( the_object->id ),
the_object
);
/* ASSERT: information->is_string == false */
the_object->name.name_u32 = name;
200682c: c0 22 20 0c clr [ %o0 + 0xc ]
}
ptimer->overrun = 0;
2006830: c0 22 20 68 clr [ %o0 + 0x68 ]
ptimer->timer_data.it_value.tv_sec = 0;
2006834: c0 22 20 5c clr [ %o0 + 0x5c ]
ptimer->timer_data.it_value.tv_nsec = 0;
2006838: c0 22 20 60 clr [ %o0 + 0x60 ]
ptimer->timer_data.it_interval.tv_sec = 0;
200683c: c0 22 20 54 clr [ %o0 + 0x54 ]
ptimer->timer_data.it_interval.tv_nsec = 0;
2006840: c0 22 20 58 clr [ %o0 + 0x58 ]
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
the_watchdog->id = id;
2006844: c0 22 20 30 clr [ %o0 + 0x30 ]
_Watchdog_Initialize( &ptimer->Timer, NULL, 0, NULL );
_Objects_Open_u32(&_POSIX_Timer_Information, &ptimer->Object, 0);
*timerid = ptimer->Object.id;
2006848: c2 26 80 00 st %g1, [ %i2 ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
200684c: c0 22 20 18 clr [ %o0 + 0x18 ]
the_watchdog->routine = routine;
2006850: c0 22 20 2c clr [ %o0 + 0x2c ]
the_watchdog->id = id;
the_watchdog->user_data = user_data;
2006854: c0 22 20 34 clr [ %o0 + 0x34 ]
_Thread_Enable_dispatch();
2006858: 40 00 0b f1 call 200981c <_Thread_Enable_dispatch>
200685c: b0 10 20 00 clr %i0
return 0;
}
2006860: 81 c7 e0 08 ret
2006864: 81 e8 00 00 restore
if ( !evp->sigev_signo )
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !is_valid_signo(evp->sigev_signo) )
rtems_set_errno_and_return_minus_one( EINVAL );
2006868: 40 00 2f b1 call 201272c <__errno>
200686c: b0 10 3f ff mov -1, %i0
2006870: 82 10 20 16 mov 0x16, %g1
2006874: c2 22 00 00 st %g1, [ %o0 ]
2006878: 81 c7 e0 08 ret
200687c: 81 e8 00 00 restore
/*
* Allocate a timer
*/
ptimer = _POSIX_Timer_Allocate();
if ( !ptimer ) {
_Thread_Enable_dispatch();
2006880: 40 00 0b e7 call 200981c <_Thread_Enable_dispatch>
2006884: b0 10 3f ff mov -1, %i0
rtems_set_errno_and_return_minus_one( EAGAIN );
2006888: 40 00 2f a9 call 201272c <__errno>
200688c: 01 00 00 00 nop
2006890: 82 10 20 0b mov 0xb, %g1 ! b <PROM_START+0xb>
2006894: c2 22 00 00 st %g1, [ %o0 ]
2006898: 81 c7 e0 08 ret
200689c: 81 e8 00 00 restore
020068a0 <timer_settime>:
timer_t timerid,
int flags,
const struct itimerspec *value,
struct itimerspec *ovalue
)
{
20068a0: 9d e3 bf 80 save %sp, -128, %sp
Objects_Locations location;
bool activated;
uint32_t initial_period;
struct itimerspec normalize;
if ( !value )
20068a4: 80 a6 a0 00 cmp %i2, 0
20068a8: 02 80 00 89 be 2006acc <timer_settime+0x22c> <== NEVER TAKEN
20068ac: 03 0e e6 b2 sethi %hi(0x3b9ac800), %g1
rtems_set_errno_and_return_minus_one( EINVAL );
/* First, it verifies if the structure "value" is correct */
if ( ( value->it_value.tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) ||
20068b0: c4 06 a0 0c ld [ %i2 + 0xc ], %g2
20068b4: 82 10 61 ff or %g1, 0x1ff, %g1
20068b8: 80 a0 80 01 cmp %g2, %g1
20068bc: 18 80 00 84 bgu 2006acc <timer_settime+0x22c>
20068c0: 01 00 00 00 nop
( value->it_value.tv_nsec < 0 ) ||
( value->it_interval.tv_nsec >= TOD_NANOSECONDS_PER_SECOND) ||
20068c4: c4 06 a0 04 ld [ %i2 + 4 ], %g2
20068c8: 80 a0 80 01 cmp %g2, %g1
20068cc: 18 80 00 80 bgu 2006acc <timer_settime+0x22c> <== NEVER TAKEN
20068d0: 80 a6 60 00 cmp %i1, 0
( value->it_interval.tv_nsec < 0 )) {
/* The number of nanoseconds is not correct */
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) {
20068d4: 12 80 00 7c bne 2006ac4 <timer_settime+0x224>
20068d8: 80 a6 60 04 cmp %i1, 4
rtems_set_errno_and_return_minus_one( EINVAL );
}
normalize = *value;
20068dc: c8 06 80 00 ld [ %i2 ], %g4
20068e0: c6 06 a0 04 ld [ %i2 + 4 ], %g3
20068e4: c4 06 a0 08 ld [ %i2 + 8 ], %g2
20068e8: c2 06 a0 0c ld [ %i2 + 0xc ], %g1
20068ec: c8 27 bf e4 st %g4, [ %fp + -28 ]
20068f0: c6 27 bf e8 st %g3, [ %fp + -24 ]
20068f4: c4 27 bf ec st %g2, [ %fp + -20 ]
/* Convert absolute to relative time */
if (flags == TIMER_ABSTIME) {
20068f8: 80 a6 60 04 cmp %i1, 4
20068fc: 02 80 00 3b be 20069e8 <timer_settime+0x148>
2006900: c2 27 bf f0 st %g1, [ %fp + -16 ]
RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Get (
timer_t id,
Objects_Locations *location
)
{
return (POSIX_Timer_Control *)
2006904: 92 10 00 18 mov %i0, %o1
2006908: 11 00 80 8f sethi %hi(0x2023c00), %o0
200690c: 94 07 bf fc add %fp, -4, %o2
2006910: 40 00 09 44 call 2008e20 <_Objects_Get>
2006914: 90 12 23 c0 or %o0, 0x3c0, %o0
* something with the structure of times of the timer: to stop, start
* or start it again
*/
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
2006918: c2 07 bf fc ld [ %fp + -4 ], %g1
200691c: 80 a0 60 00 cmp %g1, 0
2006920: 12 80 00 48 bne 2006a40 <timer_settime+0x1a0> <== NEVER TAKEN
2006924: a0 10 00 08 mov %o0, %l0
case OBJECTS_LOCAL:
/* First, it verifies if the timer must be stopped */
if ( normalize.it_value.tv_sec == 0 && normalize.it_value.tv_nsec == 0 ) {
2006928: c2 07 bf ec ld [ %fp + -20 ], %g1
200692c: 80 a0 60 00 cmp %g1, 0
2006930: 12 80 00 05 bne 2006944 <timer_settime+0xa4>
2006934: c2 07 bf f0 ld [ %fp + -16 ], %g1
2006938: 80 a0 60 00 cmp %g1, 0
200693c: 02 80 00 47 be 2006a58 <timer_settime+0x1b8>
2006940: 01 00 00 00 nop
_Thread_Enable_dispatch();
return 0;
}
/* Convert from seconds and nanoseconds to ticks */
ptimer->ticks = _Timespec_To_ticks( &value->it_interval );
2006944: 40 00 0f b8 call 200a824 <_Timespec_To_ticks>
2006948: 90 10 00 1a mov %i2, %o0
200694c: d0 24 20 64 st %o0, [ %l0 + 0x64 ]
initial_period = _Timespec_To_ticks( &normalize.it_value );
2006950: 40 00 0f b5 call 200a824 <_Timespec_To_ticks>
2006954: 90 07 bf ec add %fp, -20, %o0
activated = _POSIX_Timer_Insert_helper(
2006958: d4 04 20 08 ld [ %l0 + 8 ], %o2
return 0;
}
/* Convert from seconds and nanoseconds to ticks */
ptimer->ticks = _Timespec_To_ticks( &value->it_interval );
initial_period = _Timespec_To_ticks( &normalize.it_value );
200695c: 92 10 00 08 mov %o0, %o1
activated = _POSIX_Timer_Insert_helper(
2006960: 17 00 80 1a sethi %hi(0x2006800), %o3
2006964: 90 04 20 10 add %l0, 0x10, %o0
2006968: 96 12 e2 e4 or %o3, 0x2e4, %o3
200696c: 40 00 1f a1 call 200e7f0 <_POSIX_Timer_Insert_helper>
2006970: 98 10 00 10 mov %l0, %o4
initial_period,
ptimer->Object.id,
_POSIX_Timer_TSR,
ptimer
);
if ( !activated ) {
2006974: 80 8a 20 ff btst 0xff, %o0
2006978: 02 80 00 18 be 20069d8 <timer_settime+0x138>
200697c: 80 a6 e0 00 cmp %i3, 0
/*
* The timer has been started and is running. So we return the
* old ones in "ovalue"
*/
if ( ovalue )
2006980: 02 80 00 0b be 20069ac <timer_settime+0x10c>
2006984: c2 07 bf e4 ld [ %fp + -28 ], %g1
*ovalue = ptimer->timer_data;
2006988: c2 04 20 54 ld [ %l0 + 0x54 ], %g1
200698c: c2 26 c0 00 st %g1, [ %i3 ]
2006990: c2 04 20 58 ld [ %l0 + 0x58 ], %g1
2006994: c2 26 e0 04 st %g1, [ %i3 + 4 ]
2006998: c2 04 20 5c ld [ %l0 + 0x5c ], %g1
200699c: c2 26 e0 08 st %g1, [ %i3 + 8 ]
20069a0: c2 04 20 60 ld [ %l0 + 0x60 ], %g1
20069a4: c2 26 e0 0c st %g1, [ %i3 + 0xc ]
ptimer->timer_data = normalize;
20069a8: c2 07 bf e4 ld [ %fp + -28 ], %g1
/* Indicate that the time is running */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
20069ac: 84 10 20 03 mov 3, %g2
* The timer has been started and is running. So we return the
* old ones in "ovalue"
*/
if ( ovalue )
*ovalue = ptimer->timer_data;
ptimer->timer_data = normalize;
20069b0: c2 24 20 54 st %g1, [ %l0 + 0x54 ]
20069b4: c2 07 bf e8 ld [ %fp + -24 ], %g1
/* Indicate that the time is running */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
_TOD_Get( &ptimer->time );
20069b8: 90 04 20 6c add %l0, 0x6c, %o0
* The timer has been started and is running. So we return the
* old ones in "ovalue"
*/
if ( ovalue )
*ovalue = ptimer->timer_data;
ptimer->timer_data = normalize;
20069bc: c2 24 20 58 st %g1, [ %l0 + 0x58 ]
20069c0: c2 07 bf ec ld [ %fp + -20 ], %g1
20069c4: c2 24 20 5c st %g1, [ %l0 + 0x5c ]
20069c8: c2 07 bf f0 ld [ %fp + -16 ], %g1
/* Indicate that the time is running */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
20069cc: c4 2c 20 3c stb %g2, [ %l0 + 0x3c ]
_TOD_Get( &ptimer->time );
20069d0: 40 00 06 55 call 2008324 <_TOD_Get>
20069d4: c2 24 20 60 st %g1, [ %l0 + 0x60 ]
_Thread_Enable_dispatch();
20069d8: 40 00 0b 91 call 200981c <_Thread_Enable_dispatch>
20069dc: b0 10 20 00 clr %i0
return 0;
20069e0: 81 c7 e0 08 ret
20069e4: 81 e8 00 00 restore
normalize = *value;
/* Convert absolute to relative time */
if (flags == TIMER_ABSTIME) {
struct timespec now;
_TOD_Get( &now );
20069e8: a0 07 bf f4 add %fp, -12, %l0
20069ec: 40 00 06 4e call 2008324 <_TOD_Get>
20069f0: 90 10 00 10 mov %l0, %o0
/* Check for seconds in the past */
if ( _Timespec_Greater_than( &now, &normalize.it_value ) )
20069f4: a2 07 bf ec add %fp, -20, %l1
20069f8: 90 10 00 10 mov %l0, %o0
20069fc: 40 00 0f 62 call 200a784 <_Timespec_Greater_than>
2006a00: 92 10 00 11 mov %l1, %o1
2006a04: 80 8a 20 ff btst 0xff, %o0
2006a08: 12 80 00 31 bne 2006acc <timer_settime+0x22c>
2006a0c: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( EINVAL );
_Timespec_Subtract( &now, &normalize.it_value, &normalize.it_value );
2006a10: 92 10 00 11 mov %l1, %o1
2006a14: 40 00 0f 6e call 200a7cc <_Timespec_Subtract>
2006a18: 94 10 00 11 mov %l1, %o2
2006a1c: 92 10 00 18 mov %i0, %o1
2006a20: 11 00 80 8f sethi %hi(0x2023c00), %o0
2006a24: 94 07 bf fc add %fp, -4, %o2
2006a28: 40 00 08 fe call 2008e20 <_Objects_Get>
2006a2c: 90 12 23 c0 or %o0, 0x3c0, %o0
* something with the structure of times of the timer: to stop, start
* or start it again
*/
ptimer = _POSIX_Timer_Get( timerid, &location );
switch ( location ) {
2006a30: c2 07 bf fc ld [ %fp + -4 ], %g1
2006a34: 80 a0 60 00 cmp %g1, 0
2006a38: 02 bf ff bc be 2006928 <timer_settime+0x88>
2006a3c: a0 10 00 08 mov %o0, %l0
#endif
case OBJECTS_ERROR:
break;
}
rtems_set_errno_and_return_minus_one( EINVAL );
2006a40: 40 00 2f 3b call 201272c <__errno>
2006a44: b0 10 3f ff mov -1, %i0
2006a48: 82 10 20 16 mov 0x16, %g1
2006a4c: c2 22 00 00 st %g1, [ %o0 ]
}
2006a50: 81 c7 e0 08 ret
2006a54: 81 e8 00 00 restore
case OBJECTS_LOCAL:
/* First, it verifies if the timer must be stopped */
if ( normalize.it_value.tv_sec == 0 && normalize.it_value.tv_nsec == 0 ) {
/* Stop the timer */
(void) _Watchdog_Remove( &ptimer->Timer );
2006a58: 40 00 10 bb call 200ad44 <_Watchdog_Remove>
2006a5c: 90 02 20 10 add %o0, 0x10, %o0
/* The old data of the timer are returned */
if ( ovalue )
2006a60: 80 a6 e0 00 cmp %i3, 0
2006a64: 02 80 00 0b be 2006a90 <timer_settime+0x1f0>
2006a68: c2 07 bf e4 ld [ %fp + -28 ], %g1
*ovalue = ptimer->timer_data;
2006a6c: c2 04 20 54 ld [ %l0 + 0x54 ], %g1
2006a70: c2 26 c0 00 st %g1, [ %i3 ]
2006a74: c2 04 20 58 ld [ %l0 + 0x58 ], %g1
2006a78: c2 26 e0 04 st %g1, [ %i3 + 4 ]
2006a7c: c2 04 20 5c ld [ %l0 + 0x5c ], %g1
2006a80: c2 26 e0 08 st %g1, [ %i3 + 8 ]
2006a84: c2 04 20 60 ld [ %l0 + 0x60 ], %g1
2006a88: c2 26 e0 0c st %g1, [ %i3 + 0xc ]
/* The new data are set */
ptimer->timer_data = normalize;
2006a8c: c2 07 bf e4 ld [ %fp + -28 ], %g1
/* Indicates that the timer is created and stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
2006a90: 84 10 20 04 mov 4, %g2
(void) _Watchdog_Remove( &ptimer->Timer );
/* The old data of the timer are returned */
if ( ovalue )
*ovalue = ptimer->timer_data;
/* The new data are set */
ptimer->timer_data = normalize;
2006a94: c2 24 20 54 st %g1, [ %l0 + 0x54 ]
2006a98: c2 07 bf e8 ld [ %fp + -24 ], %g1
/* Indicates that the timer is created and stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
/* Returns with success */
_Thread_Enable_dispatch();
2006a9c: b0 10 20 00 clr %i0
(void) _Watchdog_Remove( &ptimer->Timer );
/* The old data of the timer are returned */
if ( ovalue )
*ovalue = ptimer->timer_data;
/* The new data are set */
ptimer->timer_data = normalize;
2006aa0: c2 24 20 58 st %g1, [ %l0 + 0x58 ]
2006aa4: c2 07 bf ec ld [ %fp + -20 ], %g1
2006aa8: c2 24 20 5c st %g1, [ %l0 + 0x5c ]
2006aac: c2 07 bf f0 ld [ %fp + -16 ], %g1
/* Indicates that the timer is created and stopped */
ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;
2006ab0: c4 2c 20 3c stb %g2, [ %l0 + 0x3c ]
/* Returns with success */
_Thread_Enable_dispatch();
2006ab4: 40 00 0b 5a call 200981c <_Thread_Enable_dispatch>
2006ab8: c2 24 20 60 st %g1, [ %l0 + 0x60 ]
return 0;
2006abc: 81 c7 e0 08 ret
2006ac0: 81 e8 00 00 restore
( value->it_interval.tv_nsec < 0 )) {
/* The number of nanoseconds is not correct */
rtems_set_errno_and_return_minus_one( EINVAL );
}
if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) {
2006ac4: 22 bf ff 87 be,a 20068e0 <timer_settime+0x40>
2006ac8: c8 06 80 00 ld [ %i2 ], %g4
if (flags == TIMER_ABSTIME) {
struct timespec now;
_TOD_Get( &now );
/* Check for seconds in the past */
if ( _Timespec_Greater_than( &now, &normalize.it_value ) )
rtems_set_errno_and_return_minus_one( EINVAL );
2006acc: 40 00 2f 18 call 201272c <__errno>
2006ad0: b0 10 3f ff mov -1, %i0
2006ad4: 82 10 20 16 mov 0x16, %g1
2006ad8: c2 22 00 00 st %g1, [ %o0 ]
2006adc: 81 c7 e0 08 ret
2006ae0: 81 e8 00 00 restore
020066d0 <ualarm>:
useconds_t ualarm(
useconds_t useconds,
useconds_t interval
)
{
20066d0: 9d e3 bf 98 save %sp, -104, %sp
/*
* Initialize the timer used to implement alarm().
*/
if ( !the_timer->routine ) {
20066d4: 21 00 80 86 sethi %hi(0x2021800), %l0
20066d8: a0 14 23 b0 or %l0, 0x3b0, %l0 ! 2021bb0 <_POSIX_signals_Ualarm_timer>
20066dc: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
20066e0: 80 a0 60 00 cmp %g1, 0
20066e4: 02 80 00 24 be 2006774 <ualarm+0xa4>
20066e8: a2 10 00 18 mov %i0, %l1
_Watchdog_Initialize( the_timer, _POSIX_signals_Ualarm_TSR, 0, NULL );
} else {
Watchdog_States state;
state = _Watchdog_Remove( the_timer );
20066ec: 40 00 10 8e call 200a924 <_Watchdog_Remove>
20066f0: 90 10 00 10 mov %l0, %o0
if ( (state == WATCHDOG_ACTIVE) || (state == WATCHDOG_REMOVE_IT) ) {
20066f4: 90 02 3f fe add %o0, -2, %o0
20066f8: 80 a2 20 01 cmp %o0, 1
20066fc: 08 80 00 26 bleu 2006794 <ualarm+0xc4> <== ALWAYS TAKEN
2006700: b0 10 20 00 clr %i0
/*
* If useconds is non-zero, then the caller wants to schedule
* the alarm repeatedly at that interval. If the interval is
* less than a single clock tick, then fudge it to a clock tick.
*/
if ( useconds ) {
2006704: 80 a4 60 00 cmp %l1, 0
2006708: 02 80 00 19 be 200676c <ualarm+0x9c>
200670c: 25 00 03 d0 sethi %hi(0xf4000), %l2
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
2006710: 90 10 00 11 mov %l1, %o0
2006714: 40 00 59 06 call 201cb2c <.udiv>
2006718: 92 14 a2 40 or %l2, 0x240, %o1
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
200671c: 92 14 a2 40 or %l2, 0x240, %o1
* less than a single clock tick, then fudge it to a clock tick.
*/
if ( useconds ) {
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
2006720: d0 27 bf f8 st %o0, [ %fp + -8 ]
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
2006724: 40 00 59 ae call 201cddc <.urem>
2006728: 90 10 00 11 mov %l1, %o0
200672c: 85 2a 20 07 sll %o0, 7, %g2
2006730: 83 2a 20 02 sll %o0, 2, %g1
2006734: 82 20 80 01 sub %g2, %g1, %g1
2006738: 90 00 40 08 add %g1, %o0, %o0
200673c: 91 2a 20 03 sll %o0, 3, %o0
ticks = _Timespec_To_ticks( &tp );
2006740: a2 07 bf f8 add %fp, -8, %l1
*/
if ( useconds ) {
Watchdog_Interval ticks;
tp.tv_sec = useconds / TOD_MICROSECONDS_PER_SECOND;
tp.tv_nsec = (useconds % TOD_MICROSECONDS_PER_SECOND) * 1000;
2006744: d0 27 bf fc st %o0, [ %fp + -4 ]
ticks = _Timespec_To_ticks( &tp );
2006748: 40 00 0e ff call 200a344 <_Timespec_To_ticks>
200674c: 90 10 00 11 mov %l1, %o0
if ( ticks == 0 )
ticks = 1;
_Watchdog_Insert_ticks( the_timer, _Timespec_To_ticks( &tp ) );
2006750: 40 00 0e fd call 200a344 <_Timespec_To_ticks>
2006754: 90 10 00 11 mov %l1, %o0
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2006758: 92 10 00 10 mov %l0, %o1
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
200675c: d0 24 20 0c st %o0, [ %l0 + 0xc ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2006760: 11 00 80 84 sethi %hi(0x2021000), %o0
2006764: 40 00 10 07 call 200a780 <_Watchdog_Insert>
2006768: 90 12 23 90 or %o0, 0x390, %o0 ! 2021390 <_Watchdog_Ticks_chain>
}
return remaining;
}
200676c: 81 c7 e0 08 ret
2006770: 81 e8 00 00 restore
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2006774: 03 00 80 19 sethi %hi(0x2006400), %g1
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2006778: c0 24 20 08 clr [ %l0 + 8 ]
the_watchdog->routine = routine;
200677c: 82 10 63 e4 or %g1, 0x3e4, %g1
the_watchdog->id = id;
2006780: c0 24 20 20 clr [ %l0 + 0x20 ]
the_watchdog->user_data = user_data;
2006784: c0 24 20 24 clr [ %l0 + 0x24 ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2006788: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
the_watchdog->id = id;
the_watchdog->user_data = user_data;
200678c: 10 bf ff de b 2006704 <ualarm+0x34>
2006790: b0 10 20 00 clr %i0
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
2006794: c4 04 20 0c ld [ %l0 + 0xc ], %g2
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
2006798: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
200679c: d0 04 20 14 ld [ %l0 + 0x14 ], %o0
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
20067a0: 92 07 bf f8 add %fp, -8, %o1
* boot. Since alarm() is dealing in seconds, we must account for
* this.
*/
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
20067a4: 90 02 00 02 add %o0, %g2, %o0
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
20067a8: 40 00 0e bc call 200a298 <_Timespec_From_ticks>
20067ac: 90 22 00 01 sub %o0, %g1, %o0
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
20067b0: c2 07 bf f8 ld [ %fp + -8 ], %g1
remaining += tp.tv_nsec / 1000;
20067b4: d0 07 bf fc ld [ %fp + -4 ], %o0
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
20067b8: 85 28 60 03 sll %g1, 3, %g2
20067bc: 87 28 60 08 sll %g1, 8, %g3
20067c0: 84 20 c0 02 sub %g3, %g2, %g2
remaining += tp.tv_nsec / 1000;
20067c4: 92 10 23 e8 mov 0x3e8, %o1
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
20067c8: b1 28 a0 06 sll %g2, 6, %i0
20067cc: b0 26 00 02 sub %i0, %g2, %i0
remaining += tp.tv_nsec / 1000;
20067d0: 40 00 58 d9 call 201cb34 <.div>
20067d4: b0 06 00 01 add %i0, %g1, %i0
ticks = the_timer->initial;
ticks -= (the_timer->stop_time - the_timer->start_time);
/* remaining is now in ticks */
_Timespec_From_ticks( ticks, &tp );
remaining = tp.tv_sec * TOD_MICROSECONDS_PER_SECOND;
20067d8: b1 2e 20 06 sll %i0, 6, %i0
remaining += tp.tv_nsec / 1000;
20067dc: 10 bf ff ca b 2006704 <ualarm+0x34>
20067e0: b0 02 00 18 add %o0, %i0, %i0
0201063c <unlink>:
#include <rtems/seterr.h>
int unlink(
const char *path
)
{
201063c: 9d e3 bf 70 save %sp, -144, %sp
/*
* Get the node to be unlinked. Find the parent path first.
*/
parentpathlen = rtems_filesystem_dirname ( path );
2010640: 7f ff c9 38 call 2002b20 <rtems_filesystem_dirname>
2010644: 90 10 00 18 mov %i0, %o0
if ( parentpathlen == 0 )
2010648: 80 a2 20 00 cmp %o0, 0
201064c: 12 80 00 4e bne 2010784 <unlink+0x148>
2010650: a2 07 bf e8 add %fp, -24, %l1
rtems_filesystem_get_start_loc( path, &i, &parentloc );
2010654: 90 10 00 18 mov %i0, %o0
2010658: 92 07 bf fc add %fp, -4, %o1
201065c: 94 10 00 11 mov %l1, %o2
2010660: 7f ff cd c2 call 2003d68 <rtems_filesystem_get_start_loc>
2010664: a0 10 20 00 clr %l0
2010668: a4 10 20 00 clr %l2
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
201066c: c2 07 bf e8 ld [ %fp + -24 ], %g1
name = path + parentpathlen;
2010670: b0 06 00 10 add %i0, %l0, %i0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
2010674: c2 27 bf d4 st %g1, [ %fp + -44 ]
2010678: c2 07 bf ec ld [ %fp + -20 ], %g1
name = path + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
201067c: 90 10 00 18 mov %i0, %o0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
2010680: c2 27 bf d8 st %g1, [ %fp + -40 ]
2010684: c2 07 bf f0 ld [ %fp + -16 ], %g1
name = path + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
2010688: a0 07 bf d4 add %fp, -44, %l0
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
201068c: c2 27 bf dc st %g1, [ %fp + -36 ]
2010690: c2 07 bf f4 ld [ %fp + -12 ], %g1
2010694: c2 27 bf e0 st %g1, [ %fp + -32 ]
2010698: c2 07 bf f8 ld [ %fp + -8 ], %g1
name = path + parentpathlen;
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
201069c: 40 00 08 a5 call 2012930 <strlen>
20106a0: c2 27 bf e4 st %g1, [ %fp + -28 ]
20106a4: 92 10 00 08 mov %o0, %o1
20106a8: 7f ff c9 03 call 2002ab4 <rtems_filesystem_prefix_separators>
20106ac: 90 10 00 18 mov %i0, %o0
20106b0: b0 06 00 08 add %i0, %o0, %i0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
20106b4: 40 00 08 9f call 2012930 <strlen>
20106b8: 90 10 00 18 mov %i0, %o0
20106bc: 94 10 20 00 clr %o2
20106c0: 92 10 00 08 mov %o0, %o1
20106c4: 96 10 00 10 mov %l0, %o3
20106c8: 90 10 00 18 mov %i0, %o0
20106cc: 7f ff c9 28 call 2002b6c <rtems_filesystem_evaluate_relative_path>
20106d0: 98 10 20 00 clr %o4
0, &loc, false );
if ( result != 0 ) {
20106d4: 80 a2 20 00 cmp %o0, 0
20106d8: 12 80 00 37 bne 20107b4 <unlink+0x178>
20106dc: c4 07 bf e0 ld [ %fp + -32 ], %g2
if ( free_parentloc )
rtems_filesystem_freenode( &parentloc );
return -1;
}
if ( !loc.ops->node_type_h ) {
20106e0: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1
20106e4: 80 a0 60 00 cmp %g1, 0
20106e8: 22 80 00 43 be,a 20107f4 <unlink+0x1b8> <== NEVER TAKEN
20106ec: 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 ) {
20106f0: 9f c0 40 00 call %g1
20106f4: 90 10 00 10 mov %l0, %o0
20106f8: 80 a2 20 01 cmp %o0, 1
20106fc: 02 80 00 55 be 2010850 <unlink+0x214>
2010700: c4 07 bf e0 ld [ %fp + -32 ], %g2
if ( free_parentloc )
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( EISDIR );
}
if ( !loc.ops->unlink_h ) {
2010704: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
2010708: 80 a0 60 00 cmp %g1, 0
201070c: 02 80 00 39 be 20107f0 <unlink+0x1b4> <== NEVER TAKEN
2010710: 90 10 00 11 mov %l1, %o0
if ( free_parentloc )
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*loc.ops->unlink_h)( &parentloc, &loc );
2010714: 9f c0 40 00 call %g1
2010718: 92 10 00 10 mov %l0, %o1
rtems_filesystem_freenode( &loc );
201071c: c2 07 bf e0 ld [ %fp + -32 ], %g1
2010720: 80 a0 60 00 cmp %g1, 0
2010724: 02 80 00 08 be 2010744 <unlink+0x108> <== NEVER TAKEN
2010728: b0 10 00 08 mov %o0, %i0
201072c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2010730: 80 a0 60 00 cmp %g1, 0
2010734: 02 80 00 05 be 2010748 <unlink+0x10c> <== NEVER TAKEN
2010738: 80 8c a0 ff btst 0xff, %l2
201073c: 9f c0 40 00 call %g1
2010740: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
2010744: 80 8c a0 ff btst 0xff, %l2
2010748: 02 80 00 0b be 2010774 <unlink+0x138>
201074c: c2 07 bf f4 ld [ %fp + -12 ], %g1
rtems_filesystem_freenode( &parentloc );
2010750: 80 a0 60 00 cmp %g1, 0
2010754: 02 80 00 59 be 20108b8 <unlink+0x27c> <== NEVER TAKEN
2010758: 01 00 00 00 nop
201075c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2010760: 80 a0 60 00 cmp %g1, 0
2010764: 02 80 00 55 be 20108b8 <unlink+0x27c> <== NEVER TAKEN
2010768: 01 00 00 00 nop
201076c: 9f c0 40 00 call %g1
2010770: 90 10 00 11 mov %l1, %o0
2010774: 81 c7 e0 08 ret
2010778: 81 e8 00 00 restore
return result;
}
201077c: 81 c7 e0 08 ret <== NOT EXECUTED
2010780: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
parentpathlen = rtems_filesystem_dirname ( path );
if ( parentpathlen == 0 )
rtems_filesystem_get_start_loc( path, &i, &parentloc );
else {
result = rtems_filesystem_evaluate_path( path, parentpathlen,
2010784: a0 10 00 08 mov %o0, %l0
2010788: 90 10 00 18 mov %i0, %o0
201078c: 92 10 00 10 mov %l0, %o1
2010790: 94 10 20 02 mov 2, %o2
2010794: 96 10 00 11 mov %l1, %o3
2010798: 7f ff c9 36 call 2002c70 <rtems_filesystem_evaluate_path>
201079c: 98 10 20 00 clr %o4
RTEMS_LIBIO_PERMS_WRITE,
&parentloc,
false );
if ( result != 0 )
20107a0: 80 a2 20 00 cmp %o0, 0
20107a4: 12 bf ff f6 bne 201077c <unlink+0x140> <== NEVER TAKEN
20107a8: a4 10 20 01 mov 1, %l2
/*
* Start from the parent to find the node that should be under it.
*/
loc = parentloc;
20107ac: 10 bf ff b1 b 2010670 <unlink+0x34>
20107b0: c2 07 bf e8 ld [ %fp + -24 ], %g1
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
0, &loc, false );
if ( result != 0 ) {
if ( free_parentloc )
20107b4: 80 8c a0 ff btst 0xff, %l2
20107b8: 02 bf ff ef be 2010774 <unlink+0x138> <== NEVER TAKEN
20107bc: b0 10 3f ff mov -1, %i0
rtems_filesystem_freenode( &parentloc );
20107c0: c2 07 bf f4 ld [ %fp + -12 ], %g1
20107c4: 80 a0 60 00 cmp %g1, 0
20107c8: 02 80 00 3c be 20108b8 <unlink+0x27c> <== NEVER TAKEN
20107cc: 01 00 00 00 nop
20107d0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
20107d4: 80 a0 60 00 cmp %g1, 0
20107d8: 02 bf ff e7 be 2010774 <unlink+0x138> <== NEVER TAKEN
20107dc: 90 10 00 11 mov %l1, %o0
20107e0: 9f c0 40 00 call %g1
20107e4: 01 00 00 00 nop
20107e8: 81 c7 e0 08 ret
20107ec: 81 e8 00 00 restore
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( EISDIR );
}
if ( !loc.ops->unlink_h ) {
rtems_filesystem_freenode( &loc );
20107f0: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
20107f4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
20107f8: 02 80 00 05 be 201080c <unlink+0x1d0> <== NOT EXECUTED
20107fc: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
2010800: 9f c0 40 00 call %g1 <== NOT EXECUTED
2010804: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_parentloc )
2010808: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
201080c: 02 80 00 0b be 2010838 <unlink+0x1fc> <== NOT EXECUTED
2010810: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
2010814: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2010818: 02 80 00 08 be 2010838 <unlink+0x1fc> <== NOT EXECUTED
201081c: 01 00 00 00 nop <== NOT EXECUTED
2010820: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2010824: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2010828: 02 80 00 04 be 2010838 <unlink+0x1fc> <== NOT EXECUTED
201082c: 01 00 00 00 nop <== NOT EXECUTED
2010830: 9f c0 40 00 call %g1 <== NOT EXECUTED
2010834: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2010838: 40 00 04 71 call 20119fc <__errno> <== NOT EXECUTED
201083c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
2010840: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2010844: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2010848: 81 c7 e0 08 ret <== NOT EXECUTED
201084c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY ) {
rtems_filesystem_freenode( &loc );
2010850: c2 07 bf e0 ld [ %fp + -32 ], %g1
2010854: 80 a0 60 00 cmp %g1, 0
2010858: 02 80 00 09 be 201087c <unlink+0x240> <== NEVER TAKEN
201085c: 80 8c a0 ff btst 0xff, %l2
2010860: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
2010864: 80 a0 60 00 cmp %g1, 0
2010868: 02 80 00 05 be 201087c <unlink+0x240> <== NEVER TAKEN
201086c: 80 8c a0 ff btst 0xff, %l2
2010870: 9f c0 40 00 call %g1
2010874: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
2010878: 80 8c a0 ff btst 0xff, %l2
201087c: 02 80 00 0b be 20108a8 <unlink+0x26c> <== ALWAYS TAKEN
2010880: c2 07 bf f4 ld [ %fp + -12 ], %g1
rtems_filesystem_freenode( &parentloc );
2010884: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2010888: 02 80 00 08 be 20108a8 <unlink+0x26c> <== NOT EXECUTED
201088c: 01 00 00 00 nop <== NOT EXECUTED
2010890: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED
2010894: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
2010898: 02 80 00 04 be 20108a8 <unlink+0x26c> <== NOT EXECUTED
201089c: 01 00 00 00 nop <== NOT EXECUTED
20108a0: 9f c0 40 00 call %g1 <== NOT EXECUTED
20108a4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EISDIR );
20108a8: 40 00 04 55 call 20119fc <__errno>
20108ac: b0 10 3f ff mov -1, %i0
20108b0: 82 10 20 15 mov 0x15, %g1
20108b4: c2 22 00 00 st %g1, [ %o0 ]
20108b8: 81 c7 e0 08 ret
20108bc: 81 e8 00 00 restore
0202eb74 <unmount>:
*/
int unmount(
const char *path
)
{
202eb74: 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 ) )
202eb78: 40 00 89 fe call 2051370 <strlen>
202eb7c: 90 10 00 18 mov %i0, %o0
202eb80: a0 07 bf ec add %fp, -20, %l0
202eb84: 92 10 00 08 mov %o0, %o1
202eb88: 94 10 20 00 clr %o2
202eb8c: 90 10 00 18 mov %i0, %o0
202eb90: 96 10 00 10 mov %l0, %o3
202eb94: 7f ff 67 33 call 2008860 <rtems_filesystem_evaluate_path>
202eb98: 98 10 20 01 mov 1, %o4
202eb9c: 80 a2 20 00 cmp %o0, 0
202eba0: 12 80 00 31 bne 202ec64 <unmount+0xf0>
202eba4: 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;
202eba8: c2 07 bf ec ld [ %fp + -20 ], %g1
202ebac: c4 04 60 1c ld [ %l1 + 0x1c ], %g2
202ebb0: 80 a0 80 01 cmp %g2, %g1
202ebb4: 12 80 00 4b bne 202ece0 <unmount+0x16c>
202ebb8: c2 07 bf f8 ld [ %fp + -8 ], %g1
/*
* Free the loc node and just use the nodes from the mt_entry .
*/
rtems_filesystem_freenode( &loc );
202ebbc: 80 a0 60 00 cmp %g1, 0
202ebc0: 22 80 00 09 be,a 202ebe4 <unmount+0x70> <== NEVER TAKEN
202ebc4: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
202ebc8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202ebcc: 80 a0 60 00 cmp %g1, 0
202ebd0: 22 80 00 05 be,a 202ebe4 <unmount+0x70> <== NEVER TAKEN
202ebd4: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
202ebd8: 9f c0 40 00 call %g1
202ebdc: 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;
202ebe0: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
202ebe4: c2 00 60 28 ld [ %g1 + 0x28 ], %g1
202ebe8: 80 a0 60 00 cmp %g1, 0
202ebec: 02 80 00 5b be 202ed58 <unmount+0x1e4> <== NEVER TAKEN
202ebf0: 01 00 00 00 nop
fs_root_loc = &mt_entry->mt_fs_root;
202ebf4: c2 04 60 28 ld [ %l1 + 0x28 ], %g1
202ebf8: c2 00 60 2c ld [ %g1 + 0x2c ], %g1
202ebfc: 80 a0 60 00 cmp %g1, 0
202ec00: 02 80 00 56 be 202ed58 <unmount+0x1e4> <== NEVER TAKEN
202ec04: 03 00 81 c3 sethi %hi(0x2070c00), %g1
* 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 )
202ec08: c2 00 62 24 ld [ %g1 + 0x224 ], %g1 ! 2070e24 <rtems_current_user_env>
202ec0c: c2 00 60 14 ld [ %g1 + 0x14 ], %g1
202ec10: 80 a0 40 11 cmp %g1, %l1
202ec14: 02 80 00 42 be 202ed1c <unmount+0x1a8>
202ec18: 11 00 80 ba sethi %hi(0x202e800), %o0
/*
* Verify there are no file systems below the path specified
*/
if ( rtems_filesystem_mount_iterate( is_fs_below_mount_point,
202ec1c: d2 04 60 2c ld [ %l1 + 0x2c ], %o1
202ec20: 7f ff 69 e4 call 20093b0 <rtems_filesystem_mount_iterate>
202ec24: 90 12 23 60 or %o0, 0x360, %o0
202ec28: 80 8a 20 ff btst 0xff, %o0
202ec2c: 12 80 00 3c bne 202ed1c <unmount+0x1a8>
202ec30: 01 00 00 00 nop
* 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 )
202ec34: 7f ff 68 1a call 2008c9c <rtems_libio_is_open_files_in_fs>
202ec38: 90 10 00 11 mov %l1, %o0
202ec3c: 80 a2 20 01 cmp %o0, 1
202ec40: 02 80 00 37 be 202ed1c <unmount+0x1a8>
202ec44: 01 00 00 00 nop
* 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 )
202ec48: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
202ec4c: c2 00 60 28 ld [ %g1 + 0x28 ], %g1
202ec50: 9f c0 40 00 call %g1
202ec54: 90 10 00 11 mov %l1, %o0
202ec58: 80 a2 20 00 cmp %o0, 0
202ec5c: 22 80 00 04 be,a 202ec6c <unmount+0xf8> <== ALWAYS TAKEN
202ec60: c2 04 60 28 ld [ %l1 + 0x28 ], %g1
rtems_filesystem_freenode( fs_mount_loc );
free( mt_entry );
return 0;
}
202ec64: 81 c7 e0 08 ret
202ec68: 91 e8 3f ff restore %g0, -1, %o0
* 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){
202ec6c: c2 00 60 2c ld [ %g1 + 0x2c ], %g1
202ec70: 9f c0 40 00 call %g1
202ec74: 90 10 00 11 mov %l1, %o0
202ec78: 80 a2 20 00 cmp %o0, 0
202ec7c: 12 80 00 2e bne 202ed34 <unmount+0x1c0> <== NEVER TAKEN
202ec80: 21 00 81 d3 sethi %hi(0x2074c00), %l0
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 );
202ec84: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 ! 2074c6c <rtems_libio_semaphore>
202ec88: 92 10 20 00 clr %o1
202ec8c: 7f ff 7a 6b call 200d638 <rtems_semaphore_obtain>
202ec90: 94 10 20 00 clr %o2
*/
RTEMS_INLINE_ROUTINE void rtems_chain_extract(
rtems_chain_node *the_node
)
{
_Chain_Extract( the_node );
202ec94: 7f ff 7d ca call 200e3bc <_Chain_Extract>
202ec98: 90 10 00 11 mov %l1, %o0
}
static inline void rtems_libio_unlock( void )
{
rtems_semaphore_release( rtems_libio_semaphore );
202ec9c: 7f ff 7a ae call 200d754 <rtems_semaphore_release>
202eca0: d0 04 20 6c ld [ %l0 + 0x6c ], %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 );
202eca4: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
202eca8: 80 a0 60 00 cmp %g1, 0
202ecac: 02 80 00 09 be 202ecd0 <unmount+0x15c> <== NEVER TAKEN
202ecb0: 90 10 00 11 mov %l1, %o0
202ecb4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202ecb8: 80 a0 60 00 cmp %g1, 0
202ecbc: 02 80 00 05 be 202ecd0 <unmount+0x15c> <== NEVER TAKEN
202ecc0: 01 00 00 00 nop
202ecc4: 9f c0 40 00 call %g1
202ecc8: 90 04 60 08 add %l1, 8, %o0
free( mt_entry );
202eccc: 90 10 00 11 mov %l1, %o0
202ecd0: 7f ff 67 03 call 20088dc <free>
202ecd4: b0 10 20 00 clr %i0
return 0;
202ecd8: 81 c7 e0 08 ret
202ecdc: 81 e8 00 00 restore
/*
* Verify this is the root node for the file system to be unmounted.
*/
if ( fs_root_loc->node_access != loc.node_access ){
rtems_filesystem_freenode( &loc );
202ece0: 80 a0 60 00 cmp %g1, 0
202ece4: 02 80 00 08 be 202ed04 <unmount+0x190> <== NEVER TAKEN
202ece8: 01 00 00 00 nop
202ecec: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202ecf0: 80 a0 60 00 cmp %g1, 0
202ecf4: 02 80 00 04 be 202ed04 <unmount+0x190> <== NEVER TAKEN
202ecf8: 01 00 00 00 nop
202ecfc: 9f c0 40 00 call %g1
202ed00: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( EACCES );
202ed04: 40 00 6d df call 204a480 <__errno>
202ed08: b0 10 3f ff mov -1, %i0
202ed0c: 82 10 20 0d mov 0xd, %g1
202ed10: c2 22 00 00 st %g1, [ %o0 ]
202ed14: 81 c7 e0 08 ret
202ed18: 81 e8 00 00 restore
* descriptors that are currently active and reference nodes in the
* file system that we are trying to unmount
*/
if ( rtems_libio_is_open_files_in_fs( mt_entry ) == 1 )
rtems_set_errno_and_return_minus_one( EBUSY );
202ed1c: 40 00 6d d9 call 204a480 <__errno>
202ed20: b0 10 3f ff mov -1, %i0
202ed24: 82 10 20 10 mov 0x10, %g1
202ed28: c2 22 00 00 st %g1, [ %o0 ]
202ed2c: 81 c7 e0 08 ret
202ed30: 81 e8 00 00 restore
* This was response was questionable but the best we could
* come up with.
*/
if ((fs_root_loc->ops->fsunmount_me_h )( mt_entry ) != 0){
if (( fs_mount_loc->ops->mount_h )( mt_entry ) != 0 )
202ed34: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
202ed38: c2 00 60 20 ld [ %g1 + 0x20 ], %g1 <== NOT EXECUTED
202ed3c: 9f c0 40 00 call %g1 <== NOT EXECUTED
202ed40: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
202ed44: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED
202ed48: 02 bf ff c7 be 202ec64 <unmount+0xf0> <== NOT EXECUTED
202ed4c: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred( 0 );
202ed50: 7f ff 7c 3d call 200de44 <rtems_fatal_error_occurred> <== NOT EXECUTED
202ed54: 90 10 20 00 clr %o0 ! 0 <PROM_START> <== NOT EXECUTED
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 );
202ed58: 40 00 6d ca call 204a480 <__errno> <== NOT EXECUTED
202ed5c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202ed60: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202ed64: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202ed68: 81 c7 e0 08 ret <== NOT EXECUTED
202ed6c: 81 e8 00 00 restore <== NOT EXECUTED
0202ed70 <utime>:
int utime(
const char *path,
const struct utimbuf *times
)
{
202ed70: 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 ) )
202ed74: 40 00 89 7f call 2051370 <strlen>
202ed78: 90 10 00 18 mov %i0, %o0
202ed7c: a0 07 bf ec add %fp, -20, %l0
202ed80: 92 10 00 08 mov %o0, %o1
202ed84: 94 10 20 00 clr %o2
202ed88: 90 10 00 18 mov %i0, %o0
202ed8c: 96 10 00 10 mov %l0, %o3
202ed90: 98 10 20 01 mov 1, %o4
202ed94: 7f ff 66 b3 call 2008860 <rtems_filesystem_evaluate_path>
202ed98: b0 10 3f ff mov -1, %i0
202ed9c: 80 a2 20 00 cmp %o0, 0
202eda0: 12 80 00 14 bne 202edf0 <utime+0x80>
202eda4: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1;
if ( !temp_loc.ops->utime_h ){
202eda8: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1
202edac: 80 a0 60 00 cmp %g1, 0
202edb0: 22 80 00 12 be,a 202edf8 <utime+0x88> <== NEVER TAKEN
202edb4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &temp_loc );
rtems_set_errno_and_return_minus_one( ENOTSUP );
}
result = (*temp_loc.ops->utime_h)( &temp_loc, times->actime, times->modtime );
202edb8: d4 06 60 04 ld [ %i1 + 4 ], %o2
202edbc: d2 06 40 00 ld [ %i1 ], %o1
202edc0: 9f c0 40 00 call %g1
202edc4: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &temp_loc );
202edc8: c2 07 bf f8 ld [ %fp + -8 ], %g1
202edcc: 80 a0 60 00 cmp %g1, 0
202edd0: 02 80 00 08 be 202edf0 <utime+0x80> <== NEVER TAKEN
202edd4: b0 10 00 08 mov %o0, %i0
202edd8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
202eddc: 80 a0 60 00 cmp %g1, 0
202ede0: 02 80 00 0f be 202ee1c <utime+0xac> <== NEVER TAKEN
202ede4: 01 00 00 00 nop
202ede8: 9f c0 40 00 call %g1
202edec: 90 10 00 10 mov %l0, %o0
return result;
}
202edf0: 81 c7 e0 08 ret
202edf4: 81 e8 00 00 restore
if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &temp_loc, true ) )
return -1;
if ( !temp_loc.ops->utime_h ){
rtems_filesystem_freenode( &temp_loc );
202edf8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
202edfc: 02 80 00 04 be 202ee0c <utime+0x9c> <== NOT EXECUTED
202ee00: 01 00 00 00 nop <== NOT EXECUTED
202ee04: 9f c0 40 00 call %g1 <== NOT EXECUTED
202ee08: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202ee0c: 40 00 6d 9d call 204a480 <__errno> <== NOT EXECUTED
202ee10: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
202ee14: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
202ee18: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
202ee1c: 81 c7 e0 08 ret <== NOT EXECUTED
202ee20: 81 e8 00 00 restore <== NOT EXECUTED
02005d6c <vprintk>:
*/
void vprintk(
const char *fmt,
va_list ap
)
{
2005d6c: 9d e3 bf 88 save %sp, -120, %sp
for (; *fmt != '\0'; fmt++) {
2005d70: c2 0e 00 00 ldub [ %i0 ], %g1
2005d74: 83 28 60 18 sll %g1, 0x18, %g1
2005d78: 80 a0 60 00 cmp %g1, 0
2005d7c: 02 80 00 7d be 2005f70 <vprintk+0x204> <== NEVER TAKEN
2005d80: 29 00 80 7a sethi %hi(0x201e800), %l4
2005d84: 3b 00 80 75 sethi %hi(0x201d400), %i5
unsigned i, len;
char *s, *str;
str = va_arg(ap, char *);
if ( str == NULL ) {
2005d88: 37 00 80 75 sethi %hi(0x201d400), %i3
bool sign = false;
char lead = ' ';
char c;
if (*fmt != '%') {
BSP_output_char(*fmt);
2005d8c: a8 15 21 5c or %l4, 0x15c, %l4
2005d90: ba 17 61 e0 or %i5, 0x1e0, %i5
unsigned i, len;
char *s, *str;
str = va_arg(ap, char *);
if ( str == NULL ) {
2005d94: b6 16 e1 d8 or %i3, 0x1d8, %i3
toPrint[count++] = (char) unsigned_num;
for (n=maxwidth ; n > count; n-- )
BSP_output_char(lead);
for (n = 0; n < count; n++) {
2005d98: ac 07 bf e8 add %fp, -24, %l6
bool minus = false;
bool sign = false;
char lead = ' ';
char c;
if (*fmt != '%') {
2005d9c: 91 38 60 18 sra %g1, 0x18, %o0
2005da0: 80 a2 20 25 cmp %o0, 0x25
2005da4: 32 80 00 8d bne,a 2005fd8 <vprintk+0x26c>
2005da8: c2 05 00 00 ld [ %l4 ], %g1
BSP_output_char(*fmt);
continue;
}
fmt++;
2005dac: b0 06 20 01 inc %i0
if (*fmt == '0' ) {
2005db0: c2 0e 00 00 ldub [ %i0 ], %g1
2005db4: 85 28 60 18 sll %g1, 0x18, %g2
2005db8: 87 38 a0 18 sra %g2, 0x18, %g3
2005dbc: 80 a0 e0 30 cmp %g3, 0x30
2005dc0: 02 80 00 a9 be 2006064 <vprintk+0x2f8>
2005dc4: b8 10 20 20 mov 0x20, %i4
lead = '0';
fmt++;
}
if (*fmt == '-' ) {
2005dc8: 87 38 a0 18 sra %g2, 0x18, %g3
2005dcc: 80 a0 e0 2d cmp %g3, 0x2d
2005dd0: 02 80 00 a0 be 2006050 <vprintk+0x2e4>
2005dd4: aa 10 20 00 clr %l5
minus = true;
fmt++;
}
while (*fmt >= '0' && *fmt <= '9' ) {
2005dd8: 82 00 7f d0 add %g1, -48, %g1
2005ddc: 82 08 60 ff and %g1, 0xff, %g1
2005de0: 80 a0 60 09 cmp %g1, 9
2005de4: 18 80 00 0f bgu 2005e20 <vprintk+0xb4>
2005de8: a0 10 20 00 clr %l0
width *= 10;
width += ((unsigned) *fmt - '0');
fmt++;
2005dec: b0 06 20 01 inc %i0
}
if (*fmt == '-' ) {
minus = true;
fmt++;
}
while (*fmt >= '0' && *fmt <= '9' ) {
2005df0: c2 0e 00 00 ldub [ %i0 ], %g1
width *= 10;
width += ((unsigned) *fmt - '0');
2005df4: 87 38 a0 18 sra %g2, 0x18, %g3
2005df8: 89 2c 20 03 sll %l0, 3, %g4
2005dfc: 85 28 60 18 sll %g1, 0x18, %g2
2005e00: a1 2c 20 01 sll %l0, 1, %l0
2005e04: a0 04 00 04 add %l0, %g4, %l0
2005e08: a0 04 00 03 add %l0, %g3, %l0
}
if (*fmt == '-' ) {
minus = true;
fmt++;
}
while (*fmt >= '0' && *fmt <= '9' ) {
2005e0c: 86 00 7f d0 add %g1, -48, %g3
2005e10: 86 08 e0 ff and %g3, 0xff, %g3
2005e14: 80 a0 e0 09 cmp %g3, 9
2005e18: 08 bf ff f5 bleu 2005dec <vprintk+0x80>
2005e1c: a0 04 3f d0 add %l0, -48, %l0
width *= 10;
width += ((unsigned) *fmt - '0');
fmt++;
}
if ((c = *fmt) == 'l') {
2005e20: 83 38 a0 18 sra %g2, 0x18, %g1
2005e24: 80 a0 60 6c cmp %g1, 0x6c
2005e28: 02 80 00 77 be 2006004 <vprintk+0x298>
2005e2c: 80 a0 60 63 cmp %g1, 0x63
lflag = true;
c = *++fmt;
}
if ( c == 'c' ) {
2005e30: 22 80 00 7d be,a 2006024 <vprintk+0x2b8>
2005e34: d0 06 40 00 ld [ %i1 ], %o0
/* need a cast here since va_arg() only takes fully promoted types */
char chr = (char) va_arg(ap, int);
BSP_output_char(chr);
continue;
}
if ( c == 's' ) {
2005e38: 80 a0 60 73 cmp %g1, 0x73
2005e3c: 02 80 00 8f be 2006078 <vprintk+0x30c>
2005e40: 80 a0 60 4f cmp %g1, 0x4f
continue;
}
/* must be a numeric format or something unsupported */
if ( c == 'o' || c == 'O' ) {
2005e44: 22 80 00 6e be,a 2005ffc <vprintk+0x290>
2005e48: 82 10 20 00 clr %g1
2005e4c: 80 a0 60 6f cmp %g1, 0x6f
2005e50: 22 80 00 6b be,a 2005ffc <vprintk+0x290> <== NEVER TAKEN
2005e54: 82 10 20 00 clr %g1 <== NOT EXECUTED
base = 8; sign = false;
} else if ( c == 'i' || c == 'I' ||
2005e58: 80 a0 60 49 cmp %g1, 0x49
2005e5c: 22 80 00 06 be,a 2005e74 <vprintk+0x108>
2005e60: 82 10 20 01 mov 1, %g1
2005e64: 80 a0 60 69 cmp %g1, 0x69
2005e68: 12 80 00 44 bne 2005f78 <vprintk+0x20c>
2005e6c: 80 a0 60 44 cmp %g1, 0x44
base = 16; sign = false;
} else if ( c == 'p' ) {
base = 16; sign = false; lflag = true;
} else {
BSP_output_char(c);
continue;
2005e70: 82 10 20 01 mov 1, %g1
2005e74: aa 10 20 0a mov 0xa, %l5
}
printNum(
2005e78: e6 06 40 00 ld [ %i1 ], %l3
unsigned long unsigned_num;
unsigned long n;
unsigned count;
char toPrint[20];
if ( sign && (num < 0) ) {
2005e7c: 80 88 60 ff btst 0xff, %g1
BSP_output_char(c);
continue;
}
printNum(
lflag ? va_arg(ap, long) : (long) va_arg(ap, int),
2005e80: b2 06 60 04 add %i1, 4, %i1
unsigned long unsigned_num;
unsigned long n;
unsigned count;
char toPrint[20];
if ( sign && (num < 0) ) {
2005e84: 02 80 00 05 be 2005e98 <vprintk+0x12c>
2005e88: b8 0f 20 30 and %i4, 0x30, %i4
2005e8c: 80 a4 e0 00 cmp %l3, 0
2005e90: 26 80 00 c0 bl,a 2006190 <vprintk+0x424>
2005e94: c2 05 00 00 ld [ %l4 ], %g1
} else {
unsigned_num = (unsigned long) num;
}
count = 0;
while ((n = unsigned_num / base) > 0) {
2005e98: 90 10 00 13 mov %l3, %o0
2005e9c: 92 10 00 15 mov %l5, %o1
2005ea0: 40 00 54 2a call 201af48 <.udiv>
2005ea4: ae 10 20 01 mov 1, %l7
2005ea8: a2 92 20 00 orcc %o0, 0, %l1
2005eac: 02 80 00 12 be 2005ef4 <vprintk+0x188>
2005eb0: a4 10 20 00 clr %l2
2005eb4: 10 80 00 03 b 2005ec0 <vprintk+0x154>
2005eb8: ae 10 00 15 mov %l5, %l7
2005ebc: a2 10 00 08 mov %o0, %l1
toPrint[count++] = (char) (unsigned_num - (n * base));
2005ec0: 92 10 00 11 mov %l1, %o1
2005ec4: 40 00 53 e7 call 201ae60 <.umul>
2005ec8: 90 10 00 17 mov %l7, %o0
2005ecc: 90 24 c0 08 sub %l3, %o0, %o0
} else {
unsigned_num = (unsigned long) num;
}
count = 0;
while ((n = unsigned_num / base) > 0) {
2005ed0: 92 10 00 15 mov %l5, %o1
toPrint[count++] = (char) (unsigned_num - (n * base));
2005ed4: d0 2d 80 12 stb %o0, [ %l6 + %l2 ]
} else {
unsigned_num = (unsigned long) num;
}
count = 0;
while ((n = unsigned_num / base) > 0) {
2005ed8: 90 10 00 11 mov %l1, %o0
2005edc: 40 00 54 1b call 201af48 <.udiv>
2005ee0: a4 04 a0 01 inc %l2
2005ee4: 80 a2 20 00 cmp %o0, 0
2005ee8: 12 bf ff f5 bne 2005ebc <vprintk+0x150>
2005eec: a6 10 00 11 mov %l1, %l3
2005ef0: ae 04 a0 01 add %l2, 1, %l7
toPrint[count++] = (char) (unsigned_num - (n * base));
unsigned_num = n;
}
toPrint[count++] = (char) unsigned_num;
2005ef4: a4 07 80 12 add %fp, %l2, %l2
for (n=maxwidth ; n > count; n-- )
2005ef8: 80 a4 00 17 cmp %l0, %l7
2005efc: 08 80 00 09 bleu 2005f20 <vprintk+0x1b4>
2005f00: e6 2c bf e8 stb %l3, [ %l2 + -24 ]
BSP_output_char(lead);
2005f04: c2 05 00 00 ld [ %l4 ], %g1
2005f08: 9f c0 40 00 call %g1
2005f0c: 90 10 00 1c mov %i4, %o0
toPrint[count++] = (char) (unsigned_num - (n * base));
unsigned_num = n;
}
toPrint[count++] = (char) unsigned_num;
for (n=maxwidth ; n > count; n-- )
2005f10: a0 04 3f ff add %l0, -1, %l0
2005f14: 80 a4 00 17 cmp %l0, %l7
2005f18: 38 bf ff fc bgu,a 2005f08 <vprintk+0x19c>
2005f1c: c2 05 00 00 ld [ %l4 ], %g1
BSP_output_char(lead);
for (n = 0; n < count; n++) {
2005f20: 80 a5 e0 00 cmp %l7, 0
2005f24: 22 80 00 0e be,a 2005f5c <vprintk+0x1f0> <== NEVER TAKEN
2005f28: b0 06 20 01 inc %i0 <== NOT EXECUTED
2005f2c: a2 05 ff ff add %l7, -1, %l1
2005f30: a0 10 20 00 clr %l0
2005f34: a2 05 80 11 add %l6, %l1, %l1
BSP_output_char("0123456789ABCDEF"[(int)(toPrint[count-(n+1)])]);
2005f38: c4 4c 40 00 ldsb [ %l1 ], %g2
2005f3c: c2 05 00 00 ld [ %l4 ], %g1
2005f40: d0 4f 40 02 ldsb [ %i5 + %g2 ], %o0
2005f44: 9f c0 40 00 call %g1
2005f48: 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++) {
2005f4c: 80 a4 00 17 cmp %l0, %l7
2005f50: 0a bf ff fa bcs 2005f38 <vprintk+0x1cc>
2005f54: a2 04 7f ff add %l1, -1, %l1
void vprintk(
const char *fmt,
va_list ap
)
{
for (; *fmt != '\0'; fmt++) {
2005f58: b0 06 20 01 inc %i0
2005f5c: c2 0e 00 00 ldub [ %i0 ], %g1
2005f60: 83 28 60 18 sll %g1, 0x18, %g1
2005f64: 80 a0 60 00 cmp %g1, 0
2005f68: 12 bf ff 8e bne 2005da0 <vprintk+0x34> <== ALWAYS TAKEN
2005f6c: 91 38 60 18 sra %g1, 0x18, %o0
2005f70: 81 c7 e0 08 ret <== NOT EXECUTED
2005f74: 81 e8 00 00 restore <== NOT EXECUTED
}
/* must be a numeric format or something unsupported */
if ( c == 'o' || c == 'O' ) {
base = 8; sign = false;
} else if ( c == 'i' || c == 'I' ||
2005f78: 22 bf ff bf be,a 2005e74 <vprintk+0x108>
2005f7c: 82 10 20 01 mov 1, %g1
2005f80: 80 a0 60 64 cmp %g1, 0x64
2005f84: 22 bf ff bc be,a 2005e74 <vprintk+0x108>
2005f88: 82 10 20 01 mov 1, %g1
c == 'd' || c == 'D' ) {
base = 10; sign = true;
} else if ( c == 'u' || c == 'U' ) {
2005f8c: 80 a0 60 55 cmp %g1, 0x55
2005f90: 12 80 00 05 bne 2005fa4 <vprintk+0x238>
2005f94: 80 a0 60 75 cmp %g1, 0x75
2005f98: 82 10 20 00 clr %g1
2005f9c: 10 bf ff b7 b 2005e78 <vprintk+0x10c>
2005fa0: aa 10 20 0a mov 0xa, %l5
2005fa4: 02 bf ff fe be 2005f9c <vprintk+0x230>
2005fa8: 82 10 20 00 clr %g1
base = 10; sign = false;
} else if ( c == 'x' || c == 'X' ) {
2005fac: 91 38 a0 18 sra %g2, 0x18, %o0
2005fb0: 80 a2 20 58 cmp %o0, 0x58
2005fb4: 02 bf ff b1 be 2005e78 <vprintk+0x10c>
2005fb8: aa 10 20 10 mov 0x10, %l5
2005fbc: 80 a2 20 78 cmp %o0, 0x78
2005fc0: 02 bf ff ae be 2005e78 <vprintk+0x10c>
2005fc4: 01 00 00 00 nop
base = 16; sign = false;
} else if ( c == 'p' ) {
2005fc8: 80 a2 20 70 cmp %o0, 0x70
2005fcc: 02 bf ff ab be 2005e78 <vprintk+0x10c>
2005fd0: 01 00 00 00 nop
base = 16; sign = false; lflag = true;
} else {
BSP_output_char(c);
2005fd4: c2 05 00 00 ld [ %l4 ], %g1
2005fd8: 9f c0 40 00 call %g1
2005fdc: b0 06 20 01 inc %i0
void vprintk(
const char *fmt,
va_list ap
)
{
for (; *fmt != '\0'; fmt++) {
2005fe0: c2 0e 00 00 ldub [ %i0 ], %g1
2005fe4: 83 28 60 18 sll %g1, 0x18, %g1
2005fe8: 80 a0 60 00 cmp %g1, 0
2005fec: 12 bf ff 6d bne 2005da0 <vprintk+0x34>
2005ff0: 91 38 60 18 sra %g1, 0x18, %o0
2005ff4: 81 c7 e0 08 ret
2005ff8: 81 e8 00 00 restore
base = 16; sign = false;
} else if ( c == 'p' ) {
base = 16; sign = false; lflag = true;
} else {
BSP_output_char(c);
continue;
2005ffc: 10 bf ff 9f b 2005e78 <vprintk+0x10c>
2006000: aa 10 20 08 mov 8, %l5
fmt++;
}
if ((c = *fmt) == 'l') {
lflag = true;
c = *++fmt;
2006004: b0 06 20 01 inc %i0
2006008: c2 0e 00 00 ldub [ %i0 ], %g1
200600c: 85 28 60 18 sll %g1, 0x18, %g2
}
if ( c == 'c' ) {
2006010: 83 38 a0 18 sra %g2, 0x18, %g1
2006014: 80 a0 60 63 cmp %g1, 0x63
2006018: 12 bf ff 89 bne 2005e3c <vprintk+0xd0> <== ALWAYS TAKEN
200601c: 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);
2006020: d0 06 40 00 ld [ %i1 ], %o0 <== NOT EXECUTED
BSP_output_char(chr);
2006024: c2 05 00 00 ld [ %l4 ], %g1
2006028: 91 2a 20 18 sll %o0, 0x18, %o0
200602c: 9f c0 40 00 call %g1
2006030: 91 3a 20 18 sra %o0, 0x18, %o0
void vprintk(
const char *fmt,
va_list ap
)
{
for (; *fmt != '\0'; fmt++) {
2006034: b0 06 20 01 inc %i0
2006038: c2 0e 00 00 ldub [ %i0 ], %g1
200603c: 83 28 60 18 sll %g1, 0x18, %g1
2006040: 80 a0 60 00 cmp %g1, 0
2006044: 12 bf ff 56 bne 2005d9c <vprintk+0x30> <== ALWAYS TAKEN
2006048: b2 06 60 04 add %i1, 4, %i1
200604c: 30 bf ff ea b,a 2005ff4 <vprintk+0x288> <== NOT EXECUTED
lead = '0';
fmt++;
}
if (*fmt == '-' ) {
minus = true;
fmt++;
2006050: b0 06 20 01 inc %i0
2006054: c2 0e 00 00 ldub [ %i0 ], %g1
2006058: aa 10 20 01 mov 1, %l5
200605c: 10 bf ff 5f b 2005dd8 <vprintk+0x6c>
2006060: 85 28 60 18 sll %g1, 0x18, %g2
continue;
}
fmt++;
if (*fmt == '0' ) {
lead = '0';
fmt++;
2006064: b0 06 20 01 inc %i0
2006068: c2 0e 00 00 ldub [ %i0 ], %g1
200606c: b8 10 20 30 mov 0x30, %i4
2006070: 10 bf ff 56 b 2005dc8 <vprintk+0x5c>
2006074: 85 28 60 18 sll %g1, 0x18, %g2
}
if ( c == 's' ) {
unsigned i, len;
char *s, *str;
str = va_arg(ap, char *);
2006078: e4 06 40 00 ld [ %i1 ], %l2
if ( str == NULL ) {
200607c: 80 a4 a0 00 cmp %l2, 0
2006080: 02 80 00 4a be 20061a8 <vprintk+0x43c>
2006084: b2 06 60 04 add %i1, 4, %i1
str = "";
}
/* calculate length of string */
for ( len=0, s=str ; *s ; len++, s++ )
2006088: c2 4c 80 00 ldsb [ %l2 ], %g1
200608c: 80 a0 60 00 cmp %g1, 0
2006090: 02 80 00 07 be 20060ac <vprintk+0x340>
2006094: a2 10 20 00 clr %l1
2006098: a2 04 60 01 inc %l1
200609c: c2 4c 80 11 ldsb [ %l2 + %l1 ], %g1
20060a0: 80 a0 60 00 cmp %g1, 0
20060a4: 32 bf ff fe bne,a 200609c <vprintk+0x330>
20060a8: a2 04 60 01 inc %l1
;
/* leading spaces */
if ( !minus )
20060ac: aa 8d 60 ff andcc %l5, 0xff, %l5
20060b0: 12 80 00 0e bne 20060e8 <vprintk+0x37c>
20060b4: 80 a4 20 00 cmp %l0, 0
for ( i=len ; i<width ; i++ )
20060b8: 80 a4 00 11 cmp %l0, %l1
20060bc: 08 80 00 0b bleu 20060e8 <vprintk+0x37c>
20060c0: 80 a4 20 00 cmp %l0, 0
20060c4: a6 10 00 11 mov %l1, %l3
BSP_output_char(' ');
20060c8: c2 05 00 00 ld [ %l4 ], %g1
20060cc: 9f c0 40 00 call %g1
20060d0: 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++ )
20060d4: a6 04 e0 01 inc %l3
20060d8: 80 a4 c0 10 cmp %l3, %l0
20060dc: 2a bf ff fc bcs,a 20060cc <vprintk+0x360>
20060e0: c2 05 00 00 ld [ %l4 ], %g1
BSP_output_char(' ');
/* no width option */
if (width == 0) {
20060e4: 80 a4 20 00 cmp %l0, 0
20060e8: 32 80 00 07 bne,a 2006104 <vprintk+0x398>
20060ec: d0 4c 80 00 ldsb [ %l2 ], %o0
width = len;
}
/* output the string */
for ( i=0 ; i<width && *str ; str++ )
20060f0: 80 a4 60 00 cmp %l1, 0
20060f4: 02 80 00 14 be 2006144 <vprintk+0x3d8>
20060f8: 80 a5 60 00 cmp %l5, 0
20060fc: a0 10 00 11 mov %l1, %l0
2006100: d0 4c 80 00 ldsb [ %l2 ], %o0
2006104: 80 a2 20 00 cmp %o0, 0
2006108: 02 80 00 0f be 2006144 <vprintk+0x3d8> <== NEVER TAKEN
200610c: 80 a5 60 00 cmp %l5, 0
BSP_output_char(*str);
2006110: c2 05 00 00 ld [ %l4 ], %g1
2006114: 9f c0 40 00 call %g1
2006118: a4 04 a0 01 inc %l2
if (width == 0) {
width = len;
}
/* output the string */
for ( i=0 ; i<width && *str ; str++ )
200611c: 10 80 00 06 b 2006134 <vprintk+0x3c8>
2006120: d0 4c 80 00 ldsb [ %l2 ], %o0
BSP_output_char(*str);
2006124: c2 05 00 00 ld [ %l4 ], %g1
2006128: 9f c0 40 00 call %g1
200612c: 01 00 00 00 nop
if (width == 0) {
width = len;
}
/* output the string */
for ( i=0 ; i<width && *str ; str++ )
2006130: d0 4c 80 00 ldsb [ %l2 ], %o0
2006134: 80 a2 20 00 cmp %o0, 0
2006138: 12 bf ff fb bne 2006124 <vprintk+0x3b8>
200613c: a4 04 a0 01 inc %l2
BSP_output_char(*str);
/* trailing spaces */
if ( minus )
2006140: 80 a5 60 00 cmp %l5, 0
2006144: 22 bf ff 86 be,a 2005f5c <vprintk+0x1f0>
2006148: b0 06 20 01 inc %i0
for ( i=len ; i<width ; i++ )
200614c: 80 a4 40 10 cmp %l1, %l0
2006150: 3a bf ff 83 bcc,a 2005f5c <vprintk+0x1f0>
2006154: b0 06 20 01 inc %i0
BSP_output_char(' ');
2006158: c2 05 00 00 ld [ %l4 ], %g1
200615c: 9f c0 40 00 call %g1
2006160: 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++ )
2006164: a2 04 60 01 inc %l1
2006168: 80 a4 40 10 cmp %l1, %l0
200616c: 2a bf ff fc bcs,a 200615c <vprintk+0x3f0>
2006170: c2 05 00 00 ld [ %l4 ], %g1
void vprintk(
const char *fmt,
va_list ap
)
{
for (; *fmt != '\0'; fmt++) {
2006174: b0 06 20 01 inc %i0
2006178: c2 0e 00 00 ldub [ %i0 ], %g1
200617c: 83 28 60 18 sll %g1, 0x18, %g1
2006180: 80 a0 60 00 cmp %g1, 0
2006184: 32 bf ff 07 bne,a 2005da0 <vprintk+0x34> <== ALWAYS TAKEN
2006188: 91 38 60 18 sra %g1, 0x18, %o0
200618c: 30 bf ff 9a b,a 2005ff4 <vprintk+0x288> <== NOT EXECUTED
unsigned long n;
unsigned count;
char toPrint[20];
if ( sign && (num < 0) ) {
BSP_output_char('-');
2006190: 9f c0 40 00 call %g1
2006194: 90 10 20 2d mov 0x2d, %o0
unsigned_num = (unsigned long) -num;
if (maxwidth) maxwidth--;
2006198: 80 a0 00 10 cmp %g0, %l0
unsigned count;
char toPrint[20];
if ( sign && (num < 0) ) {
BSP_output_char('-');
unsigned_num = (unsigned long) -num;
200619c: a6 20 00 13 neg %l3
if (maxwidth) maxwidth--;
20061a0: 10 bf ff 3e b 2005e98 <vprintk+0x12c>
20061a4: a0 64 20 00 subx %l0, 0, %l0
unsigned i, len;
char *s, *str;
str = va_arg(ap, char *);
if ( str == NULL ) {
20061a8: 10 bf ff b8 b 2006088 <vprintk+0x31c>
20061ac: a4 10 00 1b mov %i3, %l2
0201c9a4 <write>:
ssize_t write(
int fd,
const void *buffer,
size_t count
)
{
201c9a4: 9d e3 bf a0 save %sp, -96, %sp
ssize_t rc;
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
201c9a8: 03 00 80 79 sethi %hi(0x201e400), %g1
201c9ac: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 201e7b4 <rtems_libio_number_iops>
201c9b0: 80 a6 00 01 cmp %i0, %g1
201c9b4: 1a 80 00 23 bcc 201ca40 <write+0x9c> <== NEVER TAKEN
201c9b8: 03 00 80 7c sethi %hi(0x201f000), %g1
iop = rtems_libio_iop( fd );
201c9bc: e0 00 61 c4 ld [ %g1 + 0x1c4 ], %l0 ! 201f1c4 <rtems_libio_iops>
201c9c0: 83 2e 20 06 sll %i0, 6, %g1
201c9c4: b1 2e 20 03 sll %i0, 3, %i0
201c9c8: b0 06 00 01 add %i0, %g1, %i0
201c9cc: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open( iop );
201c9d0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
201c9d4: 80 88 61 00 btst 0x100, %g1
201c9d8: 02 80 00 1a be 201ca40 <write+0x9c> <== NEVER TAKEN
201c9dc: 80 a6 60 00 cmp %i1, 0
rtems_libio_check_buffer( buffer );
201c9e0: 02 80 00 24 be 201ca70 <write+0xcc> <== NEVER TAKEN
201c9e4: 80 a6 a0 00 cmp %i2, 0
rtems_libio_check_count( count );
201c9e8: 02 80 00 14 be 201ca38 <write+0x94>
201c9ec: b0 10 20 00 clr %i0
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
201c9f0: 80 88 60 04 btst 4, %g1
201c9f4: 02 80 00 13 be 201ca40 <write+0x9c> <== NEVER TAKEN
201c9f8: 01 00 00 00 nop
/*
* Now process the write() request.
*/
if ( !iop->handlers->write_h )
201c9fc: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
201ca00: c2 00 60 0c ld [ %g1 + 0xc ], %g1
201ca04: 80 a0 60 00 cmp %g1, 0
201ca08: 02 80 00 14 be 201ca58 <write+0xb4> <== NEVER TAKEN
201ca0c: 92 10 00 19 mov %i1, %o1
rtems_set_errno_and_return_minus_one( ENOTSUP );
rc = (*iop->handlers->write_h)( iop, buffer, count );
201ca10: 94 10 00 1a mov %i2, %o2
201ca14: 9f c0 40 00 call %g1
201ca18: 90 10 00 10 mov %l0, %o0
if ( rc > 0 )
201ca1c: b0 92 20 00 orcc %o0, 0, %i0
201ca20: 04 80 00 06 ble 201ca38 <write+0x94> <== NEVER TAKEN
201ca24: 85 3e 20 1f sra %i0, 0x1f, %g2
iop->offset += rc;
201ca28: d8 1c 20 10 ldd [ %l0 + 0x10 ], %o4
201ca2c: 86 83 40 18 addcc %o5, %i0, %g3
201ca30: 84 43 00 02 addx %o4, %g2, %g2
201ca34: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
return rc;
}
201ca38: 81 c7 e0 08 ret
201ca3c: 81 e8 00 00 restore
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_buffer( buffer );
rtems_libio_check_count( count );
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
201ca40: 7f ff d3 ef call 20119fc <__errno> <== NOT EXECUTED
201ca44: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201ca48: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
201ca4c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201ca50: 81 c7 e0 08 ret <== NOT EXECUTED
201ca54: 81 e8 00 00 restore <== NOT EXECUTED
/*
* Now process the write() request.
*/
if ( !iop->handlers->write_h )
rtems_set_errno_and_return_minus_one( ENOTSUP );
201ca58: 7f ff d3 e9 call 20119fc <__errno> <== NOT EXECUTED
201ca5c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201ca60: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
201ca64: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201ca68: 81 c7 e0 08 ret <== NOT EXECUTED
201ca6c: 81 e8 00 00 restore <== NOT EXECUTED
rtems_libio_t *iop;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_buffer( buffer );
201ca70: 7f ff d3 e3 call 20119fc <__errno> <== NOT EXECUTED
201ca74: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
201ca78: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
201ca7c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
201ca80: 81 c7 e0 08 ret <== NOT EXECUTED
201ca84: 81 e8 00 00 restore <== NOT EXECUTED
020073f8 <writev>:
ssize_t writev(
int fd,
const struct iovec *iov,
int iovcnt
)
{
20073f8: 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 );
20073fc: 03 00 80 84 sethi %hi(0x2021000), %g1
2007400: c2 00 63 d4 ld [ %g1 + 0x3d4 ], %g1 ! 20213d4 <rtems_libio_number_iops>
2007404: 80 a6 00 01 cmp %i0, %g1
2007408: 1a 80 00 3e bcc 2007500 <writev+0x108> <== NEVER TAKEN
200740c: 03 00 80 89 sethi %hi(0x2022400), %g1
iop = rtems_libio_iop( fd );
2007410: e6 00 61 b4 ld [ %g1 + 0x1b4 ], %l3 ! 20225b4 <rtems_libio_iops>
2007414: 83 2e 20 06 sll %i0, 6, %g1
2007418: b1 2e 20 03 sll %i0, 3, %i0
200741c: b0 06 00 01 add %i0, %g1, %i0
2007420: a6 04 c0 18 add %l3, %i0, %l3
rtems_libio_check_is_open( iop );
2007424: c2 04 e0 18 ld [ %l3 + 0x18 ], %g1
2007428: 80 88 61 00 btst 0x100, %g1
200742c: 02 80 00 35 be 2007500 <writev+0x108>
2007430: 80 88 60 04 btst 4, %g1
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
2007434: 02 80 00 33 be 2007500 <writev+0x108> <== NEVER TAKEN
2007438: 80 a6 60 00 cmp %i1, 0
/*
* Argument validation on IO vector
*/
if ( !iov )
200743c: 02 80 00 2b be 20074e8 <writev+0xf0>
2007440: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL );
if ( iovcnt <= 0 )
2007444: 04 80 00 29 ble 20074e8 <writev+0xf0>
2007448: 80 a6 a4 00 cmp %i2, 0x400
rtems_set_errno_and_return_minus_one( EINVAL );
if ( iovcnt > IOV_MAX )
200744c: 14 80 00 27 bg 20074e8 <writev+0xf0> <== NEVER TAKEN
2007450: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL );
if ( !iop->handlers->write_h )
2007454: c2 04 e0 40 ld [ %l3 + 0x40 ], %g1
2007458: c2 00 60 0c ld [ %g1 + 0xc ], %g1
200745c: 80 a0 60 00 cmp %g1, 0
2007460: 02 80 00 45 be 2007574 <writev+0x17c> <== NEVER TAKEN
2007464: 9a 10 20 01 mov 1, %o5
rtems_set_errno_and_return_minus_one( ENOTSUP );
2007468: 82 10 00 19 mov %i1, %g1
200746c: 88 10 20 00 clr %g4
2007470: 84 10 20 00 clr %g2
* entering the write loop.
*/
all_zeros = true;
for ( old=0, total=0, v=0 ; v < iovcnt ; v++ ) {
if ( !iov[v].iov_base )
2007474: c6 00 40 00 ld [ %g1 ], %g3
2007478: 80 a0 e0 00 cmp %g3, 0
200747c: 02 80 00 1b be 20074e8 <writev+0xf0>
2007480: 88 01 20 01 inc %g4
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 )
2007484: c6 00 60 04 ld [ %g1 + 4 ], %g3
* 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++ ) {
2007488: 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 )
200748c: 80 a0 00 03 cmp %g0, %g3
2007490: 98 40 3f ff addx %g0, -1, %o4
all_zeros = false;
/* check for wrap */
old = total;
total += iov[v].iov_len;
if ( total < old || total > SSIZE_MAX )
2007494: 86 80 80 03 addcc %g2, %g3, %g3
2007498: 0c 80 00 14 bneg 20074e8 <writev+0xf0>
200749c: 9a 0b 40 0c and %o5, %o4, %o5
20074a0: 80 a0 80 03 cmp %g2, %g3
20074a4: 14 80 00 11 bg 20074e8 <writev+0xf0>
20074a8: 80 a6 80 04 cmp %i2, %g4
* 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++ ) {
20074ac: 34 bf ff f2 bg,a 2007474 <writev+0x7c>
20074b0: 84 10 00 03 mov %g3, %g2
}
/*
* A writev with all zeros is supposed to have no effect per OpenGroup.
*/
if ( all_zeros == true ) {
20074b4: 80 8b 60 ff btst 0xff, %o5
20074b8: a4 10 20 00 clr %l2
20074bc: 12 80 00 09 bne 20074e0 <writev+0xe8>
20074c0: 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 )
20074c4: d4 06 60 04 ld [ %i1 + 4 ], %o2
20074c8: 80 a2 a0 00 cmp %o2, 0
20074cc: 12 80 00 13 bne 2007518 <writev+0x120> <== ALWAYS TAKEN
20074d0: a4 04 a0 01 inc %l2
}
/*
* Now process the writev().
*/
for ( total=0, v=0 ; v < iovcnt ; v++ ) {
20074d4: 80 a6 80 12 cmp %i2, %l2 <== NOT EXECUTED
20074d8: 14 bf ff fb bg 20074c4 <writev+0xcc>
20074dc: b2 06 60 08 add %i1, 8, %i1
if (bytes != iov[ v ].iov_len)
break;
}
return total;
}
20074e0: 81 c7 e0 08 ret
20074e4: 81 e8 00 00 restore
/* check for wrap */
old = total;
total += iov[v].iov_len;
if ( total < old || total > SSIZE_MAX )
rtems_set_errno_and_return_minus_one( EINVAL );
20074e8: 40 00 2d c8 call 2012c08 <__errno>
20074ec: b0 10 3f ff mov -1, %i0
20074f0: 82 10 20 16 mov 0x16, %g1
20074f4: c2 22 00 00 st %g1, [ %o0 ]
20074f8: 81 c7 e0 08 ret
20074fc: 81 e8 00 00 restore
bool all_zeros;
rtems_libio_check_fd( fd );
iop = rtems_libio_iop( fd );
rtems_libio_check_is_open( iop );
rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
2007500: 40 00 2d c2 call 2012c08 <__errno>
2007504: b0 10 3f ff mov -1, %i0
2007508: 82 10 20 09 mov 9, %g1
200750c: c2 22 00 00 st %g1, [ %o0 ]
2007510: 81 c7 e0 08 ret
2007514: 81 e8 00 00 restore
for ( total=0, v=0 ; v < iovcnt ; v++ ) {
/* all zero lengths has no effect */
if ( iov[v].iov_len == 0 )
continue;
bytes = (*iop->handlers->write_h)( iop, iov[v].iov_base, iov[v].iov_len );
2007518: c2 04 e0 40 ld [ %l3 + 0x40 ], %g1
200751c: d2 06 40 00 ld [ %i1 ], %o1
2007520: c2 00 60 0c ld [ %g1 + 0xc ], %g1
2007524: 9f c0 40 00 call %g1
2007528: 90 10 00 13 mov %l3, %o0
if ( bytes < 0 )
200752c: 80 a2 20 00 cmp %o0, 0
2007530: 06 80 00 0f bl 200756c <writev+0x174> <== NEVER TAKEN
2007534: 01 00 00 00 nop
return -1;
if ( bytes > 0 ) {
2007538: 02 80 00 07 be 2007554 <writev+0x15c> <== NEVER TAKEN
200753c: a1 3a 20 1f sra %o0, 0x1f, %l0
iop->offset += bytes;
2007540: c4 1c e0 10 ldd [ %l3 + 0x10 ], %g2
2007544: 86 80 c0 08 addcc %g3, %o0, %g3
total += bytes;
2007548: b0 06 00 08 add %i0, %o0, %i0
if ( bytes < 0 )
return -1;
if ( bytes > 0 ) {
iop->offset += bytes;
200754c: 84 40 80 10 addx %g2, %l0, %g2
2007550: c4 3c e0 10 std %g2, [ %l3 + 0x10 ]
total += bytes;
}
if (bytes != iov[ v ].iov_len)
2007554: c2 06 60 04 ld [ %i1 + 4 ], %g1
2007558: 80 a2 00 01 cmp %o0, %g1
200755c: 02 bf ff df be 20074d8 <writev+0xe0> <== ALWAYS TAKEN
2007560: 80 a6 80 12 cmp %i2, %l2
break;
}
return total;
}
2007564: 81 c7 e0 08 ret <== NOT EXECUTED
2007568: 81 e8 00 00 restore <== NOT EXECUTED
if ( iov[v].iov_len == 0 )
continue;
bytes = (*iop->handlers->write_h)( iop, iov[v].iov_base, iov[v].iov_len );
if ( bytes < 0 )
200756c: 81 c7 e0 08 ret <== NOT EXECUTED
2007570: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
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 );
2007574: 40 00 2d a5 call 2012c08 <__errno> <== NOT EXECUTED
2007578: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
200757c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2007580: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2007584: 81 c7 e0 08 ret <== NOT EXECUTED
2007588: 81 e8 00 00 restore <== NOT EXECUTED